You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Ciao,
simple question: syncing from NTP automatically syncs the ESP32 internal clock ? Any further requests to NTP.getTimeDateString() or NTP.getTimeString() are done from the internal clock without usingn network, right ? In other words , after the first sync, the network is not required anymore (except for the scheduled ntp syncs)
Do you know how to update the DS3231 RTC ? I'm trying to use ntp as the initial sync, then update an RTC to keep the time updated even when powered off
The text was updated successfully, but these errors were encountered:
You are right. The intention of this lib is to sync internal IDF clock. Notice that, unless you need very high precision, this library is redundant as IDF already has an internal SNTP client.
You can configure it as simple as adding this to your setup() function:
sntp_setservername (0, "pool.ntp.org");
setenv ("TZ", PSTR ("CET-1CEST,M3.5.0,M10.5.0/3"), 1); //set your time zone
tzset ();
sntp_init ();
In order to set any RTC you can use a sync event callback. Both EspNtpClient library and internal SNTP IDF client have their own event callbacks.
Ciao,
simple question: syncing from NTP automatically syncs the ESP32 internal clock ? Any further requests to
NTP.getTimeDateString()
orNTP.getTimeString()
are done from the internal clock without usingn network, right ? In other words , after the first sync, the network is not required anymore (except for the scheduled ntp syncs)Do you know how to update the DS3231 RTC ? I'm trying to use ntp as the initial sync, then update an RTC to keep the time updated even when powered off
The text was updated successfully, but these errors were encountered: