aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorPeter Johanson <[email protected]>2024-02-05 13:12:18 -0800
committerPete Johanson <[email protected]>2024-02-09 14:32:46 -0800
commit4bcecd98f8b2d0870d6c1e904b5a38cb9c7eb5b8 (patch)
tree0fa99f9d81a993f190e65cc6f2f3b18940112a3e
parent2d6c9f797c7eb3a0eef26833303ecf1565e0bde2 (diff)
downloadzmk-4bcecd98f8b2d0870d6c1e904b5a38cb9c7eb5b8.tar.gz
zmk-4bcecd98f8b2d0870d6c1e904b5a38cb9c7eb5b8.zip
fix(display): Tweaks to memory Kconfig settings.
* Don't default heap mempool by default now that there's a dedicated LVGL mempool * Set proper defaults for CiZ display hardware/custom screen. * Double the dedicated display thread stack size for CiZ.
-rw-r--r--app/Kconfig3
-rw-r--r--app/boards/arm/corneish_zen/Kconfig.defconfig7
-rw-r--r--app/boards/arm/corneish_zen/corneish_zen_v1_left_defconfig2
-rw-r--r--app/boards/arm/corneish_zen/corneish_zen_v1_right_defconfig2
-rw-r--r--app/boards/arm/corneish_zen/corneish_zen_v2_left_defconfig2
-rw-r--r--app/boards/arm/corneish_zen/corneish_zen_v2_right_defconfig2
-rw-r--r--app/module/drivers/display/il0323.c1
7 files changed, 12 insertions, 7 deletions
diff --git a/app/Kconfig b/app/Kconfig
index f9192da4a5..14456b5fe8 100644
--- a/app/Kconfig
+++ b/app/Kconfig
@@ -599,9 +599,6 @@ endmenu
#ZMK
endmenu
-config HEAP_MEM_POOL_SIZE
- default 8192 if ZMK_DISPLAY
-
config KERNEL_BIN_NAME
default "zmk"
diff --git a/app/boards/arm/corneish_zen/Kconfig.defconfig b/app/boards/arm/corneish_zen/Kconfig.defconfig
index f3cc959edd..11f932b530 100644
--- a/app/boards/arm/corneish_zen/Kconfig.defconfig
+++ b/app/boards/arm/corneish_zen/Kconfig.defconfig
@@ -57,6 +57,13 @@ config IL0323
config ZMK_DISPLAY_BLANK_ON_IDLE
default n
+# Needed for the IL0323 driver which allocs memory to clear the display
+config HEAP_MEM_POOL_SIZE
+ default 1024
+
+ config LV_Z_MEM_POOL_SIZE
+ default 4096
+
endif # ZMK_DISPLAY
menuconfig CUSTOM_WIDGET_BATTERY_STATUS
diff --git a/app/boards/arm/corneish_zen/corneish_zen_v1_left_defconfig b/app/boards/arm/corneish_zen/corneish_zen_v1_left_defconfig
index d738255601..d4de8ed3ca 100644
--- a/app/boards/arm/corneish_zen/corneish_zen_v1_left_defconfig
+++ b/app/boards/arm/corneish_zen/corneish_zen_v1_left_defconfig
@@ -44,7 +44,7 @@ CONFIG_ZMK_BLE=y
# enable display drivers
CONFIG_ZMK_DISPLAY_WORK_QUEUE_DEDICATED=y
-CONFIG_ZMK_DISPLAY_DEDICATED_THREAD_STACK_SIZE=2048
+CONFIG_ZMK_DISPLAY_DEDICATED_THREAD_STACK_SIZE=4096
CONFIG_LV_Z_BITS_PER_PIXEL=1
CONFIG_LV_COLOR_DEPTH_1=y
CONFIG_LV_DPI_DEF=145
diff --git a/app/boards/arm/corneish_zen/corneish_zen_v1_right_defconfig b/app/boards/arm/corneish_zen/corneish_zen_v1_right_defconfig
index d89377bc40..ad78217f65 100644
--- a/app/boards/arm/corneish_zen/corneish_zen_v1_right_defconfig
+++ b/app/boards/arm/corneish_zen/corneish_zen_v1_right_defconfig
@@ -44,7 +44,7 @@ CONFIG_ZMK_BLE=y
# enable display drivers
CONFIG_ZMK_DISPLAY_WORK_QUEUE_DEDICATED=y
-CONFIG_ZMK_DISPLAY_DEDICATED_THREAD_STACK_SIZE=2048
+CONFIG_ZMK_DISPLAY_DEDICATED_THREAD_STACK_SIZE=4096
CONFIG_LV_Z_BITS_PER_PIXEL=1
CONFIG_LV_COLOR_DEPTH_1=y
CONFIG_LV_DPI_DEF=145
diff --git a/app/boards/arm/corneish_zen/corneish_zen_v2_left_defconfig b/app/boards/arm/corneish_zen/corneish_zen_v2_left_defconfig
index 29a5f878ac..b6670fd8df 100644
--- a/app/boards/arm/corneish_zen/corneish_zen_v2_left_defconfig
+++ b/app/boards/arm/corneish_zen/corneish_zen_v2_left_defconfig
@@ -40,7 +40,7 @@ CONFIG_ZMK_BLE=y
# enable display drivers
CONFIG_ZMK_DISPLAY_WORK_QUEUE_DEDICATED=y
-CONFIG_ZMK_DISPLAY_DEDICATED_THREAD_STACK_SIZE=2048
+CONFIG_ZMK_DISPLAY_DEDICATED_THREAD_STACK_SIZE=4096
CONFIG_LV_Z_BITS_PER_PIXEL=1
CONFIG_LV_COLOR_DEPTH_1=y
CONFIG_LV_DPI_DEF=145
diff --git a/app/boards/arm/corneish_zen/corneish_zen_v2_right_defconfig b/app/boards/arm/corneish_zen/corneish_zen_v2_right_defconfig
index 83dc57d4dd..90cfe7698d 100644
--- a/app/boards/arm/corneish_zen/corneish_zen_v2_right_defconfig
+++ b/app/boards/arm/corneish_zen/corneish_zen_v2_right_defconfig
@@ -40,7 +40,7 @@ CONFIG_ZMK_BLE=y
# enable display drivers
CONFIG_ZMK_DISPLAY_WORK_QUEUE_DEDICATED=y
-CONFIG_ZMK_DISPLAY_DEDICATED_THREAD_STACK_SIZE=2048
+CONFIG_ZMK_DISPLAY_DEDICATED_THREAD_STACK_SIZE=4096
CONFIG_LV_Z_BITS_PER_PIXEL=1
CONFIG_LV_COLOR_DEPTH_1=y
CONFIG_LV_DPI_DEF=145
diff --git a/app/module/drivers/display/il0323.c b/app/module/drivers/display/il0323.c
index 372897aa23..c9d72fc529 100644
--- a/app/module/drivers/display/il0323.c
+++ b/app/module/drivers/display/il0323.c
@@ -177,6 +177,7 @@ static int il0323_clear_and_write_buffer(const struct device *dev, uint8_t patte
line = k_malloc(IL0323_NUMOF_PAGES);
if (line == NULL) {
+ LOG_ERR("Failed to allocate memory for the clear");
return -ENOMEM;
}