diff --git a/src/main.cpp b/src/main.cpp index fa15621..3470f63 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -185,15 +185,16 @@ void setup() { iot.mqtt.onMessage(onMqttMessage); iot.mqtt.setWill(sensorTopic.c_str(), 0, false, "OFFLINE"); -/* - while (iot.wifi.status() != WL_CONNECTED) { - delay(500); - Serial.print("."); - screen->draw(); + + // Wait here if not configured + if (iot.configuration.get("WifiConfigured") != "True") { + while (iot.wifi.status() != WL_CONNECTED) { + delay(500); + Serial.print("."); + screen->draw(); + } } - onWiFiConnect(); -*/ strcpy(state.timeStr, "--:--:--"); if (alarmclock.isNight()) { @@ -235,7 +236,7 @@ void onWiFiConnect() { } } - udp.beginMulticast(udpMulticastAddress, udpMulticastPort); +/* udp.beginMulticast(udpMulticastAddress, udpMulticastPort);*/ }