diff --git a/wled00/data/index-min.htm b/wled00/data/index-min.htm
index 79c3ad9fd..0db0064ec 100644
--- a/wled00/data/index-min.htm
+++ b/wled00/data/index-min.htm
@@ -1,9 +1,9 @@
-WLED 0.3pd
-
-
+WLED 0.4p
+
+
Loading...
@@ -66,6 +66,8 @@
+
+
diff --git a/wled00/data/index.htm b/wled00/data/index.htm
index 8d8408939..71b13f260 100644
--- a/wled00/data/index.htm
+++ b/wled00/data/index.htm
@@ -1,12 +1,13 @@
-
WLED 0.3
+ WLED 0.4p
+
@@ -13,7 +13,7 @@
WiFi setup
Connect to existing network
-Network SSID (leave empty to not connect):
+Network SSID (leave empty to not connect):
Network password:
Static IP (leave at 0.0.0.0 for DHCP):
.
@@ -51,6 +51,7 @@ Default RGB color:
Default brightness: (0-255)
+Default white value (only RGBW, -1 to disable):
Default effect ID:
Default effect speed:
Ignore and use current color, brightness and effects:
@@ -76,9 +77,8 @@ Send notifications on button press:
Emulate Alexa device:
Alexa invocation name:
Send Alexa notifications:
-Time (highly experimental!)
- Warning! NTP was updated but still causes crashes. Requires reboot.
-It is really not recommended to use this!
+Time (experimental!)
+NTP was updated but still causes crashes. Requires reboot.
Get time from NTP server:
Current local time is unknown
Advanced
@@ -97,7 +97,7 @@ Factory reset:
All EEPROM content (settings) will be erased.
HTTP traffic is not encrypted. An attacker in the same network could intercept form data!
About
-WLED version 0.3
+WLED version 0.4p
(c) 2016-2017 Christian Schwinne
Licensed under the MIT license
Uses libraries:
diff --git a/wled00/data/settings.htm b/wled00/data/settings.htm
index 61639c3d1..551dac09f 100644
--- a/wled00/data/settings.htm
+++ b/wled00/data/settings.htm
@@ -38,6 +38,7 @@
document.S_form.CLDFG.value = this.responseXML.getElementsByTagName('cldef')[1].innerHTML;
document.S_form.CLDFB.value = this.responseXML.getElementsByTagName('cldef')[2].innerHTML;
document.S_form.CLDFA.value = this.responseXML.getElementsByTagName('cldfa')[0].innerHTML;
+ document.S_form.CLDFW.value = this.responseXML.getElementsByTagName('cldfw')[0].innerHTML;
document.S_form.FXDEF.value = this.responseXML.getElementsByTagName('fxdef')[0].innerHTML;
document.S_form.SXDEF.value = this.responseXML.getElementsByTagName('sxdef')[0].innerHTML;
document.S_form.BOOTN.checked = (this.responseXML.getElementsByTagName('bootn')[0].innerHTML)!=0?true:false;
@@ -127,6 +128,7 @@
Default brightness: (0-255)
+ Default white value (only RGBW, -1 to disable):
Default effect ID:
Default effect speed:
Ignore and use current color, brightness and effects:
@@ -152,9 +154,8 @@
Emulate Alexa device:
Alexa invocation name:
Send Alexa notifications:
- Time (highly experimental!)
- Warning! NTP was updated but still causes crashes. Requires reboot.
- It is really not recommended to use this!
+ Time (experimental!)
+ NTP was updated but still causes crashes. Requires reboot.
Get time from NTP server:
Current local time is unknown
Advanced
@@ -174,7 +175,7 @@
HTTP traffic is not encrypted. An attacker in the same network could intercept form data!
About
- WLED version 0.3
+ WLED version 0.4p
(c) 2016-2017 Christian Schwinne
Licensed under the MIT license
Uses libraries:
diff --git a/wled00/htmls00.h b/wled00/htmls00.h
index e7ffd017c..fa135267d 100644
--- a/wled00/htmls00.h
+++ b/wled00/htmls00.h
@@ -24,9 +24,9 @@ const char PAGE_index[] PROGMEM = R"=====(
-WLED 0.3pd
-
-
+WLED 0.4p
+
+
Loading...
@@ -93,12 +93,14 @@ const char PAGE_index[] PROGMEM = R"=====(
+
+
-
+
diff --git a/wled00/htmls01.h b/wled00/htmls01.h
index 454e3c859..860ddbe6e 100644
--- a/wled00/htmls01.h
+++ b/wled00/htmls01.h
@@ -7,7 +7,7 @@ const char PAGE_settings[] PROGMEM = R"=====(
Settings
-
+
@@ -17,8 +17,8 @@ const char PAGE_settings[] PROGMEM = R"=====(
WiFi setup
Connect to existing network
-Network SSID (leave empty to not connect):
-Network password:
+Network SSID (leave empty to not connect):
+Network password:
Static IP (leave at 0.0.0.0 for DHCP):
.
.
@@ -55,6 +55,7 @@ Default RGB color:
Default brightness: (0-255)
+Default white value (only RGBW, -1 to disable):
Default effect ID:
Default effect speed:
Ignore and use current color, brightness and effects:
@@ -81,7 +82,7 @@ Emulate Alexa device:
Alexa invocation name:
Send Alexa notifications:
Time (experimental!)
-Could still cause crashes. Requires reboot.
+NTP was updated but still causes crashes. Requires reboot.
Get time from NTP server:
Current local time is unknown
Advanced
@@ -100,7 +101,7 @@ Factory reset:
All EEPROM content (settings) will be erased.
HTTP traffic is not encrypted. An attacker in the same network could intercept form data!
About
-WLED version 0.3
+WLED version 0.4p
(c) 2016-2017 Christian Schwinne
Licensed under the MIT license
Uses libraries:
diff --git a/wled00/wled00.ino b/wled00/wled00.ino
index b68564f46..e8d119427 100644
--- a/wled00/wled00.ino
+++ b/wled00/wled00.ino
@@ -20,7 +20,7 @@
#include "CallbackFunction.h"
//version in format yymmddb (b = daily build)
-#define VERSION 1710120
+#define VERSION 1710121
//uncomment if you have an RGBW strip
#define RGBW
@@ -50,7 +50,7 @@
/*
* @title WLED project sketch
- * @version 0.3
+ * @version 0.4p
* @author Christian Schwinne
*/
//Hardware-settings (only changeble via code)
@@ -87,6 +87,7 @@ IPAddress staticsubnet(255, 255, 255, 0);
boolean useHSB = false, useHSBDefault = false;
boolean turnOnAtBoot = true;
byte col_s[]{255, 159, 0};
+boolean useRGBW = false;
byte white_s = 0;
byte bri_s = 127;
uint8_t bri_nl = 0, bri_nls;
diff --git a/wled00/wled01_eeprom.ino b/wled00/wled01_eeprom.ino
index 4f1b8667e..43047704e 100644
--- a/wled00/wled01_eeprom.ino
+++ b/wled00/wled01_eeprom.ino
@@ -102,6 +102,7 @@ void saveSettingsToEEPROM()
EEPROM.write(369, turnOnAtBoot);
EEPROM.write(370, useHSBDefault);
EEPROM.write(371, white_s);
+ EEPROM.write(372, useRGBW);
EEPROM.commit();
}
@@ -214,5 +215,6 @@ void loadSettingsFromEEPROM()
turnOnAtBoot = EEPROM.read(369);
useHSBDefault = EEPROM.read(370);
white_s = EEPROM.read(371);
+ useRGBW = EEPROM.read(372);
useHSB = useHSBDefault;
}
diff --git a/wled00/wled02_xml.ino b/wled00/wled02_xml.ino
index d4e2e4a26..e7490e9ae 100644
--- a/wled00/wled02_xml.ino
+++ b/wled00/wled02_xml.ino
@@ -34,11 +34,11 @@ void XML_response()
resp = resp + "";
resp = resp + effectSpeed;
resp = resp + " ";
- #ifdef RGBW
- resp = resp + white;
- #else
- resp = resp + "-1";
- #endif
+ if (useRGBW) {
+ resp = resp + white;
+ } else {
+ resp = resp + "-1";
+ }
resp = resp + " ";
resp = resp + useHSB;
resp = resp + " ";
@@ -116,7 +116,11 @@ void XML_response_settings()
resp = resp + "";
}
resp = resp + "";
- resp = resp + white_s;
+ if (useRGBW) {
+ resp = resp + white_s;
+ } else {
+ resp = resp + "-1";
+ }
resp = resp + " ";
resp = resp + bri_s;
resp = resp + " ";
@@ -218,7 +222,7 @@ void XML_response_settings()
resp = resp + "Not active";
}
resp = resp + "";
- resp = resp + "WLED 0.3 (build ";
+ resp = resp + "WLED 0.4p (build ";
resp = resp + VERSION;
resp = resp + ") OK ";
resp = resp + "";
diff --git a/wled00/wled03_set.ino b/wled00/wled03_set.ino
index f2b3bf4a5..04cc5d2ef 100644
--- a/wled00/wled03_set.ino
+++ b/wled00/wled03_set.ino
@@ -133,7 +133,14 @@ void handleSettingsSet()
if (server.hasArg("CLDFW"))
{
int i = server.arg("CLDFW").toInt();
- if (i >= 0 && i <= 255) white_s = i;
+ if (i >= 0 && i <= 255)
+ {
+ useRGBW = true;
+ white_s = i;
+ } else {
+ useRGBW = false;
+ white_s = 0;
+ }
}
if (server.hasArg("CLDFA"))
{
diff --git a/wled00/wled05_init.ino b/wled00/wled05_init.ino
index 0a1a15de6..3029a673e 100644
--- a/wled00/wled05_init.ino
+++ b/wled00/wled05_init.ino
@@ -90,6 +90,12 @@ void wledInit()
server.on("/version", HTTP_GET, [](){
server.send(200, "text/plain", (String)VERSION);
});
+ server.on("/uptime", HTTP_GET, [](){
+ server.send(200, "text/plain", (String)millis());
+ });
+ server.on("/freeheap", HTTP_GET, [](){
+ server.send(200, "text/plain", (String)ESP.getFreeHeap());
+ });
if (!ota_lock){
server.on("/edit", HTTP_GET, [](){
if(!handleFileRead("/edit.htm")) server.send(200, "text/html", PAGE_edit);