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.
MIT License
336 stars 93 forks source link

FritzBox Router sends wrong ntp packet #145

Open RrPt opened 2 years ago

RrPt commented 2 years ago

Hello,

my FritzBox 7590 seems to send wrong ntp data when used as ntp server. It sends stratum = 0 and reftsSec=0 Since this two values aren#t needed to calculate time there is a workaround

change line 494 of ezTime.cpp from if ((buffer[1] < 1) or (buffer[1] > 15) or (reftsSec == 0) or (rcvtsSec == 0) or (rcvtsSec > secsSince1900)) { to if ( (rcvtsSec == 0) or (rcvtsSec > secsSince1900)) {

and it is running.

maybe in a next version this checks are optional

Rainer