Search found 3 matches

by zweieuro
Mon Sep 27, 2021 8:37 am
Forum: ESP-IDF
Topic: sntp: how to know if the time sync is done properly
Replies: 14
Views: 13799

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

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.
by zweieuro
Mon Sep 27, 2021 7:07 am
Forum: ESP-IDF
Topic: ESP32 SNTP broken with GMT ?
Replies: 3
Views: 2804

Re: ESP32 SNTP broken with GMT ?

ESP_YJM wrote:
Sun Sep 26, 2021 7:28 am
It seems SNTP not sync successfully.
Yes it seems so, but 'sntp_get_sync_status()' returns that the sync is complete, why would the status be complete if it failed? how can i detect if it failed ? and how can i detect why it failed ?
by zweieuro
Sat Sep 25, 2021 7:29 pm
Forum: ESP-IDF
Topic: ESP32 SNTP broken with GMT ?
Replies: 3
Views: 2804

ESP32 SNTP broken with GMT ?

Hi, I tried setting my SNTP to "GMT+2" and now i get nothing in response (even when synced) then 0. I use this for init: void initialize_sntp(void) { if (inited_sntp) return; inited_sntp = true; ESP_LOGI(TAG, "Initializing SNTP to %s ", MgConfig::instance()->tz_.c_str()); //setenv("TZ","GMT+2", 1); ...