added delay after configTime to fix issue that it's not really syncing

for more info see here: https://github.com/sqfmi/Watchy/pull/70#issuecomment-869416826
pull/70/head
etwasmitbaum 2021-06-29 17:03:34 +02:00
parent 4aba015a03
commit 75303e62bf
1 changed files with 1 additions and 0 deletions

View File

@ -88,6 +88,7 @@ void Watchy::syncNtpTime(){
//get NTP Time
configTime(GMT_OFFSET_SEC, DAYLIGHT_OFFSET_SEC, NTP_SERVER);
delay(4000); //delay 4 secods so configTime can finish recieving the time from the internet
getLocalTime(&timeinfo);
// convert NTP time into proper format