[已解决] 看门狗触发后如何重启esp32
Posted: Mon Jul 12, 2021 7:27 am
硬件:ESP32-WROOM-32U 模组
软件:IDF4.3
开发环境:windows10, vs code
问题:
蓝牙和WIFI共存,通过ble或者mqtt收发数据,用WIFI收发数据久了(可能是几个小时,一天或者几天)会导致系统奔溃。系统奔溃时的现象是蓝牙信号找不到,定时任务死掉,只有UART在正常收数据。日志里会打印出看门狗触发,但esp32不会被重启。
日志:
[0;31mE (7175936) task_wdt: Task watchdog got triggered. The following tasks did not reset the watchdog in time:[0m[2021-07-09 10:56:37.891]
[0;31mE (7175936) task_wdt: - IDLE (CPU 0)[0m[2021-07-09 10:56:37.897]
[0;31mE (7175936) task_wdt: Tasks currently running:[0m[2021-07-09 10:56:37.902]
[0;31mE (7175936) task_wdt: CPU 0: wifi[0m[2021-07-09 10:56:37.908]
[0;31mE (7175936) task_wdt: CPU 1: IDLE[0m[2021-07-09 10:56:37.913]
[0;31mE (7175936) task_wdt: Print CPU 0 (current core) backtrace[0m[2021-07-09 10:56:37.918]
[2021-07-09 10:56:37.918]
[2021-07-09 10:56:37.918]
Backtrace:0x4015280F:0x3FFBEA50 0x40082D99:0x3FFBEA70 0x4009CD49:0x3FFE2990 0x4009B77F:0x3FFE29B0 0x40097FE0:0x3FFE29D0 0x4009BBD3:0x3FFE29F0 0x40193093:0x3FFE2A20 0x4019530D:0x3FFE2A40 0x401BC1F2:0x3FFE2A60 0x40099BF6:0x3FFE2A80 0x40094765:0x3FFE2AB0 [2021-07-09 10:56:37.940]
[2021-07-09 10:56:37.940]
[0;31mE (7175936) task_wdt: Print CPU 1 backtrace[0m[2021-07-09 10:56:37.945]
期望:
系统奔溃,看门狗触发时可以重启esp32
软件:IDF4.3
开发环境:windows10, vs code
问题:
蓝牙和WIFI共存,通过ble或者mqtt收发数据,用WIFI收发数据久了(可能是几个小时,一天或者几天)会导致系统奔溃。系统奔溃时的现象是蓝牙信号找不到,定时任务死掉,只有UART在正常收数据。日志里会打印出看门狗触发,但esp32不会被重启。
日志:
[0;31mE (7175936) task_wdt: Task watchdog got triggered. The following tasks did not reset the watchdog in time:[0m[2021-07-09 10:56:37.891]
[0;31mE (7175936) task_wdt: - IDLE (CPU 0)[0m[2021-07-09 10:56:37.897]
[0;31mE (7175936) task_wdt: Tasks currently running:[0m[2021-07-09 10:56:37.902]
[0;31mE (7175936) task_wdt: CPU 0: wifi[0m[2021-07-09 10:56:37.908]
[0;31mE (7175936) task_wdt: CPU 1: IDLE[0m[2021-07-09 10:56:37.913]
[0;31mE (7175936) task_wdt: Print CPU 0 (current core) backtrace[0m[2021-07-09 10:56:37.918]
[2021-07-09 10:56:37.918]
[2021-07-09 10:56:37.918]
Backtrace:0x4015280F:0x3FFBEA50 0x40082D99:0x3FFBEA70 0x4009CD49:0x3FFE2990 0x4009B77F:0x3FFE29B0 0x40097FE0:0x3FFE29D0 0x4009BBD3:0x3FFE29F0 0x40193093:0x3FFE2A20 0x4019530D:0x3FFE2A40 0x401BC1F2:0x3FFE2A60 0x40099BF6:0x3FFE2A80 0x40094765:0x3FFE2AB0 [2021-07-09 10:56:37.940]
[2021-07-09 10:56:37.940]
[0;31mE (7175936) task_wdt: Print CPU 1 backtrace[0m[2021-07-09 10:56:37.945]
期望:
系统奔溃,看门狗触发时可以重启esp32