esp-idf: Task watchdog got triggered in BLE functions (IDFGH-2271)
Recently I have started experimenting with NimBLE and in after some time I started to get these errors:
E (233591) task_wdt: Task watchdog got triggered. The following tasks did not reset the watchdog in time:
E (233591) task_wdt: - IDLE0 (CPU 0)
E (233591) task_wdt: Tasks currently running:
E (233591) task_wdt: CPU 0: ble
E (233591) task_wdt: CPU 1: IDLE1
I made some research and found out that this error potentionally could be fixed by putting vTaskDelay
in these functions:
nimble_port_run
ble_ll_task
I’m not sure that’s the right way to fix the problem so please let me know if there is more information needed. The problem occures on master
branch, and I have not checked older branches.
E (31838) task_wdt: Task watchdog got triggered. The following tasks did not reset the watchdog in time:
E (31838) task_wdt: - IDLE0 (CPU 0)
E (31838) task_wdt: Tasks currently running:
E (31838) task_wdt: CPU 0: ble
E (31838) task_wdt: CPU 1: IDLE1
E (31838) task_wdt: Aborting.
abort() was called at PC 0x400d2a4f on core 0
0x400d2a4f: task_wdt_isr at /home/ildus/dev/esp-idf/components/esp32/task_wdt.c:174 (discriminator 1)
ELF file SHA256: f44515713f51fd804b7e83af6ede154af92a1a878348499d29c57e90fad272ce
Backtrace: 0x4008e7ad:0x3ffbe360 0x4008eb35:0x3ffbe380 0x400d2a4f:0x3ffbe3a0 0x40082aad:0x3ffbe3c0 0x4000bfed:0x3ffc7730 |<-CORRUPTED
0x4008e7ad: invoke_abort at /home/ildus/dev/esp-idf/components/esp32/panic.c:157
0x4008eb35: abort at /home/ildus/dev/esp-idf/components/esp32/panic.c:174
0x400d2a4f: task_wdt_isr at /home/ildus/dev/esp-idf/components/esp32/task_wdt.c:174 (discriminator 1)
0x40082aad: _xt_lowint1 at /home/ildus/dev/esp-idf/components/freertos/xtensa_vectors.S:1153
This happens on ESP-WROOM-32 on bleprph
example.
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Comments: 27 (10 by maintainers)
Commits related to this issue
- NimBLE: Include upstream fixes and use macros for log level filtering (backport v3.3) Change list: - Reduces the size of the compiled binary, PR: https://github.com/espressif/esp-nimble/pull/6 - Null... — committed to mahavirj/esp-afr-sdk by prasad-alatkar 4 years ago
- NimBLE: Include upstream fixes and use macros for log level filtering (backport v4.0) Change list: - Reduces the size of the compiled binary, PR: https://github.com/espressif/esp-nimble/pull/6 - Null... — committed to espressif/esp-idf by prasad-alatkar 4 years ago
- NimBLE: Include upstream fixes and use macros for log level filtering (backport v4.1) Change list: - Reduces the size of the compiled binary, PR: https://github.com/espressif/esp-nimble/pull/6 - Null... — committed to espressif/esp-idf by prasad-alatkar 4 years ago
- NimBLE: Include upstream fixes and use macros for log level filtering (backport v4.1) Change list: - Reduces the size of the compiled binary, PR: https://github.com/espressif/esp-nimble/pull/6 - Null... — committed to Wielebny666/esp-idf by prasad-alatkar 4 years ago
Thanks @prasad-alatkar. Sadly I was unable to reproduce the issue before and after the patch. I updated the ESP-IDF to v:latest, no issue there. @albertmbt, do you have time to look into this?
I keep trying and get back to this when I know more.
Hi @Unsigus Thank you for reporting this issue, I am attaching a temporary patch here to be applied at
$IDF_PATH/components/bt/host/nimble/nimble
. Could you please test and let me know if it resolves your issue ? patch: NimBLE_CCCD_overflow_loop_fix.zipHere you go
@albertmbt @Unsigus, @prasad-alatkar is looking into this and will update after there is progress. Thanks!