1# Copyright (c) 2023 Fabian Blatz <fabianblatz@gmail.com> 2# Copyright 2023 NXP 3# SPDX-License-Identifier: Apache-2.0 4 5config ZEPHYR_LVGL_MODULE 6 bool 7 8config LVGL 9 bool "LVGL support" 10 help 11 This option enables the LVGL graphics library. 12 13if LVGL 14 15config LV_USE_MONKEY 16 bool 17 18config LV_DPI_DEF 19 int 20 21config LV_CONF_SKIP 22 bool 23 default n 24 25config LV_USE_PRIVATE_API 26 bool 27 28config LV_USE_LOG 29 bool 30 31config LV_LOG_LEVEL_NONE 32 bool 33 34config LV_LOG_LEVEL_ERROR 35 bool 36 37config LV_LOG_LEVEL_WARN 38 bool 39 40config LV_LOG_LEVEL_INFO 41 bool 42 43config LV_LOG_LEVEL_USER 44 bool 45 46config LV_LOG_LEVEL_TRACE 47 bool 48 49config LV_Z_LOG_LEVEL 50 int 51 default 0 if LV_LOG_LEVEL_NONE || !LV_USE_LOG 52 default 1 if LV_LOG_LEVEL_ERROR 53 default 2 if LV_LOG_LEVEL_WARN 54 default 3 if LV_LOG_LEVEL_INFO 55 default 3 if LV_LOG_LEVEL_USER 56 default 4 if LV_LOG_LEVEL_TRACE 57 58config LV_Z_USE_ROUNDER_CB 59 bool 60 default y if LV_Z_AREA_X_ALIGNMENT_WIDTH != 1 || LV_Z_AREA_Y_ALIGNMENT_WIDTH != 1 61 62config APP_LINK_WITH_LVGL 63 bool "Link 'app' with LVGL" 64 default y 65 help 66 Add LVGL header files to the 'app' include path. It may be 67 disabled if the include paths for LVGL are causing aliasing 68 issues for 'app'. 69 70config LV_Z_USE_FILESYSTEM 71 bool "LVGL file system support" 72 depends on FILE_SYSTEM 73 default y if FILE_SYSTEM 74 help 75 Enable LittlevGL file system 76 77choice LV_COLOR_DEPTH 78 default LV_COLOR_DEPTH_16 79 prompt "Color depth (bits per pixel)" 80 81 config LV_COLOR_DEPTH_32 82 bool "32: ARGB8888" 83 config LV_COLOR_DEPTH_24 84 bool "24: RGB888" 85 config LV_COLOR_DEPTH_16 86 bool "16: RGB565" 87 config LV_COLOR_DEPTH_8 88 bool "8: RGB232" 89 config LV_COLOR_DEPTH_1 90 bool "1: monochrome" 91endchoice 92 93config LV_COLOR_16_SWAP 94 bool "Swap the 2 bytes of RGB565 color." 95 depends on LV_COLOR_DEPTH_16 96 97config LV_Z_COLOR_MONO_HW_INVERSION 98 bool "Hardware pixel inversion (disables software pixel inversion)." 99 depends on LV_COLOR_DEPTH_1 100 101config LV_Z_COLOR_24_BGR_TO_RGB 102 bool "Convert BGR888 to RGB888 color before flushing" 103 default y 104 depends on LV_COLOR_DEPTH_24 105 106config LV_Z_FLUSH_THREAD 107 bool "Flush LVGL frames in a separate thread" 108 help 109 Flush LVGL frames in a separate thread, while the primary thread 110 renders the next LVGL frame. Can be disabled if the performance 111 gain this approach offers is not required 112 113if LV_Z_FLUSH_THREAD 114 115config LV_Z_FLUSH_THREAD_STACK_SIZE 116 int "Stack size for flushing thread" 117 default 1024 118 help 119 Stack size for LVGL flush thread, which will call display_write 120 121config LV_Z_FLUSH_THREAD_PRIORITY 122 int "LVGL flush thread priority" 123 default -1 124 help 125 Priority of LVGL flush thread. 126 127endif # LV_Z_FLUSH_THREAD 128 129config LV_Z_AREA_X_ALIGNMENT_WIDTH 130 int "Frame X alignment size" 131 default 1 132 help 133 Number of pixels, X axis should be rounded to. Should be used to override 134 the current frame dimensions to meet display and/or LCD host 135 controller requirements. The value must be power of 2. 136 137config LV_Z_AREA_Y_ALIGNMENT_WIDTH 138 int "Frame Y alignment size" 139 default 1 140 help 141 Number of pixels, Y axis should be rounded to. Should be used to override 142 the current frame dimensions to meet display and/or LCD host 143 controller requirements. The value must be power of 2. 144 145config LV_Z_AUTO_INIT 146 bool "Initialize LVGL before application startup" 147 default y 148 help 149 Configure LVGL callbacks and display initialization before the application starts. 150 This can be useful to disable if you need to change a display's pixel format 151 prior to initialization. If using static allocation, ensure that LV_Z_BITS_PER_PIXEL 152 is set correctly. 153 154config LV_Z_INIT_PRIORITY 155 int "Default init priority for LVGL" 156 default 90 157 depends on LV_Z_AUTO_INIT 158 help 159 Priority used for the automatic initialization of LVGL. 160 161config LV_Z_LVGL_MUTEX 162 bool "Provide LVGL API mutex (un)locking functions" 163 help 164 LVGL API functions are not thread-safe, provide functions for locking and unlocking. 165 166config LV_Z_RUN_LVGL_ON_WORKQUEUE 167 bool "Use a dedicated workqueue to run LVGL core" 168 imply LV_Z_AUTO_INIT 169 imply LV_Z_LVGL_MUTEX 170 help 171 Runs the LVGL in a separate workqueue automatically 172 without requiring user to add a timed loop for that. User can 173 disable this option if periodic calls of LV timer 174 is application responsibillity 175 176if LV_Z_RUN_LVGL_ON_WORKQUEUE 177 178config LV_Z_LVGL_WORKQUEUE_STACK_SIZE 179 int "Stack size of LVGL workqueue" 180 default 4096 181 help 182 Stack size of the LVGL dedicated workqueue 183 184config LV_Z_LVGL_WORKQUEUE_PRIORITY 185 int "Priority of the LVGL workqueue" 186 default 0 187 help 188 Priority of the LVGL dedicated workequeue. 189 190endif # LV_Z_RUN_LVGL_ON_WORKQUEUE 191 192config LV_USE_DRAW_DMA2D 193 bool 194 195config LV_DRAW_DMA2D_HAL_INCLUDE 196 string 197 help 198 Must be defined to include path of CMSIS header of target processor 199 e.g. "stm32f769xx.h" or "stm32f429xx.h" 200 201config LV_Z_USE_OSAL 202 bool "Use OSAL enabling parallel rendering" 203 depends on DYNAMIC_THREAD 204 select LV_USE_PRIVATE_API 205 help 206 Use the Zephyr LVGL OSAL to enable parallel rendering 207 pipelines. 208 209config LV_USE_PXP 210 bool 211 212config LV_USE_GPU_NXP_PXP 213 bool 214 default y if LV_USE_PXP 215 216config LV_Z_PXP_INTERRUPT_PRIORITY 217 int "PXP interrupt priority" 218 depends on LV_USE_PXP 219 default 3 220 help 221 Sets the interrupt priority for PXP 222 223rsource "Kconfig.memory" 224rsource "Kconfig.input" 225rsource "Kconfig.shell" 226 227 228endif 229