From 69099fcdd786d0b6d1ac3d5a8a92b6757415d056 Mon Sep 17 00:00:00 2001 From: Blaz Kristan Date: Thu, 20 May 2021 19:54:07 +0200 Subject: [PATCH 01/36] Multi button support. --- wled00/button.cpp | 140 ++-- wled00/cfg.cpp | 145 +++- wled00/const.h | 59 +- wled00/data/settings_leds.htm | 765 +++++++++-------- wled00/data/settings_sync.htm | 21 +- wled00/data/settings_time.htm | 114 ++- wled00/fcn_declare.h | 4 +- wled00/html_settings.h | 139 ++-- wled00/set.cpp | 52 +- wled00/wled.cpp | 1442 +++++++++++++++++---------------- wled00/wled.h | 47 +- wled00/wled_eeprom.cpp | 22 +- wled00/xml.cpp | 103 ++- 13 files changed, 1677 insertions(+), 1376 deletions(-) diff --git a/wled00/button.cpp b/wled00/button.cpp index c263a66d..26218c15 100644 --- a/wled00/button.cpp +++ b/wled00/button.cpp @@ -6,105 +6,124 @@ #define WLED_DEBOUNCE_THRESHOLD 50 //only consider button input of at least 50ms as valid (debouncing) -void shortPressAction() +void shortPressAction(uint8_t b) { - if (!macroButton) + if (!macroButton[b]) { toggleOnOff(); colorUpdated(NOTIFIER_CALL_MODE_BUTTON); } else { - applyPreset(macroButton); + applyPreset(macroButton[b]); } } -bool isButtonPressed() +bool isButtonPressed(uint8_t i) { - if (btnPin>=0 && digitalRead(btnPin) == LOW) return true; - #ifdef TOUCHPIN - if (touchRead(TOUCHPIN) <= TOUCH_THRESHOLD) return true; - #endif + if (btnPin[i]<0) return false; + switch (buttonType[i]) { + case BTN_TYPE_NONE: + case BTN_TYPE_RESERVED: + break; + case BTN_TYPE_PUSH: + case BTN_TYPE_SWITCH: + if (digitalRead(btnPin[i]) == LOW) return true; + break; + case BTN_TYPE_PUSH_ACT_HIGH: + case BTN_TYPE_SWITCH_ACT_HIGH: + if (digitalRead(btnPin[i]) == HIGH) return true; + break; + case BTN_TYPE_TOUCH: + #ifdef ARDUINO_ARCH_ESP32 + if (touchRead(btnPin[i]) <= touchThreshold) return true; + DEBUG_PRINT(F("Touch value: ")); + DEBUG_PRINTLN(touchRead(btnPin[i])); + #endif + break; + } return false; } -void handleSwitch() +void handleSwitch(uint8_t b) { - if (buttonPressedBefore != isButtonPressed()) { - buttonPressedTime = millis(); - buttonPressedBefore = !buttonPressedBefore; + if (buttonPressedBefore[b] != isButtonPressed(b)) { + buttonPressedTime[b] = millis(); + buttonPressedBefore[b] = !buttonPressedBefore[b]; } - if (buttonLongPressed == buttonPressedBefore) return; + if (buttonLongPressed[b] == buttonPressedBefore[b]) return; - if (millis() - buttonPressedTime > WLED_DEBOUNCE_THRESHOLD) { //fire edge event only after 50ms without change (debounce) - if (buttonPressedBefore) { //LOW, falling edge, switch closed - if (macroButton) applyPreset(macroButton); + if (millis() - buttonPressedTime[b] > WLED_DEBOUNCE_THRESHOLD) { //fire edge event only after 50ms without change (debounce) + if (buttonPressedBefore[b]) { //LOW, falling edge, switch closed + if (macroButton[b]) applyPreset(macroButton[b]); else { //turn on if (!bri) {toggleOnOff(); colorUpdated(NOTIFIER_CALL_MODE_BUTTON);} } } else { //HIGH, rising edge, switch opened - if (macroLongPress) applyPreset(macroLongPress); + if (macroLongPress[b]) applyPreset(macroLongPress[b]); else { //turn off if (bri) {toggleOnOff(); colorUpdated(NOTIFIER_CALL_MODE_BUTTON);} } } - buttonLongPressed = buttonPressedBefore; //save the last "long term" switch state + buttonLongPressed[b] = buttonPressedBefore[b]; //save the last "long term" switch state } } void handleButton() { - if (btnPin<0 || buttonType < BTN_TYPE_PUSH) return; + for (uint8_t b=0; b BTN_TYPE_NONE)) continue; - if (buttonType == BTN_TYPE_SWITCH) { //button is not momentary, but switch. This is only suitable on pins whose on-boot state does not matter (NO gpio0) - handleSwitch(); return; - } + if (buttonType[b] == BTN_TYPE_SWITCH) { //button is not momentary, but switch. This is only suitable on pins whose on-boot state does not matter (NOT gpio0) + handleSwitch(b); continue; + } - //momentary button logic - if (isButtonPressed()) //pressed - { - if (!buttonPressedBefore) buttonPressedTime = millis(); - buttonPressedBefore = true; - - if (millis() - buttonPressedTime > 600) //long press + //momentary button logic + if (isButtonPressed(b)) //pressed { - if (!buttonLongPressed) - { - if (macroLongPress) {applyPreset(macroLongPress);} - else _setRandomColor(false,true); + if (!buttonPressedBefore[b]) buttonPressedTime[b] = millis(); + buttonPressedBefore[b] = true; - buttonLongPressed = true; + if (millis() - buttonPressedTime[b] > 600) //long press + { + if (!buttonLongPressed[b]) + { + if (macroLongPress[b]) {applyPreset(macroLongPress[b]);} + else _setRandomColor(false,true); + + buttonLongPressed[b] = true; + } } } - } - else if (!isButtonPressed() && buttonPressedBefore) //released - { - long dur = millis() - buttonPressedTime; - if (dur < WLED_DEBOUNCE_THRESHOLD) {buttonPressedBefore = false; return;} //too short "press", debounce - bool doublePress = buttonWaitTime; - buttonWaitTime = 0; - - if (dur > 6000) //long press + else if (!isButtonPressed(b) && buttonPressedBefore[b]) //released { - WLED::instance().initAP(true); - } - else if (!buttonLongPressed) { //short press - if (macroDoublePress) - { - if (doublePress) applyPreset(macroDoublePress); - else buttonWaitTime = millis(); - } else shortPressAction(); - } - buttonPressedBefore = false; - buttonLongPressed = false; - } + long dur = millis() - buttonPressedTime[b]; + if (dur < WLED_DEBOUNCE_THRESHOLD) {buttonPressedBefore[b] = false; continue;} //too short "press", debounce + bool doublePress = buttonWaitTime[b]; + buttonWaitTime[b] = 0; - if (buttonWaitTime && millis() - buttonWaitTime > 450 && !buttonPressedBefore) - { - buttonWaitTime = 0; - shortPressAction(); + if (dur > 6000 && b==0) //long press on button 0 + { + WLED::instance().initAP(true); + } + else if (!buttonLongPressed[b]) { //short press + if (macroDoublePress[b]) + { + if (doublePress) applyPreset(macroDoublePress[b]); + else buttonWaitTime[b] = millis(); + } else shortPressAction(b); + } + buttonPressedBefore[b] = false; + buttonLongPressed[b] = false; + } + + if (buttonWaitTime[b] && millis() - buttonWaitTime[b] > 450 && !buttonPressedBefore[b]) + { + buttonWaitTime[b] = 0; + shortPressAction(b); + } } } @@ -128,7 +147,8 @@ void handleIO() { if (!offMode) { #ifdef ESP8266 - //turn off built-in LED if strip is turned off + // turn off built-in LED if strip is turned off + // this will break digital bus so will need to be reinitialised on On pinMode(LED_BUILTIN, OUTPUT); digitalWrite(LED_BUILTIN, HIGH); #endif diff --git a/wled00/cfg.cpp b/wled00/cfg.cpp index 1b94c00f..20e25da2 100644 --- a/wled00/cfg.cpp +++ b/wled00/cfg.cpp @@ -62,7 +62,8 @@ bool deserializeConfig(JsonObject doc, bool fromFS) { JsonArray ap_ip = ap["ip"]; for (byte i = 0; i < 4; i++) { apIP[i] = ap_ip; - }*/ + } + */ noWifiSleep = doc[F("wifi")][F("sleep")] | !noWifiSleep; // inverted noWifiSleep = !noWifiSleep; @@ -89,13 +90,12 @@ bool deserializeConfig(JsonObject doc, bool fromFS) { for (JsonObject elm : ins) { if (s >= WLED_MAX_BUSSES) break; uint8_t pins[5] = {255, 255, 255, 255, 255}; - JsonArray pinArr = elm[F("pin")]; + JsonArray pinArr = elm["pin"]; if (pinArr.size() == 0) continue; pins[0] = pinArr[0]; uint8_t i = 0; for (int p : pinArr) { - pins[i] = p; - i++; + pins[i++] = p; if (i>4) break; } @@ -123,22 +123,47 @@ bool deserializeConfig(JsonObject doc, bool fromFS) { } if (hw_led["rev"]) busses.getBus(0)->reversed = true; //set 0.11 global reversed setting for first bus - JsonObject hw_btn_ins_0 = hw[F("btn")][F("ins")][0]; - CJSON(buttonType, hw_btn_ins_0["type"]); - int hw_btn_pin = hw_btn_ins_0[F("pin")][0] | -2; //-2 = not present in doc, keep current. -1 = disable - if (hw_btn_pin > -2) { - if (pinManager.allocatePin(hw_btn_pin,false)) { - btnPin = hw_btn_pin; - pinMode(btnPin, INPUT_PULLUP); - } else { - btnPin = -1; + // read multiple button configuration + JsonArray hw_btn_ins = hw[F("btn")][F("ins")]; + if (!hw_btn_ins.isNull()) { + uint8_t s = 0; + for (JsonObject btn : hw_btn_ins) { + CJSON(buttonType[s], btn["type"]); + int8_t pin = btn[F("pin")][0] | -1; + if (pin > -1) { + if (pinManager.allocatePin(pin,false)) { + btnPin[s] = pin; + pinMode(btnPin[s], INPUT_PULLUP); + } else { + btnPin[s] = -1; + } + } + JsonArray hw_btn_ins_0_macros = btn[F("macros")]; + CJSON(macroButton[s], hw_btn_ins_0_macros[0]); + CJSON(macroLongPress[s],hw_btn_ins_0_macros[1]); + CJSON(macroDoublePress[s], hw_btn_ins_0_macros[2]); + if (++s >= WLED_MAX_BUTTONS) break; // max buttons reached } + // clear remaining buttons + for (; s= 0) transitionDelayDefault = tdd * 100; CJSON(strip.paletteFade, light_tr["pal"]); @@ -205,7 +230,7 @@ bool deserializeConfig(JsonObject doc, bool fromFS) { CJSON(presetCycleMin, def_cy[F("range")][0]); CJSON(presetCycleMax, def_cy[F("range")][1]); - tdd = def_cy[F("dur")] | -1; + tdd = def_cy["dur"] | -1; if (tdd > 0) presetCycleTime = tdd; JsonObject interfaces = doc["if"]; @@ -257,6 +282,7 @@ bool deserializeConfig(JsonObject doc, bool fromFS) { CJSON(macroAlexaOn, interfaces[F("va")][F("macros")][0]); CJSON(macroAlexaOff, interfaces[F("va")][F("macros")][1]); +#ifndef WLED_DISABLE_BLYNK const char* apikey = interfaces["blynk"][F("token")] | "Hidden"; tdd = strnlen(apikey, 36); if (tdd > 20 || tdd == 0) @@ -265,7 +291,9 @@ bool deserializeConfig(JsonObject doc, bool fromFS) { JsonObject if_blynk = interfaces["blynk"]; getStringFromJson(blynkHost, if_blynk[F("host")], 33); CJSON(blynkPort, if_blynk["port"]); +#endif +#ifdef WLED_ENABLE_MQTT JsonObject if_mqtt = interfaces["mqtt"]; CJSON(mqttEnabled, if_mqtt["en"]); getStringFromJson(mqttServer, if_mqtt[F("broker")], 33); @@ -276,7 +304,9 @@ bool deserializeConfig(JsonObject doc, bool fromFS) { getStringFromJson(mqttDeviceTopic, if_mqtt[F("topics")][F("device")], 33); // "wled/test" getStringFromJson(mqttGroupTopic, if_mqtt[F("topics")][F("group")], 33); // "" +#endif +#ifndef WLED_DISABLE_HUESYNC JsonObject if_hue = interfaces[F("hue")]; CJSON(huePollingEnabled, if_hue["en"]); CJSON(huePollLightId, if_hue["id"]); @@ -292,6 +322,7 @@ bool deserializeConfig(JsonObject doc, bool fromFS) { for (byte i = 0; i < 4; i++) CJSON(hueIP[i], if_hue_ip[i]); +#endif JsonObject if_ntp = interfaces[F("ntp")]; CJSON(ntpEnabled, if_ntp["en"]); @@ -308,7 +339,7 @@ bool deserializeConfig(JsonObject doc, bool fromFS) { CJSON(countdownMode, ol[F("cntdwn")]); if (prev != overlayDefault) overlayCurrent = overlayDefault; - CJSON(overlayMin, ol[F("min")]); + CJSON(overlayMin, ol["min"]); CJSON(overlayMax, ol[F("max")]); CJSON(analogClock12pixel, ol[F("o12pix")]); CJSON(analogClock5MinuteMarks, ol[F("o5m")]); @@ -333,7 +364,7 @@ bool deserializeConfig(JsonObject doc, bool fromFS) { if (it > 9) break; if (it<8 && timer[F("hour")]==255) it=8; // hour==255 -> sunrise/sunset CJSON(timerHours[it], timer[F("hour")]); - CJSON(timerMinutes[it], timer[F("min")]); + CJSON(timerMinutes[it], timer["min"]); CJSON(timerMacro[it], timer[F("macro")]); byte dowPrev = timerWeekday[it]; @@ -379,6 +410,7 @@ bool deserializeConfig(JsonObject doc, bool fromFS) { } #endif + DEBUG_PRINTLN(F("Starting usermod config.")); JsonObject usermods_settings = doc["um"]; if (!usermods_settings.isNull()) usermods.readFromConfig(usermods_settings); @@ -492,27 +524,38 @@ void serializeConfig() { ins["type"] = bus->getType(); } + // button(s) JsonObject hw_btn = hw.createNestedObject("btn"); - + hw_btn["max"] = WLED_MAX_BUTTONS; // just information about max number of buttons (not actually used) JsonArray hw_btn_ins = hw_btn.createNestedArray("ins"); - // button BTNPIN + // there is always at least one button JsonObject hw_btn_ins_0 = hw_btn_ins.createNestedObject(); - hw_btn_ins_0["type"] = buttonType; - + hw_btn_ins_0["type"] = buttonType[0]; JsonArray hw_btn_ins_0_pin = hw_btn_ins_0.createNestedArray("pin"); - hw_btn_ins_0_pin.add(btnPin); - + hw_btn_ins_0_pin.add(btnPin[0]); JsonArray hw_btn_ins_0_macros = hw_btn_ins_0.createNestedArray("macros"); - hw_btn_ins_0_macros.add(macroButton); - hw_btn_ins_0_macros.add(macroLongPress); - hw_btn_ins_0_macros.add(macroDoublePress); + hw_btn_ins_0_macros.add(macroButton[0]); + hw_btn_ins_0_macros.add(macroLongPress[0]); + hw_btn_ins_0_macros.add(macroDoublePress[0]); + + // additional buttons + for (uint8_t i=1; i> 1; } @@ -688,7 +738,6 @@ void serializeConfig() { for (byte i = 0; i < 15; i++) dmx_fixmap.add(DMXFixtureMap[i]); #endif - //} JsonObject usermods_settings = doc.createNestedObject("um"); usermods.addToConfig(usermods_settings); @@ -715,15 +764,21 @@ bool deserializeConfigSec() { JsonObject interfaces = doc["if"]; +#ifndef WLED_DISABLE_BLYNK const char* apikey = interfaces["blynk"][F("token")] | "Hidden"; int tdd = strnlen(apikey, 36); if (tdd > 20 || tdd == 0) getStringFromJson(blynkApiKey, apikey, 36); +#endif +#ifdef WLED_ENABLE_MQTT JsonObject if_mqtt = interfaces["mqtt"]; getStringFromJson(mqttPass, if_mqtt["psk"], 41); +#endif +#ifndef WLED_DISABLE_HUESYNC getStringFromJson(hueApiKey, interfaces[F("hue")][F("key")], 47); +#endif JsonObject ota = doc["ota"]; getStringFromJson(otaPass, ota[F("pwd")], 33); @@ -750,12 +805,18 @@ void serializeConfigSec() { ap["psk"] = apPass; JsonObject interfaces = doc.createNestedObject("if"); +#ifndef WLED_DISABLE_BLYNK JsonObject if_blynk = interfaces.createNestedObject("blynk"); if_blynk[F("token")] = blynkApiKey; +#endif +#ifdef WLED_ENABLE_MQTT JsonObject if_mqtt = interfaces.createNestedObject("mqtt"); if_mqtt["psk"] = mqttPass; +#endif +#ifndef WLED_DISABLE_HUESYNC JsonObject if_hue = interfaces.createNestedObject("hue"); if_hue[F("key")] = hueApiKey; +#endif JsonObject ota = doc.createNestedObject("ota"); ota[F("pwd")] = otaPass; diff --git a/wled00/const.h b/wled00/const.h index 8acb57a7..d26c8486 100644 --- a/wled00/const.h +++ b/wled00/const.h @@ -31,37 +31,45 @@ #endif #endif +#ifndef WLED_MAX_BUTTONS + #ifdef ESP8266 + #define WLED_MAX_BUTTONS 2 + #else + #define WLED_MAX_BUTTONS 4 + #endif +#endif + //Usermod IDs -#define USERMOD_ID_RESERVED 0 //Unused. Might indicate no usermod present -#define USERMOD_ID_UNSPECIFIED 1 //Default value for a general user mod that does not specify a custom ID -#define USERMOD_ID_EXAMPLE 2 //Usermod "usermod_v2_example.h" -#define USERMOD_ID_TEMPERATURE 3 //Usermod "usermod_temperature.h" -#define USERMOD_ID_FIXNETSERVICES 4 //Usermod "usermod_Fix_unreachable_netservices.h" -#define USERMOD_ID_PIRSWITCH 5 //Usermod "usermod_PIR_sensor_switch.h" -#define USERMOD_ID_IMU 6 //Usermod "usermod_mpu6050_imu.h" -#define USERMOD_ID_FOUR_LINE_DISP 7 //Usermod "usermod_v2_four_line_display.h -#define USERMOD_ID_ROTARY_ENC_UI 8 //Usermod "usermod_v2_rotary_encoder_ui.h" -#define USERMOD_ID_AUTO_SAVE 9 //Usermod "usermod_v2_auto_save.h" -#define USERMOD_ID_DHT 10 //Usermod "usermod_dht.h" -#define USERMOD_ID_MODE_SORT 11 //Usermod "usermod_v2_mode_sort.h" -#define USERMOD_ID_VL53L0X 12 //Usermod "usermod_vl53l0x_gestures.h" -#define USERMOD_ID_MULTI_RELAY 101 //Usermod "usermod_multi_relay.h" -#define USERMOD_ID_ANIMATED_STAIRCASE 102 //Usermod "Animated_Staircase.h" +#define USERMOD_ID_RESERVED 0 //Unused. Might indicate no usermod present +#define USERMOD_ID_UNSPECIFIED 1 //Default value for a general user mod that does not specify a custom ID +#define USERMOD_ID_EXAMPLE 2 //Usermod "usermod_v2_example.h" +#define USERMOD_ID_TEMPERATURE 3 //Usermod "usermod_temperature.h" +#define USERMOD_ID_FIXNETSERVICES 4 //Usermod "usermod_Fix_unreachable_netservices.h" +#define USERMOD_ID_PIRSWITCH 5 //Usermod "usermod_PIR_sensor_switch.h" +#define USERMOD_ID_IMU 6 //Usermod "usermod_mpu6050_imu.h" +#define USERMOD_ID_FOUR_LINE_DISP 7 //Usermod "usermod_v2_four_line_display.h +#define USERMOD_ID_ROTARY_ENC_UI 8 //Usermod "usermod_v2_rotary_encoder_ui.h" +#define USERMOD_ID_AUTO_SAVE 9 //Usermod "usermod_v2_auto_save.h" +#define USERMOD_ID_DHT 10 //Usermod "usermod_dht.h" +#define USERMOD_ID_MODE_SORT 11 //Usermod "usermod_v2_mode_sort.h" +#define USERMOD_ID_VL53L0X 12 //Usermod "usermod_vl53l0x_gestures.h" +#define USERMOD_ID_MULTI_RELAY 13 //Usermod "usermod_multi_relay.h" +#define USERMOD_ID_ANIMATED_STAIRCASE 14 //Usermod "Animated_Staircase.h" //Access point behavior -#define AP_BEHAVIOR_BOOT_NO_CONN 0 //Open AP when no connection after boot -#define AP_BEHAVIOR_NO_CONN 1 //Open when no connection (either after boot or if connection is lost) -#define AP_BEHAVIOR_ALWAYS 2 //Always open -#define AP_BEHAVIOR_BUTTON_ONLY 3 //Only when button pressed for 6 sec +#define AP_BEHAVIOR_BOOT_NO_CONN 0 //Open AP when no connection after boot +#define AP_BEHAVIOR_NO_CONN 1 //Open when no connection (either after boot or if connection is lost) +#define AP_BEHAVIOR_ALWAYS 2 //Always open +#define AP_BEHAVIOR_BUTTON_ONLY 3 //Only when button pressed for 6 sec //Notifier callMode -#define NOTIFIER_CALL_MODE_INIT 0 //no updates on init, can be used to disable updates +#define NOTIFIER_CALL_MODE_INIT 0 //no updates on init, can be used to disable updates #define NOTIFIER_CALL_MODE_DIRECT_CHANGE 1 #define NOTIFIER_CALL_MODE_BUTTON 2 #define NOTIFIER_CALL_MODE_NOTIFICATION 3 #define NOTIFIER_CALL_MODE_NIGHTLIGHT 4 #define NOTIFIER_CALL_MODE_NO_NOTIFY 5 -#define NOTIFIER_CALL_MODE_FX_CHANGED 6 //no longer used +#define NOTIFIER_CALL_MODE_FX_CHANGED 6 //no longer used #define NOTIFIER_CALL_MODE_HUE 7 #define NOTIFIER_CALL_MODE_PRESET_CYCLE 8 #define NOTIFIER_CALL_MODE_BLYNK 9 @@ -148,9 +156,10 @@ #define BTN_TYPE_NONE 0 #define BTN_TYPE_RESERVED 1 #define BTN_TYPE_PUSH 2 -#define BTN_TYPE_PUSH_ACT_HIGH 3 //not implemented +#define BTN_TYPE_PUSH_ACT_HIGH 3 #define BTN_TYPE_SWITCH 4 -#define BTN_TYPE_SWITCH_ACT_HIGH 5 //not implemented +#define BTN_TYPE_SWITCH_ACT_HIGH 5 +#define BTN_TYPE_TOUCH 6 //Ethernet board types #define WLED_NUM_ETH_TYPES 5 @@ -203,7 +212,7 @@ // maximum number of LEDs - more than 1500 LEDs (or 500 DMA "LEDPIN 3" driven ones) will cause a low memory condition on ESP8266 #ifndef MAX_LEDS #ifdef ESP8266 -#define MAX_LEDS 8192 //rely on memory limit to limit this to 1600 LEDs +#define MAX_LEDS 1664 // can't rely on memory limit to limit this to 1600 LEDs #else #define MAX_LEDS 8192 #endif @@ -243,7 +252,7 @@ #ifdef ESP8266 #define JSON_BUFFER_SIZE 9216 #else - #define JSON_BUFFER_SIZE 16384 + #define JSON_BUFFER_SIZE 20480 #endif // Maximum size of node map (list of other WLED instances) diff --git a/wled00/data/settings_leds.htm b/wled00/data/settings_leds.htm index 2addd732..504dbd2b 100644 --- a/wled00/data/settings_leds.htm +++ b/wled00/data/settings_leds.htm @@ -1,356 +1,409 @@ - - - - - - LED Settings - - - - -
-
-
-

