SPIFFS EXAMPLE

pepopi
Posts: 32
Joined: Mon Apr 11, 2022 9:45 am

SPIFFS EXAMPLE

Postby pepopi » Thu Jun 08, 2023 10:44 am

Hello everyone,
I am running the spiffs example in two different ESP32. However I get watchdog error. How can I solve it? Thank you.
E (5336) task_wdt: Task watchdog got triggered. The following tasks/users did not reset the watchdog in time:
E (5336) task_wdt: - IDLE (CPU 0)
E (5336) task_wdt: Tasks currently running:
E (5336) task_wdt: CPU 0: main
E (5336) task_wdt: CPU 1: IDLE
E (5336) task_wdt: Print CPU 0 (current core) backtrace


Backtrace: 0x400DDB0B:0x3FFB0CC0 0x400DDC92:0x3FFB0CE0 0x400827A5:0x3FFB0D00 0x40082D7A:0x3FFB46E0 0x40082DC7:0x3FFB4700 0x40082D3B:0x3FFB4720 0x40084991:0x3FFB4740 0x40084C11:0x3FFB4760 0x4008450B:0x3FFB4780 0x400DD376:0x3FFB47C0 0x400D68E9:0x3FFB47F0 0x400DA513:0x3FFB4820 0x400D8133:0x3FFB4850 0x400DA125:0x3FFB48A0 0x400D6FA2:0x3FFB48E0 0x400D64BE:0x3FFB4910 0x400D4015:0x3FFB4930 0x400DE5E6:0x3FFB4950 0x400DE699:0x3FFB4980 0x400D5824:0x3FFB49A0 0x400ECE12:0x3FFB4A80 0x400886D9:0x3FFB4AB0
0x400ddb0b: task_wdt_timeout_handling at C:/Users/Usuario/esp/esp-idf/components/esp_system/task_wdt/task_wdt.c:461 (discriminator 3)

0x400ddc92: task_wdt_isr at C:/Users/Usuario/esp/esp-idf/components/esp_system/task_wdt/task_wdt.c:585

0x400827a5: _xt_lowint1 at C:/Users/Usuario/esp/esp-idf/components/freertos/FreeRTOS-Kernel/portable/xtensa/xtensa_vectors.S:1118

0x40082d7a: esp_timer_impl_get_counter_reg at C:/Users/Usuario/esp/esp-idf/components/esp_timer/src/esp_timer_impl_lac.c:111

0x40082dc7: esp_timer_impl_get_time at C:/Users/Usuario/esp/esp-idf/components/esp_timer/src/esp_timer_impl_lac.c:141

0x40082d3b: esp_system_get_time at C:/Users/Usuario/esp/esp-idf/components/esp_timer/src/system_time.c:53

0x40084991: on_spi1_released at C:/Users/Usuario/esp/esp-idf/components/spi_flash/spi_flash_os_func_app.c:352
(inlined by) spi1_end at C:/Users/Usuario/esp/esp-idf/components/spi_flash/spi_flash_os_func_app.c:115

0x40084c11: spiflash_end_default at C:/Users/Usuario/esp/esp-idf/components/spi_flash/esp_flash_api.c:138

0x4008450b: esp_flash_read at C:/Users/Usuario/esp/esp-idf/components/spi_flash/esp_flash_api.c:849

0x400dd376: esp_partition_read at C:/Users/Usuario/esp/esp-idf/components/esp_partition/partition_target.c:38

0x400d68e9: spiffs_api_read at C:/Users/Usuario/esp/esp-idf/components/spiffs/spiffs_api.c:28

0x400da513: spiffs_phys_rd at C:/Users/Usuario/esp/esp-idf/components/spiffs/spiffs/src/spiffs_cache.c:161

0x400d8133: spiffs_obj_lu_find_entry_visitor at C:/Users/Usuario/esp/esp-idf/components/spiffs/spiffs/src/spiffs_nucleus.c:166

0x400da125: spiffs_obj_lu_find_free_obj_id at C:/Users/Usuario/esp/esp-idf/components/spiffs/spiffs/src/spiffs_nucleus.c:2164

0x400d6fa2: SPIFFS_open at C:/Users/Usuario/esp/esp-idf/components/spiffs/spiffs/src/spiffs_hydrogen.c:250

0x400d64be: vfs_spiffs_open at C:/Users/Usuario/esp/esp-idf/components/spiffs/esp_spiffs.c:531

0x400d4015: esp_vfs_open at C:/Users/Usuario/esp/esp-idf/components/vfs/vfs.c:404 (discriminator 3)

0x400de5e6: _fopen_r at /builds/idf/crosstool-NG/.build/HOST-x86_64-w64-mingw32/xtensa-esp32-elf/src/newlib/newlib/libc/stdio/fopen.c:129

0x400de699: fopen at /builds/idf/crosstool-NG/.build/HOST-x86_64-w64-mingw32/xtensa-esp32-elf/src/newlib/newlib/libc/stdio/fopen.c:168

0x400d5824: app_main at C:/Users/Usuario/Desktop/spiffs/main/spiffs_example_main.c:84 (discriminator 13)

0x400ece12: main_task at C:/Users/Usuario/esp/esp-idf/components/freertos/FreeRTOS-Kernel/portable/port_common.c:131 (discriminator 2)

0x400886d9: vPortTaskWrapper at C:/Users/Usuario/esp/esp-idf/components/freertos/FreeRTOS-Kernel/portable/xtensa/port.c:154


I (5456) example: File written
I (5456) example: Renaming file
I (5516) example: Reading file
I (5516) example: Read from file: 'Hello World!'
I (5516) example: SPIFFS unmounted

MicroController
Posts: 1729
Joined: Mon Oct 17, 2022 7:38 pm
Location: Europe, Germany

Re: SPIFFS EXAMPLE

Postby MicroController » Thu Jun 08, 2023 11:23 am

What's the log output before

Code: Select all

E (5336) task_wdt: Task watchdog got triggered. The following tasks/users did not reset the watchdog in time:
?
It looks like the program/CPU 0 is busy doing something for about 5s before even the first write to the file. Is it formatting the SPIFFS partition?

Easiest fix may be to change the WDT configuration.

Who is online

Users browsing this forum: Baidu [Spider] and 122 guests