esp_reset_reason()
Posted: Mon Jul 13, 2020 12:41 pm
Using v4.1-beta1-317-g84b51781c with rev 1 ESP32
Following an ESP_EN reboot esp_reset_reason() returns 7, ESP_RST_WDT, //!< Reset due to other watchdogs)
On a different board where I have access to the console then following UART reprogramming I get 1, ESP_RST_POWERON, //!< Reset due to power-on event
Both results are unexpected. Does the reset reason work?
EDIT: I am looking establish if power has been removed rather than watchdog reset. I have a voltage supervisor which toggles ESP_EN. I also have a watchdog circuit which toggles ESP_EN and so as I think about it the esp_reset_reason() probably will not tell the difference between real power loss & ESP_EN watchdog and supervisor reset?
Following an ESP_EN reboot esp_reset_reason() returns 7, ESP_RST_WDT, //!< Reset due to other watchdogs)
On a different board where I have access to the console then following UART reprogramming I get 1, ESP_RST_POWERON, //!< Reset due to power-on event
Both results are unexpected. Does the reset reason work?
EDIT: I am looking establish if power has been removed rather than watchdog reset. I have a voltage supervisor which toggles ESP_EN. I also have a watchdog circuit which toggles ESP_EN and so as I think about it the esp_reset_reason() probably will not tell the difference between real power loss & ESP_EN watchdog and supervisor reset?