gmag11 / ESPNtpClient

High accuracy NTP library for ESP32 and ESP8266
MIT License
119 stars 26 forks source link

GET data don't set system datetime #55

Open vslinuxdotnet opened 2 months ago

vslinuxdotnet commented 2 months ago

Seams that the lib don't update the system datetime in esp8266. Fixed by do this:

if (syncEventTriggered) { syncEventTriggered = false; processSyncEvent (ntpEvent); setTime(time (NULL));//fix system datetime }