LED & Hardware setup

- Total LED count:
- Recommended power supply for brightest white:
- ?
-
-
- Enable automatic brightness limiter:
-
- Maximum Current: mA
- - Automatically limits brightness to stay close to the limit.
- Keep at <1A if powering LEDs directly from the ESP 5V pin!
- If you are using an external power supply, enter its rating.
- (Current estimated usage: unknown)


- LED voltage (Max. current for a single LED):
-
- - Keep at default if you are unsure about your type of LEDs.
-
-

Hardware setup

-
LED outputs:
- -
- LED Memory Usage: 0 / ? B
-

- - Button pin:  ×
- IR pin:  ×
- Relay pin:  ×
- Active high -

Defaults

- Turn LEDs on after power up/reset:
- Default brightness: (0-255)

- Apply preset at boot (0 uses defaults) -
- or -
- Set current preset cycle setting as boot default:

- Use Gamma correction for color: (strongly recommended)
- Use Gamma correction for brightness: (not recommended)

- Brightness factor: % -

Transitions

- Crossfade:
- Transition Time: ms
- Enable Palette transitions: -

Timed light

- Default Duration: min
- Default Target brightness:
- Mode: - -

Advanced

- Palette blending: -
- - Auto-calculate white channel from RGB:
- -

- -
- - + + + + + + LED Settings + + + + +
+
+
+

