BOOT_DELAY_SECONDS 3

This commit is contained in:
Patrick Haßel 2025-01-16 11:49:46 +01:00
parent 3a1003b0af
commit ebacfbed02

View File

@ -4,6 +4,8 @@
#include "clock.h"
#include "log.h"
#define BOOT_DELAY_SECONDS 3
void bootDelay() {
info("Waiting for WiFi...");
while (!isWiFiConnected()) {
@ -18,9 +20,9 @@ void bootDelay() {
yield();
}
info("Waiting 5 seconds for OTA update...");
info("Waiting %d seconds for OTA update...", BOOT_DELAY_SECONDS);
const auto start = millis();
while (millis() - start < 5000) {
while (millis() - start < BOOT_DELAY_SECONDS * 1000) {
wifiLoop();
yield();
}