ropg / ezTime

ezTime — pronounced "Easy Time" — is a very easy to use Arduino time and date library that provides NTP network time lookups, extensive timezone support, formatted time and date strings, user events, millisecond precision and more.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

NTP update time violates NTP.org guidelines

MikeyMoMo opened this issue · comments

You should, by default, only fetch time from NTP.org once per day. Their guidelines request that and be sure to avoid on the hour and half hour calls and surely avoid midnight calls. I would suggest using 86578 (or something quite similar) as that is slightly over a day and will cycle through the day, slowly, not sitting on one of the hotspot time for NTP.org.

This line:
#define NTP_INTERVAL 86578 // default update interval in seconds

Perhaps adding an RTC (like the DS1307 or DS3231) option, and use the RTC instead of millis(), continue to use millis if no RTC, or if RTC is invalid. Then maybe depending on the accuracy of the RTC, maybe get NTP time once every couple of days.