LED & Hardware setup

+ Total LED count:
+ Recommended power supply for brightest white:
+ ?
+
+
+ Enable automatic brightness limiter:
+
+ Maximum Current: mA
+ + Automatically limits brightness to stay close to the limit.
+ Keep at <1A if powering LEDs directly from the ESP 5V pin!
+ If you are using an external power supply, enter its rating.
+ (Current estimated usage: unknown)


+ LED voltage (Max. current for a single LED):
+
+ + Keep at default if you are unsure about your type of LEDs.
+
+

Hardware setup

+
LED outputs:
+ +
+ LED Memory Usage: 0 / ? B
+

+
+
+ Touch threshold:
+ IR pin:  ×
+ IR info
+ Relay pin: invert  ×
+
+

Defaults

+ Turn LEDs on after power up/reset:
+ Default brightness: (0-255)

+ Apply preset at boot (0 uses defaults) +
- or -
+ Set current preset cycle setting as boot default:

+ Use Gamma correction for color: (strongly recommended)
+ Use Gamma correction for brightness: (not recommended)

+ Brightness factor: % +

Transitions

+ Crossfade:
+ Transition Time: ms
+ Enable Palette transitions: +

Timed light

+ Default Duration: min
+ Default Target brightness:
+ Mode: + +

Advanced

