This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Retain a RAM value after a Watchdog timeout?

Hi,

I'd like to retain a value in RAM after any type of reset, including a watchdog timeout, so that I can read it back in the bootloader immediately after a reset.

Unfortunately, I understand that GPREGRET is initialized on a watchdog reset, so I cannot save my value there.

Is there any mechanism to retain a value in RAM after a watchdog reset? I realize I could write the value to some non-volatile storage (such as pstorage or external SPI flash) when it gets updated, but I'd prefer a more lightweight approach if possible.

Parents Reply Children
No Data
Related