btidey wrote:Try changing the type for sleepTimesS to an unsigned long instead of an int.
Hello there and thank you for your reply,
*** I tried editting the code in these 2 places but it didn't work
const int sleepTimeS = 3.6e+9
ESP.deepSleep(sleepTimeS, WAKE_RF_DEFAULT); // Sleep for 60 seconds
*** This edit on the 2 lines works for close to an hour
const int sleepTimeS = 3600;
ESP.deepSleep(sleepTimeS * 1000000ul, WAKE_RF_DEFAULT); // Sleep for 60 seconds
*** I think by adding the ul above causes the number to go positive from what I have found on google.
I googled for the difference between const int and unsigned int and from what I can make out ( NOT A PROGRAMMER ) const int can go either positive or negative but unsigned would always be positive is that correct in saying?
So I kind of understand why what your saying should work...
#define sleepTimeS 3600ull
.
.
ESP.deepSleep(sleepTimeS * 1000000ull, WAKE_RF_DEFAULT); // Sleep for 60 seconds
schufti wrote:since in the library sleeptime is defined as unit64_t you probably should use ull
#define sleepTimeS 3600ull
.
.
ESP.deepSleep(sleepTimeS * 1000000ull, WAKE_RF_DEFAULT); // Sleep for 60 seconds
Thank you schufti I will add the extra l