diff --git a/TODO.txt b/TODO.txt
index 8affbdec..333af814 100644
--- a/TODO.txt
+++ b/TODO.txt
@@ -1,5 +1,4 @@
captive portal for ap
-alexa settings
ntp bug
simple slide transition
additional color picker field
@@ -46,6 +45,7 @@ toggle notifier
var. brightness
BUGS
+general forced reset (usually around 48h)
NTP crash (1-48h)
static ip disables mdns
? authentification for security relevant areas ([/settings, /reset])
diff --git a/wled00/data/settings.htm b/wled00/data/settings.htm
index 433db21a..0a6c2382 100644
--- a/wled00/data/settings.htm
+++ b/wled00/data/settings.htm
@@ -146,7 +146,7 @@
Target brightness: (0-255)
Change after: min
Fade:
-
Daisy chain
+ Broadcast
UDP Port:
Receive notifications:
Send notifications on direct change:
diff --git a/wled00/htmls01.h b/wled00/htmls01.h
index c5f53308..b524cd1a 100644
--- a/wled00/htmls01.h
+++ b/wled00/htmls01.h
@@ -150,7 +150,7 @@ const char PAGE_settings[] PROGMEM = R"=====(
Target brightness: (0-255)
Change after: min
Fade:
- Daisy chain
+ Broadcast
UDP Port:
Receive notifications:
Send notifications on direct change:
diff --git a/wled00/wled00.ino b/wled00/wled00.ino
index a6dd33bf..cbcfc5bf 100644
--- a/wled00/wled00.ino
+++ b/wled00/wled00.ino
@@ -21,8 +21,11 @@
#include "UpnpBroadcastResponder.h"
#include "CallbackFunction.h"
+//version in format yymmddb (b = daily build)
+#define VERSION 1703202
+
//to toggle usb serial debug (un)comment following line
-//#define DEBUG
+#define DEBUG
#ifdef DEBUG
#define DEBUG_PRINT(x) Serial.print (x)
@@ -40,8 +43,8 @@
* @author Christian Schwinne
*/
//Hardware-settings (only changeble via code)
-#define LEDCOUNT 255 //maximum, exact count set-able via settings
-#define MAXDIRECT 255 //for direct access like arls, should be >= LEDCOUNT
+#define LEDCOUNT 93 //maximum, exact count set-able via settings
+#define MAXDIRECT 93 //for direct access like arls, should be >= LEDCOUNT
uint8_t buttonPin = 0; //needs pull-up
uint8_t auxPin = 15; //use e.g. for external relay
uint8_t auxDefaultState = 0; //0: input 1: high 2: low
@@ -179,7 +182,7 @@ WS2812FX strip = WS2812FX(LEDCOUNT, 2, NEO_GRB + NEO_KHZ800);
File fsUploadFile;
#ifdef DEBUG
-int debugIndex = 0;
+long debugTime = 0;
int lastWifiState = 3;
long wifiStateChangedTime = 0;
#endif
@@ -241,8 +244,7 @@ void loop() {
//DEBUG
#ifdef DEBUG
- debugIndex ++;
- if (debugIndex > 99999)
+ if (millis() - debugTime > 5000)
{
debugIndex = 0;
DEBUG_PRINTLN("---MODULE DEBUG INFO---");
@@ -257,7 +259,8 @@ void loop() {
lastWifiState = WiFi.status();
DEBUG_PRINT("Wifi state: "); DEBUG_PRINTLN(wifiStateChangedTime);
DEBUG_PRINT("NTP last sync: "); DEBUG_PRINTLN(ntpLastSyncTime);
- DEBUG_PRINT("Client IP: "); DEBUG_PRINTLN(WiFi.localIP());
+ DEBUG_PRINT("Client IP: "); DEBUG_PRINTLN(WiFi.localIP());
+ debugTime = millis();
}
#endif
}
diff --git a/wled00/wled02_xml.ino b/wled00/wled02_xml.ino
index 2911c76b..ef578e05 100644
--- a/wled00/wled02_xml.ino
+++ b/wled00/wled02_xml.ino
@@ -212,7 +212,9 @@ void XML_response_settings()
resp = resp + "Not active";
}
resp = resp + "";
- resp = resp + "WLED 0.3pd OK";
+ resp = resp + "WLED 0.3pd (build";
+ resp = resp + VERSION;
+ resp = resp + ") OK";
resp = resp + "";
DEBUG_PRINTLN(resp);
server.send(200, "text/xml", resp);
diff --git a/wled00/wled05_init.ino b/wled00/wled05_init.ino
index fff701d4..7f065bee 100644
--- a/wled00/wled05_init.ino
+++ b/wled00/wled05_init.ino
@@ -58,11 +58,11 @@ void wledInit()
}
DEBUG_PRINTLN("mDNS responder started");
- if (udpPort > 0 && udpPort != ntpLocalPort)
+ if (udpPort > 0 && udpPort != ntpLocalPort && WiFi.status() == WL_CONNECTED)
{
udpConnected = notifierUdp.begin(udpPort);
}
- if (ntpEnabled)
+ if (ntpEnabled && WiFi.status() == WL_CONNECTED)
ntpConnected = ntpUdp.begin(ntpLocalPort);
//SERVER INIT