From 66fe185bfe339f406c4662911156c616eece9915 Mon Sep 17 00:00:00 2001 From: hans boot Date: Thu, 11 Apr 2024 08:14:01 +0200 Subject: [PATCH 1/2] Allow LV_MEM_CUSTOM override --- include/lv_conf_v7.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/lv_conf_v7.h b/include/lv_conf_v7.h index e2adf67e..764be7bd 100644 --- a/include/lv_conf_v7.h +++ b/include/lv_conf_v7.h @@ -80,8 +80,10 @@ typedef int16_t lv_coord_t; #define LV_FS_SEEK(x, y) lv_fs_seek(x, y) #define _lv_img_decoder_t _lv_img_decoder +#ifndef LV_MEM_CUSTOM /* 1: use custom malloc/free, 0: use the built-in `lv_mem_alloc` and `lv_mem_free` */ #define LV_MEM_CUSTOM 0 +#endif #if LV_MEM_CUSTOM == 0 /* Size of the memory used by `lv_mem_alloc` in bytes (>= 2kB)*/ From 99d9a0668e3b2fa816822a3a27e50d5a897c3f42 Mon Sep 17 00:00:00 2001 From: hans boot Date: Thu, 11 Apr 2024 08:22:17 +0200 Subject: [PATCH 2/2] Allow LV_MEM_CUSTOM override also in v8 --- include/lv_conf_v8.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/lv_conf_v8.h b/include/lv_conf_v8.h index 4cb1442c..494982d7 100644 --- a/include/lv_conf_v8.h +++ b/include/lv_conf_v8.h @@ -86,8 +86,10 @@ typedef int16_t lv_coord_t; /* LittelvGL's internal memory manager's settings. * The graphical objects and other related data are stored here. */ +#ifndef LV_MEM_CUSTOM /* 1: use custom malloc/free, 0: use the built-in `lv_mem_alloc` and `lv_mem_free` */ #define LV_MEM_CUSTOM 0 +#endif #if LV_MEM_CUSTOM == 0 /* Size of the memory used by `lv_mem_alloc` in bytes (>= 2kB)*/ //# define LV_MEM_SIZE (32U * 1024U)