M Hotchin
M Hotchin
Sorry about check-in, revert, check-in. Still learning Git.
> Hi @MHotchin can we consider [this](https://github.com/arduino/arduino-cli/issues/1315#issuecomment-860538455) solved using this trick? It addresses the problem for command line users, but doesn't appear to help IDE users. I'll leave it to...
It wouldn't be possible without changing the data type returned by getEpochTime(). Right now the unix time is 1,575,693,824. Multiplying by 1000 will overflow the maximum value that an unsigned...
Currently the memory buffer used to send and receive the UDP packet is allocated in the NTP object. It is only ever used in one function, it could be allocated...
My mistake - it's used in two places, but none of the data in the buffer is reused. It could be stack allocated in both functions.
Pull request #177 would fix this.
I have seen this problem as well. This date seems to correspond to an NTP time of 0x0000000 in the seconds component. Once the code subtracts 70 years, the resulting...
I decided to to add some error checking, since then I haven't seen the problem. I've forked and committed my changes here: https://github.com/MHotchin/NTPClient Summary: - more error checking around all...
Code change as follows: void NTPClient::begin(int port) { this->_port = port; this->_udpSetup = this->_udp->begin(this->_port); }
No sense using a while() loop, if ‘begin()’ fails you should wait some time *then* try again. Your code should always handle the case that ‘update()’ fails, so if ‘begin()’...