So you're a Noob? Post your questions here until you graduate! Don't be shy.

User avatar
By Ilocans
#77958 Hi,

I read a lot on internet about deepsleep and I understood that I should connect my RST to GPIO16 to be able to wake up from deepsleep. Some say a wire, other a resistor (470ohm or 1k). I tried both.
However, its seems in my case that when the esp wake up it kind of reboot. It does not continue from where it felt asleep or keep my variables values.
I would like to be able to keep track of certain information when my esp wake up. LIke if I trigger some action or not. What is the best way to do so ?

Thanks for your help,
User avatar
By schufti
#77971 what you describe is exactly the way it is designed.
"deep sleep" is not like hibernation in windows.
you could check the boot reason for specific action and/or store relevant information in rtc ram.
User avatar
By btidey
#77975 Depending on what you need to retain, you can either use the EEPROM variable space or the SPIFFS filing system.

I normally use the SPIFFS filing system in my battery deep sleep projects. This works along the lines

Wake up
Load config file from SPIFFS and set 'static' operational values.
Load status file from SPIFFS and set dynamic operational values.
Run the activity required,
Save new dynamic values to status file if anything has changed.
Go to sleep