Arduino News here

Moderator: igrr

User avatar
By mrburnette
#70993
dannybackx wrote:I wrote an app in two versions. It's supposed to switch a light on and off to spoof burglars.

The one version is with time() and configTime(), the other uses the sntp_ calls.

Both seem to forget about the timezone after a while. At first the clock is right, a couple of hours later the device seems to think it's in London.

Any clues ?


I do it this-a-way

https://www.hackster.io/rayburne/nist-date-amp-time-with-esp8266-and-oled-display-e8b9a9

Ray
User avatar
By dannybackx
#71022
mrburnette wrote:I do it this-a-way

https://www.hackster.io/rayburne/nist-date-amp-time-with-esp8266-and-oled-display-e8b9a9

Ray


Interesting. I want to interpret the date/time info and do something with it, though. For instance : turn on a light between 7 and 8am. It would be trivial to add that to your app with some text decoding.

But there are APIs for this, and they let me down. I'm still looking for clues as to why the timezone appears to be reset every couple of hours.