diff --git a/platformio.ini b/platformio.ini index 9df10889..b5f3ecd4 100644 --- a/platformio.ini +++ b/platformio.ini @@ -252,6 +252,23 @@ lib_deps = makuna/NeoPixelBus @ 2.6.9 https://github.com/pbolduc/AsyncTCP.git @ 1.2.0 +[esp32s3] +;; generic definitions for all ESP32-S3 boards +build_flags = -g + -DESP32 + -DARDUINO_ARCH_ESP32 + -DARDUINO_ARCH_ESP32S3 + -DCONFIG_IDF_TARGET_ESP32S3 + -D CONFIG_ASYNC_TCP_USE_WDT=0 + -DCO + +lib_deps = + ${env.lib_deps} + ;; currently we need the latest NeoPixelBus dev version, because it contains important bugfixes for -S3 + https://github.com/Makuna/NeoPixelBus.git#master @ 2.7.0 + https://github.com/pbolduc/AsyncTCP.git @ 1.2.0 + + # ------------------------------------------------------------------------------ # WLED BUILDS # ------------------------------------------------------------------------------ @@ -375,6 +392,20 @@ upload_speed = 460800 build_unflags = ${common.build_unflags} lib_deps = ${esp32c3.lib_deps} +[env:esp32s3dev_8MB] +;; ESP32-S3-DevKitC-1 development board, with 8MB FLASH, no PSRAM +board = esp32-s3-devkitc-1 +platform = espressif32@5.1.1 +platform_packages = platformio/framework-arduinoespressif32@3.20004.220825 +upload_speed = 921600 +build_unflags = ${common.build_unflags} +build_flags = ${common.build_flags} ${esp32s3.build_flags} -D CONFIG_LITTLEFS_FOR_IDF_3_2 -D WLED_WATCHDOG_TIMEOUT=0 -D ARDUINO_USB_MODE=1 -D ARDUINO_USB_CDC_ON_BOOT=0 -D ARDUINO_USB_MSC_ON_BOOT=0 +lib_deps = ${esp32s3.lib_deps} +board_build.partitions = tools/WLED_ESP32_8MB.csv +board_build.f_flash = 80000000L +board_build.flash_mode = qio +monitor_filters = esp32_exception_decoder + [env:esp8285_4CH_MagicHome] board = esp8285 platform = ${common.platform_wled_default} @@ -437,6 +468,29 @@ build_unflags = ${common.build_unflags} build_flags = ${common.build_flags_esp8266} -D LEDPIN=12 -D IRPIN=-1 -D RLYPIN=2 lib_deps = ${esp8266.lib_deps} +[env:lolin_s2_mini] +platform = espressif32@5.1.1 +board = lolin_s2_mini +board_build.partitions = tools/WLED_ESP32_4MB_1MB_FS.csv +build_unflags = ${common.build_unflags} +build_flags = ${common.build_flags} ${esp32s2.build_flags} #-D WLED_RELEASE_NAME=LolinS2 + -DBOARD_HAS_PSRAM + -D ARDUINO_USB_CDC_ON_BOOT + -D WLED_USE_PSRAM + -D WLED_WATCHDOG_TIMEOUT=0 + -D CONFIG_ASYNC_TCP_USE_WDT=0 + -D LEDPIN=16 + -D BTNPIN=18 + -D RLYPIN=9 + -D IRPIN=7 + -D HW_PIN_SCL=35 + -D HW_PIN_SDA=33 + -D HW_PIN_CLOCKSPI=7 + -D HW_PIN_DATASPI=11 + -D HW_PIN_MISOSPI=9 +; -D STATUSLED=15 +lib_deps = ${esp32s2.lib_deps} + # ------------------------------------------------------------------------------ # custom board configurations # ------------------------------------------------------------------------------ diff --git a/usermods/usermod_v2_word_clock/readme.md b/usermods/usermod_v2_word_clock/readme.md index 9c4d1ac0..ae87b744 100644 --- a/usermods/usermod_v2_word_clock/readme.md +++ b/usermods/usermod_v2_word_clock/readme.md @@ -1,11 +1,12 @@ # Word Clock Usermod V2 This usermod can be used to drive a wordclock with a 11x10 pixel matrix with WLED. There are also 4 additional dots for the minutes. -The visualisation is desribed in 4 mask with LED numbers (single dots for minutes, minutes, hours and "clock/Uhr"). -There are 2 parameters to chnage the behaviour: +The visualisation is desribed in 4 mask with LED numbers (single dots for minutes, minutes, hours and "clock/Uhr"). The index of the LEDs in the masks always starts with the index 0, even if the ledOffset is not 0. +There are 3 parameters to change the behaviour: active: enable/disable usermod -diplayItIs: enable/disable display of "Es ist" on the clock. +diplayItIs: enable/disable display of "Es ist" on the clock +ledOffset: number of LEDs before the wordclock LEDs ## Installation diff --git a/usermods/usermod_v2_word_clock/usermod_v2_word_clock.h b/usermods/usermod_v2_word_clock/usermod_v2_word_clock.h index 10b83dd0..87f68f48 100644 --- a/usermods/usermod_v2_word_clock/usermod_v2_word_clock.h +++ b/usermods/usermod_v2_word_clock/usermod_v2_word_clock.h @@ -23,6 +23,7 @@ class WordClockUsermod : public Usermod // set your config variables to their boot default value (this can also be done in readFromConfig() or a constructor if you prefer) bool usermodActive = false; bool displayItIs = false; + int ledOffset = 100; // defines for mask sizes #define maskSizeLeds 114 @@ -358,6 +359,7 @@ class WordClockUsermod : public Usermod JsonObject top = root.createNestedObject("WordClockUsermod"); top["active"] = usermodActive; top["displayItIs"] = displayItIs; + top["ledOffset"] = ledOffset; } /* @@ -386,6 +388,7 @@ class WordClockUsermod : public Usermod configComplete &= getJsonValue(top["active"], usermodActive); configComplete &= getJsonValue(top["displayItIs"], displayItIs); + configComplete &= getJsonValue(top["ledOffset"], ledOffset); return configComplete; } @@ -407,7 +410,7 @@ class WordClockUsermod : public Usermod if (maskLedsOn[x] == 0) { // set pixel off - strip.setPixelColor(x, RGBW32(0,0,0,0)); + strip.setPixelColor(x + ledOffset, RGBW32(0,0,0,0)); } } } diff --git a/wled00/cfg.cpp b/wled00/cfg.cpp index 8b3b2221..271ded17 100644 --- a/wled00/cfg.cpp +++ b/wled00/cfg.cpp @@ -377,6 +377,7 @@ bool deserializeConfig(JsonObject doc, bool fromFS) { CJSON(e131Universe, if_live_dmx[F("uni")]); CJSON(e131SkipOutOfSequence, if_live_dmx[F("seqskip")]); CJSON(DMXAddress, if_live_dmx[F("addr")]); + if (!DMXAddress || DMXAddress > 510) DMXAddress = 1; CJSON(DMXMode, if_live_dmx["mode"]); tdd = if_live[F("timeout")] | -1; diff --git a/wled00/data/settings_sync.htm b/wled00/data/settings_sync.htm index 595dac29..0e59c248 100644 --- a/wled00/data/settings_sync.htm +++ b/wled00/data/settings_sync.htm @@ -13,7 +13,7 @@ } function H(){window.open("https://kno.wled.ge/interfaces/udp-notifier/");} function B(){window.open("/settings","_self");} - function adj(){if (d.Sf.DI.value == 6454) {if (d.Sf.DA.value == 1) d.Sf.DA.value = 0; if (d.Sf.EU.value == 1) d.Sf.EU.value = 0;} + function adj(){if (d.Sf.DI.value == 6454) {if (d.Sf.EU.value == 1) d.Sf.EU.value = 0;} else if (d.Sf.DI.value == 5568) {if (d.Sf.DA.value == 0) d.Sf.DA.value = 1; if (d.Sf.EU.value == 0) d.Sf.EU.value = 1;} } // https://www.educative.io/edpresso/how-to-dynamically-load-a-js-file-in-javascript function loadJS(FILE_URL, async = true) { @@ -147,7 +147,7 @@ Multicast:
Start universe:
Reboot required. Check out LedFx!
Skip out-of-sequence packets:
-DMX start address:
+DMX start address:
DMX mode: