Esp8266-7 deep sleep variable
Posted: Tue Feb 11, 2020 9:48 pm
I am trying to write a code that uses a variable for deep sleep. I want to be able to change the deep sleep duration remotely depending on sensor data. basically it is just
This should put the ESP into deep sleep for 1 min, but it basically just goes into deep sleep and immediately wakes up and reconnects then wash, rinse, repeat.
Is the ESP capable of utilizing a variable for the deep sleep duration?
Code: Select all
long sleepTime = 60000
ESP.deepSleep (sleepTime);
This should put the ESP into deep sleep for 1 min, but it basically just goes into deep sleep and immediately wakes up and reconnects then wash, rinse, repeat.
Is the ESP capable of utilizing a variable for the deep sleep duration?