From 31cc638d5248cfa36cbd2ca9ae50d78a78ed1b3f Mon Sep 17 00:00:00 2001 From: David Gauchard Date: Wed, 20 Dec 2017 13:04:55 +0100 Subject: [PATCH] in example properly wait for NTP to be set fix #3905 --- .../examples/HTTPSRequestCACert/HTTPSRequestCACert.ino | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libraries/ESP8266WiFi/examples/HTTPSRequestCACert/HTTPSRequestCACert.ino b/libraries/ESP8266WiFi/examples/HTTPSRequestCACert/HTTPSRequestCACert.ino index 2fc0f2eb03..1a63e6f658 100644 --- a/libraries/ESP8266WiFi/examples/HTTPSRequestCACert/HTTPSRequestCACert.ino +++ b/libraries/ESP8266WiFi/examples/HTTPSRequestCACert/HTTPSRequestCACert.ino @@ -53,7 +53,7 @@ void setup() { Serial.print("Setting time using SNTP"); configTime(8 * 3600, 0, "pool.ntp.org", "time.nist.gov"); time_t now = time(nullptr); - while (now < 1000) { + while (now < 8 * 3600 * 2) { delay(500); Serial.print("."); now = time(nullptr);