-
Notifications
You must be signed in to change notification settings - Fork 12
Conversation
Thanks for this PR. It seems to be a very good improvements, but I have to spend some time to test and see if everything is working OK with the new PR. Best Regards, |
Hi, I just have time to test this PR now, and sorry that it's nor working. Can you spend time to verify and check / fix Testing with Nano_33_IoTBefore update with this PR => OK
After update with this PR => never UPDATED
Testing with Nano_RP2040_ConnectBefore update with this PR => OK
After update with this PR => never UPDATED
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This PR is not working. Please check the Test results in comment.
After fixing the issue, you have to delete the old repo, then refork / rebase.
It was working for me in my real world use with an Adafruit Metro M4 Express AirLift (WiFi) - Lite, together with #4, at least. How did you perform your tests? How can I run the same? |
Just use the NINA_NTPClient_Basic on a board using WiFiNINS, suchj as Nano-33-IoT, Nano-RP2040-Connect. I haven't checked if it's working with other boards using Ethernet yet because the previous tests failed. |
…k around WiFiUDP::flush() not implemented.)
a6c22fe
to
f954284
Compare
I rebased this branch, but did not perform any new testing. I don't currently have any boards in hand on which I can test this. (I shipped the board I was using for a now tentatively completed project.) Can you see if the issue persists with the rebased code? That would be how I was testing it before, with both this and #4 merged. |
Still not working using your latest rebased code. I'll spend some time later to find out and fix the issue, just put it in the bucket list.
|
This resolves an issue I experienced where some old packets were causing updates to old times.
For instance, suppose an NTP packet from the server is delayed, so
NTPClient::update()
retries before the first arrives. Then the first arrives, time is updated, and the second packet arrives, and remains unparsed. Before this patch, when callingupdate()
the next time, it would parse the old out-of-date packet.The original NTPClient tries to do this, with its
parsePacket()
/flush()
loop in itsforceUpdate()
function (which is also used by itsupdate()
function). It doesn't work though, sinceWiFiUDP::parsePacket()
doesn't advance to the next packet withoutWiFiUDP::read()
, andWiFiUDP::flush()
isn't implemented.