Im currently using an ESP32-WROOM-32D with CAN and a webserver that serves a webpage for uploading .bin-files for OTA update.
I observed that when there is data traffic on the CAN bus and I am doing a OTA update, the ESP crashes at the erase flash stage during update process.
This is the error log:
Code: Select all
Guru Meditation Error: Core 0 panic'ed (Interrupt wdt timeout on CPU0)
Core 0 register dump:
PC : 0x400907f1 PS : 0x00060034 A0 : 0x800fd394 A1 : 0x3ffbe570
0x400907f1: portENTER_CRITICAL_NESTED at /home/michael/20190206/esp-idf/components/freertos/tasks.c:3537
(inlined by) vTaskEnterCritical at /home/michael/20190206/esp-idf/components/freertos/tasks.c:4226
A2 : 0x3ffbef98 A3 : 0x3ffbe594 A4 : 0x00000000 A5 : 0x00000040
A6 : 0x00000008 A7 : 0x00000000 A8 : 0x3ffc13fc A9 : 0x3ffbe560
A10 : 0x00000003 A11 : 0x00060023 A12 : 0x00060021 A13 : 0x00000001
A14 : 0x00060021 A15 : 0x00000000 SAR : 0x00000018 EXCCAUSE: 0x00000005
EXCVADDR: 0x00000000 LBEG : 0x00000000 LEND : 0x00000000 LCOUNT : 0x00000000
Core 0 was running in ISR context:
EPC1 : 0x40081fe9 EPC2 : 0x00000000 EPC3 : 0x00000000 EPC4 : 0x400907f1
0x40081fe9: esp_intr_noniram_enable at /home/michael/20190206/esp-idf/src/actia/factory-app/components/esp32/intr_alloc.c:883
0x400907f1: portENTER_CRITICAL_NESTED at /home/michael/20190206/esp-idf/components/freertos/tasks.c:3537
(inlined by) vTaskEnterCritical at /home/michael/20190206/esp-idf/components/freertos/tasks.c:4226
Backtrace: 0x400907f1:0x3ffbe570 0x400fd391:0x3ffbe590 0x40082411:0x3ffbe5c0 0x40081fe6:0x3ffb0180 0x40082e0b:0x3ffb01a0 0x4008204f:0x3ffb01c0 0x4008ff96:0x3ffb01e0
0x400907f1: portENTER_CRITICAL_NESTED at /home/michael/20190206/esp-idf/components/freertos/tasks.c:3537
(inlined by) vTaskEnterCritical at /home/michael/20190206/esp-idf/components/freertos/tasks.c:4226
0x400fd391: can_intr_handler_main at /home/michael/20190206/esp-idf/components/driver/can.c:869
CAN ISR. In my update_handler I called can_stop() and then can_driver_uninstall() before starting the update.
Then I was able to complete the update. However when Im navigating to another site and start the CAN controller again (with can_driver_install() and can_start() a lot of negative side effects are occuring.
This is my log:
Code: Select all
E (108855) emac: Initialise PHY device Timeout
E (109855) emac: Timed out waiting for PHY register 0x2 to have value 0x0007(mask 0xffff). Current value 0x0000
E (110855) emac: Timed out waiting for PHY register 0x3 to have value 0xc0f0(mask 0xfff0). Current value 0x0000
E (110855) emac: Initialise PHY device Timeout
E (110855) uart: uart_flush_input(1255): uart driver error
E (110865) uart: uart_write_bytes(1152): uart driver error
E (110865) uart: uart_read_bytes(1187): uart driver error
E (110965) esp_ota_ops: ota data invalid, no current app. Assuming factory
W (111845) httpd_txrx: httpd_sock_err: error in send : 104
What could be the reason that my internal interfaces are crashing after deactivating and reactivating CAN after doing an update (erasing and writing to flash) ?
I'll appreciate any help,
Thanks for the support.