bastelgarage / dual-led-ring-watch

3D Printed Wall-Mounted NeoPixel LED Clock with NTP Synchronization
MIT License
54 stars 4 forks source link

Issue with Hour ring #3

Closed ctobio closed 11 months ago

ctobio commented 11 months ago

For some odd reason, no matter what I do, the hour ring seems to consistently show UTC+2. Note- I compiled this for ESP32 which involved changing esp8266WiFi.h to WiFi.h and PIN D6 to PIN 23 (or the pin of your choice).

The minute ring works perfectly, but even with modifying the time zone values, nothing seems to fix this issue. I'm not sure if this is an ESP32 thing or something else entirely.

AlfMueller commented 11 months ago

Have a look at the settings for the time zone from the library

https://github.com/JChristensen/Timezone/blob/master/examples/WorldClock/WorldClock.ino

ctobio commented 11 months ago

Ive replaced lines 33-35 with TimeChangeRule usEDT = {"EDT", Second, Sun, Mar, 2, -240}; // Eastern Daylight Time = UTC - 4 hours TimeChangeRule usEST = {"EST", First, Sun, Nov, 2, -300}; // Eastern Standard Time = UTC - 5 hours Timezone usET(usEDT, usEST);

And 55 with time_t local = usET.toLocal(utc);

It still looks like I'm in CET. Sorry for the noob questions.

AlfMueller commented 11 months ago

have fun :-)