Skip to content

Commit 2f4541a

Browse files
committed
modules: lvgl: Register print callback after lv_init
Move initialization of the print callback handler after calling lv_init, as the latter zeroes the global callback structure. Signed-off-by: Fabian Blatz <[email protected]> (cherry picked from commit 5cffb8e)
1 parent be6b87c commit 2f4541a

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

modules/lvgl/lvgl.c

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -209,12 +209,18 @@ static int lvgl_init(void)
209209
lvgl_heap_init();
210210
#endif
211211

212+
lv_init();
213+
lv_tick_set_cb(k_uptime_get_32);
214+
212215
#if CONFIG_LV_Z_LOG_LEVEL != 0
213216
lv_log_register_print_cb(lvgl_log);
214217
#endif
215218

219+
<<<<<<< HEAD
216220
lv_init();
217221

222+
=======
223+
>>>>>>> 5cffb8e5a6d (modules: lvgl: Register print callback after lv_init)
218224
#ifdef CONFIG_LV_Z_USE_FILESYSTEM
219225
lvgl_fs_init();
220226
#endif

0 commit comments

Comments
 (0)