+ Palette blending: +
+ + Auto-calculate white channel from RGB:
+ +

+ +
+ + diff --git a/wled00/data/settings_sync.htm b/wled00/data/settings_sync.htm index c1e28197..ff6e1082 100644 --- a/wled00/data/settings_sync.htm +++ b/wled00/data/settings_sync.htm @@ -15,29 +15,10 @@ function GetV(){var d=document;}

Sync setup

-

Button setup

-Button type: -
-Infrared remote: -
-IR info

WLED Broadcast

UDP Port:
2nd Port:
-Receive Brightness, Color, and Effects
+Receive: Brightness, Color, and Effects
Send notifications on direct change:
Send notifications on button press or IR:
Send Alexa notifications:
diff --git a/wled00/data/settings_time.htm b/wled00/data/settings_time.htm index f8a0d9f1..53b893fb 100644 --- a/wled00/data/settings_time.htm +++ b/wled00/data/settings_time.htm @@ -6,41 +6,41 @@ Time Settings - +

404 Not Found

Akemi does not know where you are headed...

diff --git a/wled00/data/welcome.htm b/wled00/data/welcome.htm index f0e1b463..1b2bb60f 100644 --- a/wled00/data/welcome.htm +++ b/wled00/data/welcome.htm @@ -31,11 +31,11 @@ } img { - width: 999px; - max-width: 85%; + width: 950px; + max-width: 82%; image-rendering: pixelated; image-rendering: crisp-edges; - margin: 25px 0 -10px 0; + margin: 4vh 0 0 0; animation: fi 1s; } @@ -50,7 +50,7 @@ - +

