NTPClient
NTPClient copied to clipboard
delay(10) to wait for NTP data messes interrupt routines
trafficstars
Hi, Can you change the program that has delay (10) in waiting for NTP data and use millis() instead. So that our interrupt in the main program will not be delayed. Thanks!
do {
delay ( 10 );
cb = this->_udp->parsePacket();
if (timeout > 100) return false; // timeout after 1000 ms
timeout++;
}
I agree, this is a good suggestion.
Hi guys, I've prepared a fix for this in PR https://github.com/arduino-libraries/NTPClient/pull/163