From d1e92137dda16a703d63cd4f62586b11eceee64b Mon Sep 17 00:00:00 2001 From: Florian Date: Mon, 28 Aug 2023 17:54:16 -0400 Subject: [PATCH] [OTA] Fix http timeout (#1736) Time should be in milli seconds not in seconds --- main/main.ino | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/main/main.ino b/main/main.ino index cb41903..fd051f4 100644 --- a/main/main.ino +++ b/main/main.ino @@ -2438,7 +2438,7 @@ String latestVersion; bool checkForUpdates() { Log.notice(F("Update check, free heap: %d"), ESP.getFreeHeap()); HTTPClient http; - http.setTimeout(GeneralTimeOut - 1); // -1 to avoid WDT + http.setTimeout((GeneralTimeOut - 1) * 1000); // -1 to avoid WDT http.setFollowRedirects(HTTPC_STRICT_FOLLOW_REDIRECTS); http.begin(OTA_JSON_URL, OTAserver_cert); int httpCode = http.GET();