sntp: how to know if the time sync is done properly

asurti
Posts: 7
Joined: Tue Sep 07, 2021 9:37 am

Re: sntp: how to know if the time sync is done properly

Postby asurti » Wed Sep 15, 2021 10:34 am

Thanks for the confirmation!

ESP_YJM
Posts: 300
Joined: Fri Feb 26, 2021 10:30 am

Re: sntp: how to know if the time sync is done properly

Postby ESP_YJM » Thu Sep 16, 2021 2:57 am

Do this issue solved? If yes, i will mark it as solved. Or you can comment here when you face the similar issue.

asurti
Posts: 7
Joined: Tue Sep 07, 2021 9:37 am

Re: sntp: how to know if the time sync is done properly

Postby asurti » Thu Sep 16, 2021 4:31 am

Yes, it did solve the issue.
But just wondering, why we need to restart the sntp. Can't we have an API which is just to sync time?

ESP_YJM
Posts: 300
Joined: Fri Feb 26, 2021 10:30 am

Re: sntp: how to know if the time sync is done properly

Postby ESP_YJM » Fri Sep 17, 2021 1:59 am

No, lwip sntp not reproduce a public API to send sntp request. As you saw, it is static and need need maintain some timeout function and state, so stopping sntp module and re-starting it is a easy way to send sntp request.

zweieuro
Posts: 3
Joined: Sat Sep 25, 2021 7:23 pm

Re: sntp: how to know if the time sync is done properly

Postby zweieuro » Mon Sep 27, 2021 8:37 am

Is there a way to find out why the SNTP 'failed' in the first place?
I've tried just restarting until the current year is reported, but that doesn't seem to get me anywhere and just loop indefinitely.

Who is online

Users browsing this forum: Google [Bot], mejhaMA and 100 guests