sntp/lwip: Add SNTP_UPDATE_DELAY option in Kconfig

Closes: https://github.com/espressif/esp-idf/issues/2277
Closes: IDFGH-337
This commit is contained in:
Konstantin Kondrashov
2019-06-17 15:44:25 +08:00
parent c5e89897ef
commit b107b832ca
2 changed files with 32 additions and 9 deletions

View File

@@ -841,6 +841,16 @@ enum {
#define LWIP_DHCP_MAX_NTP_SERVERS CONFIG_LWIP_DHCP_MAX_NTP_SERVERS
#define LWIP_TIMEVAL_PRIVATE 0
/*
--------------------------------------
------------ SNTP options ------------
--------------------------------------
*/
/*
* SNTP update delay - in milliseconds
*/
#define SNTP_UPDATE_DELAY CONFIG_LWIP_SNTP_UPDATE_DELAY
#define SNTP_SET_SYSTEM_TIME_US(sec, us) \
do { \
struct timeval tv = { .tv_sec = sec, .tv_usec = us }; \