1
0
mirror of https://github.com/esp8266/Arduino.git synced 2025-06-29 16:03:14 +03:00

settimeofday_cb: distinguish from user or sntp (#7637)

* settimeofday_cb: distinguish from user or sntp
This commit is contained in:
david gauchard
2020-10-23 10:43:45 +02:00
committed by GitHub
parent ace5e98bf6
commit 95fb104562
12 changed files with 89 additions and 48 deletions

View File

@ -3574,7 +3574,7 @@ extern "C" {
#define SNTP_SERVER_DNS 1 // enable SNTP support DNS names through sntp_setservername / sntp_getservername
#define SNTP_SET_SYSTEM_TIME_US(t,us) do { struct timeval tv = { t, us }; settimeofday(&tv, NULL); } while (0)
#define SNTP_SET_SYSTEM_TIME_US(t,us) do { struct timeval tv = { t, us }; settimeofday(&tv, (struct timezone*)0xFeedC0de); } while (0)
#define SNTP_SUPPRESS_DELAY_CHECK 1
#define SNTP_UPDATE_DELAY_DEFAULT 3600000 // update delay defined by a default weak function