Welcome to WLED!

Thank you for installing my application!

diff --git a/wled00/html_other.h b/wled00/html_other.h index 75489818..19d6667e 100644 --- a/wled00/html_other.h +++ b/wled00/html_other.h @@ -55,9 +55,9 @@ Please do not close or refresh the page :)
)====="; const char PAGE_welcome[] PROGMEM = R"=====(Welcome! +src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAG0AAAAfCAMAAADazLOuAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAABLUExURQAAAAB81gCU/zKq///mo7sWMN8bO+ZIYtZaAP9rAP+HMsCiG+TAIOnMS0KqNU7KPnLUZOrq6v///4CAgGhoaL+/v6CgoExMTAAAAAlm4O8AAAAZdFJOU////////////////////////////////wABNAq3AAAACXBIWXMAAA7DAAAOwwHHb6hkAAACN0lEQVRIS73VjVLCMBAEYIr8CYKkrdj3f1J37zaXFCpTO+piaDgbPq9px9VQ0qyrvKj4q6m0Zr1h+M7xF1zRmnWzqV9/0d2jttGotO1uv9dUObwej5oqp7fzWVPl8n69aprzoOUUbbvdIbV3OLwitXc6vSG1d7m8I3feSEN0j2CeNbOY4MxigjOLCc4sZsTV2l1cCyy4wIILLLjAxtykltq2rbTU+qi01N5rXNO2leaFORoija2l5MM5a02ac9Ya16Sk5tgaPrUpjZub0BL6YqSxKwbH77XUUmSkJXSl8QtaMuyJhq5maL5nTKVpZC13VmtMpTFT2g4vJjTuGfMzzXftiUZnhdtgb1xofvypRon5TjNnxYN9zJo6K5ruSIzQtGuVZn0x91rKvdHBvm39E7SyZ4y06Gz8BDBFKzsXmhcwyfsGZ9VpbhoiCinaxPNmGWmWWrNU2jB0q6HvOhN1JUtCixQtp2g51ZVUXIPS2RMAD++T2nY/DrDjOMDO4wC7jmNYj3d73nrXug8Yt9uNB8xNU1cKNXWlUFNXCjV1pZhGTE83m2vWfYf/NGj4Bg1zu5JD3/MnH5ZWfLOksbmGWGjgXMN5/C2GXYGFFW9Nmtle6Xut0Gm+JsayCj8z0nhjGvYJzVf4aSzmNYsr+u7Q2JIdoX3YOQjOslmsW1jJ3120nE9gfo79hTaNdcsqVR610lvO47pllae9ReZ805zKo2a3iaY5c75pTmVCA6dJ5H7N0sr/asPwBehb7ifEhusRAAAAAElFTkSuQmCC">

Welcome to WLED!

Thank you for installing my application!

Next steps:

Connect the module to your local WiFi here!
)====="; diff --git a/wled00/wled.h b/wled00/wled.h index 88055a16..8ce5a7b3 100644 --- a/wled00/wled.h +++ b/wled00/wled.h @@ -8,7 +8,7 @@ */ // version code in format yymmddb (b = daily build) -#define VERSION 2106100 +#define VERSION 2106140 //uncomment this if you have a "my_config.h" file you'd like to use //#define WLED_USE_MY_CONFIG