mirror of
https://github.com/esphome/esphome.git
synced 2025-03-14 04:25:15 +01:00
Return sntp_set_sync_interval in setup
This commit is contained in:
parent
2c90f61de1
commit
e14cd7e6ab
1 changed files with 1 additions and 0 deletions
|
@ -51,6 +51,7 @@ void SNTPComponent::setup() {
|
|||
#ifdef USE_ESP_IDF
|
||||
this->stop_poller();
|
||||
sntp_set_time_sync_notification_cb([](struct timeval *tv) { sync_time_to_report_ = tv->tv_sec; });
|
||||
sntp_set_sync_interval(this->get_update_interval());
|
||||
#endif // USE_ESP_IDF
|
||||
|
||||
sntp_init();
|
||||
|
|
Loading…
Add table
Reference in a new issue