Elecrow esp32s3 lvgl screen shifting error and flash data storage while uart0 in use
I am using an elecrow 5" ESP32 display, Arduino IDE to program, lvgl.h 8.3.6, esp32 2.0.3 version for one of my projects.
I've been running into some hurdles with my elecrow 5" ESP32 display project, particularly concerning the user interface (UI) stability. The issues seem to revolve around UART0 usage and data storage using the Preferences library & SPIFFS.
- UART0 Usage:
Using UART0 introduces a noticeable delay in UI screen rendering. This delay leads to a shifting error on the screen, resulting in a less-than-desirable user experience. This delay persists until the UART0 operation is complete, impacting the overall usability of the device.
2. Preferences Library:
I've been utilizing the Preferences library for data storage. However, when writing data to preferences, the UI screen shifts abruptly, disrupting the user experience momentarily until the writing process is complete.
I'm seeking advice and solutions from the community to address these challenges effectively, especially considering the shift from SPIFFS to the Preferences library.
Has anyone encountered similar issues with UART0 and the Preferences library on the ESP32 platform? How did you manage to mitigate them? Any insights, tips, or alternative approaches would be greatly appreciated.
I have attached the zip file of my code images and video too.
My code/zips file along with video and images: https://drive.google.com/drive/folders/1VVY-vayRMkl2C4ID9k9nUXdzeJxrErCy?usp=drive_link
Comments
there might be some following issue and I have been going through each one of them.
1.Some unwanted memory modifications.
2.False LVGL coordinate/colour setting caused by the UART or filesystem
3.ESP32 documentation (espressif-docs) : Why do I get drift (overall drift of the display) when driving an RGB LCD screen? 1
I working on them one by one.
Thank you :
# [SOLVED]
Changes i made are as following :
1.Prefer speed > changed From 16000000 to 9000000
2.-> /* Change to your screen resolution */
static uint32_t screenWidth = 800;
static uint32_t screen height = 480;
Also Keep a minimum delay in the Timer callback function when calling multiple lvgl updates because in some cases Touch input gets delayed but it works fine when adjust the used /required delay to a minimum. I suggest you do not use a delay in your code unless it is must .
I am sharing drive link of my code here working fine → LINK
Thank you