I am working on ESP WRover-IB controller, where I have implemented the earth detection via External Interrupt on GPIO.
Now the logic is that, There is a timer that is running to overflow in 2 second. But External Interrupt will keep clearing the counter of timer.
Once the mains get off, the timer will overflow and generate an Interrupt.
In interrupt, I am trying to Backup some data into the flash But during saving data controller get reset and the reason is "Guru Meditation Error: Core 0 panic'ed (Interrupt wdt timeout on CPU0)."
I am sharing the code also, Please Suggest me how to resolve this issue.
void IRAM_ATTR Power_Watchdog_Timer_ISR() {
/*BEGIN CODE: On Earthing Falure*/
if(Chrg_Gun1.Transaction_Id != 0){
esp_task_wdt_reset();
rtc_wdt_feed();
TIMERG1.wdt_feed = 1;
TIMERG0.wdt_feed = 1;
noInterrupts();
/*INFO: Stopping Code Watch Dog*/
TIMERG1.wdt_wprotect = TIMG_WDT_WKEY_VALUE;
TIMERG1.wdt_feed = 1;
TIMERG1.wdt_config0.en = 0;
TIMERG1.wdt_wprotect = 0;
digitalWrite(GPIO_RELAY,LOW);
timerAlarmDisable(Power_Timer);
TIMERG1.wdt_feed = 1;
TIMERG0.wdt_feed = 1;
EEPROM_Write_Byte(KEY_TIMESTAMP_HR,rHour);
EEPROM_Write_Byte(KEY_TIMESTAMP_MIN,rMinute);
EEPROM_Write_Byte(KEY_TIMESTAMP_SEC,rSecond);
TIMERG1.wdt_feed = 1;
TIMERG0.wdt_feed = 1;
EEPROM_Write_Byte(KEY_TIMESTAMP_DAY,rDay);
EEPROM_Write_Byte(KEY_TIMESTAMP_MON,rMonth);
EEPROM_Write_Uint16(KEY_TIMESTAMP_YEAR,rYear);
TIMERG1.wdt_feed = 1;
TIMERG0.wdt_feed = 1;
EEPROM_Write_Uint32(KEY_METERVALUE,(uint32_t)Chrg_Gun1.Meter_Now);
EEPROM_Write_Uint32(KEY_ISAVAILABLE,1);
interrupts();
}
Guru Meditation Error: Core 1 panic'ed (Interrupt wdt timeout on CPU1).
Core 1 register dump:
PC : 0x4008a0dc PS : 0x00060435 A0 : 0x80089352 A1 : 0x3ffbed1c
A2 : 0x3ffb8a00 A3 : 0x3ffb8890 A4 : 0x00000004 A5 : 0x00060423
A6 : 0x00060423 A7 : 0x00000001 A8 : 0x3ffb8890 A9 : 0x00000018
A10 : 0x3ffb8890 A11 : 0x00000018 A12 : 0x3ffc1804 A13 : 0x00060423
A14 : 0x007bee78 A15 : 0x003fffff SAR : 0x0000000a EXCCAUSE: 0x00000006
EXCVADDR: 0x00000000 LBEG : 0x40085fb5 LEND : 0x40085fc5 LCOUNT : 0xffffffff
Core 1 was running in ISR context:
EPC1 : 0x400d8e2f EPC2 : 0x00000000 EPC3 : 0x00000000 EPC4 : 0x00000000
Guru Meditation Error: Core 0 panic'ed (Interrupt wdt timeout on CPU0).
-
- Posts: 1
- Joined: Mon Feb 03, 2025 6:33 am
-
- Posts: 916
- Joined: Mon Jul 22, 2019 3:20 pm
Re: Guru Meditation Error: Core 0 panic'ed (Interrupt wdt timeout on CPU0).
Interrupts need to execute quickly in order to hand control back to the system. Start a separate task to interact with the hardware. You should also make your process as quick as possible, so combine all those bytes into a single array and make one write to the EEPROM.
Who is online
Users browsing this forum: No registered users and 109 guests