Commit a9aad1de authored by Daniel DeGrasse's avatar Daniel DeGrasse Committed by Carles Cufi
Browse files

samples: modules: lvgl: enable widgets demo



Enable LVGL widgets demo within Zephyr. This demo requires additional
stack and heap space in order to execute correctly, so raise the stack
and heap size to enable it to run.

Signed-off-by: default avatarDaniel DeGrasse <daniel.degrasse@nxp.com>
parent 78b4735e
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -81,3 +81,10 @@ target_sources_ifdef(CONFIG_LV_USE_DEMO_BENCHMARK app PRIVATE
target_sources_ifdef(CONFIG_LV_USE_DEMO_STRESS app PRIVATE
    ${LVGL_DIR}/demos/stress/lv_demo_stress.c
)

target_sources_ifdef(CONFIG_LV_USE_DEMO_WIDGETS app PRIVATE
    ${LVGL_DIR}/demos/widgets/assets/img_clothes.c
    ${LVGL_DIR}/demos/widgets/assets/img_demo_widgets_avatar.c
    ${LVGL_DIR}/demos/widgets/assets/img_lvgl_logo.c
    ${LVGL_DIR}/demos/widgets/lv_demo_widgets.c
)
+6 −0
Original line number Diff line number Diff line
@@ -25,6 +25,12 @@ config LV_Z_DEMO_STRESS
	help
	  Build stress testing demo application.

config LV_Z_DEMO_WIDGETS
	bool "LVGL widgets demo"
	select LV_USE_DEMO_WIDGETS
	help
	  Build stress testing demo application.

endchoice

source "Kconfig.zephyr"
+2 −2
Original line number Diff line number Diff line
CONFIG_MAIN_STACK_SIZE=2048
CONFIG_MAIN_STACK_SIZE=4096
CONFIG_LOG=y
CONFIG_SHELL=y

CONFIG_LVGL=y
CONFIG_LV_Z_MEM_POOL_SIZE=16384
CONFIG_LV_Z_MEM_POOL_SIZE=49152
CONFIG_LV_Z_SHELL=y
CONFIG_LV_USE_MONKEY=y

+4 −2
Original line number Diff line number Diff line
@@ -29,9 +29,11 @@ int main(void)
	lv_demo_benchmark();
#elif defined(CONFIG_LV_USE_DEMO_STRESS)
	lv_demo_stress();
#elif defined(CONFIG_LV_USE_DEMO_WIDGETS)
	lv_demo_widgets();
#else
#error Enable one of the demos CONFIG_LV_USE_DEMO_MUSIC, CONFIG_LV_USE_DEMO_BENCHMARK \
or CONFIG_LV_USE_DEMO_STRESS.
#error Enable one of the demos CONFIG_LV_USE_DEMO_MUSIC, CONFIG_LV_USE_DEMO_BENCHMARK ,\
	CONFIG_LV_USE_DEMO_STRESS, or CONFIG_LV_USE_DEMO_WIDGETS
#endif

	lv_task_handler();