Description
What MCU/Processor/Board and compiler are you using?
NRF5340DK with waveshare_epaper_gdew075t7 E-Ink
What LVGL version are you using?
v8.2.0
What do you want to achieve?
I want to add calendar entries added to the screen with only updating the single entry itself.
But the whole screen goes black-white-black … and updates completely when invoking the lv_task_handler() . It works fine with any other element on the screen.
The base object is the “wallpaper”, on which the object “calendar_window” is used to arrange the calendar entries.
Whats funny is, that the first entry appears correct and only its area of the e-ink is changed. When the second entry is added and lv_task_handler() is called again, the whole screen gets updated. But i cant reproduce this state. Now every entry triggers the whole screen refresh.
What have you tried so far?
I tried to change many style attributes, reduced the size of the appointment entries. And it seems to have an influence, but i dont get the correlation.
Also i deactivated many objects in the background to minimize the error reasons.
Also i tried to initialize the objects once in the beginning and only change the label, but same behaviour.
Code to reproduce
Unfortunately the code is very big, so it cant be reproduced easily.
This is the code, that is called multiple times, once for every entry:
int halign = 60;
int valign = 4 + 35 + (40 * (appstart - 8));
int width = WINDOW_WIDTH - halign - 4 - 20;
int height = 40 * (append - appstart) - 3 - 20;
calendar_appointment_slot[slot] = lv_obj_create(calendar_window);
lv_obj_add_style(calendar_appointment_slot[slot], &style_appointment, 0);
lv_obj_set_size(calendar_appointment_slot[slot], width, height);
lv_obj_align(calendar_appointment_slot[slot], LV_ALIGN_TOP_LEFT, halign, valign);
lv_task_handler();
calendar_appointment_label[slot] = lv_label_create(calendar_appointment_slot[slot]);
lv_label_set_text(calendar_appointment_label[slot], lecture);
lv_obj_align(calendar_appointment_label[slot], LV_ALIGN_CENTER, 0, 0);
lv_task_handler();
Does anyone have an idea what things could cause this behaviour?