From 64bd9053a25297f7a442ca831c7da5b44bd33f84 Mon Sep 17 00:00:00 2001 From: jacqueline Date: Wed, 12 Jun 2024 17:54:40 +1000 Subject: Update LVGL to v9.1.0 --- .../stdlib/micropython/lv_mem_core_micropython.c | 95 ++++++++++++++++++++++ 1 file changed, 95 insertions(+) create mode 100644 lib/lvgl/src/stdlib/micropython/lv_mem_core_micropython.c (limited to 'lib/lvgl/src/stdlib/micropython') diff --git a/lib/lvgl/src/stdlib/micropython/lv_mem_core_micropython.c b/lib/lvgl/src/stdlib/micropython/lv_mem_core_micropython.c new file mode 100644 index 00000000..69c8bd68 --- /dev/null +++ b/lib/lvgl/src/stdlib/micropython/lv_mem_core_micropython.c @@ -0,0 +1,95 @@ +/** + * @file lv_malloc_core.c + */ + +/********************* + * INCLUDES + *********************/ +#include "../lv_mem.h" +#if LV_USE_STDLIB_MALLOC == LV_STDLIB_MICROPYTHON +#include "../../stdlib/lv_mem.h" +#include "include/lv_mp_mem_custom_include.h" + +/********************* + * DEFINES + *********************/ + +/********************** + * TYPEDEFS + **********************/ + +/********************** + * STATIC PROTOTYPES + **********************/ + +/********************** + * STATIC VARIABLES + **********************/ + +/********************** + * MACROS + **********************/ + +/********************** + * GLOBAL FUNCTIONS + **********************/ + +void lv_mem_init(void) +{ + return; /*Nothing to init*/ +} + +void lv_mem_deinit(void) +{ + return; /*Nothing to deinit*/ + +} + +lv_mem_pool_t lv_mem_add_pool(void * mem, size_t bytes) +{ + /*Not supported*/ + LV_UNUSED(mem); + LV_UNUSED(bytes); + return NULL; +} + +void lv_mem_remove_pool(lv_mem_pool_t pool) +{ + /*Not supported*/ + LV_UNUSED(pool); + return; +} + +void * lv_malloc_core(size_t size) +{ + return m_malloc(size); +} + +void * lv_realloc_core(void * p, size_t new_size) +{ + return m_realloc(p, new_size); +} + +void lv_free_core(void * p) +{ + m_free(p); +} + +void lv_mem_monitor_core(lv_mem_monitor_t * mon_p) +{ + /*Not supported*/ + LV_UNUSED(mon_p); + return; +} + +lv_result_t lv_mem_test_core(void) +{ + /*Not supported*/ + return LV_RESULT_OK; +} + +/********************** + * STATIC FUNCTIONS + **********************/ + +#endif /*LV_STDLIB_MICROPYTHON*/ -- cgit v1.2.3