mirror of
https://github.com/esphome/esphome.git
synced 2026-10-09 21:13:12 +00:00
[esp32] Record the PC for cache error and interrupt watchdog crashes (#20415)
This commit is contained in:
@@ -531,6 +531,9 @@ void IRAM_ATTR __wrap_esp_panic_handler(panic_info_t *info) {
|
||||
// Xtensa: walk the backtrace using the public API
|
||||
if (info->frame != nullptr) {
|
||||
auto *xt_frame = (XtExcFrame *) info->frame;
|
||||
// IDF leaves addr unset for SoC-level panics (cache error, interrupt WDT)
|
||||
if (info->pseudo_excause)
|
||||
s_raw_crash_data.pc = xt_frame->pc;
|
||||
if (!g_panic_abort) {
|
||||
// Abort-class frames carry no useful cause/vaddr: TWDT task snapshots
|
||||
// never wrote them and abort() traps describe only the synthetic trap.
|
||||
|
||||
Reference in New Issue
Block a user