lvgl / lv_port_esp32

LVGL ported to ESP32 including various display and touchpad drivers
MIT License
995 stars 427 forks source link

LVGL Lottie plays partially then crashes #344

Open tank104 opened 4 days ago

tank104 commented 4 days ago

Describe the issue Using LVGL Lottie with ESP32-S3 Touch LCD 1.28 plays about 1/4 of lottie and then crashes out without any guru meditation error.

Code to reproduce the issue

static void show_lottie(void) { / Task lock / lvgl_port_lock(0);

extern const uint8_t lv_example_lottie_approve[]; extern const size_t lv_example_lottie_approve_size;

lv_obj_t *lottie = lv_lottie_create(lv_screen_active()); lv_lottie_set_src_data(lottie, lv_example_lottie_approve, lv_example_lottie_approve_size);

static uint8_t buf[64 64 4]; lv_lottie_set_buffer(lottie, 64, 64, buf);

lv_obj_center(lottie);

/* Task unlock */
lvgl_port_unlock();

}

void app_main(void) { ESP_ERROR_CHECK(app_lcd_init()); ESP_ERROR_CHECK(app_lvgl_init());

show_lottie(); }

Expected Results

Lottie animation to play in full.

Actual Results

Lottie animation plays around 1/3 and then crashes with below error

I (31) boot: ESP-IDF v5.2.1-dirty 2nd stage bootloader I (31) boot: compile time Jul 3 2024 09:57:26 I (31) boot: Multicore bootloader I (35) boot: chip revision: v0.2 I (39) boot.esp32s3: Boot SPI Speed : 80MHz I (44) boot.esp32s3: SPI Mode : DIO I (48) boot.esp32s3: SPI Flash Size : 2MB W (53) boot.esp32s3: PRO CPU has been reset by WDT. W (58) boot.esp32s3: APP CPU has been reset by WDT. I (64) boot: Enabling RNG early entropy source... I (70) boot: Partition Table: I (73) boot: ## Label Usage Type ST Offset Length I (80) boot: 0 nvs WiFi data 01 02 00009000 00006000 I (88) boot: 1 phy_init RF data 01 01 0000f000 00001000 I (95) boot: 2 factory factory app 00 00 00010000 00100000 I (103) boot: End of partition table I (107) esp_image: segment 0: paddr=00010020 vaddr=3c0c0020 size=30f88h (200584) map I (152) esp_image: segment 1: paddr=00040fb0 vaddr=3fc95b00 size=02c64h ( 11364) load I (154) esp_image: segment 2: paddr=00043c1c vaddr=40374000 size=0c3fch ( 50172) load I (168) esp_image: segment 3: paddr=00050020 vaddr=42000020 size=b1a2ch (727596) map I (299) esp_image: segment 4: paddr=00101a54 vaddr=403803fc size=05668h ( 22120) load I (311) boot: Loaded app from partition at offset 0x10000 I (312) boot: Disabling RNG early entropy source... I (323) cpu_start: Multicore app I (333) cpu_start: Pro cpu start user code I (333) cpu_start: cpu freq: 160000000 Hz I (333) cpu_start: Application information: I (336) cpu_start: Project name: MataaraHua I (341) cpu_start: App version: 1df29b3-dirty I (347) cpu_start: Compile time: Jul 3 2024 10:17:41 I (353) cpu_start: ELF file SHA256: ab3186b8a... I (358) cpu_start: ESP-IDF: v5.2.1-dirty I (363) cpu_start: Min chip rev: v0.0 I (368) cpu_start: Max chip rev: v0.99 I (373) cpu_start: Chip rev: v0.2 I (378) heap_init: Initializing. RAM available for dynamic allocation: I (385) heap_init: At 3FCAE468 len 0003B2A8 (236 KiB): RAM I (391) heap_init: At 3FCE9710 len 00005724 (21 KiB): RAM I (397) heap_init: At 3FCF0000 len 00008000 (32 KiB): DRAM I (403) heap_init: At 600FE010 len 00001FD8 (7 KiB): RTCRAM I (411) spi_flash: detected chip: winbond I (414) spi_flash: flash io: dio W (418) spi_flash: Detected size(16384k) larger than the size in the binary image header(2048k). Using the size in the binary image header. W (432) i2c: This driver is an old driver, please migrate your application code to adapt driver/i2c_master.h I (442) sleep: Configure to isolate all GPIO pins in sleep state I (449) sleep: Enable automatic switching of GPIO sleep configuration I (456) main_task: Started on CPU0 I (466) main_task: Calling app_main() I (466) example: Create lcd gc9a01 I (466) gpio: GPIO[2]| InputEn: 0| OutputEn: 1| OpenDrain: 0| Pullup: 0| Pulldown: 0| Intr:0 I (476) example: Initialize SPI bus I (486) gpio: GPIO[8]| InputEn: 0| OutputEn: 1| OpenDrain: 0| Pullup: 0| Pulldown: 0| Intr:0 I (486) gpio: GPIO[14]| InputEn: 0| OutputEn: 1| OpenDrain: 0| Pullup: 0| Pulldown: 0| Intr:0 I (496) gc9a01: LCD panel create success, version: 2.0.0 I (626) example: Turn on LCD backlight I (626) example: Create touch controller CST816S I (626) gpio: GPIO[5]| InputEn: 1| OutputEn: 0| OpenDrain: 0| Pullup: 0| Pulldown: 0| Intr:2 I (636) gpio: GPIO[13]| InputEn: 0| OutputEn: 1| OpenDrain: 0| Pullup: 0| Pulldown: 0| Intr:0 I (1036) CST816S: IC id: 181 I (1036) example: LVGL Init I (1036) LVGL: Starting LVGL task I (1116) main_task: Returned from app_main() ESP-ROM:esp32s3-20210327 Build:Mar 27 2021 rst:0x8 (TG1WDT_SYS_RST),boot:0x18 (SPI_FAST_FLASH_BOOT) Saved PC:0x42003727 0x42003727: panic_handler at C:/Users/andre/esp/v5.2.1/esp-idf/components/esp_system/port/panic_handler.c:145

SPIWP:0xee mode:DIO, clock div:1 load:0x3fce3810,len:0x178c load:0x403c9700,len:0x4 load:0x403c9704,len:0xcbc load:0x403cc700,len:0x2da0 entry 0x403c9914

ESP32 Chip version

S3

ESP-IDF version

5.2.1

Development kit used

IDF

Development machine OS

Windows / CS Code

Compilation warnings/errors (if available)

None

tank104 commented 4 days ago

Is it strange I don't get a Guru Meditation error? Really stumped how to debug that error since so little information is given, but I certainly am not an expert on ESP-IDF yet.

Also other LVGL examples work fine - like lv_example_chart_1()

Just not lv_example_lottie_1() (which the code above is a copy of)