Merge branch 'main' into e131-prio

This commit is contained in:
mxklb 2022-12-20 01:07:18 +01:00
commit 3a5a3a0d09
89 changed files with 4055 additions and 2626 deletions

View File

@ -56,6 +56,9 @@ body:
options: options:
- ESP8266 - ESP8266
- ESP32 - ESP32
- ESP32-S3
- ESP32-S2
- ESP32-C3
- Other - Other
validations: validations:
required: true required: true

6
package-lock.json generated
View File

@ -1742,9 +1742,9 @@
"integrity": "sha1-fjL3W0E4EpHQRhHxvxQQmsAGUdc=" "integrity": "sha1-fjL3W0E4EpHQRhHxvxQQmsAGUdc="
}, },
"qs": { "qs": {
"version": "6.5.2", "version": "6.5.3",
"resolved": "https://registry.npmjs.org/qs/-/qs-6.5.2.tgz", "resolved": "https://registry.npmjs.org/qs/-/qs-6.5.3.tgz",
"integrity": "sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA==" "integrity": "sha512-qxXIEh4pCGfHICj1mAJQ2/2XVZkjCDTcEgfoSQxc/fYivUZxTkk7L3bDBJSoNrEzXI17oUO5Dp07ktqE5KzczA=="
}, },
"rc": { "rc": {
"version": "1.2.8", "version": "1.2.8",

View File

@ -6,16 +6,14 @@
# ENVIRONMENTS # ENVIRONMENTS
# #
# Please uncomment one of the lines below to select your board(s) # Please uncomment one of the lines below to select your board(s)
# (use `platformio_override.ini` when building for your own board; see `platformio_override.ini.sample` for an example)
# ------------------------------------------------------------------------------ # ------------------------------------------------------------------------------
# Travis CI binaries (use `platformio_override.ini` when building for your own board; see `platformio_override.ini.sample` for an example) # Release / CI binaries
; default_envs = travis_esp8266, travis_esp32 default_envs = nodemcuv2, esp8266_2m, esp01_1m_full, esp32dev, esp32_eth, esp32s2_saola, esp32c3, esp32s3dev_8MB
# Release binaries
default_envs = nodemcuv2, esp8266_2m, esp01_1m_full, esp32dev, esp32_eth, esp32s2_saola, esp32c3
# Build everything # Build everything
; default_envs = esp32dev, esp8285_4CH_MagicHome, codm-controller-0.6-rev2, codm-controller-0.6, esp32s2_saola, d1_mini_5CH_Shojo_PCB, d1_mini, sp501e, travis_esp8266, travis_esp32, nodemcuv2, esp32_eth, anavi_miracle_controller, esp07, esp01_1m_full, m5atom, h803wf, d1_mini_ota, heltec_wifi_kit_8, esp8285_H801, d1_mini_debug, wemos_shield_esp32, elekstube_ips ; default_envs = esp32dev, esp8285_4CH_MagicHome, codm-controller-0.6-rev2, codm-controller-0.6, esp32s2_saola, d1_mini_5CH_Shojo_PCB, d1_mini, sp501e, nodemcuv2, esp32_eth, anavi_miracle_controller, esp07, esp01_1m_full, m5atom, h803wf, d1_mini_ota, heltec_wifi_kit_8, esp8285_H801, d1_mini_debug, wemos_shield_esp32, elekstube_ips
# Single binaries (uncomment your board) # Single binaries (uncomment your board)
; default_envs = elekstube_ips ; default_envs = elekstube_ips
@ -113,6 +111,7 @@ build_flags =
-D DECODE_SONY=true -D DECODE_SONY=true
-D DECODE_SAMSUNG=true -D DECODE_SAMSUNG=true
-D DECODE_LG=true -D DECODE_LG=true
; -Dregister= # remove warnings in C++17 due to use of deprecated register keyword by the FastLED library
-DWLED_USE_MY_CONFIG -DWLED_USE_MY_CONFIG
; -D USERMOD_SENSORSTOMQTT ; -D USERMOD_SENSORSTOMQTT
#For ADS1115 sensor uncomment following #For ADS1115 sensor uncomment following
@ -120,13 +119,6 @@ build_flags =
build_unflags = build_unflags =
# enables all features for travis CI
build_flags_all_features =
-D WLED_ENABLE_ADALIGHT
-D WLED_ENABLE_DMX
-D WLED_ENABLE_MQTT
-D WLED_ENABLE_WEBSOCKETS
build_flags_esp8266 = ${common.build_flags} ${esp8266.build_flags} build_flags_esp8266 = ${common.build_flags} ${esp8266.build_flags}
build_flags_esp32 = ${common.build_flags} ${esp32.build_flags} build_flags_esp32 = ${common.build_flags} ${esp32.build_flags}
@ -269,8 +261,8 @@ build_flags = -g
lib_deps = lib_deps =
${env.lib_deps} ${env.lib_deps}
;; currently we need the latest NeoPixelBus dev version, because it contains important bugfixes for -S3 ;; NeoPixelBus 2.7.1 is the first that has official support for ESP32-S3
https://github.com/Makuna/NeoPixelBus.git#master @ 2.7.0 makuna/NeoPixelBus @ ~2.7.1
https://github.com/pbolduc/AsyncTCP.git @ 1.2.0 https://github.com/pbolduc/AsyncTCP.git @ 1.2.0
@ -284,7 +276,7 @@ platform = ${common.platform_wled_default}
platform_packages = ${common.platform_packages} platform_packages = ${common.platform_packages}
board_build.ldscript = ${common.ldscript_4m1m} board_build.ldscript = ${common.ldscript_4m1m}
build_unflags = ${common.build_unflags} build_unflags = ${common.build_unflags}
build_flags = ${common.build_flags_esp8266} -D WLED_RELEASE_NAME=ESP8266 build_flags = ${common.build_flags_esp8266} -D WLED_RELEASE_NAME=ESP8266 #-DWLED_DISABLE_2D
lib_deps = ${esp8266.lib_deps} lib_deps = ${esp8266.lib_deps}
monitor_filters = esp8266_exception_decoder monitor_filters = esp8266_exception_decoder
@ -385,6 +377,7 @@ board_build.partitions = tools/WLED_ESP32_4MB_1MB_FS.csv
board_build.flash_mode = qio board_build.flash_mode = qio
upload_speed = 460800 upload_speed = 460800
build_unflags = ${common.build_unflags} build_unflags = ${common.build_unflags}
build_flags = ${common.build_flags} ${esp32s2.build_flags} #-D WLED_RELEASE_NAME=S2_saola
lib_deps = ${esp32s2.lib_deps} lib_deps = ${esp32s2.lib_deps}
[env:esp32c3] [env:esp32c3]
@ -403,13 +396,18 @@ lib_deps = ${esp32c3.lib_deps}
board = esp32-s3-devkitc-1 board = esp32-s3-devkitc-1
platform = espressif32@5.1.1 platform = espressif32@5.1.1
platform_packages = platform_packages =
upload_speed = 921600 upload_speed = 921600 ; or 460800
build_unflags = ${common.build_unflags} 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 build_flags = ${common.build_flags} ${esp32s3.build_flags}
-D CONFIG_LITTLEFS_FOR_IDF_3_2 -D WLED_WATCHDOG_TIMEOUT=0
-D ARDUINO_USB_CDC_ON_BOOT=0 -D ARDUINO_USB_MSC_ON_BOOT=0 -D ARDUINO_DFU_ON_BOOT=0 -D ARDUINO_USB_MODE=1 ;; for boards with serial-to-USB chip
;-D ARDUINO_USB_CDC_ON_BOOT=1 -D ARDUINO_USB_MSC_ON_BOOT=0 -D ARDUINO_DFU_ON_BOOT=0 ; -D ARDUINO_USB_MODE=0 ;; for boards with USB-OTG connector only (USBCDC or "TinyUSB")
;-D WLED_DEBUG
lib_deps = ${esp32s3.lib_deps} lib_deps = ${esp32s3.lib_deps}
board_build.partitions = tools/WLED_ESP32_8MB.csv board_build.partitions = tools/WLED_ESP32_8MB.csv
board_build.f_flash = 80000000L board_build.f_flash = 80000000L
board_build.flash_mode = qio board_build.flash_mode = qio
; board_build.flash_mode = dio ;; try this if you have problems at startup
monitor_filters = esp32_exception_decoder monitor_filters = esp32_exception_decoder
[env:esp32s3dev_8MB_PSRAM] [env:esp32s3dev_8MB_PSRAM]
@ -422,8 +420,8 @@ platform_packages =
upload_speed = 921600 upload_speed = 921600
build_unflags = ${common.build_unflags} build_unflags = ${common.build_unflags}
build_flags = ${common.build_flags} ${esp32s3.build_flags} 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_MSC_ON_BOOT=0 -D CONFIG_LITTLEFS_FOR_IDF_3_2 -D WLED_WATCHDOG_TIMEOUT=0
; -D ARDUINO_USB_CDC_ON_BOOT=0 -D ARDUINO_USB_MODE=1 -D ARDUINO_USB_MSC_ON_BOOT=0 ; -D ARDUINO_USB_CDC_ON_BOOT=0
; -D WLED_RELEASE_NAME=ESP32-S3_PSRAM ; -D WLED_RELEASE_NAME=ESP32-S3_PSRAM
-D WLED_USE_PSRAM -DBOARD_HAS_PSRAM ; tells WLED that PSRAM shall be used -D WLED_USE_PSRAM -DBOARD_HAS_PSRAM ; tells WLED that PSRAM shall be used
lib_deps = ${esp32s3.lib_deps} lib_deps = ${esp32s3.lib_deps}
@ -588,22 +586,6 @@ build_unflags = ${common.build_unflags}
build_flags = ${common.build_flags_esp8266} -D WLED_RELEASE_NAME=ESP01 -D WLED_DISABLE_OTA -D USERMOD_MY9291 build_flags = ${common.build_flags_esp8266} -D WLED_RELEASE_NAME=ESP01 -D WLED_DISABLE_OTA -D USERMOD_MY9291
lib_deps = ${esp8266.lib_deps} lib_deps = ${esp8266.lib_deps}
# ------------------------------------------------------------------------------
# travis test board configurations
# ------------------------------------------------------------------------------
[env:travis_esp8266]
extends = env:d1_mini
build_type = debug
build_unflags = ${common.build_unflags}
build_flags = ${common.build_flags_esp8266} ${common.debug_flags} ${common.build_flags_all_features}
[env:travis_esp32]
extends = env:esp32dev
; build_type = debug
build_unflags = ${common.build_unflags}
build_flags = ${common.build_flags_esp32} ${common.debug_flags} ${common.build_flags_all_features}
# ------------------------------------------------------------------------------ # ------------------------------------------------------------------------------
# codm pixel controller board configurations # codm pixel controller board configurations
# codm-controller-0.6 can also be used for the TYWE3S controller # codm-controller-0.6 can also be used for the TYWE3S controller

View File

@ -15,11 +15,11 @@
A fast and feature-rich implementation of an ESP8266/ESP32 webserver to control NeoPixel (WS2812B, WS2811, SK6812) LEDs or also SPI based chipsets like the WS2801 and APA102! A fast and feature-rich implementation of an ESP8266/ESP32 webserver to control NeoPixel (WS2812B, WS2811, SK6812) LEDs or also SPI based chipsets like the WS2801 and APA102!
## ⚙️ Features ## ⚙️ Features
- WS2812FX library integrated for over 100 special effects - WS2812FX library with more than 100 special effects
- FastLED noise effects and 50 palettes - FastLED noise effects and 50 palettes
- Modern UI with color, effect and segment controls - Modern UI with color, effect and segment controls
- Segments to set different effects and colors to parts of the LEDs - Segments to set different effects and colors to user defined parts of the LED string
- Settings page - configuration over network - Settings page - configuration via the network
- Access Point and station mode - automatic failsafe AP - Access Point and station mode - automatic failsafe AP
- Up to 10 LED outputs per instance - Up to 10 LED outputs per instance
- Support for RGBW strips - Support for RGBW strips
@ -28,7 +28,7 @@ A fast and feature-rich implementation of an ESP8266/ESP32 webserver to control
- Nightlight function (gradually dims down) - Nightlight function (gradually dims down)
- Full OTA software updatability (HTTP + ArduinoOTA), password protectable - Full OTA software updatability (HTTP + ArduinoOTA), password protectable
- Configurable analog clock (Cronixie, 7-segment and EleksTube IPS clock support via usermods) - Configurable analog clock (Cronixie, 7-segment and EleksTube IPS clock support via usermods)
- Configurable Auto Brightness limit for safer operation - Configurable Auto Brightness limit for safe operation
- Filesystem-based config for easier backup of presets and settings - Filesystem-based config for easier backup of presets and settings
## 💡 Supported light control interfaces ## 💡 Supported light control interfaces
@ -51,7 +51,7 @@ A fast and feature-rich implementation of an ESP8266/ESP32 webserver to control
See the [documentation on our official site](https://kno.wled.ge)! See the [documentation on our official site](https://kno.wled.ge)!
[On this page](https://kno.wled.ge/basics/tutorials/) you can find excellent tutorials made by the community and helpful tools to help you get your new lamp up and running! [On this page](https://kno.wled.ge/basics/tutorials/) you can find excellent tutorials and tools to help you get your new project up and running!
## 🖼️ User interface ## 🖼️ User interface
<img src="/images/macbook-pro-space-gray-on-the-wooden-table.jpg" width="50%"><img src="/images/walking-with-iphone-x.jpg" width="50%"> <img src="/images/macbook-pro-space-gray-on-the-wooden-table.jpg" width="50%"><img src="/images/walking-with-iphone-x.jpg" width="50%">
@ -70,12 +70,16 @@ Join the Discord server to discuss everything about WLED!
<a href="https://discord.gg/KuqP7NE"><img src="https://discordapp.com/api/guilds/473448917040758787/widget.png?style=banner2" width="25%"></a> <a href="https://discord.gg/KuqP7NE"><img src="https://discordapp.com/api/guilds/473448917040758787/widget.png?style=banner2" width="25%"></a>
Check out the WLED [Discourse forum](https://wled.discourse.group)! Check out the WLED [Discourse forum](https://wled.discourse.group)!
You can also send me mails to [dev.aircoookie@gmail.com](mailto:dev.aircoookie@gmail.com), but please only do so if you want to talk to me privately.
If WLED really brightens up your every day, you can [![](https://img.shields.io/badge/send%20me%20a%20small%20gift-paypal-blue.svg?style=flat-square)](https://paypal.me/aircoookie) You can also send me mails to [dev.aircoookie@gmail.com](mailto:dev.aircoookie@gmail.com), but please, only do so if you want to talk to me privately.
If WLED really brightens up your day, you can [![](https://img.shields.io/badge/send%20me%20a%20small%20gift-paypal-blue.svg?style=flat-square)](https://paypal.me/aircoookie)
*Disclaimer:* *Disclaimer:*
If you are sensitive to photosensitive epilepsy it is not recommended that you use this software.
In case you still want to try, don't use strobe, lighting or noise modes or high effect speed settings. If you are prone to photosensitive epilepsy, we recommended you do **not** use this software.
If you still want to try, don't use strobe, lighting or noise modes or high effect speed settings.
As per the MIT license, I assume no liability for any damage to you or any other person or equipment. As per the MIT license, I assume no liability for any damage to you or any other person or equipment.

View File

@ -14,7 +14,7 @@ async-timeout==4.0.2
# via zeroconf # via zeroconf
bottle==0.12.23 bottle==0.12.23
# via platformio # via platformio
certifi==2022.6.15 certifi==2022.12.7
# via requests # via requests
charset-normalizer==2.1.1 charset-normalizer==2.1.1
# via requests # via requests
@ -23,9 +23,7 @@ click==8.1.3
# platformio # platformio
# uvicorn # uvicorn
colorama==0.4.5 colorama==0.4.5
# via # via platformio
# click
# platformio
h11==0.13.0 h11==0.13.0
# via # via
# uvicorn # uvicorn
@ -58,8 +56,6 @@ starlette==0.20.4
# via platformio # via platformio
tabulate==0.8.10 tabulate==0.8.10
# via platformio # via platformio
typing-extensions==4.3.0
# via starlette
urllib3==1.26.11 urllib3==1.26.11
# via requests # via requests
uvicorn==0.18.2 uvicorn==0.18.2

View File

@ -2,7 +2,7 @@
This usermod will read from an ADS1115 ADC. The voltages are displayed in the Info section of the web UI. This usermod will read from an ADS1115 ADC. The voltages are displayed in the Info section of the web UI.
Configuration is all completed via the Usermod menu. There are no settings to set in code! Configuration is performed via the Usermod menu. There are no parameters to set in code!
## Installation ## Installation

View File

@ -1,14 +1,14 @@
# Usermod Animated Staircase # Usermod Animated Staircase
This usermod makes your staircase look cool by switching it on with an animation. It uses This usermod makes your staircase look cool by illuminating it with an animation. It uses
PIR or ultrasonic sensors at the top and bottom of your stairs to: PIR or ultrasonic sensors at the top and bottom of your stairs to:
- Light up the steps in your walking direction, leading the way. - Light up the steps in the direction you're walking.
- Switch off the steps after you, in the direction of the last detected movement. - Switch off the steps after you, in the direction of the last detected movement.
- Always switch on when one of the sensors detects movement, even if an effect - Always switch on when one of the sensors detects movement, even if an effect
is still running. It can therewith handle multiple people on the stairs gracefully. is still running. It can gracefully handle multiple people on the stairs.
The Animated Staircase can be controlled by the WLED API. Change settings such as The Animated Staircase can be controlled by the WLED API. Change settings such as
speed, on/off time and distance settings by sending an HTTP request, see below. speed, on/off time and distance by sending an HTTP request, see below.
## WLED integration ## WLED integration
To include this usermod in your WLED setup, you have to be able to [compile WLED from source](https://github.com/Aircoookie/WLED/wiki/Compiling-WLED). To include this usermod in your WLED setup, you have to be able to [compile WLED from source](https://github.com/Aircoookie/WLED/wiki/Compiling-WLED).
@ -20,17 +20,16 @@ Edit `usermods_list.cpp`:
2. add `#include "../usermods/Animated_Staircase/Animated_Staircase.h"` to the top of the file 2. add `#include "../usermods/Animated_Staircase/Animated_Staircase.h"` to the top of the file
3. add `usermods.add(new Animated_Staircase());` to the end of the `void registerUsermods()` function. 3. add `usermods.add(new Animated_Staircase());` to the end of the `void registerUsermods()` function.
You can configure usermod using Usermods settings page. You can configure usermod using the Usermods settings page.
Please enter GPIO pins for PIR sensors or ultrasonic sensor (trigger and echo). Please enter GPIO pins for PIR or ultrasonic sensors (trigger and echo).
If you use PIR sensor enter -1 for echo pin. If you use PIR sensor enter -1 for echo pin.
Maximum distance for ultrasonic sensor can be configured as a time needed for echo (see below). Maximum distance for ultrasonic sensor can be configured as the time needed for an echo (see below).
## Hardware installation ## Hardware installation
1. Stick the LED strip under each step of the stairs. 1. Attach the LED strip to each step of the stairs.
2. Connect the ESP8266 pin D4 or ESP32 pin D2 to the first LED data pin at the bottom step 2. Connect the ESP8266 pin D4 or ESP32 pin D2 to the first LED data pin at the bottom step.
of your stairs.
3. Connect the data-out pin at the end of each strip per step to the data-in pin on the 3. Connect the data-out pin at the end of each strip per step to the data-in pin on the
other end of the next step, creating one large virtual LED strip. next step, creating one large virtual LED strip.
4. Mount sensors of choice at the bottom and top of the stairs and connect them to the ESP. 4. Mount sensors of choice at the bottom and top of the stairs and connect them to the ESP.
5. To make sure all LEDs get enough power and have your staircase lighted evenly, power each 5. To make sure all LEDs get enough power and have your staircase lighted evenly, power each
step from one side, using at least AWG14 or 2.5mm^2 cable. Don't connect them serial as you step from one side, using at least AWG14 or 2.5mm^2 cable. Don't connect them serial as you
@ -62,7 +61,7 @@ or remove them and put everything on one line.
To read the current settings, open a browser to `http://xxx.xxx.xxx.xxx/json/state` (use your WLED To read the current settings, open a browser to `http://xxx.xxx.xxx.xxx/json/state` (use your WLED
device IP address). The device will respond with a json object containing all WLED settings. device IP address). The device will respond with a json object containing all WLED settings.
The staircase settings and sensor states are inside the WLED status element: The staircase settings and sensor states are inside the WLED "state" element:
```json ```json
{ {
@ -70,14 +69,14 @@ The staircase settings and sensor states are inside the WLED status element:
"staircase": { "staircase": {
"enabled": true, "enabled": true,
"bottom-sensor": false, "bottom-sensor": false,
"tops-ensor": false "top-sensor": false
}, },
} }
``` ```
### Enable/disable the usermod ### Enable/disable the usermod
By disabling the usermod you will be able to keep the LED's on, independent from the sensor By disabling the usermod you will be able to keep the LED's on, independent from the sensor
activity. This enables to play with the lights without the usermod switching them on or off. activity. This enables you to play with the lights without the usermod switching them on or off.
To disable the usermod: To disable the usermod:
@ -92,17 +91,17 @@ To enable the usermod again, use `"enabled":true`.
Alternatively you can use _Usermod_ Settings page where you can change other parameters as well. Alternatively you can use _Usermod_ Settings page where you can change other parameters as well.
### Changing animation parameters and detection range of the ultrasonic HC-SR04 sensor ### Changing animation parameters and detection range of the ultrasonic HC-SR04 sensor
Using _Usermod_ Settings page you can define different usermod parameters, includng sensor pins, delay between segment activation and so on. Using _Usermod_ Settings page you can define different usermod parameters, includng sensor pins, delay between segment activation etc.
When an ultrasonic sensor is enabled you can enter maximum detection distance in centimeters separately for top and bottom sensors. When an ultrasonic sensor is enabled you can enter maximum detection distance in centimeters separately for top and bottom sensors.
**Please note:** that using an HC-SR04 sensor, particularly when detecting echos at longer **Please note:** using an HC-SR04 sensor, particularly when detecting echos at longer
distances creates delays in the WLED software, and _might_ introduce timing hickups in your animations or distances creates delays in the WLED software, _might_ introduce timing hiccups in your animation or
a less responsive web interface. It is therefore advised to keep the detection distance as short as possible. a less responsive web interface. It is therefore advised to keep the detection distance as short as possible.
### Animation triggering through the API ### Animation triggering through the API
Instead of stairs activation by one of the sensors, you can also trigger the animation through In addition to activation by one of the stair sensors, you can also trigger the animation manually
the API. To simulate triggering the bottom sensor, use: via the API. To simulate triggering the bottom sensor, use:
```bash ```bash
curl -X POST -H "Content-Type: application/json" \ curl -X POST -H "Content-Type: application/json" \
@ -110,7 +109,7 @@ curl -X POST -H "Content-Type: application/json" \
xxx.xxx.xxx.xxx/json/state xxx.xxx.xxx.xxx/json/state
``` ```
Likewise, to trigger the top sensor, use: Likewise, to trigger the top sensor:
```bash ```bash
curl -X POST -H "Content-Type: application/json" \ curl -X POST -H "Content-Type: application/json" \
@ -119,7 +118,7 @@ curl -X POST -H "Content-Type: application/json" \
``` ```
**MQTT** **MQTT**
You can publish a message with either `up` or `down` on topic `/swipe` to trigger animation. You can publish a message with either `up` or `down` on topic `/swipe` to trigger animation.
You can also use `on` or `off` for enabling or disabling usermod. You can also use `on` or `off` for enabling or disabling the usermod.
Have fun with this usermod.<br/> Have fun with this usermod.<br/>
www.rolfje.com www.rolfje.com

View File

@ -1,7 +1,7 @@
# BH1750 usermod # BH1750 usermod
This usermod will read from an ambient light sensor like the BH1750 sensor. This usermod will read from an ambient light sensor like the BH1750.
The luminance is displayed both in the Info section of the web UI as well as published to the `/luminance` MQTT topic if enabled. The luminance is displayed in both the Info section of the web UI, as well as published to the `/luminance` MQTT topic if enabled.
## Dependencies ## Dependencies
- Libraries - Libraries
@ -28,9 +28,9 @@ The following settings can be set at compile-time but are configurable on the us
* `USERMOD_BH1750_MAX_MEASUREMENT_INTERVAL` - the max number of milliseconds between measurements, defaults to 10000ms * `USERMOD_BH1750_MAX_MEASUREMENT_INTERVAL` - the max number of milliseconds between measurements, defaults to 10000ms
* `USERMOD_BH1750_MIN_MEASUREMENT_INTERVAL` - the min number of milliseconds between measurements, defaults to 500ms * `USERMOD_BH1750_MIN_MEASUREMENT_INTERVAL` - the min number of milliseconds between measurements, defaults to 500ms
* `USERMOD_BH1750_OFFSET_VALUE` - the offset value to report on, defaults to 1 * `USERMOD_BH1750_OFFSET_VALUE` - the offset value to report on, defaults to 1
* `USERMOD_BH1750_FIRST_MEASUREMENT_AT` - the number of milliseconds after boot to take first measurement, defaults to 10 seconds * `USERMOD_BH1750_FIRST_MEASUREMENT_AT` - the number of milliseconds after boot to take first measurement, defaults to 10000 ms
In addition, on the Usermod screen allows you to: In addition, the Usermod screen allows you to:
- enable/disable the usermod - enable/disable the usermod
- Enable Home Assistant Discovery of usermod - Enable Home Assistant Discovery of usermod
- Configure the SCL/SDA pins - Configure the SCL/SDA pins
@ -44,6 +44,6 @@ Jul 2022
- Added Home Assistant Discovery - Added Home Assistant Discovery
- Implemented PinManager to register pins - Implemented PinManager to register pins
- Made pins configurable in usermod menu - Made pins configurable in usermod menu
- Added API call to read illuminance from other modules - Added API call to read luminance from other modules
- Enhanced info-screen outputs - Enhanced info-screen outputs
- Updated `readme.md` - Updated `readme.md`

View File

@ -6,14 +6,14 @@ This Usermod is designed to read a `BME280` or `BMP280` sensor and output the fo
- Heat Index (`BME280` only) - Heat Index (`BME280` only)
- Dew Point (`BME280` only) - Dew Point (`BME280` only)
Configuration is all completed via the Usermod menu. There are no settings to set in code! The following settings can be configured in the Usermod Menu: Configuration is performed via the Usermod menu. There are no parameters to set in code! The following settings can be configured in the Usermod Menu:
- Temperature Decimals (number of decimal places to output) - Temperature Decimals (number of decimal places to output)
- Humidity Decimals - Humidity Decimals
- Pressure Decimals - Pressure Decimals
- Temperature Interval (how many seconds between reads of temperature and humidity) - Temperature Interval (how many seconds between temperature and humidity measurements)
- Pressure Interval - Pressure Interval
- Publish Always (turn off to only publish changes, on to publish whether or not value changed) - Publish Always (turn off to only publish changes, on to publish whether or not value changed)
- Use Celsius (turn off to use Farenheit) - Use Celsius (turn off to use Fahrenheit)
- Home Assistant Discovery (turn on to sent MQTT Discovery entries for Home Assistant) - Home Assistant Discovery (turn on to sent MQTT Discovery entries for Home Assistant)
- SCL/SDA GPIO Pins - SCL/SDA GPIO Pins
@ -23,7 +23,7 @@ Dependencies
- `Wire` - `Wire`
- These must be added under `lib_deps` in your `platform.ini` (or `platform_override.ini`). - These must be added under `lib_deps` in your `platform.ini` (or `platform_override.ini`).
- Data is published over MQTT - make sure you've enabled the MQTT sync interface. - Data is published over MQTT - make sure you've enabled the MQTT sync interface.
- This usermod also writes to serial (GPIO1 on ESP8266). Please make sure nothing else listening on the serial TX pin of your board will get confused by log messages! - This usermod also writes to serial (GPIO1 on ESP8266). Please make sure nothing else is listening to the serial TX pin or your board will get confused by log messages!
In addition to outputting via MQTT, you can read the values from the Info Screen on the dashboard page of the device's web interface. In addition to outputting via MQTT, you can read the values from the Info Screen on the dashboard page of the device's web interface.
@ -37,7 +37,7 @@ Methods also exist to read the read/calculated values from other WLED modules th
- `getHeatIndexC()` - `getHeatIndexC()`
- `getHeatIndexF()` - `getHeatIndexF()`
# Complilation # Compiling
To enable, compile with `USERMOD_BME280` defined (e.g. in `platformio_override.ini`) To enable, compile with `USERMOD_BME280` defined (e.g. in `platformio_override.ini`)
```ini ```ini
@ -63,7 +63,7 @@ Pressure | `<deviceTopic>/pressure`
Heat index | `<deviceTopic>/heat_index` Heat index | `<deviceTopic>/heat_index`
Dew point | `<deviceTopic>/dew_point` Dew point | `<deviceTopic>/dew_point`
If you are using Home Assistant, and `Home Assistant Discovery` is turned on, Home Assistant should automatically detect a new device, provided you have the MQTT integration installed. The device is seperate from the main WLED device and will contain sensors for Pressure, Humidity, Temperature, Dew Point and Heat Index. If you are using Home Assistant, and `Home Assistant Discovery` is turned on, Home Assistant should automatically detect a new device, provided you have the MQTT integration installed. The device is separate from the main WLED device and will contain sensors for Pressure, Humidity, Temperature, Dew Point and Heat Index.
# Revision History # Revision History
Jul 2022 Jul 2022
@ -82,8 +82,8 @@ Apr 2021
Dec 2020 Dec 2020
- Ported to V2 Usermod format - Ported to V2 Usermod format
- Customisable `measure intervals` - Customizable `measure intervals`
- Customisable number of `decimal places` in published sensor values - Customizable number of `decimal places` in published sensor values
- Pressure measured in units of hPa instead of Pa - Pressure measured in units of hPa instead of Pa
- Calculation of heat index (apparent temperature) and dew point - Calculation of heat index (apparent temperature) and dew point
- `16x oversampling` of sensor during measurement - `16x oversampling` of sensor during measurement

View File

@ -1,11 +1,11 @@
# DHT Temperature/Humidity sensor usermod # DHT Temperature/Humidity sensor usermod
This usermod will read from an attached DHT22 or DHT11 humidity and temperature sensor. This usermod will read from an attached DHT22 or DHT11 humidity and temperature sensor.
The sensor readings are displayed in the Info section of the web UI (and optionally send to a MQTT broker). The sensor readings are displayed in the Info section of the web UI (and optionally sent to an MQTT broker).
If sensor is not detected after a while (10 update intervals), this usermod will be disabled. If sensor is not detected after 10 update intervals, the usermod will be disabled.
If enabled measured temperature and humidity will be published to the following MQTT topics If enabled, measured temperature and humidity will be published to the following MQTT topics
* `{devceTopic}/dht/temperature` * `{devceTopic}/dht/temperature`
* `{devceTopic}/dht/humidity` * `{devceTopic}/dht/humidity`
@ -15,13 +15,13 @@ Copy the example `platformio_override.ini` to the root directory. This file sho
### Define Your Options ### Define Your Options
* `USERMOD_DHT` - define this to have this user mod included wled00\usermods_list.cpp * `USERMOD_DHT` - define this to include this user mod wled00\usermods_list.cpp
* `USERMOD_DHT_DHTTYPE` - DHT model: 11, 21, 22 for DHT11, DHT21, or DHT22, defaults to 22/DHT22 * `USERMOD_DHT_DHTTYPE` - DHT model: 11, 21, 22 for DHT11, DHT21, or DHT22, defaults to 22/DHT22
* `USERMOD_DHT_PIN` - pin to which DTH is connected, defaults to Q2 pin on QuinLed Dig-Uno's board * `USERMOD_DHT_PIN` - pin to which DTH is connected, defaults to Q2 pin on QuinLed Dig-Uno's board
* `USERMOD_DHT_CELSIUS` - define this to report temperatures in degrees celsious, otherwise fahrenheit will be reported * `USERMOD_DHT_CELSIUS` - define this to report temperatures in degrees Celsius, otherwise Fahrenheit will be reported
* `USERMOD_DHT_MEASUREMENT_INTERVAL` - the number of milliseconds between measurements, defaults to 60 seconds * `USERMOD_DHT_MEASUREMENT_INTERVAL` - the number of milliseconds between measurements, defaults to 60000 ms
* `USERMOD_DHT_FIRST_MEASUREMENT_AT` - the number of milliseconds after boot to take first measurement, defaults to 90 seconds * `USERMOD_DHT_FIRST_MEASUREMENT_AT` - the number of milliseconds after boot to take first measurement, defaults to 90000 ms
* `USERMOD_DHT_MQTT` - publish measurements to the MQTT broker * `USERMOD_DHT_MQTT` - publish measurements to an MQTT broker
* `USERMOD_DHT_STATS` - For debug, report delay stats * `USERMOD_DHT_STATS` - For debug, report delay stats
## Project link ## Project link
@ -35,11 +35,11 @@ If you are using `platformio_override.ini`, you should be able to refresh the ta
## Change Log ## Change Log
2022-10-15 2022-10-15
* Add possibility to publish sensor readings to an MQTT broker * Add ability to publish sensor readings to an MQTT broker
* fix compilation error for sample [env:d1_mini_usermod_dht_C] task * fix compilation error for sample [env:d1_mini_usermod_dht_C] task
2020-02-04 2020-02-04
* Change default QuinLed pin to Q2 * Change default QuinLed pin to Q2
* Instead of trying to keep updates at constant cadence, space readings out by measurement interval; hope this helps to avoid occasional bursts of readings with errors * Instead of trying to keep updates at constant cadence, space out readings by measurement interval. Hopefully, this helps eliminate occasional bursts of readings with errors
* Add some more (optional) stats * Add some more (optional) stats
2020-02-03 2020-02-03
* Due to poor readouts on ESP32 with previous DHT library, rewrote to use https://github.com/alwynallan/DHT_nonblocking * Due to poor readouts on ESP32 with previous DHT library, rewrote to use https://github.com/alwynallan/DHT_nonblocking

View File

@ -15,7 +15,7 @@ Not supported:
- On-device setup with buttons (WiFi setup only) - On-device setup with buttons (WiFi setup only)
Your images must be 1-135 pixels wide and 1-240 pixels high. Your images must be 1-135 pixels wide and 1-240 pixels high.
For BMP, 1, 4, 8, and 24 bits per pixel formats are supported. BMP 1, 4, 8, and 24 bits per pixel formats are supported.
## Installation ## Installation
@ -26,11 +26,11 @@ Use LED pin 12, relay pin 27 and button pin 34.
## Use of RGB565 images ## Use of RGB565 images
Binary 16-bit per pixel RGB565 format `.bin` and `.clk` images are now supported. This has the benefit of only using 2/3rds of the file size a 24 BPP `.bmp` has. Binary 16-bit per pixel RGB565 format `.bin` and `.clk` images are now supported. This has the benefit of using only 2/3rds of the file space a 24 BPP `.bmp` occupies.
The drawback is that this format cannot be handled by common image programs and that an extra conversion step is needed. The drawback is this format cannot be handled by common image programs and an extra conversion step is needed.
You can use https://lvgl.io/tools/imageconverter to convert your .bmp to a .bin file (settings `True color` and `Binary RGB565`). You can use https://lvgl.io/tools/imageconverter to convert your .bmp to a .bin file (settings `True color` and `Binary RGB565`).
Thank you to @RedNax67 for adding .bin and .clk support. Thank you to @RedNax67 for adding .bin and .clk support.
For most clockface designs, using 4 or 8 BPP BMP formats will save even more file size: For most clockface designs, using 4 or 8 BPP BMP format will reduce file size even more:
| Bits per pixel | File size in kB (for 135x240 img) | % of 24 BPP BMP | Max unique colors | Bits per pixel | File size in kB (for 135x240 img) | % of 24 BPP BMP | Max unique colors
| --- | --- | --- | --- | | --- | --- | --- | --- |

View File

@ -10,7 +10,7 @@ For BME280 sensor use usermod_bme280.cpp. Copy to wled00 and rename to usermod.c
## Features ## Features
- SSD1306 128x32 and 128x64 I2C OLED display - SSD1306 128x32 and 128x64 I2C OLED display
- On screen IP address, SSID and controller status (e.g. ON or OFF, recent effect) - On screen IP address, SSID and controller status (e.g. ON or OFF, recent effect)
- Auto display shutoff for saving display lifetime - Auto display shutoff for extending display lifetime
- Dallas temperature sensor - Dallas temperature sensor
- Reporting temperature to MQTT broker - Reporting temperature to MQTT broker
@ -39,15 +39,15 @@ default_envs = esp07
... ...
lib_deps_external = lib_deps_external =
... ...
#For use SSD1306 OLED display uncomment following #To use the SSD1306 OLED display, uncomment following
U8g2@~2.27.3 U8g2@~2.27.3
#For Dallas sensor uncomment following 2 lines #For Dallas sensor, uncomment the following 2 lines
DallasTemperature@~3.8.0 DallasTemperature@~3.8.0
OneWire@~2.3.5 OneWire@~2.3.5
... ...
``` ```
For BME280 sensor uncomment `U8g2@~2.27.3`,`BME280@~3.0.0 under` `[common]` section in `platformio.ini`: For BME280 sensor, uncomment `U8g2@~2.27.3`,`BME280@~3.0.0 under` `[common]` section in `platformio.ini`:
```ini ```ini
# platformio.ini # platformio.ini
... ...
@ -60,7 +60,7 @@ default_envs = esp07
... ...
lib_deps_external = lib_deps_external =
... ...
#For use SSD1306 OLED display uncomment following #To use the SSD1306 OLED display, uncomment following
U8g2@~2.27.3 U8g2@~2.27.3
#For BME280 sensor uncomment following #For BME280 sensor uncomment following
BME280@~3.0.0 BME280@~3.0.0

View File

@ -2,15 +2,16 @@
**Attention: This usermod compiles only for ESP8266** **Attention: This usermod compiles only for ESP8266**
This usermod-v2 modification performs a ping request to the local IP address every 60 seconds. By this procedure the net services of WLED remains accessible in some problematic WLAN environments. This usermod-v2 modification performs a ping request to a local IP address every 60 seconds. This ensures WLED net services remain accessible in some problematic WLAN environments.
The modification works with static or DHCP IP address configuration. The modification works with static or DHCP IP address configuration.
_Story:_ _Story:_
Unfortunately, with all ESP projects where a web server or other network services are running, I have the problem that after some time the web server is no longer accessible. Now I found out that the connection is at least reestablished when a ping request is executed by the device. Unfortunately, with many ESP projects where a web server or other network services are running, after some time, the connecton to the web server is lost.
The connection can be reestablished with a ping request from the device.
With this modification, in the worst case, the network functions are not available for 60 seconds until the next ping request. With this modification, in the worst case, the network functions are not available until the next ping request. (60 seconds)
## Webinterface ## Webinterface

View File

@ -2,8 +2,8 @@
## Purpose ## Purpose
The JSON IR remote allows users to customize IR remote behavior without writing custom code and compiling. The JSON IR remote enables users to customize IR remote behavior without writing custom code and compiling.
It also enables using any remote that is compatible with your IR receiver. Using the JSON IR remote, you can It also allows using any remote compatible with your IR receiver. Using the JSON IR remote, you can
map buttons from any remote to any HTTP request API or JSON API command. map buttons from any remote to any HTTP request API or JSON API command.
## Usage ## Usage

View File

@ -13,28 +13,29 @@ The info page in the web interface shows the remaining time of the off timer. Us
## Sensor connection ## Sensor connection
My setup uses an HC-SR501 or HC-SR602 sensor, a HC-SR505 should also work. My setup uses an HC-SR501 or HC-SR602 sensor, an HC-SR505 should also work.
The usermod uses GPIO13 (D1 mini pin D7) by default for the sensor signal but can be changed in the Usermod settings page. The usermod uses GPIO13 (D1 mini pin D7) by default for the sensor signal, but can be changed in the Usermod settings page.
[This example page](http://www.esp8266learning.com/wemos-mini-pir-sensor-example.php) describes how to connect the sensor. [This example page](http://www.esp8266learning.com/wemos-mini-pir-sensor-example.php) describes how to connect the sensor.
Use the potentiometers on the sensor to set the time-delay to the minimum and the sensitivity to about half, or slightly above. Use the potentiometers on the sensor to set the time delay to the minimum and the sensitivity to about half, or slightly above.
You can also use usermod's off timer instead of sensor's. In such case rotate the potentiometer to its shortest time possible (or use SR602 which lacks such potentiometer). You can also use usermod's off timer instead of sensor's. In such case rotate the potentiometer to its shortest time possible (or use SR602 which lacks such potentiometer).
## Usermod installation ## Usermod installation
**NOTE:** Usermod has been included in master branch of WLED so it can be compiled in directly just by defining `-D USERMOD_PIRSWITCH` and optionaly `-D PIR_SENSOR_PIN=16` to override default pin. You can also change the default off tim by adding `-D PIR_SENSOR_OFF_SEC=30`. **NOTE:** Usermod has been included in master branch of WLED so it can be compiled in directly just by defining `-D USERMOD_PIRSWITCH` and optionaly `-D PIR_SENSOR_PIN=16` to override default pin. You can also change the default off time by adding `-D PIR_SENSOR_OFF_SEC=30`.
## API to enable/disable the PIR sensor from outside. For example from another usermod. ## API to enable/disable the PIR sensor from outside. For example from another usermod:
To query or change the PIR sensor state the methods `bool PIRsensorEnabled()` and `void EnablePIRsensor(bool enable)` are available. To query or change the PIR sensor state the methods `bool PIRsensorEnabled()` and `void EnablePIRsensor(bool enable)` are available.
When the PIR sensor state changes an MQTT message is broadcasted with topic `wled/deviceMAC/motion` and message `on` or `off`. When the PIR sensor state changes an MQTT message is broadcasted with topic `wled/deviceMAC/motion` and message `on` or `off`.
Usermod can also be configured to just send MQTT message and not change WLED state using settings page as well as responding to motion only during nighttime (assuming NTP and lattitude/longitude are set to determine sunrise/sunset times). Usermod can also be configured to send just the MQTT message but not change WLED state using settings page as well as responding to motion only at night
(assuming NTP and lattitude/longitude are set to determine sunrise/sunset times).
### There are two options to get access to the usermod instance: ### There are two options to get access to the usermod instance:
1. Include `usermod_PIR_sensor_switch.h` **before** you include the other usermod in `usermods_list.cpp' 1. Include `usermod_PIR_sensor_switch.h` **before** you include other usermods in `usermods_list.cpp'
or or
@ -63,7 +64,7 @@ class MyUsermod : public Usermod {
### Configuration options ### Configuration options
Usermod can be configured in Usermods settings page. Usermod can be configured via the Usermods settings page.
* `PIRenabled` - enable/disable usermod * `PIRenabled` - enable/disable usermod
* `pin` - dynamically change GPIO pin where PIR sensor is attached to ESP * `pin` - dynamically change GPIO pin where PIR sensor is attached to ESP
@ -71,8 +72,8 @@ Usermod can be configured in Usermods settings page.
* `on-preset` - preset triggered when PIR activates (if this is 0 it will just turn WLED on) * `on-preset` - preset triggered when PIR activates (if this is 0 it will just turn WLED on)
* `off-preset` - preset triggered when PIR deactivates (if this is 0 it will just turn WLED off) * `off-preset` - preset triggered when PIR deactivates (if this is 0 it will just turn WLED off)
* `nighttime-only` - enable triggering only between sunset and sunrise (you will need to set up _NTP_, _Lat_ & _Lon_ in Time & Macro settings) * `nighttime-only` - enable triggering only between sunset and sunrise (you will need to set up _NTP_, _Lat_ & _Lon_ in Time & Macro settings)
* `mqtt-only` - only send MQTT messages, do not interact with WLED * `mqtt-only` - send only MQTT messages, do not interact with WLED
* `off-only` - only trigger presets or turn WLED on/off in WLED is not already on (displaying effect) * `off-only` - only trigger presets or turn WLED on/off if WLED is not already on (displaying effect)
* `notifications` - enable or disable sending notifications to other WLED instances using Sync button * `notifications` - enable or disable sending notifications to other WLED instances using Sync button

View File

@ -235,7 +235,7 @@ private:
if (offTimerStart > 0 && millis() - offTimerStart > m_switchOffDelay) { if (offTimerStart > 0 && millis() - offTimerStart > m_switchOffDelay) {
offTimerStart = 0; offTimerStart = 0;
if (enabled == true) { if (enabled == true) {
if (!m_mqttOnly && (!m_nightTimeOnly || (m_nightTimeOnly && !isDayTime()))) switchStrip(false); if (!m_mqttOnly && (!m_nightTimeOnly || (m_nightTimeOnly && !isDayTime()) || PIRtriggered)) switchStrip(false);
else if (NotifyUpdateMode != CALL_MODE_NO_NOTIFY) updateInterfaces(CALL_MODE_WS_SEND); else if (NotifyUpdateMode != CALL_MODE_NO_NOTIFY) updateInterfaces(CALL_MODE_WS_SEND);
publishMqtt("off"); publishMqtt("off");
} }

View File

@ -2,12 +2,12 @@
v2 Usermod to to control PWM fan with RPM feedback and temperature control v2 Usermod to to control PWM fan with RPM feedback and temperature control
This usermod requires Dallas Temperature usermod to obtain temperature information. If this is not available the fan will always run at 100% speed. This usermod requires the Dallas Temperature usermod to obtain temperature information. If it's not available, the fan will run at 100% speed.
If the fan does not have _tacho_ (RPM) output you can set the _tacho-pin_ to -1 to not use that feature. If the fan does not have _tachometer_ (RPM) output you can set the _tachometer-pin_ to -1 to disable that feature.
You can also set the thershold temperature at which fan runs at lowest speed. If the actual temperature measured will be 3°C greater than threshold temperature the fan will run at 100%. You can also set the thershold temperature at which fan runs at lowest speed. If the measured temperature is 3°C greater than the threshold temperature, the fan will run at 100%.
If the _tacho_ is supported the current speed (in RPM) will be repored in WLED Info page. If the _tachometer_ is supported, the current speed (in RPM) will be displayed on the WLED Info page.
## Installation ## Installation
@ -20,7 +20,7 @@ All of the parameters are configured during run-time using Usermods settings pag
This includes: This includes:
* PWM output pin (can be configured at compile time `-D PWM_PIN=xx`) * PWM output pin (can be configured at compile time `-D PWM_PIN=xx`)
* tacho input pin (can be configured at compile time `-D TACHO_PIN=xx`) * tachometer input pin (can be configured at compile time `-D TACHO_PIN=xx`)
* sampling frequency in seconds * sampling frequency in seconds
* threshold temperature in degees C * threshold temperature in degees C
@ -32,10 +32,10 @@ No special requirements.
## Control PWM fan speed using JSON API ## Control PWM fan speed using JSON API
You can use e.g. `{"PWM-fan":{"speed":30,"lock":true}}` to set fan speed to 30 percent of maximum speed (replace 30 with arbitrary value between 0 and 100) and lock the speed. e.g. you can use `{"PWM-fan":{"speed":30,"lock":true}}` to lock fan speed to 30 percent of maximum. (replace 30 with an arbitrary value between 0 and 100)
If you include `speed` property you can set fan speed in percent (%) of maximum speed. If you include `speed` property you can set fan speed as a percentage (%) of maximum speed.
If you include `lock` property you can lock (_true_) or unlock (_false_) fan speed. If you include `lock` property you can lock (_true_) or unlock (_false_) the fan speed.
If the fan speed is unlocked it will revert to temperature controlled speed on next update cycle. Once fan speed is locked it will remain so until it is unlocked by next API call. If the fan speed is unlocked, it will revert to temperature controlled speed on the next update cycle. Once fan speed is locked it will remain so until it is unlocked by the next API call.
## Change Log ## Change Log

View File

@ -1,6 +1,6 @@
# DS1307/DS3231 Real time clock # DS1307/DS3231 Real time clock
Gets the time from I2C RTC module on boot. This allows clocks to operate e.g. if temporarily no WiFi is available. Gets the time from I2C RTC module on boot. This allows clock operation if WiFi is not available.
The stored time is updated each time NTP is synced. The stored time is updated each time NTP is synced.
## Installation ## Installation

View File

@ -1,8 +1,8 @@
# RelayBlinds usermod # RelayBlinds usermod
This simple usermod toggles two relay pins momentarily (default for 500ms) when `userVar0` is set. This simple usermod toggles two relay pins momentarily (defaults to 500ms) when `userVar0` is set.
This can be used to e.g. "push" the buttons of a window blinds motor controller. e.g. can be used to "push" the buttons of a window blinds motor controller.
v1 usermod. Please replace usermod.cpp in the `wled00` directory with the one in this file. v1 usermod. Please replace usermod.cpp in the `wled00` directory with the one in this file.
You may upload `index.htm` to `[WLED-IP]/edit` to replace the default lighting UI with a simple Up/Down button one. You may upload `index.htm` to `[WLED-IP]/edit` to replace the default lighting UI with a simple Up/Down button one.
Also, a simple `presets.json` file is available, this makes the relay actions controllable via two presets to facilitate control e.g. via the default UI or Alexa. A simple `presets.json` file is available. This makes the relay actions controllable via two presets to facilitate control e.g. the default UI or Alexa.

View File

@ -1,7 +1,7 @@
# SN_Photoresistor usermod # SN_Photoresistor usermod
This usermod will read from an attached photoresistor sensor like the KY-018 sensor. This usermod will read from an attached photoresistor sensor like the KY-018.
The luminance is displayed both in the Info section of the web UI as well as published to the `/luminance` MQTT topic if enabled. The luminance is displayed in both the Info section of the web UI as well as published to the `/luminance` MQTT topic, if enabled.
## Installation ## Installation
@ -9,15 +9,15 @@ Copy the example `platformio_override.ini` to the root directory. This file sho
### Define Your Options ### Define Your Options
* `USERMOD_SN_PHOTORESISTOR` - define this to have this user mod included wled00\usermods_list.cpp * `USERMOD_SN_PHOTORESISTOR` - Enables this user mod. wled00\usermods_list.cpp
* `USERMOD_SN_PHOTORESISTOR_MEASUREMENT_INTERVAL` - the number of milliseconds between measurements, defaults to 60 seconds * `USERMOD_SN_PHOTORESISTOR_MEASUREMENT_INTERVAL` - Number of milliseconds between measurements. Defaults to 60000 ms
* `USERMOD_SN_PHOTORESISTOR_FIRST_MEASUREMENT_AT` - the number of milliseconds after boot to take first measurement, defaults to 20 seconds * `USERMOD_SN_PHOTORESISTOR_FIRST_MEASUREMENT_AT` - Number of milliseconds after boot to take first measurement. Defaults to 20000 ms
* `USERMOD_SN_PHOTORESISTOR_REFERENCE_VOLTAGE` - the voltage supplied to the sensor, defaults to 5v * `USERMOD_SN_PHOTORESISTOR_REFERENCE_VOLTAGE` - Voltage supplied to the sensor. Defaults to 5v
* `USERMOD_SN_PHOTORESISTOR_ADC_PRECISION` - the ADC precision is the number of distinguishable ADC inputs, defaults to 1024.0 (10 bits) * `USERMOD_SN_PHOTORESISTOR_ADC_PRECISION` - ADC precision. Defaults to 10 bits
* `USERMOD_SN_PHOTORESISTOR_RESISTOR_VALUE` - the resistor size, defaults to 10000.0 (10K hms) * `USERMOD_SN_PHOTORESISTOR_RESISTOR_VALUE` - Resistor size, defaults to 10000.0 (10K Ohms)
* `USERMOD_SN_PHOTORESISTOR_OFFSET_VALUE` - the offset value to report on, defaults to 25 * `USERMOD_SN_PHOTORESISTOR_OFFSET_VALUE` - Offset value to report on. Defaults to 25
All parameters can be configured at runtime using Usermods settings page. All parameters can be configured at runtime via the Usermods settings page.
## Project link ## Project link

View File

@ -1,15 +1,15 @@
# ST7789 TFT IPS Color display 240x240pxwith ESP32 boards # Using the ST7789 TFT IPS 240x240 pixel color display with ESP32 boards
This usermod allow to use 240x240 display to display following: This usermod enables display of the following:
* current date and time; * Current date and time;
* Network SSID; * Network SSID;
* IP address; * IP address;
* WiFi signal strength; * WiFi signal strength;
* Brightness; * Brightness;
* Chosen effect; * Selected effect;
* Chosen palette; * Selected palette;
* effect speed and intensity; * Effect speed and intensity;
* Estimated current in mA; * Estimated current in mA;
## Hardware ## Hardware
@ -41,9 +41,9 @@ lib_deps =
... ...
``` ```
Also, while in the `platformio.ini` file, you must change the environment setup to build for just the esp32dev platform as follows: In the `platformio.ini` file, you must change the environment setup to build for just the esp32dev platform as follows:
Add lines to section: Add the following lines to section:
```ini ```ini
default_envs = esp32dev default_envs = esp32dev
@ -64,14 +64,14 @@ build_flags = ${common.build_flags_esp32}
;-DCONFIG_SPIRAM_SUPPORT=1 ;-DCONFIG_SPIRAM_SUPPORT=1
``` ```
Save the `platformio.ini` file. Once this is saved, the required library files should be automatically downloaded for modifications in a later step. Save the `platformio.ini` file. Once saved, the required library files should be automatically downloaded for modifications in a later step.
### TFT_eSPI Library Adjustments ### TFT_eSPI Library Adjustments
If you are not using PlatformIO you need to modify a file in the `TFT_eSPI` library. If you followed the directions to modify and save the `platformio.ini` file above, the `Setup24_ST7789.h` file can be found in the `/.pio/libdeps/esp32dev/TFT_eSPI/User_Setups/` folder. If you are not using PlatformIO, you need to modify a file in the `TFT_eSPI` library. If you followed the directions to modify and save the `platformio.ini` file above, the `Setup24_ST7789.h` file can be found in the `/.pio/libdeps/esp32dev/TFT_eSPI/User_Setups/` folder.
Edit `Setup_ST7789.h` file and uncomment nad changep GPIO pin numbers in lines containing `TFT_MOSI`, `TFT_SCLK`, `TFT_RST`, `TFT_DC`. Edit `Setup_ST7789.h` file and uncomment and change GPIO pin numbers in lines containing `TFT_MOSI`, `TFT_SCLK`, `TFT_RST`, `TFT_DC`.
Modify the `User_Setup_Select.h` by uncommentig the line containing `#include <User_Setups/Setup24_ST7789.h>` and commenting out line containing `#include <User_Setup.h>`. Modify the `User_Setup_Select.h` by uncommenting the line containing `#include <User_Setups/Setup24_ST7789.h>` and commenting out the line containing `#include <User_Setup.h>`.
If your display includes backlight enable pin, #define TFT_BL with backlight enable GPIO number. If your display uses the backlight enable pin, add this definition: #define TFT_BL with backlight enable GPIO number.

View File

@ -2,14 +2,14 @@
This usermod implements support for [Si7021 I²C temperature and humidity sensors](https://www.silabs.com/documents/public/data-sheets/Si7021-A20.pdf). This usermod implements support for [Si7021 I²C temperature and humidity sensors](https://www.silabs.com/documents/public/data-sheets/Si7021-A20.pdf).
The sensor data will *not* be shown on the WLED UI (so far) but published via MQTT to WLED's "build in" MQTT device topic. As of this writing, the sensor data will *not* be shown on the WLED UI, but it _is_ published via MQTT to WLED's "built-in" MQTT device topic.
``` ```
temperature: $mqttDeviceTopic/si7021_temperature temperature: $mqttDeviceTopic/si7021_temperature
humidity: $mqttDeviceTopic/si7021_humidity humidity: $mqttDeviceTopic/si7021_humidity
``` ```
Additionally the following sensors can be published: The following sensors can also be published:
``` ```
heat_index: $mqttDeviceTopic/si7021_heat_index heat_index: $mqttDeviceTopic/si7021_heat_index
@ -17,7 +17,7 @@ dew_point: $mqttDeviceTopic/si7021_dew_point
absolute_humidity: $mqttDeviceTopic/si7021_absolute_humidity absolute_humidity: $mqttDeviceTopic/si7021_absolute_humidity
``` ```
Sensor data will be updated/send every 60 seconds. Sensor data will be updated/sent every 60 seconds.
This usermod also supports Home Assistant Auto Discovery. This usermod also supports Home Assistant Auto Discovery.

View File

@ -1,19 +1,19 @@
# TTGO T-Display ESP32 with 240x135 TFT via SPI with TFT_eSPI # TTGO T-Display ESP32 with 240x135 TFT via SPI with TFT_eSPI
This usermod allows use of the TTGO T-Display ESP32 module with integrated 240x135 display This usermod enables use of the TTGO 240x135 T-Display ESP32 module
for controlling WLED and showing the following information: for controlling WLED and showing the following information:
* Current SSID * Current SSID
* IP address if obtained * IP address, if obtained
* If connected to a network, current brightness % is shown * If connected to a network, current brightness percentage is shown
* in AP mode AP IP and password are shown * In AP mode, AP, IP and password are shown
* Current effect * Current effect
* Current palette * Current palette
* Estimated current in mA is shown (NOTE: for this to be a reasonable value, the correct LED type must be specified in the LED Prefs section) * Estimated current in mA (NOTE: for this to be a reasonable value, the correct LED type must be specified in the LED Prefs section)
Button pin is mapped to the onboard button next to the side actuated reset button of the TTGO T-Display board. Button pin is mapped to the onboard button adjacent to the reset button of the TTGO T-Display board.
I have designed a 3D printed case around this board and an ["ElectroCookie"](https://amzn.to/2WCNeeA) project board, a [level shifter](https://amzn.to/3hbKu18), a [buck regulator](https://amzn.to/3mLMy0W), and a DC [power jack](https://amzn.to/3phj9NZ). I use 12V WS2815 LED strips for my projects, and power them with 12V power supplies, so the regulator drops the voltage to the 5V level I need to power the ESP module and the level shifter. If there is any interest in this case, which elevates the board and display on some custom extended headers to make place the screen at the top of the enclosure (with accessible buttons), let me know, and I could post the STL files. It is a bit tricky to get the height correct, so I also designed a one-time use 3D printed solder fixture to set the board in the right location and at the correct height for the housing. (It is one-time use because it has to be cut off after soldering to be able to remove it). I didn't think the effort to make it in multiple pieces was worthwhile. I have designed a 3D printed case around this board and an ["ElectroCookie"](https://amzn.to/2WCNeeA) project board, a [level shifter](https://amzn.to/3hbKu18), a [buck regulator](https://amzn.to/3mLMy0W), and a DC [power jack](https://amzn.to/3phj9NZ). I use 12V WS2815 LED strips for my projects, and power them with 12V power supplies. The regulator supplies 5V for the ESP module and the level shifter. If there is any interest in this case which elevates the board and display on custom extended standoffs to place the screen at the top of the enclosure (with accessible buttons), let me know, and I will post the STL files. It is a bit tricky to get the height correct, so I also designed a one-time use 3D printed solder fixture to set the board in the right location and at the correct height for the housing. (It is one-time use because it has to be cut off after soldering to be able to remove it). I didn't think the effort to make it in multiple pieces was worthwhile.
Usermod based on a rework of the ssd1306_i2c_oled_u8g2 usermod from the WLED repo. Based on a rework of the ssd1306_i2c_oled_u8g2 usermod from the WLED repo.
## Hardware ## Hardware
![Hardware](assets/ttgo_hardware1.png) ![Hardware](assets/ttgo_hardware1.png)
@ -30,8 +30,8 @@ Usermod based on a rework of the ssd1306_i2c_oled_u8g2 usermod from the WLED rep
Functionality checked with: Functionality checked with:
* TTGO T-Display * TTGO T-Display
* PlatformIO * PlatformIO
* Group of 4 individual Neopixels from Adafruit, and a several full strings of 12v WS2815 LEDs. * Group of 4 individual Neopixels from Adafruit and several full strings of 12v WS2815 LEDs.
* The hardware design shown above should be limited to shorter strings. For larger strings, I use a different setup with a dedicated 12v power supply and power them directly off the supply (in addition to dropping the 12v supply down to 5v with a buck regulator for the ESP module and level shifter). * The hardware design shown above should be limited to shorter strings. For larger strings, I use a different setup with a dedicated 12v power supply and power them directly from said supply (in addition to dropping the 12v to 5v with a buck regulator for the ESP module and level shifter).
## Setup Needed: ## Setup Needed:
* As with all usermods, copy the usermod.cpp file from the TTGO-T-Display usermod folder to the wled00 folder (replacing the default usermod.cpp file). * As with all usermods, copy the usermod.cpp file from the TTGO-T-Display usermod folder to the wled00 folder (replacing the default usermod.cpp file).
@ -51,24 +51,24 @@ lib_deps =
... ...
``` ```
Also, while in the `platformio.ini` file, you must change the environment setup to build for just the esp32dev platform as follows: In the `platformio.ini` file, you must change the environment setup to build for just the esp32dev platform as follows:
Comment out the line described below: Comment out the line described below:
```ini ```ini
# Travis CI binaries (comment this out when building for single board) # Release binaries
; default_envs = travis_esp8266, esp01, esp01_1m_ota, travis_esp32 ; default_envs = nodemcuv2, esp8266_2m, esp01_1m_full, esp32dev, esp32_eth, esp32s2_saola, esp32c3
``` ```
and UNCOMMENT the following line in the 'Single binaries' section: and uncomment the following line in the 'Single binaries' section:
```ini ```ini
default_envs = esp32dev default_envs = esp32dev
``` ```
Save the `platformio.ini` file. Once this is saved, the required library files should be automatically downloaded for modifications in a later step. Save the `platformio.ini` file. Once saved, the required library files should be automatically downloaded for modifications in a later step.
### Platformio_overrides.ini (added) ### Platformio_overrides.ini (added)
Copy the `platformio_overrides.ini` file which is contained in the `usermods/TTGO-T-Display/` folder into the root of your project folder. This file contains an override that remaps the button pin of WLED to use the on-board button to the right of the USB-C connector (when viewed with the port oriented downward - see hardware photo). Copy the `platformio_overrides.ini` file which is contained in the `usermods/TTGO-T-Display/` folder into the root of your project folder. This file contains an override that remaps the button pin of WLED to use the on-board button to the right of the USB-C connector (when viewed with the port oriented downward - see hardware photo).
### TFT_eSPI Library Adjustments (board selection) ### TFT_eSPI Library Adjustments (board selection)
We need to modify a file in the `TFT_eSPI` library to select the correct board. If you followed the directions to modify and save the `platformio.ini` file above, the `User_Setup_Select.h` file can be found in the `/.pio/libdeps/esp32dev/TFT_eSPI_ID1559` folder. You need to modify a file in the `TFT_eSPI` library to select the correct board. If you followed the directions to modify and save the `platformio.ini` file above, the `User_Setup_Select.h` file can be found in the `/.pio/libdeps/esp32dev/TFT_eSPI_ID1559` folder.
Modify the `User_Setup_Select.h` file as follows: Modify the `User_Setup_Select.h` file as follows:
* Comment out the following line (which is the 'default' setup file): * Comment out the following line (which is the 'default' setup file):
@ -80,12 +80,12 @@ Modify the `User_Setup_Select.h` file as follows:
#include <User_Setups/Setup25_TTGO_T_Display.h> // Setup file for ESP32 and TTGO T-Display ST7789V SPI bus TFT #include <User_Setups/Setup25_TTGO_T_Display.h> // Setup file for ESP32 and TTGO T-Display ST7789V SPI bus TFT
``` ```
Run the build and it should complete correctly. If you see a failure like this: Build the file. If you see a failure like this:
```ini ```ini
xtensa-esp32-elf-g++: error: wled00\wled00.ino.cpp: No such file or directory xtensa-esp32-elf-g++: error: wled00\wled00.ino.cpp: No such file or directory
xtensa-esp32-elf-g++: fatal error: no input files xtensa-esp32-elf-g++: fatal error: no input files
``` ```
Just try building again - I find that sometimes this happens on the first build attempt and subsequent attempts will build correctly. try building again. Sometimes this happens on the first build attempt and subsequent attempts build correctly.
## Arduino IDE ## Arduino IDE
- UNTESTED - UNTESTED

View File

@ -1,9 +1,9 @@
# Temperature usermod # Temperature usermod
Based on the excellent `QuinLED_Dig_Uno_Temp_MQTT` by srg74 and 400killer! Based on the excellent `QuinLED_Dig_Uno_Temp_MQTT` usermod by srg74 and 400killer!
This usermod will read from an attached DS18B20 temperature sensor (as available on the QuinLED Dig-Uno) Reads an attached DS18B20 temperature sensor (as available on the QuinLED Dig-Uno)
The temperature is displayed both in the Info section of the web UI as well as published to the `/temperature` MQTT topic if enabled. Temperature is displayed in both the Info section of the web UI as well as published to the `/temperature` MQTT topic, if enabled.
This usermod may be expanded with support for different sensor types in the future. May be expanded with support for different sensor types in the future.
If temperature sensor is not detected during boot, this usermod will be disabled. If temperature sensor is not detected during boot, this usermod will be disabled.
@ -13,10 +13,10 @@ Copy the example `platformio_override.ini` to the root directory. This file sho
### Define Your Options ### Define Your Options
* `USERMOD_DALLASTEMPERATURE` - define this to have this user mod included wled00\usermods_list.cpp * `USERMOD_DALLASTEMPERATURE` - enables this user mod wled00/usermods_list.cpp
* `USERMOD_DALLASTEMPERATURE_FIRST_MEASUREMENT_AT` - the number of milliseconds after boot to take first measurement, defaults to 20 seconds * `USERMOD_DALLASTEMPERATURE_FIRST_MEASUREMENT_AT` - umber of milliseconds after boot to take first measurement, defaults to 20000 ms
All parameters can be configured at runtime using Usermods settings page, including pin, selection to display temerature in degrees Celsius or Farenheit mand measurement interval. All parameters can be configured at runtime via the Usermods settings page, including pin, temperature in degrees Celsius or Farenheit and measurement interval.
## Project link ## Project link
@ -50,8 +50,8 @@ lib_deps =
## Change Log ## Change Log
2020-09-12 2020-09-12
* Changed to use async, non-blocking implementation * Changed to use async non-blocking implementation
* Do not report low temperatures that indicate an error to mqtt * Do not report erroneous low temperatures to MQTT
* Disable plugin if temperature sensor not detected * Disable plugin if temperature sensor not detected
* Report the number of seconds until the first read in the info screen instead of sensor error * Report the number of seconds until the first read in the info screen instead of sensor error
2021-04 2021-04

View File

@ -1,10 +1,10 @@
# Description # Description
That usermod implements support of simple hand gestures with VL53L0X sensor: on/off and brightness correction. Implements support of simple hand gestures via a VL53L0X sensor: on/off and brightness adjustment.
It can be useful for kitchen strips to avoid any touches. Useful for controlling strips when you want to avoid touching anything.
- on/off - just swipe a hand below your sensor ("shortPressAction" is called and can be customized through WLED macros) - on/off - swipe your hand below the sensor ("shortPressAction" is called. Can be customized via WLED macros)
- brightness correction - keep your hand below sensor for 1 second to switch to "brightness" mode. - brightness adjustment - hold your hand below the sensor for 1 second to switch to "brightness" mode.
Configure brightness by changing distance to the sensor (see parameters below for customization). adjust the brightness by changing the distance between your hand and the sensor (see parameters below for customization).
## Installation ## Installation

View File

@ -9,10 +9,10 @@
## Features ## Features
- SSD1306 128x32 or 128x64 I2C OLED display - SSD1306 128x32 or 128x64 I2C OLED display
- On screen IP address, SSID and controller status (e.g. ON or OFF, recent effect) - On screen IP address, SSID and controller status (e.g. ON or OFF, recent effect)
- Auto display shutoff for saving display lifetime - Auto display shutoff for extending display lifetime
- Dallas temperature sensor - Dallas temperature sensor
- Reporting temperature to MQTT broker - Reporting temperature to MQTT broker
- Relay for energy saving - Relay for saving energy
## Hardware ## Hardware
![Shield](https://github.com/srg74/WLED-wemos-shield/blob/master/resources/Images/Assembly_8.jpg) ![Shield](https://github.com/srg74/WLED-wemos-shield/blob/master/resources/Images/Assembly_8.jpg)

View File

@ -1776,13 +1776,13 @@ class AudioReactive : public Usermod {
oappend(SET_F("addOption(dd,'Send',1);")); oappend(SET_F("addOption(dd,'Send',1);"));
oappend(SET_F("addOption(dd,'Receive',2);")); oappend(SET_F("addOption(dd,'Receive',2);"));
oappend(SET_F("addInfo('AudioReactive:digitalmic:type',1,'<i>requires reboot!</i>');")); // 0 is field type, 1 is actual field oappend(SET_F("addInfo('AudioReactive:digitalmic:type',1,'<i>requires reboot!</i>');")); // 0 is field type, 1 is actual field
oappend(SET_F("addInfo('AudioReactive:digitalmic:pin[]',0,'I2S Serial Data', '<i><span class=\"h\">sd/data/dout</span></i>');")); oappend(SET_F("addInfo('AudioReactive:digitalmic:pin[]',0,'<i>sd/data/dout</i>','I2S SD');"));
oappend(SET_F("addInfo('AudioReactive:digitalmic:pin[]',1,'I2S L/R Clock','<i><span class=\"h\">ws/clk/lrck</span></i>');")); oappend(SET_F("addInfo('AudioReactive:digitalmic:pin[]',1,'<i>ws/clk/lrck</i>','I2S WS');"));
oappend(SET_F("addInfo('AudioReactive:digitalmic:pin[]',2,'I2S Serial Clock','<i>sck/bclk</i>');")); oappend(SET_F("addInfo('AudioReactive:digitalmic:pin[]',2,'<i>sck/bclk</i>','I2S SCK');"));
#if !defined(CONFIG_IDF_TARGET_ESP32S2) && !defined(CONFIG_IDF_TARGET_ESP32C3) && !defined(CONFIG_IDF_TARGET_ESP32S3) #if !defined(CONFIG_IDF_TARGET_ESP32S2) && !defined(CONFIG_IDF_TARGET_ESP32C3) && !defined(CONFIG_IDF_TARGET_ESP32S3)
oappend(SET_F("addInfo('AudioReactive:digitalmic:pin[]',3,'I2S Master CLK','<i>only use -1, 0, 1 or 3</i>');")); oappend(SET_F("addInfo('AudioReactive:digitalmic:pin[]',3,'<i>only use -1, 0, 1 or 3</i>','I2S MCLK');"));
#else #else
oappend(SET_F("addInfo('AudioReactive:digitalmic:pin[]',3,'', 'I2S Master CLK');")); oappend(SET_F("addInfo('AudioReactive:digitalmic:pin[]',3,'<i>master clock</i>','I2S MCLK');"));
#endif #endif
oappend(SET_F("addInfo('AudioReactive:digitalmic:pin[]',4,'','I2C SDA');")); oappend(SET_F("addInfo('AudioReactive:digitalmic:pin[]',4,'','I2C SDA');"));
oappend(SET_F("addInfo('AudioReactive:digitalmic:pin[]',5,'','I2C SCL');")); oappend(SET_F("addInfo('AudioReactive:digitalmic:pin[]',5,'','I2C SCL');"));

View File

@ -1,11 +1,11 @@
# Audioreactive usermod # Audioreactive usermod
This usermod allows controlling LEDs using audio input. Audio input can be either microphone or analog-in (AUX) using appropriate adapter. Enabless controlling LEDs via audio input. Audio source can be a microphone or analog-in (AUX) using an appropriate adapter.
Supported microphones range from cheap analog (MAX4466, MAX9814, ...) to high quality digital (INMP441, ICS-43434, ...) and dgital Line-In. Supported microphones range from analog (MAX4466, MAX9814, ...) to digital (INMP441, ICS-43434, ...).
The usermod does audio processing and provides data structure that specially written effect can use. Does audio processing and provides data structure that specially written effects can use.
The usermod **does not** provide effects or draws anything to LED strip/matrix. **does not** provide effects or draw anything to an LED strip/matrix.
## Additional Documentation ## Additional Documentation
This usermod is an evolution of [SR-WLED](https://github.com/atuline/WLED), and a lot of documentation and information can be found in the [SR-WLED wiki](https://github.com/atuline/WLED/wiki): This usermod is an evolution of [SR-WLED](https://github.com/atuline/WLED), and a lot of documentation and information can be found in the [SR-WLED wiki](https://github.com/atuline/WLED/wiki):
@ -42,9 +42,9 @@ ArduinoFFT `develop` library is slightly more accurate, and slighly faster than
## Configuration ## Configuration
All parameters are runtime configurable though some may require hard boot after change (I2S microphone or selected GPIOs). All parameters are runtime configurable. Some may require a hard reset after changing them (I2S microphone or selected GPIOs).
If you want to define default GPIOs during compile time use the following addtional build_flags (default values in parentheses): If you want to define default GPIOs during compile time, use the following (default values in parentheses):
- `-D SR_DMTYPE=x` : defines digital microphone type: 0=analog, 1=generic I2S (default), 2=ES7243 I2S, 3=SPH0645 I2S, 4=generic I2S with master clock, 5=PDM I2S - `-D SR_DMTYPE=x` : defines digital microphone type: 0=analog, 1=generic I2S (default), 2=ES7243 I2S, 3=SPH0645 I2S, 4=generic I2S with master clock, 5=PDM I2S
- `-D AUDIOPIN=x` : GPIO for analog microphone/AUX-in (36) - `-D AUDIOPIN=x` : GPIO for analog microphone/AUX-in (36)
@ -55,7 +55,7 @@ If you want to define default GPIOs during compile time use the following addtio
- `-D ES7243_SDAPIN` : GPIO for I2C SDA pin on ES7243 microphone (-1) - `-D ES7243_SDAPIN` : GPIO for I2C SDA pin on ES7243 microphone (-1)
- `-D ES7243_SCLPIN` : GPIO for I2C SCL pin on ES7243 microphone (-1) - `-D ES7243_SCLPIN` : GPIO for I2C SCL pin on ES7243 microphone (-1)
**NOTE** Due to the fact that usermod uses I2S peripherial for analog audio sampling, use of analog *buttons* (i.e. potentiometers) is disabled while running this usermod with analog microphone. **NOTE** I2S is used for analog audio sampling. Hence, the analog *buttons* (i.e. potentiometers) are disabled when running this usermod with an analog microphone.
### Advanced Compile-Time Options ### Advanced Compile-Time Options
You can use the following additional flags in your `build_flags` You can use the following additional flags in your `build_flags`

View File

@ -1,12 +1,11 @@
# :battery: Battery status/level Usermod :battery: # :battery: Battery status/level Usermod :battery:
Enables battery level monitoring of your project.
This Usermod allows you to monitor the battery level of your battery powered project.
You can see the battery level and voltage in the `info modal`. You can see the battery level and voltage in the `info modal`.
For this to work the positive side of the (18650) battery must be connected to pin `A0` of the d1mini/esp8266 with a 100k ohm resistor (see [Useful Links](#useful-links)). For this to work, the positive side of the (18650) battery must be connected to pin `A0` of the d1 mini/esp8266 with a 100k Ohm resistor (see [Useful Links](#useful-links)).
If you have a esp32 board it is best to connect the positive side of the battery to ADC1 (GPIO32 - GPIO39) If you have an ESP32 board, connect the positive side of the battery to ADC1 (GPIO32 - GPIO39)
<p align="center"> <p align="center">
<img width="300" src="assets/battery_info_screen.png"> <img width="300" src="assets/battery_info_screen.png">
@ -24,15 +23,15 @@ define `USERMOD_BATTERY_STATUS_BASIC` in `my_config.h`
### Define Your Options ### Define Your Options
* `USERMOD_BATTERY_STATUS_BASIC` - define this (in `my_config.h`) to have this usermod included wled00\usermods_list.cpp * `USERMOD_BATTERY_STATUS_BASIC` - define this (in `my_config.h`) to have this usermod included wled00\usermods_list.cpp
* `USERMOD_BATTERY_MEASUREMENT_PIN` - defaults to A0 on esp8266 and GPIO32 on esp32 * `USERMOD_BATTERY_MEASUREMENT_PIN` - defaults to A0 on ESP8266 and GPIO32 on ESP32
* `USERMOD_BATTERY_MEASUREMENT_INTERVAL` - the frequency to check the battery, defaults to 30 seconds * `USERMOD_BATTERY_MEASUREMENT_INTERVAL` - battery check interval. defaults to 30 seconds
* `USERMOD_BATTERY_MIN_VOLTAGE` - minimum voltage of the Battery used, default is 2.6 (18650 battery standard) * `USERMOD_BATTERY_MIN_VOLTAGE` - minimum battery voltage. default is 2.6 (18650 battery standard)
* `USERMOD_BATTERY_MAX_VOLTAGE` - maximum voltage of the Battery used, default is 4.2 (18650 battery standard) * `USERMOD_BATTERY_MAX_VOLTAGE` - maximum battery voltage. default is 4.2 (18650 battery standard)
All parameters can be configured at runtime using Usermods settings page. All parameters can be configured at runtime via the Usermods settings page.
## Important :warning: ## Important :warning:
* Make sure you know your battery specification ! not every battery is the same ! * Make sure you know your battery specifications! All batteries are **NOT** the same!
* Example: * Example:
| Your battery specification table | | Options you can define | | Your battery specification table | | Options you can define |

View File

@ -1,11 +1,11 @@
# Blynk controllable relay # Blynk controllable relay
This usermod allows controlling a relay state from the user variables. It also allows the user variables to be set over Blynk. Enables controlling a relay state via user variables. Allows the user variables to be set via Blynk.
Optionally, the servo can have a reset timer to go back to it's default state after an interval. This interval is set through userVar1. Optionally, the servo can have a reset timer to return to its default state after a user definable interval. The interval is set via userVar1.
## Instalation ## Instalation
Replace the WLED06_usermod.ino file in Aircoookies WLED folder with the one here. Replace the WLED06_usermod.ino file in Aircoookies WLED folder, with the one here.
## Customizations ## Customizations
@ -16,13 +16,13 @@ Update the following parameters in WLED06_usermod.ino to configure the mod's beh
#define RELAY_PIN 5 #define RELAY_PIN 5
//Which pin state should the relay default to //Which pin state should the relay default to
#define RELAY_PIN_DEFAULT LOW #define RELAY_PIN_DEFAULT LOW
//If >0 The controller returns to RELAY_PIN_DEFAULT after this time in milliseconds //If >0 The controller returns to RELAY_PIN_DEFAULT after this time, in milliseconds
#define RELAY_PIN_TIMER_DEFAULT 3000 #define RELAY_PIN_TIMER_DEFAULT 3000
//Blynk virtual pin for controlling relay //Blynk virtual pin for controlling relay
#define BLYNK_USER_VAR0_PIN V9 #define BLYNK_USER_VAR0_PIN V9
//Blynk virtual pin for controlling relay timer //Blynk virtual pin for controlling relay timer
#define BLYNK_USER_VAR1_PIN V10 #define BLYNK_USER_VAR1_PIN V10
//Number of milliseconds between updating blynk //Number of milliseconds between Blynk updates
#define BLYNK_RELAY_UPDATE_INTERVAL 5000 #define BLYNK_RELAY_UPDATE_INTERVAL 5000
``` ```

View File

@ -0,0 +1,457 @@
#pragma once
#include "wled.h"
/*
* Usermod that implements BobLight "ambilight" protocol
*
* See the accompanying README.md file for more info.
*/
#ifndef BOB_PORT
#define BOB_PORT 19333 // Default boblightd port
#endif
class BobLightUsermod : public Usermod {
typedef struct _LIGHT {
char lightname[5];
float hscan[2];
float vscan[2];
} light_t;
private:
unsigned long lastTime = 0;
bool enabled = false;
bool initDone = false;
light_t *lights = nullptr;
uint16_t numLights = 0; // 16 + 9 + 16 + 9
uint16_t top, bottom, left, right; // will be filled in readFromConfig()
uint16_t pct;
WiFiClient bobClient;
WiFiServer *bob;
uint16_t bobPort = BOB_PORT;
static const char _name[];
static const char _enabled[];
/*
# boblight
# Copyright (C) Bob 2009
#
# makeboblight.sh created by Adam Boeglin <adamrb@gmail.com>
#
# boblight is free software: you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by the
# Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# boblight is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program. If not, see <http://www.gnu.org/licenses/>.
*/
// fills the lights[] array with position & depth of scan for each LED
void fillBobLights(int bottom, int left, int top, int right, float pct_scan) {
int lightcount = 0;
int total = top+left+right+bottom;
int bcount;
if (total > strip.getLengthTotal()) {
DEBUG_PRINTLN(F("BobLight: Too many lights."));
return;
}
// start left part of bottom strip (clockwise direction, 1st half)
if (bottom > 0) {
bcount = 1;
float brange = 100.0/bottom;
float bcurrent = 50.0;
if (bottom < top) {
int diff = top - bottom;
brange = 100.0/top;
bcurrent -= (diff/2)*brange;
}
while (bcount <= bottom/2) {
float btop = bcurrent - brange;
String name = "b"+String(bcount);
strncpy(lights[lightcount].lightname, name.c_str(), 4);
lights[lightcount].hscan[0] = btop;
lights[lightcount].hscan[1] = bcurrent;
lights[lightcount].vscan[0] = 100 - pct_scan;
lights[lightcount].vscan[1] = 100;
lightcount+=1;
bcurrent = btop;
bcount+=1;
}
}
// left side
if (left > 0) {
int lcount = 1;
float lrange = 100.0/left;
float lcurrent = 100.0;
while (lcount <= left) {
float ltop = lcurrent - lrange;
String name = "l"+String(lcount);
strncpy(lights[lightcount].lightname, name.c_str(), 4);
lights[lightcount].hscan[0] = 0;
lights[lightcount].hscan[1] = pct_scan;
lights[lightcount].vscan[0] = ltop;
lights[lightcount].vscan[1] = lcurrent;
lightcount+=1;
lcurrent = ltop;
lcount+=1;
}
}
// top side
if (top > 0) {
int tcount = 1;
float trange = 100.0/top;
float tcurrent = 0;
while (tcount <= top) {
float ttop = tcurrent + trange;
String name = "t"+String(tcount);
strncpy(lights[lightcount].lightname, name.c_str(), 4);
lights[lightcount].hscan[0] = tcurrent;
lights[lightcount].hscan[1] = ttop;
lights[lightcount].vscan[0] = 0;
lights[lightcount].vscan[1] = pct_scan;
lightcount+=1;
tcurrent = ttop;
tcount+=1;
}
}
// right side
if (right > 0) {
int rcount = 1;
float rrange = 100.0/right;
float rcurrent = 0;
while (rcount <= right) {
float rtop = rcurrent + rrange;
String name = "r"+String(rcount);
strncpy(lights[lightcount].lightname, name.c_str(), 4);
lights[lightcount].hscan[0] = 100-pct_scan;
lights[lightcount].hscan[1] = 100;
lights[lightcount].vscan[0] = rcurrent;
lights[lightcount].vscan[1] = rtop;
lightcount+=1;
rcurrent = rtop;
rcount+=1;
}
}
// right side of bottom strip (2nd half)
if (bottom > 0) {
float brange = 100.0/bottom;
float bcurrent = 100;
if (bottom < top) {
brange = 100.0/top;
}
while (bcount <= bottom) {
float btop = bcurrent - brange;
String name = "b"+String(bcount);
strncpy(lights[lightcount].lightname, name.c_str(), 4);
lights[lightcount].hscan[0] = btop;
lights[lightcount].hscan[1] = bcurrent;
lights[lightcount].vscan[0] = 100 - pct_scan;
lights[lightcount].vscan[1] = 100;
lightcount+=1;
bcurrent = btop;
bcount+=1;
}
}
numLights = lightcount;
#if WLED_DEBUG
DEBUG_PRINTLN(F("Fill light data: "));
DEBUG_PRINTF(" lights %d\n", numLights);
for (int i=0; i<numLights; i++) {
DEBUG_PRINTF(" light %s scan %2.1f %2.1f %2.1f %2.1f\n", lights[i].lightname, lights[i].vscan[0], lights[i].vscan[1], lights[i].hscan[0], lights[i].hscan[1]);
}
#endif
}
void BobSync() { yield(); } // allow other tasks, should also be used to force pixel redraw (not with WLED)
void BobClear() { for (size_t i=0; i<numLights; i++) setRealtimePixel(i, 0, 0, 0, 0); }
void pollBob();
public:
void setup() {
uint16_t totalLights = bottom + left + top + right;
if ( totalLights > strip.getLengthTotal() ) {
DEBUG_PRINTLN(F("BobLight: Too many lights."));
DEBUG_PRINTF("%d+%d+%d+%d>%d\n", bottom, left, top, right, strip.getLengthTotal());
totalLights = strip.getLengthTotal();
top = bottom = (uint16_t) roundf((float)totalLights * 16.0f / 50.0f);
left = right = (uint16_t) roundf((float)totalLights * 9.0f / 50.0f);
}
lights = new light_t[totalLights];
if (lights) fillBobLights(bottom, left, top, right, float(pct)); // will fill numLights
else enable(false);
initDone = true;
}
void connected() {
// we can only start server when WiFi is connected
if (!bob) bob = new WiFiServer(bobPort, 1);
bob->begin();
bob->setNoDelay(true);
}
void loop() {
if (!enabled || strip.isUpdating()) return;
if (millis() - lastTime > 10) {
lastTime = millis();
pollBob();
}
}
void enable(bool en) { enabled = en; }
/**
* handling of MQTT message
* topic only contains stripped topic (part after /wled/MAC)
* topic should look like: /swipe with amessage of [up|down]
*/
bool onMqttMessage(char* topic, char* payload) {
//if (strlen(topic) == 6 && strncmp_P(topic, PSTR("/subtopic"), 6) == 0) {
// String action = payload;
// if (action == "on") {
// enable(true);
// return true;
// } else if (action == "off") {
// enable(false);
// return true;
// }
//}
return false;
}
/**
* subscribe to MQTT topic for controlling usermod
*/
void onMqttConnect(bool sessionPresent) {
//char subuf[64];
//if (mqttDeviceTopic[0] != 0) {
// strcpy(subuf, mqttDeviceTopic);
// strcat_P(subuf, PSTR("/subtopic"));
// mqtt->subscribe(subuf, 0);
//}
}
void addToJsonInfo(JsonObject& root)
{
JsonObject user = root["u"];
if (user.isNull()) user = root.createNestedObject("u");
JsonArray infoArr = user.createNestedArray(FPSTR(_name));
String uiDomString = F("<button class=\"btn btn-xs\" onclick=\"requestJson({");
uiDomString += FPSTR(_name);
uiDomString += F(":{");
uiDomString += FPSTR(_enabled);
uiDomString += enabled ? F(":false}});\">") : F(":true}});\">");
uiDomString += F("<i class=\"icons ");
uiDomString += enabled ? "on" : "off";
uiDomString += F("\">&#xe08f;</i></button>");
infoArr.add(uiDomString);
}
/*
* addToJsonState() can be used to add custom entries to the /json/state part of the JSON API (state object).
* Values in the state object may be modified by connected clients
*/
void addToJsonState(JsonObject& root)
{
}
/*
* readFromJsonState() can be used to receive data clients send to the /json/state part of the JSON API (state object).
* Values in the state object may be modified by connected clients
*/
void readFromJsonState(JsonObject& root) {
if (!initDone) return; // prevent crash on boot applyPreset()
bool en = enabled;
JsonObject um = root[FPSTR(_name)];
if (!um.isNull()) {
if (um[FPSTR(_enabled)].is<bool>()) {
en = um[FPSTR(_enabled)].as<bool>();
} else {
String str = um[FPSTR(_enabled)]; // checkbox -> off or on
en = (bool)(str!="off"); // off is guaranteed to be present
}
if (en != enabled && lights) {
enable(en);
if (!enabled && bob && bob->hasClient()) {
if (bobClient) bobClient.stop();
bobClient = bob->available();
BobClear();
exitRealtime();
}
}
}
}
void appendConfigData() {
//oappend(SET_F("dd=addDropdown('usermod','selectfield');"));
//oappend(SET_F("addOption(dd,'1st value',0);"));
//oappend(SET_F("addOption(dd,'2nd value',1);"));
oappend(SET_F("addInfo('BobLight:top',1,'LEDs');")); // 0 is field type, 1 is actual field
oappend(SET_F("addInfo('BobLight:bottom',1,'LEDs');")); // 0 is field type, 1 is actual field
oappend(SET_F("addInfo('BobLight:left',1,'LEDs');")); // 0 is field type, 1 is actual field
oappend(SET_F("addInfo('BobLight:right',1,'LEDs');")); // 0 is field type, 1 is actual field
oappend(SET_F("addInfo('BobLight:pct',1,'Depth of scan [%]');")); // 0 is field type, 1 is actual field
}
void addToConfig(JsonObject& root) {
JsonObject umData = root.createNestedObject(FPSTR(_name));
umData[FPSTR(_enabled)] = enabled;
umData[F("port")] = bobPort;
umData[F("top")] = top;
umData[F("bottom")] = bottom;
umData[F("left")] = left;
umData[F("right")] = right;
umData[F("pct")] = pct;
}
bool readFromConfig(JsonObject& root) {
JsonObject umData = root[FPSTR(_name)];
bool configComplete = !umData.isNull();
bool en = enabled;
configComplete &= getJsonValue(umData[FPSTR(_enabled)], en);
enable(en);
configComplete &= getJsonValue(umData[F("port")], bobPort);
configComplete &= getJsonValue(umData[F("bottom")], bottom, 16);
configComplete &= getJsonValue(umData[F("top")], top, 16);
configComplete &= getJsonValue(umData[F("left")], left, 9);
configComplete &= getJsonValue(umData[F("right")], right, 9);
configComplete &= getJsonValue(umData[F("pct")], pct, 5); // Depth of scan [%]
pct = MIN(50,MAX(1,pct));
uint16_t totalLights = bottom + left + top + right;
if (initDone && numLights != totalLights) {
if (lights) delete[] lights;
setup();
}
return configComplete;
}
/*
* handleOverlayDraw() is called just before every show() (LED strip update frame) after effects have set the colors.
* Use this to blank out some LEDs or set them to a different color regardless of the set effect mode.
* Commonly used for custom clocks (Cronixie, 7 segment)
*/
void handleOverlayDraw() {
//strip.setPixelColor(0, RGBW32(0,0,0,0)) // set the first pixel to black
}
uint16_t getId() { return USERMOD_ID_BOBLIGHT; }
};
// strings to reduce flash memory usage (used more than twice)
const char BobLightUsermod::_name[] PROGMEM = "BobLight";
const char BobLightUsermod::_enabled[] PROGMEM = "enabled";
// main boblight handling (definition here prevents inlining)
void BobLightUsermod::pollBob() {
//check if there are any new clients
if (bob && bob->hasClient()) {
//find free/disconnected spot
if (!bobClient || !bobClient.connected()) {
if (bobClient) bobClient.stop();
bobClient = bob->available();
DEBUG_PRINTLN(F("Boblight: Client connected."));
}
//no free/disconnected spot so reject
WiFiClient bobClientTmp = bob->available();
bobClientTmp.stop();
BobClear();
exitRealtime();
}
//check clients for data
if (bobClient && bobClient.connected()) {
realtimeLock(realtimeTimeoutMs); // lock strip as we have a client connected
//get data from the client
while (bobClient.available()) {
String input = bobClient.readStringUntil('\n');
// DEBUG_PRINT("Client: "); DEBUG_PRINTLN(input); // may be to stressful on Serial
if (input.startsWith(F("hello"))) {
DEBUG_PRINTLN(F("hello"));
bobClient.print(F("hello\n"));
} else if (input.startsWith(F("ping"))) {
DEBUG_PRINTLN(F("ping 1"));
bobClient.print(F("ping 1\n"));
} else if (input.startsWith(F("get version"))) {
DEBUG_PRINTLN(F("version 5"));
bobClient.print(F("version 5\n"));
} else if (input.startsWith(F("get lights"))) {
char tmp[64];
String answer = "";
sprintf_P(tmp, PSTR("lights %d\n"), numLights);
DEBUG_PRINT(tmp);
answer.concat(tmp);
for (int i=0; i<numLights; i++) {
sprintf_P(tmp, PSTR("light %s scan %2.1f %2.1f %2.1f %2.1f\n"), lights[i].lightname, lights[i].vscan[0], lights[i].vscan[1], lights[i].hscan[0], lights[i].hscan[1]);
DEBUG_PRINT(tmp);
answer.concat(tmp);
}
bobClient.print(answer);
} else if (input.startsWith(F("set priority"))) {
DEBUG_PRINTLN(F("set priority not implemented"));
// not implemented
} else if (input.startsWith(F("set light "))) { // <id> <cmd in rgb, speed, interpolation> <value> ...
input.remove(0,10);
String tmp = input.substring(0,input.indexOf(' '));
int light_id = -1;
for (uint16_t i=0; i<numLights; i++) {
if (strncmp(lights[i].lightname, tmp.c_str(), 4) == 0) {
light_id = i;
break;
}
}
if (light_id == -1) return;
input.remove(0,input.indexOf(' ')+1);
if (input.startsWith(F("rgb "))) {
input.remove(0,4);
tmp = input.substring(0,input.indexOf(' '));
uint8_t red = (uint8_t)(255.0f*tmp.toFloat());
input.remove(0,input.indexOf(' ')+1); // remove first float value
tmp = input.substring(0,input.indexOf(' '));
uint8_t green = (uint8_t)(255.0f*tmp.toFloat());
input.remove(0,input.indexOf(' ')+1); // remove second float value
tmp = input.substring(0,input.indexOf(' '));
uint8_t blue = (uint8_t)(255.0f*tmp.toFloat());
//strip.setPixelColor(light_id, RGBW32(red, green, blue, 0));
setRealtimePixel(light_id, red, green, blue, 0);
} // currently no support for interpolation or speed, we just ignore this
} else if (input.startsWith(F("sync"))) {
BobSync();
} else {
// Client sent gibberish
DEBUG_PRINTLN(F("Client sent gibberish."));
bobClient.stop();
bobClient = bob->available();
BobClear();
}
}
}
}

View File

@ -0,0 +1,37 @@
# BobLight usermod
This usermod allows displaying BobLight ambilight protocol on WLED device with a limited command set (not a full implementation).
BobLight protocol uses a TCP connection which guarantees packet delivery at the possible expense of latency delays. It is not very efficient (as it uses plaintext comands) so is not suited for large number of LEDs.
This implementation is intended for TV backlight in combination with XBMC/Kodi BobLight add-on.
The LEDs can be configured in usermod settings page. The configuration is simple: you enter the number of LED pixels on each side of your TV (top, right, bottom, left).
The LEDs should be wired in a clockwise orientation starting in the middle of bottom side (left half of bottom leds is where the string should start).
```
+-------->-------+
| |
^ v
| |
+---<--+ ---<---+
^
start
```
## Installation
Add `-D USERMOD_BOBLIGHT` to your PlatformIO environment.
If you are not using PlatformIO (which you should) try adding `#define USERMOD_BOBLIGHT` to *my_config.h*.
## Configuration
All parameters are runtime configurable though changing port may require reboot.
If you want to define default port during compile time use the following (default values in parentheses):
- `BOB_PORT=x` : defines default TCP port for usermod to listen on (19333)
## Release notes
2022-11 Initial implementation by @blazoncek (AKA Blaz Kristan)

View File

@ -1,13 +1,13 @@
# MPU-6050 Six-Axis (Gyro + Accelerometer) Driver # MPU-6050 Six-Axis (Gyro + Accelerometer) Driver
This usermod-v2 modification allows the connection of a MPU-6050 IMU sensor to v2 of this usermod enables connection of a MPU-6050 IMU sensor to
allow for effects that are controlled by the orientation or motion of the WLED Device. work with effects controlled by the orientation or motion of the WLED Device.
The MPU6050 has a built in "Digital Motion Processor" which does a lot of the heavy The MPU6050 has a built in "Digital Motion Processor" which does the "heavy lifting"
lifting in integrating the gyro and accel measurements to get potentially more integrating the gyro and accelerometer measurements to get potentially more
useful gravity vector and orientation output. useful gravity vector and orientation output.
It is pretty straightforward to comment out some of the variables being read off the device if they're not needed to save CPU/Mem/Bandwidth. It is fairly straightforward to comment out variables being read from the device if they're not needed. Saves CPU/Memory/Bandwidth.
_Story:_ _Story:_

View File

@ -1,37 +1,37 @@
# Multi Relay # Multi Relay
This usermod-v2 modification allows the connection of multiple relays each with individual delay and on/off mode. This usermod-v2 modification allows the connection of multiple relays, each with individual delay and on/off mode.
## HTTP API ## HTTP API
All responses are returned as JSON. All responses are returned in JSON format.
* Status Request: `http://[device-ip]/relays` * Status Request: `http://[device-ip]/relays`
* Switch Command: `http://[device-ip]/relays?switch=1,0,1,1` * Switch Command: `http://[device-ip]/relays?switch=1,0,1,1`
The number of numbers behind the switch parameter must correspond to the number of relays. The number 1 switches the relay on. The number 0 switches the relay off. The number of values behind the switch parameter must correspond to the number of relays. The value 1 switches the relay on, 0 switches it off.
* Toggle Command: `http://[device-ip]/relays?toggle=1,0,1,1` * Toggle Command: `http://[device-ip]/relays?toggle=1,0,1,1`
The number of numbers behind the parameter switch must correspond to the number of relays. The number 1 causes a toggling of the relay. The number 0 leaves the state of the device. The number of values behind the parameter switch must correspond to the number of relays. The value 1 causes the relay to toggle, 0 leaves its state unchanged.
Examples Examples:
1. total of 4 relays, relay 2 will be toggled: `http://[device-ip]/relays?toggle=0,1,0,0` 1. total of 4 relays, relay 2 will be toggled: `http://[device-ip]/relays?toggle=0,1,0,0`
2. total of 3 relays, relay 1&3 will be switched on: `http://[device-ip]/relays?switch=1,0,1` 2. total of 3 relays, relay 1&3 will be switched on: `http://[device-ip]/relays?switch=1,0,1`
## JSON API ## JSON API
You can switch relay state using the following JSON object transmitted to: `http://[device-ip]/json` You can toggle the relay state by sending the following JSON object to: `http://[device-ip]/json`
Switch relay 0 on: `{"MultiRelay":{"relay":0,"on":true}}` Switch relay 0 on: `{"MultiRelay":{"relay":0,"on":true}}`
Switch relay4 3 & 4 off: `{"MultiRelay":[{"relay":2,"on":false},{"relay":3,"on":false}]}` Switch relay 3 and 4 off: `{"MultiRelay":[{"relay":2,"on":false},{"relay":3,"on":false}]}`
## MQTT API ## MQTT API
* `wled`/_deviceMAC_/`relay`/`0`/`command` `on`|`off`|`toggle` * `wled`/_deviceMAC_/`relay`/`0`/`command` `on`|`off`|`toggle`
* `wled`/_deviceMAC_/`relay`/`1`/`command` `on`|`off`|`toggle` * `wled`/_deviceMAC_/`relay`/`1`/`command` `on`|`off`|`toggle`
When relay is switched it will publish a message: When a relay is switched, a message is published:
* `wled`/_deviceMAC_/`relay`/`0` `on`|`off` * `wled`/_deviceMAC_/`relay`/`0` `on`|`off`
@ -42,7 +42,7 @@ When relay is switched it will publish a message:
or or
2. Use `#define USERMOD_MULTI_RELAY` in wled.h or `-D USERMOD_MULTI_RELAY` in your platformio.ini 2. Use `#define USERMOD_MULTI_RELAY` in wled.h or `-D USERMOD_MULTI_RELAY` in your platformio.ini
You can override the default maximum number (4) of relays by defining MULTI_RELAY_MAX_RELAYS. You can override the default maximum number of relays (which is 4) by defining MULTI_RELAY_MAX_RELAYS.
Example **usermods_list.cpp**: Example **usermods_list.cpp**:
@ -78,15 +78,15 @@ void registerUsermods()
## Configuration ## Configuration
Usermod can be configured in Usermods settings page. Usermod can be configured via the Usermods settings page.
* `enabled` - enable/disable usermod * `enabled` - enable/disable usermod
* `pin` - GPIO pin where relay is attached to ESP (can be configured at compile time `-D MULTI_RELAY_PINS=xx,xx,...`) * `pin` - ESP GPIO pin the relay is connected to (can be configured at compile time `-D MULTI_RELAY_PINS=xx,xx,...`)
* `delay-s` - delay in seconds after on/off command is received * `delay-s` - delay in seconds after on/off command is received
* `active-high` - toggle high/low activation of relay (can be used to reverse relay states) * `active-high` - assign high/low activation of relay (can be used to reverse relay states)
* `external` - if enabled WLED does not control relay, it can only be triggered by external command (MQTT, HTTP, JSON or button) * `external` - if enabled, WLED does not control relay, it can only be triggered by an external command (MQTT, HTTP, JSON or button)
* `button` - button (from LED Settings) that controls this relay * `button` - button (from LED Settings) that controls this relay
* `broadcast`- time in seconds between state broadcasts using MQTT * `broadcast`- time in seconds between MQTT relay-state broadcasts
* `HA-discovery`- enable Home Assistant auto discovery * `HA-discovery`- enable Home Assistant auto discovery
If there is no MultiRelay section, just save current configuration and re-open Usermods settings page. If there is no MultiRelay section, just save current configuration and re-open Usermods settings page.

View File

@ -1,10 +1,12 @@
# Photoresister sensor with MQTT # Photoresister sensor with MQTT
This simple usermod allows attaching a photoresistor sensor like the KY-018 and publish the readings in percentage over MQTT. The frequency of MQTT messages can be modified, and there is a threshold value that can be set so that significant changes in the readings can be published immediately instead of waiting for the next update. This was found to be a good compromise between spamming MQTT messages and delayed updates. Enables attaching a photoresistor sensor like the KY-018 and publishing the readings as a percentage, via MQTT. The frequency of MQTT messages is user definable.
A threshold value can be set so significant changes in the readings are published immediately vice waiting for the next update. This was found to be a good compromise between excessive MQTT traffic and delayed updates.
I also found it useful to limit the frequency of analog pin reads because otherwise the board hangs. I also found it useful to limit the frequency of analog pin reads, otherwise the board hangs.
This usermod has only been tested with the KY-018 sensor though should work for any other analog pin sensor. Note that this does not control the LED strip directly, it only publishes MQTT readings for use with other integrations like Home Assistant. This usermod has only been tested with the KY-018 sensor though it should work for any other analog pin sensor.
Note: this does not control the LED strip directly, it only publishes MQTT readings for use with other integrations like Home Assistant.
## Installation ## Installation

View File

@ -1,12 +1,11 @@
### Shift Light for Project Cars ### Shift Light for Project Cars
Turn your WLED lights into a rev light and shift indicator for Project Cars. Turn your WLED lights into a rev light and shift indicator for Project Cars.
It's easy to use.
It is pretty straight forward to use. 1. Make sure your WLED device and your PC/console are on the same network and can talk to each other
1. Make sure, your WLED device and your PC/console are on the same network and can talk to each other 2. Go to the gameplay settings menu in PCARS and enable UDP. There are 9 numbers you can choose from. This is the refresh rate. The lower the number, the better. However, you might run into problems at faster rates.
2. Go to the gameplay settings menu in PCARS and enable UDP. There are 9 numbers you can choose from. This is the refresh rate. The lower the number, the better. But you might run into problems at faster rates.
| Number | Updates/Second | | Number | Updates/Second |
| ------ | -------------- | | ------ | -------------- |
@ -20,4 +19,5 @@ It is pretty straight forward to use.
| 8 | 05 | | 8 | 05 |
| 9 | 1 | | 9 | 1 |
3. once you enter a race, WLED should automatically shift to PCARS mode. Done. 3. Once you enter a race, WLED should automatically shift to PCARS mode.
4. Done.

View File

@ -0,0 +1,27 @@
# PWM outputs
v2 Usermod to add generic PWM outputs to WLED. Usermode could be used to control servo motors, LED brightness or any other device controlled by PWM signal.
## Installation
Add the compile-time option `-D USERMOD_PWM_OUTPUTS` to your `platformio.ini` (or `platformio_override.ini`). By default upt to 3 PWM outputs could be configured, to increase that limit add build argument `-D USERMOD_PWM_OUTPUT_PINS=10` (replace 10 by desired amount).
Currently only ESP32 is supported.
## Configuration
By default PWM outputs are disabled, navigate to Usermods settings and configure desired PWM pins and frequencies.
## Usage
If PWM output is configured, it starts to publish its duty cycle value (0-1) both to state JSON and to info JSON (visible in UI info panel). To set PWM duty cycle, use JSON api (over HTTP or over Serial)
```json
{
"pwm": {
"0": {"duty": 0.1},
"1": {"duty": 0.2},
...
}
}
```

View File

@ -0,0 +1,221 @@
#pragma once
#include "wled.h"
#ifndef ESP32
#error This usermod does not support the ESP8266.
#endif
#ifndef USERMOD_PWM_OUTPUT_PINS
#define USERMOD_PWM_OUTPUT_PINS 3
#endif
class PwmOutput {
public:
void open(int8_t pin, uint32_t freq) {
if (enabled_) {
if (pin == pin_ && freq == freq_) {
return; // PWM output is already open
} else {
close(); // Config has changed, close and reopen
}
}
pin_ = pin;
freq_ = freq;
if (pin_ < 0)
return;
DEBUG_PRINTF("pwm_output[%d]: setup to freq %d\n", pin_, freq_);
if (!pinManager.allocatePin(pin_, true, PinOwner::UM_PWM_OUTPUTS))
return;
channel_ = pinManager.allocateLedc(1);
if (channel_ == 255) {
DEBUG_PRINTF("pwm_output[%d]: failed to quire ledc\n", pin_);
pinManager.deallocatePin(pin_, PinOwner::UM_PWM_OUTPUTS);
return;
}
ledcSetup(channel_, freq_, bit_depth_);
ledcAttachPin(pin_, channel_);
DEBUG_PRINTF("pwm_output[%d]: init successful\n", pin_);
enabled_ = true;
}
void close() {
DEBUG_PRINTF("pwm_output[%d]: close\n", pin_);
if (!enabled_)
return;
pinManager.deallocatePin(pin_, PinOwner::UM_PWM_OUTPUTS);
if (channel_ != 255)
pinManager.deallocateLedc(channel_, 1);
channel_ = 255;
duty_ = 0.0f;
enabled_ = false;
}
void setDuty(const float duty) {
DEBUG_PRINTF("pwm_output[%d]: set duty %f\n", pin_, duty);
if (!enabled_)
return;
duty_ = min(1.0f, max(0.0f, duty));
const uint32_t value = static_cast<uint32_t>((1 << bit_depth_) * duty_);
ledcWrite(channel_, value);
}
void setDuty(const uint16_t duty) {
setDuty(static_cast<float>(duty) / 65535.0f);
}
bool isEnabled() const {
return enabled_;
}
void addToJsonState(JsonObject& pwmState) const {
pwmState[F("duty")] = duty_;
}
void readFromJsonState(JsonObject& pwmState) {
if (pwmState.isNull()) {
return;
}
float duty;
if (getJsonValue(pwmState[F("duty")], duty)) {
setDuty(duty);
}
}
void addToJsonInfo(JsonObject& user) const {
if (!enabled_)
return;
char buffer[12];
sprintf_P(buffer, PSTR("PWM pin %d"), pin_);
JsonArray data = user.createNestedArray(buffer);
data.add(1e2f * duty_);
data.add(F("%"));
}
void addToConfig(JsonObject& pwmConfig) const {
pwmConfig[F("pin")] = pin_;
pwmConfig[F("freq")] = freq_;
}
bool readFromConfig(JsonObject& pwmConfig) {
if (pwmConfig.isNull())
return false;
bool configComplete = true;
int8_t newPin = pin_;
uint32_t newFreq = freq_;
configComplete &= getJsonValue(pwmConfig[F("pin")], newPin);
configComplete &= getJsonValue(pwmConfig[F("freq")], newFreq);
open(newPin, newFreq);
return configComplete;
}
private:
int8_t pin_ {-1};
uint32_t freq_ {50};
static const uint8_t bit_depth_ {12};
uint8_t channel_ {255};
float duty_ {0.0f};
bool enabled_ {false};
};
class PwmOutputsUsermod : public Usermod {
public:
static const char USERMOD_NAME[];
static const char PWM_STATE_NAME[];
void setup() {
// By default all PWM outputs are disabled, no setup do be done
}
void loop() {
}
void addToJsonState(JsonObject& root) {
JsonObject pwmStates = root.createNestedObject(PWM_STATE_NAME);
for (int i = 0; i < USERMOD_PWM_OUTPUT_PINS; i++) {
const PwmOutput& pwm = pwms_[i];
if (!pwm.isEnabled())
continue;
char buffer[4];
sprintf_P(buffer, PSTR("%d"), i);
JsonObject pwmState = pwmStates.createNestedObject(buffer);
pwm.addToJsonState(pwmState);
}
}
void readFromJsonState(JsonObject& root) {
JsonObject pwmStates = root[PWM_STATE_NAME];
if (pwmStates.isNull())
return;
for (int i = 0; i < USERMOD_PWM_OUTPUT_PINS; i++) {
PwmOutput& pwm = pwms_[i];
if (!pwm.isEnabled())
continue;
char buffer[4];
sprintf_P(buffer, PSTR("%d"), i);
JsonObject pwmState = pwmStates[buffer];
pwm.readFromJsonState(pwmState);
}
}
void addToJsonInfo(JsonObject& root) {
JsonObject user = root[F("u")];
if (user.isNull())
user = root.createNestedObject(F("u"));
for (int i = 0; i < USERMOD_PWM_OUTPUT_PINS; i++) {
const PwmOutput& pwm = pwms_[i];
pwm.addToJsonInfo(user);
}
}
void addToConfig(JsonObject& root) {
JsonObject top = root.createNestedObject(USERMOD_NAME);
for (int i = 0; i < USERMOD_PWM_OUTPUT_PINS; i++) {
const PwmOutput& pwm = pwms_[i];
char buffer[8];
sprintf_P(buffer, PSTR("PWM %d"), i);
JsonObject pwmConfig = top.createNestedObject(buffer);
pwm.addToConfig(pwmConfig);
}
}
bool readFromConfig(JsonObject& root) {
JsonObject top = root[USERMOD_NAME];
if (top.isNull())
return false;
bool configComplete = true;
for (int i = 0; i < USERMOD_PWM_OUTPUT_PINS; i++) {
PwmOutput& pwm = pwms_[i];
char buffer[8];
sprintf_P(buffer, PSTR("PWM %d"), i);
JsonObject pwmConfig = top[buffer];
configComplete &= pwm.readFromConfig(pwmConfig);
}
return configComplete;
}
uint16_t getId() {
return USERMOD_ID_PWM_OUTPUTS;
}
private:
PwmOutput pwms_[USERMOD_PWM_OUTPUT_PINS];
};
const char PwmOutputsUsermod::USERMOD_NAME[] PROGMEM = "PwmOutputs";
const char PwmOutputsUsermod::PWM_STATE_NAME[] PROGMEM = "pwm";

View File

@ -1,5 +1,5 @@
# QuinLED-An-Penta # QuinLED-An-Penta
The (un)official usermod to get the best out of the QuinLED-An-Penta (https://quinled.info/quinled-an-penta/), like using the OLED and the SHT30 temperature/humidity sensor. The (un)official usermod to get the best out of the QuinLED-An-Penta (https://quinled.info/quinled-an-penta/), e.g. using the OLED and the SHT30 temperature/humidity sensor.
## Requirements ## Requirements
* "u8gs" by olikraus, v2.28 or higher: https://github.com/olikraus/u8g2 * "u8gs" by olikraus, v2.28 or higher: https://github.com/olikraus/u8g2
@ -31,15 +31,15 @@ lib_deps = ${esp32.lib_deps}
## Some words about the (optional) OLED ## Some words about the (optional) OLED
This mod has been optimized for an SSD1306 driven 128x64 OLED. Using a smaller OLED or an OLED using a different driver will result in unexpected results. This mod has been optimized for an SSD1306 driven 128x64 OLED. Using a smaller OLED or an OLED using a different driver will result in unexpected results.
I highly recommend using these "two color monochromatic OLEDs", which have the first 16 pixels in a different color than the other 48, e.g. a yellow/blue OLED. I highly recommend using these "two color monochromatic OLEDs", which have the first 16 pixels in a different color than the other 48, e.g. a yellow/blue OLED.
Also note, you need to have an **SPI** driven OLED, **not i2c**! Note: you _must_ use an **SPI** driven OLED, **not an i2c one**!
### Limitations combined with Ethernet ### Limitations combined with Ethernet
The initial development of this mod had been done with a beta version of the QuinLED-An-Penta, which had a different IO layout for the OLED: The CS pin used to be IO_0, but has been changed to IO27 with the first v1 public release. Unfortunately, IO27 is used by the Ethernet boards, so WLED will not let you enable the OLED screen, if you're using it with Ethernet. This unfortunately makes the development I've done to support/show Ethernet information void, as it cannot be used. The initial development of this mod was done with a beta version of the QuinLED-An-Penta, which had a different IO layout for the OLED: The CS pin _was_ IO_0, but has been changed to IO27 with the first v1 public release. Unfortunately, IO27 is used by Ethernet boards, so WLED will not let you enable the OLED screen, if you're using it with Ethernet. Unfortunately, that makes the development I've done to support/show Ethernet information invalid, as it cannot be used.
However (and I've not tried this, as I don't own a v1 board): You can try to modify this mod and try to use IO27 for the OLED and share it with the Ethernet board. It is "just" the chip select pin, so there is a chance that both can coexist and use the same IO. You need to skip WLEDs PinManager for the CS pin, so WLED will not block using it. If you don't know how this works: Leave it. If you know what I'm talking about: Try it and please let me know on the Intermit.Tech (QuinLED) Discord server: https://discord.gg/WdbAauG However, (and I've not tried this, as I don't own a v1 board) you can modify this usermod and try to use IO27 for the OLED and share it with the Ethernet board. It is "just" the chip select pin, so there is a chance that both can coexist and use the same IO. You need to skip WLEDs PinManager for the CS pin, so WLED will not block using it. If you don't know how this works, don't change it. If you know what I'm talking about, try it and please let me know on the Intermit.Tech (QuinLED) Discord server: https://discord.gg/WdbAauG
### My OLED flickers after some time, what should I do? ### My OLED flickers after some time, what should I do?
That's a tricky one: During development I saw that the OLED sometimes starts to "bug out" / flicker and won't work anymore. This seems to be caused by the high PWM interference the board produces. It seems to loose its settings and then doesn't know how to draw anymore. Turns out the only way to fix this is to call the libraries `begin()` method again which will re-initialize the display. That's a tricky one. During development I saw that the OLED sometimes starts to "drop out" / flicker and won't work anymore. This seems to be caused by the high PWM interference the board produces. It seems to lose its settings then doesn't know how to draw anymore. Turns out the only way to fix this is to call the libraries `begin()` method again which re-initializes the display.
If you're facing this issue, you can enable a setting I've added which will call the `begin()` roughly every 60 seconds between a page change. This will make the page change take ~500ms, but will fix the display. If you're facing this issue, you can enable a setting which will call the `begin()` roughly every 60 seconds between page changes. This will make the page change take ~500ms, but will fix the display.
## Configuration ## Configuration
@ -53,11 +53,11 @@ Navigate to the "Config" and then to the "Usermods" section. If you compiled WLE
* Possible values: Enabled/Disabled * Possible values: Enabled/Disabled
* Default: Disabled * Default: Disabled
* OLED-Flip-Screen-180: * OLED-Flip-Screen-180:
* What it does: Flips the screen 180° / upside-down * What it does: Flips the screen 180°
* Possible values: Enabled/Disabled * Possible values: Enabled/Disabled
* Default: Disabled * Default: Disabled
* OLED-Seconds-Per-Page: * OLED-Seconds-Per-Page:
* What it does: Defines how long the OLED should stay on one page in seconds before changing to the next * What it does: Number of seconds the OLED should stay on one page before changing pages
* Possible values: Enabled/Disabled * Possible values: Enabled/Disabled
* Default: 10 * Default: 10
* OLED-Fix-Bugged-Screen: * OLED-Fix-Bugged-Screen:

View File

@ -2,17 +2,17 @@
This folder serves as a repository for usermods (custom `usermod.cpp` files)! This folder serves as a repository for usermods (custom `usermod.cpp` files)!
If you have created an usermod that you believe is useful (for example to support a particular sensor, display, feature...), feel free to contribute by opening a pull request! If you have created a usermod you believe is useful (for example to support a particular sensor, display, feature...), feel free to contribute by opening a pull request!
In order for other people to be able to have fun with your usermod, please keep these points in mind: In order for other people to be able to have fun with your usermod, please keep these points in mind:
- Create a folder in this folder with a descriptive name (for example `usermod_ds18b20_temp_sensor_mqtt`) - Create a folder in this folder with a descriptive name (for example `usermod_ds18b20_temp_sensor_mqtt`)
- Include your custom files - Include your custom files
- If your usermod requires changes to other WLED files, please write a `readme.md` outlining the steps one has to take to use the usermod - If your usermod requires changes to other WLED files, please write a `readme.md` outlining the steps one needs to take
- Create a pull request! - Create a pull request!
- If your feature is useful for the majority of WLED users, I will consider adding it to the base code! - If your feature is useful for the majority of WLED users, I will consider adding it to the base code!
While I do my best to not break too much, keep in mind that as WLED is being updated, usermods might break. While I do my best to not break too much, keep in mind that as WLED is updated, usermods might break.
I am not actively maintaining any usermod in this directory, that is your responsibility as the creator of the usermod. I am not actively maintaining any usermod in this directory, that is your responsibility as the creator of the usermod.
For new usermods, I would recommend trying out the new v2 usermod API, which allows installing multiple usermods at once and new functions! For new usermods, I would recommend trying out the new v2 usermod API, which allows installing multiple usermods at once and new functions!

View File

@ -5,8 +5,8 @@ This usermod-v2 adds support for the awesome RGB Rotary Encoder Board by Adam Ze
https://user-images.githubusercontent.com/3090131/124680599-0180ab80-dec7-11eb-9065-a6d08ebe0287.mp4 https://user-images.githubusercontent.com/3090131/124680599-0180ab80-dec7-11eb-9065-a6d08ebe0287.mp4
## Credits ## Credits
The actual / original code that does the different LED modes is from Adam Zeloof. So I don't take credit for these. But I ported it to WLED, which involved replacing the LED library he used (because, guess what, WLED already has one; so no need to add another one, but use whatever WLED uses), plus the rotary encoder library, because that one was not compatible with ESP, only Arduino. The actual / original code that controls the LED modes is from Adam Zeloof. I take no credit for it. I ported it to WLED, which involved replacing the LED library he used, (because WLED already has one, so no need to add another one) plus the rotary encoder library because it was not compatible with ESP, only Arduino.
So it was quite more work than I hoped, but I got there eventually :) It was quite a bit more work than I hoped, but I got there eventually :)
## Requirements ## Requirements
* "ESP Rotary" by Lennart Hennigs, v1.5.0 or higher: https://github.com/LennartHennigs/ESPRotary * "ESP Rotary" by Lennart Hennigs, v1.5.0 or higher: https://github.com/LennartHennigs/ESPRotary
@ -33,25 +33,25 @@ lib_deps = ${esp8266.lib_deps}
``` ```
## How to connect the board to your ESP ## How to connect the board to your ESP
We gonna need (minimum) three or (maximum) four GPIOs for the board: We'll need (minimum) three or (maximum) four GPIOs for the board:
* "ea": Basically tells if the encoder goes into one or the other direction * "ea": reports the encoder direction
* "eb": Same thing, but the other direction * "eb": Same thing, opposite direction
* "di": LED data in. To actually control the LEDs * "di": LED data in.
* *(optional)* "sw": The integrated switch in the rotary encoder. Can be omitted for the bare functionality of just controlling the brightness * *(optional)* "sw": The integrated switch in the rotary encoder. Can be omitted for the bare functionality of controlling only the brightness
We also gonna need some power, so: We'll also need power:
* "vdd": Needs to be connected to **+5V**. * "vdd": Needs to be connected to **+5V**.
* "gnd": Well, it's GND. * "gnd": Ground.
You can freely pick the GPIOs, it doesn't matter. Those will be configured in the "Usermods" section in the WLED web panel: You can freely pick the GPIOs, it doesn't matter. Those will be configured in the "Usermods" section of the WLED web panel:
## Configuration ## Configuration
Navigate to the "Config" and then to the "Usermods" section. If you compiled WLED with `-D RGB_ROTARY_ENCODER`, you will see the config for it there. The settings there are the GPIOs we mentioned before (*Note: The switch pin is not there, as this can just be configured the "normal" button on the "LED Preferences" page*), plus a few more: Navigate to the "Config" and then to the "Usermods" section. If you compiled WLED with `-D RGB_ROTARY_ENCODER`, you will see the config for it there. The settings there are the aforementioned GPIOs, (*Note: The switch pin is not there, as this can just be configured the "normal" button on the "LED Preferences" page*) plus a few more:
* LED pin: * LED pin:
* Possible values: Any valid and available GPIO * Possible values: Any valid and available GPIO
* Default: 3 * Default: 3
* What it does: Pin to control the LED ring * What it does: controls the LED ring
* ea pin: * ea pin:
* Possible values: Any valid and available GPIO * Possible values: Any valid and available GPIO
* Default: 15 * Default: 15
@ -63,7 +63,7 @@ Navigate to the "Config" and then to the "Usermods" section. If you compiled WLE
* LED Mode: * LED Mode:
* Possible values: 1-3 * Possible values: 1-3
* Default: 3 * Default: 3
* What it does: The usermod provides three different modes of how the LEDs can look like. Here's an example: https://github.com/isotope-engineering/RGB-Encoder-Board/blob/master/images/rgb-encoder-animations.gif * What it does: The usermod provides three different modes of how the LEDs can appear. Here's an example: https://github.com/isotope-engineering/RGB-Encoder-Board/blob/master/images/rgb-encoder-animations.gif
* Up left is "1" * Up left is "1"
* Up right is not supported / doesn't make sense for brightness control * Up right is not supported / doesn't make sense for brightness control
* Bottom left is "2" * Bottom left is "2"
@ -71,15 +71,15 @@ Navigate to the "Config" and then to the "Usermods" section. If you compiled WLE
* LED Brightness: * LED Brightness:
* Possible values: 1-255 * Possible values: 1-255
* Default: 64 * Default: 64
* What it does: Brightness of the LED ring * What it does: sets LED ring Brightness
* Steps per click: * Steps per click:
* Possible values: Any positive number * Possible values: Any positive number
* Default: 4 * Default: 4
* What it does: With each "click", a rotary encoder actually increments it's "steps". Most rotary encoder do four "steps" per "click". I know this sounds super weird, so just leave this the default value, unless your rotary encoder behaves weirdly, like with one click, it makes two LEDs light up, or you sometimes need two click for one LED. Then you should play around with this value or write a small sketch using the same "ESP Rotary" library and read out the steps it does. * What it does: With each "click", a rotary encoder actually increments its "steps". Most rotary encoders produce four "steps" per "click". Leave this at the default value unless your rotary encoder behaves strangely. e.g. with one click, it makes two LEDs light up, or you need two clicks for one LED. If that's the case, adjust this value or write a small sketch using the same "ESP Rotary" library and read out the steps it produce.
* Increment per click: * Increment per click:
* Possible values: Any positive number * Possible values: Any positive number
* Default: 5 * Default: 5
* What it does: Most rotary encoder have 20 "clicks", so basically 20 positions. This value should be set to 100 / `number of clicks` * What it does: Most rotary encoders have 20 "clicks" or positions. This value should be set to 100/`number of clicks`
## Change log ## Change log
2021-07 2021-07

View File

@ -1,12 +1,12 @@
# Sensors To Home Assistant (or mqtt) # Send sensor data To Home Assistant
This usermod will publish values of the BMP280, CCS811 and Si7021 sensors to Home Assistant via MQTT. Publishes BMP280, CCS811 and Si7021 measurements to Home Assistant via MQTT.
Its using home assistant automatic device discovery feature. Uses Home Assistant Automatic Device Discovery.
The use of Home Assistant is not mandatory; it will publish the sensor values via MQTT just fine without it. The use of Home Assistant is not mandatory. The mod will publish sensor values via MQTT just fine without it.
Its resusing the mqtt connection set in the WLED web user interface. Uses the MQTT connection set in the WLED web user interface.
## Maintainer ## Maintainer
@ -15,12 +15,12 @@ twitter.com/mpronk89
## Features ## Features
- Reads BMP280, CCS811 and Si7021 senors - Reads BMP280, CCS811 and Si7021 senors
- Publishes via MQTT, configured via webui of wled - Publishes via MQTT, configured via WLED webUI
- Announces device in Home Assistant for easy setup - Announces device in Home Assistant for easy setup
- Efficient energy usage - Efficient energy usage
- Updates every 60 seconds - Updates every 60 seconds
## Example mqtt topics: ## Example MQTT topics:
`$mqttDeviceTopic` is set in webui of WLED! `$mqttDeviceTopic` is set in webui of WLED!
@ -40,7 +40,7 @@ IAQ: $mqttDeviceTopic/iaq
### Requirements ### Requirements
1. BMP280/CCS811/Si7021 sensor. E.g. https://aliexpress.com/item/32979998543.html 1. BMP280/CCS811/Si7021 sensor. E.g. https://aliexpress.com/item/32979998543.html
2. A microcontroller which can talk i2c, e.g. esp32 2. A microcontroller that supports i2c. e.g. esp32
### installation ### installation
@ -77,7 +77,7 @@ SDA_PIN = 4;
adafruit/Adafruit Si7021 Library @ 1.4.0 adafruit/Adafruit Si7021 Library @ 1.4.0
``` ```
The #ifdefs in `usermods_list.cpp` should do the rest :) The #ifdefs in `usermods_list.cpp` should do the rest
# Credits # Credits

View File

@ -1,25 +1,25 @@
# Seven Segment Display # Seven Segment Display
Usermod that uses the overlay feature to create a configurable seven segment display. Uses the overlay feature to create a configurable seven segment display.
This has only been tested on a single configuration. Colon support is entirely untested. This has only been tested on a single configuration. Colon support has _not_ been tested.
## Installation ## Installation
Add the compile-time option `-D USERMOD_SEVEN_SEGMENT` to your `platformio.ini` (or `platformio_override.ini`) or use `#define USERMOD_SEVEN_SEGMENT` in `my_config.h`. Add the compile-time option `-D USERMOD_SEVEN_SEGMENT` to your `platformio.ini` (or `platformio_override.ini`) or use `#define USERMOD_SEVEN_SEGMENT` in `my_config.h`.
## Settings ## Settings
Settings can be controlled through both the usermod setting page and through MQTT with a raw payload. Settings can be controlled via both the usermod setting page and through MQTT with a raw payload.
##### Example ##### Example
Topic ```<mqttDeviceTopic||mqttGroupTopic>/sevenSeg/perSegment/set``` Topic ```<mqttDeviceTopic||mqttGroupTopic>/sevenSeg/perSegment/set```
Payload ```3``` Payload ```3```
#### perSegment -- ssLEDPerSegment #### perSegment -- ssLEDPerSegment
The number of individual LEDs per segment. There are 7 segments per digit. The number of individual LEDs per segment. 7 segments per digit.
#### perPeriod -- ssLEDPerPeriod #### perPeriod -- ssLEDPerPeriod
The number of individual LEDs per period. A ':' has 2x periods. The number of individual LEDs per period. A ':' (colon) has two periods.
#### startIdx -- ssStartLED #### startIdx -- ssStartLED
Index of the LED that the display starts at. Allows a seven segment display to be in the middle of a string. Index of the LED the display starts at. Enabless a seven segment display to be in the middle of a string.
#### timeEnable -- ssTimeEnabled #### timeEnable -- ssTimeEnabled
When true, when displayMask is configured for a time output and no message is set the time will be displayed. When true, when displayMask is configured for a time output and no message is set, the time will be displayed.
#### scrollSpd -- ssScrollSpeed #### scrollSpd -- ssScrollSpeed
Time, in milliseconds, between message shifts when the length of displayMsg exceeds the length of the displayMask. Time, in milliseconds, between message shifts when the length of displayMsg exceeds the length of the displayMask.
#### displayMask -- ssDisplayMask #### displayMask -- ssDisplayMask
@ -35,9 +35,9 @@ All others for alpha numeric, (will be blank when displaying time)
```HHMMSS ``` ```HHMMSS ```
```hh:MM:SS ``` ```hh:MM:SS ```
#### displayMsg -- ssDisplayMessage #### displayMsg -- ssDisplayMessage
Message to be displayed across the display. If the length exceeds the length of the displayMask the message will scroll at scrollSpd. To 'remove' a message or revert back to time, if timeEnabled is true, set the message to '~'. Message to be displayed. If the message length exceeds the length of displayMask, the message will scroll at scrollSpd. To 'remove' a message or revert back to time, if timeEnabled is true, set the message to '~'.
#### displayCfg -- ssDisplayConfig #### displayCfg -- ssDisplayConfig
The order that your LEDs are configured. All seven segments in the display need to be wired the same way. The order your LEDs are configured in. All segments in the display need to be wired the same way.
<pre> <pre>
------- -------
/ A / 0 - EDCGFAB / A / 0 - EDCGFAB

View File

@ -1,6 +1,6 @@
# Seven Segment Display Reloaded # Seven Segment Display Reloaded
Usermod that uses the overlay feature to create a configurable seven segment display. Uses the overlay feature to create a configurable seven segment display.
Optimized for maximum configurability and use with seven segment clocks by parallyze (https://www.instructables.com/member/parallyze/instructables/) Optimized for maximum configurability and use with seven segment clocks by parallyze (https://www.instructables.com/member/parallyze/instructables/)
Very loosely based on the existing usermod "seven segment display". Very loosely based on the existing usermod "seven segment display".
@ -12,26 +12,26 @@ Add the compile-time option `-D USERMOD_SSDR` to your `platformio.ini` (or `plat
For the auto brightness option, the usermod SN_Photoresistor has to be installed as well. See SN_Photoresistor/readme.md for instructions. For the auto brightness option, the usermod SN_Photoresistor has to be installed as well. See SN_Photoresistor/readme.md for instructions.
## Settings ## Settings
All settings can be controlled the usermod setting page. All settings can be controlled via the usermod settings page.
Part of the settings can be controlled through MQTT with a raw payload or through a json request to /json/state. Part of the settings can be controlled through MQTT with a raw payload or through a json request to /json/state.
### enabled ### enabled
Enables/disables this overlay usermod Enables/disables this usermod
### inverted ### inverted
Enables the inverted mode in which the background should be enabled and the digits should be black (leds off) Enables the inverted mode in which the background should be enabled and the digits should be black (LEDs off)
### Colon-blinking ### Colon-blinking
Enables the blinking colon(s) if they are defined Enables the blinking colon(s) if they are defined
### enable-auto-brightness ### enable-auto-brightness
Enables the auto brightness feature. Can be only used with the usermod SN_Photoresistor installed. Enables the auto brightness feature. Can be used only when the usermod SN_Photoresistor is installed.
### auto-brightness-min / auto-brightness-max ### auto-brightness-min / auto-brightness-max
The lux value calculated from usermod SN_Photoresistor will be mapped to the values defined here. The lux value calculated from usermod SN_Photoresistor will be mapped to the values defined here.
The mapping is 0 - 1000 lux will be mapped to auto-brightness-min - auto-brightness-max The mapping, 0 - 1000 lux, will be mapped to auto-brightness-min and auto-brightness-max
The mA current protection of WLED will override the calculated value if it is too high. WLED current protection will override the calculated value if it is too high.
### Display-Mask ### Display-Mask
Defines the type of the time/date display. Defines the type of the time/date display.
@ -61,7 +61,7 @@ See following example for usage.
## Example ## Example
Example for Leds definition Example of an LED definition:
``` ```
< A > < A >
/\ /\ /\ /\
@ -74,15 +74,15 @@ E C
< D > < D >
``` ```
Leds or Range of Leds are seperated by a comma "," LEDs or Range of LEDs are separated by a comma ","
Segments are seperated by a semicolon ";" and are read as A;B;C;D;E;F;G Segments are separated by a semicolon ";" and are read as A;B;C;D;E;F;G
Digits are seperated by colon ":" -> A;B;C;D;E;F;G:A;B;C;D;E;F;G Digits are separated by colon ":" -> A;B;C;D;E;F;G:A;B;C;D;E;F;G
Ranges are defined as lower to higher (lower first) Ranges are defined as lower to higher (lower first)
For example, an clock definition for the following clock (https://www.instructables.com/Lazy-7-Quick-Build-Edition/) is For example, a clock definition for the following clock (https://www.instructables.com/Lazy-7-Quick-Build-Edition/) is
- hour "59,46;47-48;50-51;52-53;54-55;57-58;49,56:0,13;1-2;4-5;6-7;8-9;11-12;3,10" - hour "59,46;47-48;50-51;52-53;54-55;57-58;49,56:0,13;1-2;4-5;6-7;8-9;11-12;3,10"
@ -96,18 +96,18 @@ or
depending on the orientation. depending on the orientation.
# The example detailed: # Example details:
hour "59,46;47-48;50-51;52-53;54-55;57-58;49,56:0,13;1-2;4-5;6-7;8-9;11-12;3,10" hour "59,46;47-48;50-51;52-53;54-55;57-58;49,56:0,13;1-2;4-5;6-7;8-9;11-12;3,10"
there are two digits seperated by ":" there are two digits separated by ":"
- 59,46;47-48;50-51;52-53;54-55;57-58;49,56 - 59,46;47-48;50-51;52-53;54-55;57-58;49,56
- 0,13;1-2;4-5;6-7;8-9;11-12;3,10 - 0,13;1-2;4-5;6-7;8-9;11-12;3,10
In the first digit, In the first digit,
the **segment A** consists of the leds number **59 and 46**., **segment B** consists of the leds number **47, 48** and so on the **segment A** consists of the LEDs number **59 and 46**., **segment B** consists of the LEDs number **47, 48** and so on
The second digit starts again with **segment A** and leds **0 and 13**, **segment B** consists of the leds number **1 and 2** and so on The second digit starts again with **segment A** and LEDs **0 and 13**, **segment B** consists of the LEDs number **1 and 2** and so on
### first digit of the hour ### first digit of the hour
- Segment A: 59, 46 - Segment A: 59, 46

56
usermods/sht/readme.md Normal file
View File

@ -0,0 +1,56 @@
# SHT
Usermod to support various SHT i2c sensors like the SHT30, SHT31, SHT35 and SHT85
## Requirements
* "SHT85" by Rob Tillaart, v0.2 or higher: https://github.com/RobTillaart/SHT85
## Usermod installation
Simply copy the below block (build task) to your `platformio_override.ini` and compile WLED using this new build task. Or use an existing one, add the buildflag `-D USERMOD_SHT` and the below library dependencies.
ESP32:
```
[env:custom_esp32dev_usermod_sht]
extends = env:esp32dev
build_flags = ${common.build_flags_esp32}
-D USERMOD_SHT
lib_deps = ${esp32.lib_deps}
robtillaart/SHT85@~0.3.3
```
ESP8266:
```
[env:custom_d1_mini_usermod_sht]
extends = env:d1_mini
build_flags = ${common.build_flags_esp8266}
-D USERMOD_SHT
lib_deps = ${esp8266.lib_deps}
robtillaart/SHT85@~0.3.3
```
## MQTT Discovery for Home Assistant
If you're using Home Assistant and want to have the temperature and humidity available as entities in HA, you can tick the "Add-To-Home-Assistant-MQTT-Discovery" option in the usermod settings. If you have an MQTT broker configured under "Sync Settings" and it is connected, the mod will publish the auto discovery message to your broker and HA will instantly find it and create an entity each for the temperature and humidity.
### Publishing readings via MQTT
Regardless of having MQTT discovery ticked or not, the mod will always report temperature and humidity to the WLED MQTT topic of that instance, if you have a broker configured and it's connected.
## Configuration
Navigate to the "Config" and then to the "Usermods" section. If you compiled WLED with `-D USERMOD_SHT`, you will see the config for it there:
* SHT-Type:
* What it does: Select the SHT sensor type you want to use
* Possible values: SHT30, SHT31, SHT35, SHT85
* Default: SHT30
* Unit:
* What it does: Select which unit should be used to display the temperature in the info section. Also used when sending via MQTT discovery, see below.
* Possible values: Celsius, Fahrenheit
* Default: Celsius
* Add-To-HA-MQTT-Discovery:
* What it does: Makes the temperature and humidity available via MQTT discovery, so they're automatically added to Home Assistant, because that way it's typesafe.
* Possible values: Enabled/Disabled
* Default: Disabled
## Change log
2022-12
* First implementation.
## Credits
ezcGman | Andy: Find me on the Intermit.Tech (QuinLED) Discord server: https://discord.gg/WdbAauG

492
usermods/sht/usermod_sht.h Normal file
View File

@ -0,0 +1,492 @@
#pragma once
#include "SHT85.h"
#define USERMOD_SHT_TYPE_SHT30 0
#define USERMOD_SHT_TYPE_SHT31 1
#define USERMOD_SHT_TYPE_SHT35 2
#define USERMOD_SHT_TYPE_SHT85 3
class ShtUsermod : public Usermod
{
private:
bool enabled = false; // Is usermod enabled or not
bool firstRunDone = false; // Remembers if the first config load run had been done
bool pinAllocDone = true; // Remembers if we have allocated pins
bool initDone = false; // Remembers if the mod has been completely initialised
bool haMqttDiscovery = false; // Is MQTT discovery enabled or not
bool haMqttDiscoveryDone = false; // Remembers if we already published the HA discovery topics
// SHT vars
SHT *shtTempHumidSensor; // Instance of SHT lib
byte shtType = 0; // SHT sensor type to be used. Default: SHT30
byte unitOfTemp = 0; // Temperature unit to be used. Default: Celsius (0 = Celsius, 1 = Fahrenheit)
bool shtInitDone = false; // Remembers if SHT sensor has been initialised
bool shtReadDataSuccess = false; // Did we have a successful data read and is a valid temperature and humidity available?
const byte shtI2cAddress = 0x44; // i2c address of the sensor. 0x44 is the default for all SHT sensors. Change this, if needed
unsigned long shtLastTimeUpdated = 0; // Remembers when we read data the last time
bool shtDataRequested = false; // Reading data is done async. This remembers if we asked the sensor to read data
float shtCurrentTempC = 0; // Last read temperature in Celsius
float shtCurrentTempF = 0; // Last read temperature in Fahrenheit
float shtCurrentHumidity = 0; // Last read humidity in RH%
void initShtTempHumiditySensor();
void cleanupShtTempHumiditySensor();
void cleanup();
bool isShtReady();
void publishTemperatureAndHumidityViaMqtt();
void publishHomeAssistantAutodiscovery();
void appendDeviceToMqttDiscoveryMessage(JsonDocument& root);
public:
// Strings to reduce flash memory usage (used more than twice)
static const char _name[];
static const char _enabled[];
static const char _shtType[];
static const char _unitOfTemp[];
static const char _haMqttDiscovery[];
void setup();
void loop();
void onMqttConnect(bool sessionPresent);
void appendConfigData();
void addToConfig(JsonObject &root);
bool readFromConfig(JsonObject &root);
void addToJsonInfo(JsonObject& root);
float getTemperatureC();
float getTemperatureF();
float getHumidity();
uint16_t getId() { return USERMOD_ID_SHT; }
};
// Strings to reduce flash memory usage (used more than twice)
const char ShtUsermod::_name[] PROGMEM = "SHT-Sensor";
const char ShtUsermod::_enabled[] PROGMEM = "Enabled";
const char ShtUsermod::_shtType[] PROGMEM = "SHT-Type";
const char ShtUsermod::_unitOfTemp[] PROGMEM = "Unit";
const char ShtUsermod::_haMqttDiscovery[] PROGMEM = "Add-To-HA-MQTT-Discovery";
/**
* Initialise SHT sensor.
*
* Using the correct constructor according to config and initialises it using the
* global i2c pins.
*
* @return void
*/
void ShtUsermod::initShtTempHumiditySensor()
{
switch (shtType) {
case USERMOD_SHT_TYPE_SHT30: shtTempHumidSensor = (SHT *) new SHT30(); break;
case USERMOD_SHT_TYPE_SHT31: shtTempHumidSensor = (SHT *) new SHT31(); break;
case USERMOD_SHT_TYPE_SHT35: shtTempHumidSensor = (SHT *) new SHT35(); break;
case USERMOD_SHT_TYPE_SHT85: shtTempHumidSensor = (SHT *) new SHT85(); break;
}
shtTempHumidSensor->begin(shtI2cAddress, i2c_sda, i2c_scl);
if (shtTempHumidSensor->readStatus() == 0xFFFF) {
DEBUG_PRINTF("[%s] SHT init failed!\n", _name);
cleanupShtTempHumiditySensor();
cleanup();
return;
}
shtInitDone = true;
}
/**
* Cleanup the SHT sensor.
*
* Properly calls "reset" for the sensor then releases it from memory.
*
* @return void
*/
void ShtUsermod::cleanupShtTempHumiditySensor()
{
if (isShtReady()) {
shtTempHumidSensor->reset();
}
delete shtTempHumidSensor;
shtInitDone = false;
}
/**
* Cleanup the mod completely.
*
* Calls ::cleanupShtTempHumiditySensor() to cleanup the SHT sensor and
* deallocates pins.
*
* @return void
*/
void ShtUsermod::cleanup()
{
if (isShtReady()) {
cleanupShtTempHumiditySensor();
}
if (pinAllocDone) {
PinManagerPinType pins[2] = { { i2c_sda, true }, { i2c_scl, true } };
pinManager.deallocateMultiplePins(pins, 2, PinOwner::HW_I2C);
pinAllocDone = false;
}
enabled = false;
}
/**
* Checks if the SHT sensor has been initialised.
*
* @return bool
*/
bool ShtUsermod::isShtReady()
{
return shtInitDone;
}
/**
* Publish temperature and humidity to WLED device topic.
*
* Will add a "/temperature" and "/humidity" topic to the WLED device topic.
* Temperature will be written in configured unit.
*
* @return void
*/
void ShtUsermod::publishTemperatureAndHumidityViaMqtt() {
if (!WLED_MQTT_CONNECTED) return;
char buf[128];
snprintf_P(buf, 127, PSTR("%s/temperature"), mqttDeviceTopic);
mqtt->publish(buf, 0, false, String((unitOfTemp ? getTemperatureF() : getTemperatureC())).c_str());
snprintf_P(buf, 127, PSTR("%s/humidity"), mqttDeviceTopic);
mqtt->publish(buf, 0, false, String(shtCurrentHumidity).c_str());
}
/**
* If enabled, publishes HA MQTT device discovery topics.
*
* Will make Home Assistant add temperature and humidity as entities automatically.
*
* Note: Whenever usermods are part of the WLED integration in HA, this can be dropped.
*
* @return void
*/
void ShtUsermod::publishHomeAssistantAutodiscovery() {
if (!WLED_MQTT_CONNECTED) return;
char json_str[1024], buf[128];
size_t payload_size;
StaticJsonDocument<1024> json;
snprintf_P(buf, 127, PSTR("%s Temperature"), serverDescription);
json[F("name")] = buf;
snprintf_P(buf, 127, PSTR("%s/temperature"), mqttDeviceTopic);
json[F("stat_t")] = buf;
json[F("dev_cla")] = F("temperature");
json[F("stat_cla")] = F("measurement");
snprintf_P(buf, 127, PSTR("%s-temperature"), escapedMac.c_str());
json[F("uniq_id")] = buf;
json[F("unit_of_meas")] = F("°C");
appendDeviceToMqttDiscoveryMessage(json);
payload_size = serializeJson(json, json_str);
snprintf_P(buf, 127, PSTR("homeassistant/sensor/%s/%s-temperature/config"), escapedMac.c_str(), escapedMac.c_str());
mqtt->publish(buf, 0, true, json_str, payload_size);
json.clear();
snprintf_P(buf, 127, PSTR("%s Humidity"), serverDescription);
json[F("name")] = buf;
snprintf_P(buf, 127, PSTR("%s/humidity"), mqttDeviceTopic);
json[F("stat_t")] = buf;
json[F("dev_cla")] = F("humidity");
json[F("stat_cla")] = F("measurement");
snprintf_P(buf, 127, PSTR("%s-humidity"), escapedMac.c_str());
json[F("uniq_id")] = buf;
json[F("unit_of_meas")] = F("%");
appendDeviceToMqttDiscoveryMessage(json);
payload_size = serializeJson(json, json_str);
snprintf_P(buf, 127, PSTR("homeassistant/sensor/%s/%s-humidity/config"), escapedMac.c_str(), escapedMac.c_str());
mqtt->publish(buf, 0, true, json_str, payload_size);
haMqttDiscoveryDone = true;
}
/**
* Helper to add device information to MQTT discovery topic.
*
* @return void
*/
void ShtUsermod::appendDeviceToMqttDiscoveryMessage(JsonDocument& root) {
JsonObject device = root.createNestedObject("dev");
device[F("ids")] = escapedMac.c_str();
device[F("name")] = serverDescription;
device[F("sw")] = versionString;
device[F("mdl")] = ESP.getChipModel();
device[F("mf")] = F("espressif");
}
/**
* Setup the mod.
*
* Allocates i2c pins as PinOwner::HW_I2C, so they can be allocated multiple times.
* And calls ::initShtTempHumiditySensor() to initialise the sensor.
*
* @see Usermod::setup()
* @see UsermodManager::setup()
*
* @return void
*/
void ShtUsermod::setup()
{
if (enabled) {
PinManagerPinType pins[2] = { { i2c_sda, true }, { i2c_scl, true } };
// GPIOs can be set to -1 and allocateMultiplePins() will return true, so check they're gt zero
if (i2c_sda < 0 || i2c_scl < 0 || !pinManager.allocateMultiplePins(pins, 2, PinOwner::HW_I2C)) {
DEBUG_PRINTF("[%s] SHT pin allocation failed!\n", _name);
cleanup();
return;
}
pinAllocDone = true;
initShtTempHumiditySensor();
initDone = true;
}
firstRunDone = true;
}
/**
* Actually reading data (async) from the sensor every 30 seconds.
*
* If last reading is at least 30 seconds, it will trigger a reading using
* SHT::requestData(). We will then continiously check SHT::dataReady() if
* data is ready to be read. If so, it's read, stored locally and published
* via MQTT.
*
* @see Usermod::loop()
* @see UsermodManager::loop()
*
* @return void
*/
void ShtUsermod::loop()
{
if (!enabled || !initDone || strip.isUpdating()) return;
if (isShtReady()) {
if (millis() - shtLastTimeUpdated > 30000 && !shtDataRequested) {
shtTempHumidSensor->requestData();
shtDataRequested = true;
shtLastTimeUpdated = millis();
}
if (shtDataRequested) {
if (shtTempHumidSensor->dataReady()) {
if (shtTempHumidSensor->readData(false)) {
shtCurrentTempC = shtTempHumidSensor->getTemperature();
shtCurrentTempF = shtTempHumidSensor->getFahrenheit();
shtCurrentHumidity = shtTempHumidSensor->getHumidity();
publishTemperatureAndHumidityViaMqtt();
shtReadDataSuccess = true;
}
else {
shtReadDataSuccess = false;
}
shtDataRequested = false;
}
}
}
}
/**
* Whenever MQTT is connected, publish HA autodiscovery topics.
*
* Is only donce once.
*
* @see Usermod::onMqttConnect()
* @see UsermodManager::onMqttConnect()
*
* @return void
*/
void ShtUsermod::onMqttConnect(bool sessionPresent) {
if (haMqttDiscovery && !haMqttDiscoveryDone) publishHomeAssistantAutodiscovery();
}
/**
* Add dropdown for sensor type and unit to UM config page.
*
* @see Usermod::appendConfigData()
* @see UsermodManager::appendConfigData()
*
* @return void
*/
void ShtUsermod::appendConfigData() {
oappend(SET_F("dd=addDropdown('"));
oappend(_name);
oappend(SET_F("','"));
oappend(_shtType);
oappend(SET_F("');"));
oappend(SET_F("addOption(dd,'SHT30',0);"));
oappend(SET_F("addOption(dd,'SHT31',1);"));
oappend(SET_F("addOption(dd,'SHT35',2);"));
oappend(SET_F("addOption(dd,'SHT85',3);"));
oappend(SET_F("dd=addDropdown('"));
oappend(_name);
oappend(SET_F("','"));
oappend(_unitOfTemp);
oappend(SET_F("');"));
oappend(SET_F("addOption(dd,'Celsius',0);"));
oappend(SET_F("addOption(dd,'Fahrenheit',1);"));
}
/**
* Add config data to be stored in cfg.json.
*
* @see Usermod::addToConfig()
* @see UsermodManager::addToConfig()
*
* @return void
*/
void ShtUsermod::addToConfig(JsonObject &root)
{
JsonObject top = root.createNestedObject(FPSTR(_name)); // usermodname
top[FPSTR(_enabled)] = enabled;
top[FPSTR(_shtType)] = shtType;
top[FPSTR(_unitOfTemp)] = unitOfTemp;
top[FPSTR(_haMqttDiscovery)] = haMqttDiscovery;
}
/**
* Apply config on boot or save of UM config page.
*
* This is called whenever WLED boots and loads cfg.json, or when the UM config
* page is saved. Will properly re-instantiate the SHT class upon type change and
* publish HA discovery after enabling.
*
* @see Usermod::readFromConfig()
* @see UsermodManager::readFromConfig()
*
* @return bool
*/
bool ShtUsermod::readFromConfig(JsonObject &root)
{
JsonObject top = root[FPSTR(_name)];
if (top.isNull()) {
DEBUG_PRINTF("[%s] No config found. (Using defaults.)\n", _name);
return false;
}
bool oldEnabled = enabled;
byte oldShtType = shtType;
bool oldHaMqttDiscovery = haMqttDiscovery;
getJsonValue(top[FPSTR(_enabled)], enabled);
getJsonValue(top[FPSTR(_shtType)], shtType);
getJsonValue(top[FPSTR(_unitOfTemp)], unitOfTemp);
getJsonValue(top[FPSTR(_haMqttDiscovery)], haMqttDiscovery);
// First run: reading from cfg.json, nothing to do here, will be all done in setup()
if (!firstRunDone) {
DEBUG_PRINTF("[%s] First run, nothing to do\n", _name);
}
// Check if mod has been en-/disabled
else if (enabled != oldEnabled) {
enabled ? setup() : cleanup();
DEBUG_PRINTF("[%s] Usermod has been en-/disabled\n", _name);
}
// Config has been changed, so adopt to changes
else if (enabled) {
if (oldShtType != shtType) {
cleanupShtTempHumiditySensor();
initShtTempHumiditySensor();
}
if (oldHaMqttDiscovery != haMqttDiscovery && haMqttDiscovery) {
publishHomeAssistantAutodiscovery();
}
DEBUG_PRINTF("[%s] Config (re)loaded\n", _name);
}
return true;
}
/**
* Adds the temperature and humidity actually to the info section and /json info.
*
* This is called every time the info section is opened ot /json is called.
*
* @see Usermod::addToJsonInfo()
* @see UsermodManager::addToJsonInfo()
*
* @return void
*/
void ShtUsermod::addToJsonInfo(JsonObject& root)
{
if (!enabled && !isShtReady()) {
return;
}
JsonObject user = root["u"];
if (user.isNull()) user = root.createNestedObject("u");
JsonArray jsonTemp = user.createNestedArray(F("Temperature"));
JsonArray jsonHumidity = user.createNestedArray(F("Humidity"));
if (shtLastTimeUpdated == 0 || !shtReadDataSuccess) {
jsonTemp.add(0);
jsonHumidity.add(0);
if (shtLastTimeUpdated == 0) {
jsonTemp.add(F(" Not read yet"));
jsonHumidity.add(F(" Not read yet"));
}
else {
jsonTemp.add(F(" Error"));
jsonHumidity.add(F(" Error"));
}
return;
}
jsonHumidity.add(shtCurrentHumidity);
jsonHumidity.add(F(" RH"));
unitOfTemp ? jsonTemp.add(getTemperatureF()) : jsonTemp.add(getTemperatureC());
unitOfTemp ? jsonTemp.add(F(" °F")) : jsonTemp.add(F(" °C"));
}
/**
* Getter for last read temperature in Celsius.
*
* @return float
*/
float ShtUsermod::getTemperatureC() {
return shtCurrentTempC;
}
/**
* Getter for last read temperature in Fahrenheit.
*
* @return float
*/
float ShtUsermod::getTemperatureF() {
return shtCurrentTempF;
}
/**
* Getter for last read humidity in RH%.
*
* @return float
*/
float ShtUsermod::getHumidity() {
return shtCurrentHumidity;
}

View File

@ -1,6 +1,6 @@
# Smartnest # Smartnest
This usermod-v2 modification allows integration with `smartnest.cz` service which provides MQTT integration with voice assistants. Enables integration with `smartnest.cz` service which provides MQTT integration with voice assistants.
In order to setup Smartnest follow the [documentation](https://www.docu.smartnest.cz/). In order to setup Smartnest follow the [documentation](https://www.docu.smartnest.cz/).
## MQTT API ## MQTT API
@ -49,7 +49,7 @@ void registerUsermods()
## Configuration ## Configuration
Usermod has no configuration but relies on the MQTT configuration.\ Usermod has no configuration, but it relies on the MQTT configuration.\
Under Config > Sync Interfaces > MQTT: Under Config > Sync Interfaces > MQTT:
* Enable MQTT check box * Enable MQTT check box
* Set the `Broker` field to: `smartnest.cz` * Set the `Broker` field to: `smartnest.cz`

View File

@ -2,13 +2,13 @@
Quick usermod to accomplish something similar to [this video](https://www.youtube.com/watch?v=NHkju5ncC4A). Quick usermod to accomplish something similar to [this video](https://www.youtube.com/watch?v=NHkju5ncC4A).
This usermod allows you to add a lightstrip alongside or on the steps of a staircase. This usermod enables you to add a lightstrip alongside or on the steps of a staircase.
When the `userVar0` variable is set, the LEDs will gradually turn on in a Wipe effect. When the `userVar0` variable is set, the LEDs will gradually turn on in a Wipe effect.
Both directions are supported by setting userVar0 to 1 and 2, respectively (HTTP API commands `U0=1` and `U0=2`). Both directions are supported by setting userVar0 to 1 and 2, respectively (HTTP API commands `U0=1` and `U0=2`).
After the Wipe is complete, the light will either stay on (Solid effect) indefinitely or after `userVar1` seconds have elapsed. After the Wipe is complete, the light will either stay on (Solid effect) indefinitely or extinguish after `userVar1` seconds have elapsed.
If userVar0 is updated (e.g. by triggering a second sensor) the light will slowly fade off. If userVar0 is updated (e.g. by triggering a second sensor) the light will fade slowly until it's off.
This could be extended to also run a Wipe effect in reverse order to turn the LEDs back off. This could be extended to also run a Wipe effect in reverse order to turn the LEDs off.
This is just a basic version to accomplish this using HTTP API calls `U0` and `U1` and/or macros. This is just a basic version to accomplish this using HTTP API calls `U0` and `U1` and/or macros.
It should be easy to adapt this code however to interface with motion sensors or other input devices. It should be easy to adapt this code to interface with motion sensors or other input devices.

View File

@ -1,18 +1,18 @@
# Rotary Encoder (Brightness and Color) # Rotary Encoder (Brightness and Color)
V2 usermod that allows changing brightness and color using a rotary encoder, V2 usermod that enables changing brightness and color using a rotary encoder
change between modes by pressing a button (many encoders have one included) change between modes by pressing a button (many encoders have one included)
but it will wait for AUTOSAVE_SETTLE_MS milliseconds, a "settle" it will wait for AUTOSAVE_SETTLE_MS milliseconds. a "settle"
period in case there are other changes (any change will period in case there are other changes (any change will
extend the "settle" window). extend the "settle" period).
It will additionally load preset AUTOSAVE_PRESET_NUM at startup. It will additionally load preset AUTOSAVE_PRESET_NUM at startup.
during the first `loop()`. Reasoning below. during the first `loop()`. Reasoning below.
AutoSaveUsermod is standalone, but if FourLineDisplayUsermod is installed, it will notify the user of the saved changes. AutoSaveUsermod is standalone, but if FourLineDisplayUsermod is installed, it will notify the user of the saved changes.
Note: I don't love that WLED doesn't respect the brightness of the preset being auto loaded, so the AutoSaveUsermod will set the AUTOSAVE_PRESET_NUM preset in the first loop, so brightness IS honored. This means WLED will effectively ignore Default brightness and Apply N preset at boot when the AutoSaveUsermod is installed. Note: WLED doesn't respect the brightness of the preset being auto loaded, so the AutoSaveUsermod will set the AUTOSAVE_PRESET_NUM preset in the first loop, so brightness IS honored. This means WLED will effectively ignore Default brightness and Apply N preset at boot when the AutoSaveUsermod is installed.
## Installation ## Installation

View File

@ -9,13 +9,13 @@ to preset number AUTOSAVE_PRESET_NUM after a change to any of:
* palette * palette
but it will wait for AUTOSAVE_AFTER_SEC seconds, but it will wait for AUTOSAVE_AFTER_SEC seconds,
a "settle" period in case there are other changes (any change will extend the "settle" window). a "settle" period in case there are other changes (any change will extend the "settle" period).
It will additionally load preset AUTOSAVE_PRESET_NUM at startup during the first `loop()`. It will additionally load preset AUTOSAVE_PRESET_NUM at startup during the first `loop()`.
AutoSaveUsermod is standalone, but if FourLineDisplayUsermod is installed, it will notify the user of the saved changes. AutoSaveUsermod is standalone, but if FourLineDisplayUsermod is installed, it will notify the user of the saved changes.
Note: I don't love that WLED doesn't respect the brightness of the preset being auto loaded, so the AutoSaveUsermod will set the AUTOSAVE_PRESET_NUM preset in the first loop, so brightness IS honored. This means WLED will effectively ignore Default brightness and Apply N preset at boot when the AutoSaveUsermod is installed. Note: WLED doesn't respect the brightness of the preset being auto loaded, so the AutoSaveUsermod will set the AUTOSAVE_PRESET_NUM preset in the first loop, so brightness IS honored. This means WLED will effectively ignore Default brightness and Apply N preset at boot when the AutoSaveUsermod is installed.
## Installation ## Installation
@ -25,7 +25,7 @@ This file should be placed in the same directory as `platformio.ini`.
### Define Your Options ### Define Your Options
* `USERMOD_AUTO_SAVE` - define this to have this the Auto Save usermod included wled00\usermods_list.cpp * `USERMOD_AUTO_SAVE` - define this to have this usermod included wled00\usermods_list.cpp
* `AUTOSAVE_AFTER_SEC` - define the delay time after the settings auto-saving routine should be executed * `AUTOSAVE_AFTER_SEC` - define the delay time after the settings auto-saving routine should be executed
* `AUTOSAVE_PRESET_NUM` - define the preset number used by autosave usermod * `AUTOSAVE_PRESET_NUM` - define the preset number used by autosave usermod
* `USERMOD_AUTO_SAVE_ON_BOOT` - define if autosave should be enabled on boot * `USERMOD_AUTO_SAVE_ON_BOOT` - define if autosave should be enabled on boot

View File

@ -2,9 +2,9 @@
First, thanks to the authors of the ssd11306_i2c_oled_u8g2 mod. First, thanks to the authors of the ssd11306_i2c_oled_u8g2 mod.
This usermod provides a four line display using either Provides a four line display using either
128x32 or 128x64 OLED displays. 128x32 or 128x64 OLED displays.
It's can operate independently, but starts to provide It can operate independently, but starts to provide
a relatively complete on-device UI when paired with the a relatively complete on-device UI when paired with the
Rotary Encoder UI usermod. I strongly encourage you to use Rotary Encoder UI usermod. I strongly encourage you to use
them together. them together.
@ -19,11 +19,11 @@ This file should be placed in the same directory as `platformio.ini`.
### Define Your Options ### Define Your Options
* `USERMOD_FOUR_LINE_DISPLAY` - define this to have this the Four Line Display mod included wled00\usermods_list.cpp - also tells Rotary Encoder usermod, if installed, that the display is available * `USERMOD_FOUR_LINE_DISPLAY` - define this to have this mod included wled00\usermods_list.cpp - also tells Rotary Encoder usermod, if installed, the display is available
* `FLD_PIN_SCL` - The display SCL pin, defaults to 5 * `FLD_PIN_SCL` - The display SCL pin, defaults to 5
* `FLD_PIN_SDA` - The display SDA pin, defaults to 4 * `FLD_PIN_SDA` - The display SDA pin, defaults to 4
All of the parameters can be configured using Usermods settings page, inluding GPIO pins. All of the parameters can be configured via the Usermods settings page, inluding GPIO pins.
### PlatformIO requirements ### PlatformIO requirements
@ -44,7 +44,7 @@ UI usermod folder for how to include these using `platformio_override.ini`.
* 6 = SPI SSD1306 128x32 * 6 = SPI SSD1306 128x32
* 7 = SPI SSD1306 128x64 (4 double-height lines) * 7 = SPI SSD1306 128x64 (4 double-height lines)
* `contrast` - set display contrast (higher contrast may reduce display lifetime) * `contrast` - set display contrast (higher contrast may reduce display lifetime)
* `refreshRateSec` - time in seconds for display refresh * `refreshRateSec` - display refresh time in seconds
* `screenTimeOutSec` - screen saver time-out in seconds * `screenTimeOutSec` - screen saver time-out in seconds
* `flip` - flip/rotate display 180° * `flip` - flip/rotate display 180°
* `sleepMode` - enable/disable screen saver * `sleepMode` - enable/disable screen saver

View File

@ -4,12 +4,12 @@ Thank you to the authors of the original version of these usermods. It would not
"usermod_v2_four_line_display" "usermod_v2_four_line_display"
"usermod_v2_rotary_encoder_ui" "usermod_v2_rotary_encoder_ui"
The core of these usermods are a copy of the originals. The main changes are done to the FourLineDisplay usermod. The core of these usermods are a copy of the originals. The main changes are to the FourLineDisplay usermod.
The display usermod UI has been completely changed. The display usermod UI has been completely changed.
The changes made to the RotaryEncoder usermod were made to support the new UI in the display usermod. The changes made to the RotaryEncoder usermod were made to support the new UI in the display usermod.
Without the display it functions identical to the original. Without the display it, functions identical to the original.
The original "usermod_v2_auto_save" will not work with the display just yet. The original "usermod_v2_auto_save" will not work with the display just yet.
Press the encoder to cycle through the options: Press the encoder to cycle through the options:
@ -22,7 +22,7 @@ Press the encoder to cycle through the options:
*Saturation (only if display is used) *Saturation (only if display is used)
Press and hold the encoder to display Network Info Press and hold the encoder to display Network Info
if AP is active then it will display AP ssid and Password if AP is active, it will display AP, SSID and password
Also shows if the timer is enabled Also shows if the timer is enabled

View File

@ -8,26 +8,26 @@ palettes to other usermods. Notably it provides:
```char **getModesQStrings()``` ```char **getModesQStrings()```
Provides an array of char* (pointers) to the names of the Provides a char* array (pointers) to the names of the
palettes within JSON_mode_names, in the same order as palettes contained in JSON_mode_names, in the same order as
JSON_mode_names. These strings end in double quote (") JSON_mode_names. These strings end in double quote (")
(or \0 if there is a problem). (or \0 if there is a problem).
```byte *getModesAlphaIndexes()``` ```byte *getModesAlphaIndexes()```
An array of byte designating the indexes of names of the A byte array designating the indexes of names of the
modes in alphabetical order. "Solid" will always remain modes in alphabetical order. "Solid" will always remain
at the front of the list. at the top of the list.
```char **getPalettesQStrings()``` ```char **getPalettesQStrings()```
Provides an array of char* (pointers) to the names of the Provides a char* array (pointers) to the names of the
palettes within JSON_palette_names, in the same order as palettes contained in JSON_palette_names, in the same order as
JSON_palette_names. These strings end in double quote (") JSON_palette_names. These strings end in double quote (")
(or \0 if there is a problem). (or \0 if there is a problem).
```byte *getPalettesAlphaIndexes()``` ```byte *getPalettesAlphaIndexes()```
An array of byte designating the indexes of names of the A byte array designating the indexes of names of the
palettes in alphabetical order. "Default" and those palettes in alphabetical order. "Default" and those
starting with "(" will always remain at the front of the list. starting with "(" will always remain at the top of the list.

View File

@ -1,8 +1,10 @@
# Ping Pong LED Clock # Ping Pong LED Clock
This Usermod File contains a modification to use WLED in combination with the Ping Pong Ball LED Clock as built in [Instructables](https://www.instructables.com/Ping-Pong-Ball-LED-Clock/). Contains a modification to use WLED in combination with the Ping Pong Ball LED Clock as built in [Instructables](https://www.instructables.com/Ping-Pong-Ball-LED-Clock/).
## Installation ## Installation
To install this Usermod you instruct PlatformIO to compile the Projekt with the USERMOD_PING_PONG_CLOCK flag. WLED then automatically provides you with various settings in the Usermod Page to configure this Usermod. To install this Usermod, you instruct PlatformIO to compile the Project with the USERMOD_PING_PONG_CLOCK flag.
Note: If your clock is bigger or smaller then mine, you may have to update the led indices for the indivdual numbers and the base indices. WLED then automatically provides you with various settings on the Usermod Page.
Note: Depending on the size of your clock, you may have to update the led indices for the indivdual numbers and the base indices.

View File

@ -20,10 +20,10 @@ This file should be placed in the same directory as `platformio.ini`.
* `USERMOD_FOUR_LINE_DISPLAY` - define this to have this the Four Line Display mod included wled00\usermods_list.cpp * `USERMOD_FOUR_LINE_DISPLAY` - define this to have this the Four Line Display mod included wled00\usermods_list.cpp
also tells this usermod that the display is available also tells this usermod that the display is available
(see the Four Line Display usermod `readme.md` for more details) (see the Four Line Display usermod `readme.md` for more details)
* `ENCODER_DT_PIN` - The encoders DT pin, defaults to 12 * `ENCODER_DT_PIN` &nbsp;&nbsp;- defaults to 12
* `ENCODER_CLK_PIN` - The encoders CLK pin, defaults to 14 * `ENCODER_CLK_PIN` - defaults to 14
* `ENCODER_SW_PIN` - The encoders SW pin, defaults to 13 * `ENCODER_SW_PIN` &nbsp;&nbsp;- defaults to 13
* `USERMOD_ROTARY_ENCODER_GPIO` - The GPIO functionality: * `USERMOD_ROTARY_ENCODER_GPIO` - GPIO functionality:
`INPUT_PULLUP` to use internal pull-up `INPUT_PULLUP` to use internal pull-up
`INPUT` to use pull-up on the PCB `INPUT` to use pull-up on the PCB

View File

@ -4,12 +4,12 @@ Thank you to the authors of the original version of these usermods. It would not
"usermod_v2_four_line_display" "usermod_v2_four_line_display"
"usermod_v2_rotary_encoder_ui" "usermod_v2_rotary_encoder_ui"
The core of these usermods are a copy of the originals. The main changes are done to the FourLineDisplay usermod. The core of these usermods are a copy of the originals. The main changes are to the FourLineDisplay usermod.
The display usermod UI has been completely changed. The display usermod UI has been completely changed.
The changes made to the RotaryEncoder usermod were made to support the new UI in the display usermod. The changes made to the RotaryEncoder usermod were made to support the new UI in the display usermod.
Without the display it functions identical to the original. Without the display, it functions identical to the original.
The original "usermod_v2_auto_save" will not work with the display just yet. The original "usermod_v2_auto_save" will not work with the display just yet.
Press the encoder to cycle through the options: Press the encoder to cycle through the options:
@ -22,17 +22,17 @@ Press the encoder to cycle through the options:
*Saturation (only if display is used) *Saturation (only if display is used)
Press and hold the encoder to display Network Info Press and hold the encoder to display Network Info
if AP is active then it will display AP ssid and Password if AP is active, it will display the AP, SSID and Password
Also shows if the timer is enabled Also shows if the timer is enabled.
[See the pair of usermods in action](https://www.youtube.com/watch?v=ulZnBt9z3TI) [See the pair of usermods in action](https://www.youtube.com/watch?v=ulZnBt9z3TI)
## Installation ## Installation
Please refer to the original `usermod_v2_rotary_encoder_ui` readme for the main instructions Please refer to the original `usermod_v2_rotary_encoder_ui` readme for the main instructions.<br/>
Then to activate this alternative usermod add `#define USE_ALT_DISPlAY` to the `usermods_list.cpp` file, To activate this alternative usermod, add `#define USE_ALT_DISPlAY` to the `usermods_list.cpp` file,
or add `-D USE_ALT_DISPlAY` to the original `platformio_override.ini.sample` file or add `-D USE_ALT_DISPlAY` to the original `platformio_override.ini.sample` file.
### PlatformIO requirements ### PlatformIO requirements

View File

@ -750,7 +750,7 @@ public:
StaticJsonDocument<64> root; StaticJsonDocument<64> root;
char str[64]; char str[64];
sprintf_P(str, PSTR("%d~%d~%s"), presetLow, presetHigh, increase?"":"-"); sprintf_P(str, PSTR("%d~%d~%s"), presetLow, presetHigh, increase?"":"-");
root[F("ps")] = str; root["ps"] = str;
deserializeState(root.as<JsonObject>(), CALL_MODE_BUTTON_PRESET); deserializeState(root.as<JsonObject>(), CALL_MODE_BUTTON_PRESET);
/* /*
String apireq = F("win&PL=~"); String apireq = F("win&PL=~");

View File

@ -1,8 +1,8 @@
# Word Clock Usermod V2 # 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. This usermod drives an 11x10 pixel matrix wordclock with WLED. There are 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"). The index of the LEDs in the masks always starts with the index 0, even if the ledOffset is not 0. The visualisation is described by 4 masks with LED numbers (single dots for minutes, minutes, hours and "clock"). The index of the LEDs in the masks always starts at 0, even if the ledOffset is not 0.
There are 3 parameters to change the behaviour: There are 3 parameters that control behavior:
active: enable/disable usermod active: enable/disable usermod
diplayItIs: enable/disable display of "Es ist" on the clock diplayItIs: enable/disable display of "Es ist" on the clock
@ -10,23 +10,23 @@ ledOffset: number of LEDs before the wordclock LEDs
### Update for alternatative wiring pattern ### Update for alternatative wiring pattern
Based on this fantastic work I added an alternative wiring pattern. Based on this fantastic work I added an alternative wiring pattern.
For original you have to use a long wire to connect DO - DI from first line to the next line. The original used a long wire to connect DO to DI, from one line to the next line.
I wired my clock in meander style. So the first LED in second line is in the right. I wired my clock in meander style. So the first LED in the second line is on the right.
With this problem every second line was inverted and showed the wrong letter. With this method, every other line was inverted and showed the wrong letter.
I added a switch in usermod called "meander wiring?" to enable/disable alternativ wiring pattern. I added a switch in usermod called "meander wiring?" to enable/disable the alternate wiring pattern.
## Installation ## Installation
Copy and update the example `platformio_override.ini.sample` Copy and update the example `platformio_override.ini.sample`
from the Rotary Encoder UI usermode folder to the root directory of your particular build. from the Rotary Encoder UI usermod folder to the root directory of your particular build.
This file should be placed in the same directory as `platformio.ini`. This file should be placed in the same directory as `platformio.ini`.
### Define Your Options ### Define Your Options
* `USERMOD_WORDCLOCK` - define this to have this the Auto Save usermod included wled00\usermods_list.cpp * `USERMOD_WORDCLOCK` - define this to have this usermod included wled00\usermods_list.cpp
### PlatformIO requirements ### PlatformIO requirements

View File

@ -1,6 +1,6 @@
# Controlling Wiz lights # Controlling Wiz lights
This usermod allows the control of [WiZ](https://www.wizconnected.com/en/consumer/) lights that are in the same network as the WLED controller. Enabless controlling [WiZ](https://www.wizconnected.com/en/consumer/) lights that are part of the same network as the WLED controller.
The mod takes the colors from the first few pixels and sends them to the lights. The mod takes the colors from the first few pixels and sends them to the lights.
@ -8,22 +8,22 @@ The mod takes the colors from the first few pixels and sends them to the lights.
- Interval (ms) - Interval (ms)
- How frequently to update the WiZ lights, in milliseconds. - How frequently to update the WiZ lights, in milliseconds.
- Setting too low may causse ESP to become unresponsive. - Setting it too low may causse the ESP to become unresponsive.
- Send Delay (ms) - Send Delay (ms)
- An optional millisecond delay after updating each WiZ light. - An optional millisecond delay after updating each WiZ light.
- Can help smooth out effects when using a larger number of WiZ lights - Can help smooth out effects when using a large number of WiZ lights
- Use Enhanced White - Use Enhanced White
- Enables using the WiZ lights onboard white LEDs instead of sending maximum RGB values. - Uses the WiZ lights onboard white LEDs instead of sending maximum RGB values.
- Tunable with warm and cool LEDs as supported by WiZ bulbs - Tunable with warm and cool LEDs as supported by WiZ bulbs
- Note: Only sent when max RGB value is set, need to have automatic brightness limiter disabled - Note: Only sent when max RGB value is set, the automatic brightness limiter must be disabled
- ToDo: Have better logic for white value mixing to better take advantage of the lights capabilities - ToDo: Have better logic for white value mixing to take advantage of the light's capabilities
- Always Force Update - Always Force Update
- Can be enabled to always send update message to light, even when color matches what was previously sent. - Can be enabled to always send update message to light even if the new value matches the old value.
- Force update every x minutes - Force update every x minutes
- Configuration option to allow adjusting the default force update timeout of 5 minutes. - adjusts the default force update timeout of 5 minutes.
- Setting to 0 has the same impact as enabling Always Force Update - Setting to 0 is the same as enabling Always Force Update
- -
Then enter the IPs for the lights to be controlled, in order. There is currently a limit of 15 devices that can be controled, but that number Next, enter the IP addresses for the lights to be controlled, in order. The limit is 15 devices, but that number
can be easily changed by updating _MAX_WIZ_LIGHTS_. can be easily changed by updating _MAX_WIZ_LIGHTS_.
@ -31,5 +31,5 @@ can be easily changed by updating _MAX_WIZ_LIGHTS_.
## Related project ## Related project
If you use these lights and python, make sure to check out the [pywizlight](https://github.com/sbidy/pywizlight) project. I learned how to If you use these lights and python, make sure to check out the [pywizlight](https://github.com/sbidy/pywizlight) project. You can learn how to
format the messages to control the lights from that project. format the messages to control the lights from that project.

View File

@ -75,6 +75,10 @@ class WizLightsUsermod : public Usermod {
UDP.endPacket(); UDP.endPacket();
} }
// Override definition so it compiles
void setup() {
}
// TODO: Check millis() rollover // TODO: Check millis() rollover

View File

@ -2,8 +2,8 @@
By @bwente By @bwente
See https://www.hackster.io/bwente/word-clock-with-just-two-components-073834 for the hardware guide! See https://www.hackster.io/bwente/word-clock-with-just-two-components-073834 for the hardware guide!<br/>
Includes a customizable feature to lower the brightness at night. Includes a customizable feature to reduce the brightness at night.
![image](https://user-images.githubusercontent.com/371964/197094071-f8ccaf59-1d85-4dd2-8e09-1389675291e1.png) ![image](https://user-images.githubusercontent.com/371964/197094071-f8ccaf59-1d85-4dd2-8e09-1389675291e1.png)

View File

@ -24,8 +24,8 @@
Modified heavily for WLED Modified heavily for WLED
*/ */
#include "FX.h"
#include "wled.h" #include "wled.h"
#include "FX.h"
#include "fcn_declare.h" #include "fcn_declare.h"
#define IBN 5100 #define IBN 5100
@ -3483,6 +3483,7 @@ uint16_t mode_tetrix(void) {
if (SEGENV.call == 0) { if (SEGENV.call == 0) {
drop->stack = 0; // reset brick stack size drop->stack = 0; // reset brick stack size
drop->step = 0; drop->step = 0;
if (SEGMENT.check1) drop->col = 0;// use only one color from palette
//for (int i=0; i<SEGLEN; i++) SEGMENT.setPixelColor(indexToVStrip(i, stripNr), SEGCOLOR(1)); // will fill virtual strip only //for (int i=0; i<SEGLEN; i++) SEGMENT.setPixelColor(indexToVStrip(i, stripNr), SEGCOLOR(1)); // will fill virtual strip only
} }
@ -3494,7 +3495,7 @@ uint16_t mode_tetrix(void) {
speed = map(speed, 1, 255, 5000, 250); // time taken for full (SEGLEN) drop speed = map(speed, 1, 255, 5000, 250); // time taken for full (SEGLEN) drop
drop->speed = float(SEGLEN * FRAMETIME) / float(speed); // set speed drop->speed = float(SEGLEN * FRAMETIME) / float(speed); // set speed
drop->pos = SEGLEN; // start at end of segment (no need to subtract 1) drop->pos = SEGLEN; // start at end of segment (no need to subtract 1)
drop->col = random8(0,15)<<4; // limit color choices so there is enough HUE gap if (!SEGMENT.check1) drop->col = random8(0,15)<<4; // limit color choices so there is enough HUE gap
drop->step = 1; // drop state (0 init, 1 forming, 2 falling) drop->step = 1; // drop state (0 init, 1 forming, 2 falling)
drop->brick = (SEGMENT.intensity ? (SEGMENT.intensity>>5)+1 : random8(1,5)) * (1+(SEGLEN>>6)); // size of brick drop->brick = (SEGMENT.intensity ? (SEGMENT.intensity>>5)+1 : random8(1,5)) * (1+(SEGLEN>>6)); // size of brick
} }
@ -3508,7 +3509,7 @@ uint16_t mode_tetrix(void) {
if (drop->step == 2) { // falling if (drop->step == 2) { // falling
if (drop->pos > drop->stack) { // fall until top of stack if (drop->pos > drop->stack) { // fall until top of stack
drop->pos -= drop->speed; // may add gravity as: speed += gravity drop->pos -= drop->speed; // may add gravity as: speed += gravity
if (uint16_t(drop->pos) < drop->stack) drop->pos = drop->stack; if (int(drop->pos) < int(drop->stack)) drop->pos = drop->stack;
for (int i=int(drop->pos); i<SEGLEN; i++) { for (int i=int(drop->pos); i<SEGLEN; i++) {
uint32_t col = i<int(drop->pos)+drop->brick ? SEGMENT.color_from_palette(drop->col, false, false, 0) : SEGCOLOR(1); uint32_t col = i<int(drop->pos)+drop->brick ? SEGMENT.color_from_palette(drop->col, false, false, 0) : SEGCOLOR(1);
SEGMENT.setPixelColor(indexToVStrip(i, stripNr), col); SEGMENT.setPixelColor(indexToVStrip(i, stripNr), col);
@ -3528,6 +3529,7 @@ uint16_t mode_tetrix(void) {
} else { } else {
drop->stack = 0; // reset brick stack size drop->stack = 0; // reset brick stack size
drop->step = 0; // proceed with next brick drop->step = 0; // proceed with next brick
if (SEGMENT.check1) drop->col += 8; // gradually increase palette index
} }
} }
} }
@ -3538,7 +3540,7 @@ uint16_t mode_tetrix(void) {
return FRAMETIME; return FRAMETIME;
} }
static const char _data_FX_MODE_TETRIX[] PROGMEM = "Tetrix@!,Width;!,!;!;;sx=0,ix=0,pal=11,m12=1"; static const char _data_FX_MODE_TETRIX[] PROGMEM = "Tetrix@!,Width,,,,One color;!,!;!;;sx=0,ix=0,pal=11,m12=1";
/* /*

View File

@ -369,9 +369,10 @@ typedef struct Segment {
uint32_t call; // call counter uint32_t call; // call counter
uint16_t aux0; // custom var uint16_t aux0; // custom var
uint16_t aux1; // custom var uint16_t aux1; // custom var
byte* data; byte* data; // effect data pointer
CRGB* leds; CRGB* leds; // local leds[] array (may be a pointer to global)
static CRGB *_globalLeds; static CRGB *_globalLeds; // global leds[] array
static uint16_t maxWidth, maxHeight; // these define matrix width & height (max. segment dimensions)
private: private:
union { union {
@ -657,8 +658,6 @@ class WS2812FX { // 96 bytes
vPanels(1), vPanels(1),
panelH(8), panelH(8),
panelW(8), panelW(8),
matrixWidth(DEFAULT_LED_COUNT),
matrixHeight(1),
matrix{0,0,0,0}, matrix{0,0,0,0},
panel{{0,0,0,0}}, panel{{0,0,0,0}},
#endif #endif
@ -814,9 +813,7 @@ class WS2812FX { // 96 bytes
uint16_t uint16_t
panelH, panelH,
panelW, panelW;
matrixWidth,
matrixHeight;
typedef struct panel_bitfield_t { typedef struct panel_bitfield_t {
bool bottomStart : 1; // starts at bottom? bool bottomStart : 1; // starts at bottom?

View File

@ -29,8 +29,8 @@
// setUpMatrix() - constructs ledmap array from matrix of panels with WxH pixels // setUpMatrix() - constructs ledmap array from matrix of panels with WxH pixels
// this converts physical (possibly irregular) LED arrangement into well defined // this converts physical (possibly irregular) LED arrangement into well defined
// array of logical pixels: fist entry corresponds to left-topmost logical pixel // array of logical pixels: fist entry corresponds to left-topmost logical pixel
// followed by horizontal pixels, when matrixWidth logical pixels are added they // followed by horizontal pixels, when Segment::maxWidth logical pixels are added they
// are followed by next row (down) of matrixWidth pixels (and so forth) // are followed by next row (down) of Segment::maxWidth pixels (and so forth)
// note: matrix may be comprised of multiple panels each with different orientation // note: matrix may be comprised of multiple panels each with different orientation
// but ledmap takes care of that. ledmap is constructed upon initialization // but ledmap takes care of that. ledmap is constructed upon initialization
// so matrix should disable regular ledmap processing // so matrix should disable regular ledmap processing
@ -41,19 +41,20 @@ void WS2812FX::setUpMatrix() {
customMappingTable = nullptr; customMappingTable = nullptr;
customMappingSize = 0; customMappingSize = 0;
// isMatrix is set in cfg.cpp or set.cpp
if (isMatrix) { if (isMatrix) {
matrixWidth = hPanels * panelW; Segment::maxWidth = hPanels * panelW;
matrixHeight = vPanels * panelH; Segment::maxHeight = vPanels * panelH;
// safety check // safety check
if (matrixWidth * matrixHeight > MAX_LEDS) { if (Segment::maxWidth * Segment::maxHeight > MAX_LEDS || Segment::maxWidth == 1 || Segment::maxHeight == 1) {
matrixWidth = _length; Segment::maxWidth = _length;
matrixHeight = 1; Segment::maxHeight = 1;
isMatrix = false; isMatrix = false;
return; return;
} }
customMappingSize = matrixWidth * matrixHeight; customMappingSize = Segment::maxWidth * Segment::maxHeight;
customMappingTable = new uint16_t[customMappingSize]; customMappingTable = new uint16_t[customMappingSize];
if (customMappingTable != nullptr) { if (customMappingTable != nullptr) {
@ -69,7 +70,7 @@ void WS2812FX::setUpMatrix() {
x = (matrix.vertical ? matrix.bottomStart : matrix.rightStart) ? h - i - 1 : i; x = (matrix.vertical ? matrix.bottomStart : matrix.rightStart) ? h - i - 1 : i;
x = matrix.serpentine && j%2 ? h - x - 1 : x; x = matrix.serpentine && j%2 ? h - x - 1 : x;
startL = (matrix.vertical ? y : x) * panelW + (matrix.vertical ? x : y) * matrixWidth * panelH; // logical index (top-left corner) startL = (matrix.vertical ? y : x) * panelW + (matrix.vertical ? x : y) * Segment::maxWidth * panelH; // logical index (top-left corner)
startP = p * panelW * panelH; // physical index (top-left corner) startP = p * panelW * panelH; // physical index (top-left corner)
uint8_t H = panel[h*j + i].vertical ? panelW : panelH; uint8_t H = panel[h*j + i].vertical ? panelW : panelH;
@ -79,7 +80,7 @@ void WS2812FX::setUpMatrix() {
y = (panel[h*j + i].vertical ? panel[h*j + i].rightStart : panel[h*j + i].bottomStart) ? H - l - 1 : l; y = (panel[h*j + i].vertical ? panel[h*j + i].rightStart : panel[h*j + i].bottomStart) ? H - l - 1 : l;
x = (panel[h*j + i].vertical ? panel[h*j + i].bottomStart : panel[h*j + i].rightStart) ? W - k - 1 : k; x = (panel[h*j + i].vertical ? panel[h*j + i].bottomStart : panel[h*j + i].rightStart) ? W - k - 1 : k;
x = (panel[h*j + i].serpentine && l%2) ? (W - x - 1) : x; x = (panel[h*j + i].serpentine && l%2) ? (W - x - 1) : x;
offset = (panel[h*j + i].vertical ? y : x) + (panel[h*j + i].vertical ? x : y) * matrixWidth; offset = (panel[h*j + i].vertical ? y : x) + (panel[h*j + i].vertical ? x : y) * Segment::maxWidth;
customMappingTable[startL + offset] = startP + q; customMappingTable[startL + offset] = startP + q;
} }
} }
@ -88,22 +89,22 @@ void WS2812FX::setUpMatrix() {
#ifdef WLED_DEBUG #ifdef WLED_DEBUG
DEBUG_PRINT(F("Matrix ledmap:")); DEBUG_PRINT(F("Matrix ledmap:"));
for (uint16_t i=0; i<customMappingSize; i++) { for (uint16_t i=0; i<customMappingSize; i++) {
if (!(i%matrixWidth)) DEBUG_PRINTLN(); if (!(i%Segment::maxWidth)) DEBUG_PRINTLN();
DEBUG_PRINTF("%4d,", customMappingTable[i]); DEBUG_PRINTF("%4d,", customMappingTable[i]);
} }
DEBUG_PRINTLN(); DEBUG_PRINTLN();
#endif #endif
} else { } else {
// memory allocation error // memory allocation error
matrixWidth = _length; Segment::maxWidth = _length;
matrixHeight = 1; Segment::maxHeight = 1;
isMatrix = false; isMatrix = false;
return; return;
} }
} else { } else {
// not a matrix set up // not a matrix set up
matrixWidth = _length; Segment::maxWidth = _length;
matrixHeight = 1; Segment::maxHeight = 1;
} }
#endif #endif
} }
@ -113,7 +114,7 @@ void IRAM_ATTR WS2812FX::setPixelColorXY(int x, int y, uint32_t col)
{ {
#ifndef WLED_DISABLE_2D #ifndef WLED_DISABLE_2D
if (!isMatrix) return; // not a matrix set-up if (!isMatrix) return; // not a matrix set-up
uint16_t index = y * matrixWidth + x; uint16_t index = y * Segment::maxWidth + x;
if (index >= customMappingSize) return; // customMappingSize is always W * H of matrix in 2D setup if (index >= customMappingSize) return; // customMappingSize is always W * H of matrix in 2D setup
#else #else
uint16_t index = x; uint16_t index = x;
@ -126,7 +127,7 @@ void IRAM_ATTR WS2812FX::setPixelColorXY(int x, int y, uint32_t col)
// returns RGBW values of pixel // returns RGBW values of pixel
uint32_t WS2812FX::getPixelColorXY(uint16_t x, uint16_t y) { uint32_t WS2812FX::getPixelColorXY(uint16_t x, uint16_t y) {
#ifndef WLED_DISABLE_2D #ifndef WLED_DISABLE_2D
uint16_t index = (y * matrixWidth + x); uint16_t index = (y * Segment::maxWidth + x);
if (index >= customMappingSize) return 0; // customMappingSize is always W * H of matrix in 2D setup if (index >= customMappingSize) return 0; // customMappingSize is always W * H of matrix in 2D setup
#else #else
uint16_t index = x; uint16_t index = x;
@ -151,7 +152,7 @@ uint16_t IRAM_ATTR Segment::XY(uint16_t x, uint16_t y) {
void IRAM_ATTR Segment::setPixelColorXY(int x, int y, uint32_t col) void IRAM_ATTR Segment::setPixelColorXY(int x, int y, uint32_t col)
{ {
if (!strip.isMatrix) return; // not a matrix set-up if (Segment::maxHeight==1) return; // not a matrix set-up
if (x >= virtualWidth() || y >= virtualHeight() || x<0 || y<0) return; // if pixel would fall out of virtual segment just exit if (x >= virtualWidth() || y >= virtualHeight() || x<0 || y<0) return; // if pixel would fall out of virtual segment just exit
if (leds) leds[XY(x,y)] = col; if (leds) leds[XY(x,y)] = col;
@ -198,7 +199,7 @@ void IRAM_ATTR Segment::setPixelColorXY(int x, int y, uint32_t col)
// anti-aliased version of setPixelColorXY() // anti-aliased version of setPixelColorXY()
void Segment::setPixelColorXY(float x, float y, uint32_t col, bool aa) void Segment::setPixelColorXY(float x, float y, uint32_t col, bool aa)
{ {
if (!strip.isMatrix) return; // not a matrix set-up if (Segment::maxHeight==1) return; // not a matrix set-up
if (x<0.0f || x>1.0f || y<0.0f || y>1.0f) return; // not normalized if (x<0.0f || x>1.0f || y<0.0f || y>1.0f) return; // not normalized
const uint16_t cols = virtualWidth(); const uint16_t cols = virtualWidth();

View File

@ -75,6 +75,8 @@
/////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////
uint16_t Segment::_usedSegmentData = 0U; // amount of RAM all segments use for their data[] uint16_t Segment::_usedSegmentData = 0U; // amount of RAM all segments use for their data[]
CRGB *Segment::_globalLeds = nullptr; CRGB *Segment::_globalLeds = nullptr;
uint16_t Segment::maxWidth = DEFAULT_LED_COUNT;
uint16_t Segment::maxHeight = 1;
// copy constructor // copy constructor
Segment::Segment(const Segment &orig) { Segment::Segment(const Segment &orig) {
@ -192,7 +194,7 @@ void Segment::setUpLeds() {
// deallocation happens in resetIfRequired() as it is called when segment changes or in destructor // deallocation happens in resetIfRequired() as it is called when segment changes or in destructor
if (Segment::_globalLeds) if (Segment::_globalLeds)
#ifndef WLED_DISABLE_2D #ifndef WLED_DISABLE_2D
leds = &Segment::_globalLeds[start + startY*strip.matrixWidth]; // TODO: remove this hack leds = &Segment::_globalLeds[start + startY*Segment::maxWidth];
#else #else
leds = &Segment::_globalLeds[start]; leds = &Segment::_globalLeds[start];
#endif #endif
@ -497,7 +499,7 @@ void IRAM_ATTR Segment::setPixelColor(int i, uint32_t col)
if (i >= virtualLength() || i<0) return; // if pixel would fall out of segment just exit if (i >= virtualLength() || i<0) return; // if pixel would fall out of segment just exit
#ifndef WLED_DISABLE_2D #ifndef WLED_DISABLE_2D
if (is2D()) { // if this does not work use strip.isMatrix if (is2D()) {
uint16_t vH = virtualHeight(); // segment height in logical pixels uint16_t vH = virtualHeight(); // segment height in logical pixels
uint16_t vW = virtualWidth(); uint16_t vW = virtualWidth();
switch (map1D2D) { switch (map1D2D) {
@ -530,7 +532,7 @@ void IRAM_ATTR Segment::setPixelColor(int i, uint32_t col)
break; break;
} }
return; return;
} else if (strip.isMatrix && (width()==1 || height()==1)) { // TODO remove this hack } else if (Segment::maxHeight!=1 && (width()==1 || height()==1)) {
// we have a vertical or horizontal 1D segment (WARNING: virtual...() may be transposed) // we have a vertical or horizontal 1D segment (WARNING: virtual...() may be transposed)
int x = 0, y = 0; int x = 0, y = 0;
if (virtualHeight()>1) y = i; if (virtualHeight()>1) y = i;
@ -618,7 +620,7 @@ uint32_t Segment::getPixelColor(int i)
i &= 0xFFFF; i &= 0xFFFF;
#ifndef WLED_DISABLE_2D #ifndef WLED_DISABLE_2D
if (is2D()) { // if this does not work use strip.isMatrix if (is2D()) {
uint16_t vH = virtualHeight(); // segment height in logical pixels uint16_t vH = virtualHeight(); // segment height in logical pixels
uint16_t vW = virtualWidth(); uint16_t vW = virtualWidth();
switch (map1D2D) { switch (map1D2D) {
@ -1322,6 +1324,7 @@ void WS2812FX::setSegment(uint8_t n, uint16_t i1, uint16_t i2, uint8_t grouping,
// disabled segments should get removed using purgeSegments() // disabled segments should get removed using purgeSegments()
DEBUG_PRINT(F("-- Segment ")); DEBUG_PRINT(n); DEBUG_PRINTLN(F(" marked inactive.")); DEBUG_PRINT(F("-- Segment ")); DEBUG_PRINT(n); DEBUG_PRINTLN(F(" marked inactive."));
seg.stop = 0; seg.stop = 0;
seg.options = 0b0000000000000101; // on & selected
//if (seg.name) { //if (seg.name) {
// delete[] seg.name; // delete[] seg.name;
// seg.name = nullptr; // seg.name = nullptr;
@ -1333,10 +1336,10 @@ void WS2812FX::setSegment(uint8_t n, uint16_t i1, uint16_t i2, uint8_t grouping,
} }
if (isMatrix) { if (isMatrix) {
#ifndef WLED_DISABLE_2D #ifndef WLED_DISABLE_2D
if (i1 < matrixWidth) seg.start = i1; if (i1 < Segment::maxWidth) seg.start = i1;
seg.stop = i2 > matrixWidth ? matrixWidth : i2; seg.stop = i2 > Segment::maxWidth ? Segment::maxWidth : i2;
if (startY < matrixHeight) seg.startY = startY; if (startY < Segment::maxHeight) seg.startY = startY;
seg.stopY = stopY > matrixHeight ? matrixHeight : MAX(1,stopY); seg.stopY = stopY > Segment::maxHeight ? Segment::maxHeight : MAX(1,stopY);
#endif #endif
} else { } else {
if (i1 < _length) seg.start = i1; if (i1 < _length) seg.start = i1;
@ -1360,7 +1363,7 @@ void WS2812FX::restartRuntime() {
void WS2812FX::resetSegments() { void WS2812FX::resetSegments() {
_segments.clear(); // destructs all Segment as part of clearing _segments.clear(); // destructs all Segment as part of clearing
#ifndef WLED_DISABLE_2D #ifndef WLED_DISABLE_2D
segment seg = isMatrix ? Segment(0, matrixWidth, 0, matrixHeight) : Segment(0, _length); segment seg = isMatrix ? Segment(0, Segment::maxWidth, 0, Segment::maxHeight) : Segment(0, _length);
#else #else
segment seg = Segment(0, _length); segment seg = Segment(0, _length);
#endif #endif
@ -1376,9 +1379,9 @@ void WS2812FX::makeAutoSegments(bool forceReset) {
else if (getActiveSegmentsNum() == 1) { else if (getActiveSegmentsNum() == 1) {
size_t i = getLastActiveSegmentId(); size_t i = getLastActiveSegmentId();
_segments[i].start = 0; _segments[i].start = 0;
_segments[i].stop = matrixWidth; _segments[i].stop = Segment::maxWidth;
_segments[i].startY = 0; _segments[i].startY = 0;
_segments[i].stopY = matrixHeight; _segments[i].stopY = Segment::maxHeight;
_segments[i].grouping = 1; _segments[i].grouping = 1;
_segments[i].spacing = 0; _segments[i].spacing = 0;
_mainSegment = i; _mainSegment = i;

View File

@ -104,7 +104,7 @@ bool deserializeConfig(JsonObject doc, bool fromFS) {
CJSON(strip.matrix.bottomStart, matrix[F("pb")]); CJSON(strip.matrix.bottomStart, matrix[F("pb")]);
CJSON(strip.matrix.rightStart, matrix[F("pr")]); CJSON(strip.matrix.rightStart, matrix[F("pr")]);
CJSON(strip.matrix.vertical, matrix[F("pv")]); CJSON(strip.matrix.vertical, matrix[F("pv")]);
CJSON(strip.matrix.serpentine, matrix[F("ps")]); CJSON(strip.matrix.serpentine, matrix["ps"]);
JsonArray panels = matrix[F("panels")]; JsonArray panels = matrix[F("panels")];
uint8_t s = 0; uint8_t s = 0;
@ -203,6 +203,18 @@ bool deserializeConfig(JsonObject doc, bool fromFS) {
int8_t pin = btn["pin"][0] | -1; int8_t pin = btn["pin"][0] | -1;
if (pin > -1 && pinManager.allocatePin(pin, false, PinOwner::Button)) { if (pin > -1 && pinManager.allocatePin(pin, false, PinOwner::Button)) {
btnPin[s] = pin; btnPin[s] = pin;
#ifdef ARDUINO_ARCH_ESP32
// ESP32 only: check that analog button pin is a valid ADC gpio
if (((buttonType[s] == BTN_TYPE_ANALOG) || (buttonType[s] == BTN_TYPE_ANALOG_INVERTED)) && (digitalPinToAnalogChannel(btnPin[s]) < 0))
{
// not an ADC analog pin
DEBUG_PRINTF("PIN ALLOC error: GPIO%d for analog button #%d is not an analog pin!\n", btnPin[s], s);
btnPin[s] = -1;
pinManager.deallocatePin(pin,PinOwner::Button);
}
else
#endif
{
if (disablePullUp) { if (disablePullUp) {
pinMode(btnPin[s], INPUT); pinMode(btnPin[s], INPUT);
} else { } else {
@ -212,6 +224,7 @@ bool deserializeConfig(JsonObject doc, bool fromFS) {
pinMode(btnPin[s], INPUT_PULLUP); pinMode(btnPin[s], INPUT_PULLUP);
#endif #endif
} }
}
} else { } else {
btnPin[s] = -1; btnPin[s] = -1;
} }
@ -698,7 +711,7 @@ void serializeConfig() {
matrix[F("pb")] = strip.matrix.bottomStart; matrix[F("pb")] = strip.matrix.bottomStart;
matrix[F("pr")] = strip.matrix.rightStart; matrix[F("pr")] = strip.matrix.rightStart;
matrix[F("pv")] = strip.matrix.vertical; matrix[F("pv")] = strip.matrix.vertical;
matrix[F("ps")] = strip.matrix.serpentine; matrix["ps"] = strip.matrix.serpentine;
JsonArray panels = matrix.createNestedArray(F("panels")); JsonArray panels = matrix.createNestedArray(F("panels"));
for (uint8_t i=0; i<strip.hPanels*strip.vPanels; i++) { for (uint8_t i=0; i<strip.hPanels*strip.vPanels; i++) {

View File

@ -97,7 +97,10 @@
#define USERMOD_ID_ANALOG_CLOCK 33 //Usermod "Analog_Clock.h" #define USERMOD_ID_ANALOG_CLOCK 33 //Usermod "Analog_Clock.h"
#define USERMOD_ID_PING_PONG_CLOCK 34 //Usermod "usermod_v2_ping_pong_clock.h" #define USERMOD_ID_PING_PONG_CLOCK 34 //Usermod "usermod_v2_ping_pong_clock.h"
#define USERMOD_ID_ADS1115 35 //Usermod "usermod_ads1115.h" #define USERMOD_ID_ADS1115 35 //Usermod "usermod_ads1115.h"
#define USERMOD_ID_BOBLIGHT 36 //Usermod "boblight.h"
#define USERMOD_ID_SD_CARD 37 //Usermod "usermod_sd_card.h" #define USERMOD_ID_SD_CARD 37 //Usermod "usermod_sd_card.h"
#define USERMOD_ID_PWM_OUTPUTS 38 //Usermod "usermod_pwm_outputs.h
#define USERMOD_ID_SHT 39 //Usermod "usermod_sht.h
//Access point behavior //Access point behavior
#define AP_BEHAVIOR_BOOT_NO_CONN 0 //Open AP when no connection after boot #define AP_BEHAVIOR_BOOT_NO_CONN 0 //Open AP when no connection after boot
@ -394,12 +397,22 @@
#define INTERFACE_UPDATE_COOLDOWN 2000 //time in ms to wait between websockets, alexa, and MQTT updates #define INTERFACE_UPDATE_COOLDOWN 2000 //time in ms to wait between websockets, alexa, and MQTT updates
// HW_PIN_SCL & HW_PIN_SDA are used for information in usermods settings page and usermods themselves
// which GPIO pins are actually used in a hardwarea layout (controller board)
#if defined(I2CSCLPIN) && !defined(HW_PIN_SCL)
#define HW_PIN_SCL I2CSCLPIN
#endif
#if defined(I2CSDAPIN) && !defined(HW_PIN_SDA)
#define HW_PIN_SDA I2CSDAPIN
#endif
// you cannot change HW I2C pins on 8266
#if defined(ESP8266) && defined(HW_PIN_SCL) #if defined(ESP8266) && defined(HW_PIN_SCL)
#undef HW_PIN_SCL #undef HW_PIN_SCL
#endif #endif
#if defined(ESP8266) && defined(HW_PIN_SDA) #if defined(ESP8266) && defined(HW_PIN_SDA)
#undef HW_PIN_SDA #undef HW_PIN_SDA
#endif #endif
// defaults for 1st I2C on ESP32 (Wire global)
#ifndef HW_PIN_SCL #ifndef HW_PIN_SCL
#define HW_PIN_SCL SCL #define HW_PIN_SCL SCL
#endif #endif
@ -407,6 +420,18 @@
#define HW_PIN_SDA SDA #define HW_PIN_SDA SDA
#endif #endif
// HW_PIN_SCLKSPI & HW_PIN_MOSISPI & HW_PIN_MISOSPI are used for information in usermods settings page and usermods themselves
// which GPIO pins are actually used in a hardwarea layout (controller board)
#if defined(SPISCLKPIN) && !defined(HW_PIN_CLOCKSPI)
#define HW_PIN_CLOCKSPI SPISCLKPIN
#endif
#if defined(SPIMOSIPIN) && !defined(HW_PIN_MOSISPI)
#define HW_PIN_MOSISPI SPIMOSIPIN
#endif
#if defined(SPIMISOPIN) && !defined(HW_PIN_MISOSPI)
#define HW_PIN_MISOSPI SPIMISOPIN
#endif
// you cannot change HW SPI pins on 8266
#if defined(ESP8266) && defined(HW_PIN_CLOCKSPI) #if defined(ESP8266) && defined(HW_PIN_CLOCKSPI)
#undef HW_PIN_CLOCKSPI #undef HW_PIN_CLOCKSPI
#endif #endif
@ -416,10 +441,7 @@
#if defined(ESP8266) && defined(HW_PIN_MISOSPI) #if defined(ESP8266) && defined(HW_PIN_MISOSPI)
#undef HW_PIN_MISOSPI #undef HW_PIN_MISOSPI
#endif #endif
#if defined(ESP8266) && defined(HW_PIN_CSSPI) // defaults for VSPI on ESP32 (SPI global, SPI.cpp) as HSPI is used by WLED (bus_wrapper.h)
#undef HW_PIN_CSSPI
#endif
// defaults for VSPI
#ifndef HW_PIN_CLOCKSPI #ifndef HW_PIN_CLOCKSPI
#define HW_PIN_CLOCKSPI SCK #define HW_PIN_CLOCKSPI SCK
#endif #endif
@ -429,8 +451,5 @@
#ifndef HW_PIN_MISOSPI #ifndef HW_PIN_MISOSPI
#define HW_PIN_MISOSPI MISO #define HW_PIN_MISOSPI MISO
#endif #endif
#ifndef HW_PIN_CSSPI
#define HW_PIN_CSSPI SS
#endif
#endif #endif

View File

@ -128,12 +128,13 @@ button {
display: inline-block; display: inline-block;
} }
.icons.on { .on {
color: var(--c-g); color: var(--c-g) !important;
} }
.icons.off { .off {
color: var(--c-6); color: var(--c-6) !important;
cursor: default !important;
} }
.top .icons, .bot .icons { .top .icons, .bot .icons {
@ -981,7 +982,7 @@ textarea {
.segname, .pname { .segname, .pname {
white-space: nowrap; white-space: nowrap;
cursor: pointer; /*cursor: pointer;*/
text-align: center; text-align: center;
overflow: clip; overflow: clip;
text-overflow: ellipsis; text-overflow: ellipsis;

View File

@ -286,15 +286,15 @@
</div> </div>
<div id="fxopt" class="option fade"> <div id="fxopt" class="option fade">
<label id="opt0" class="check ochkl hide"><i class="icons">&#xe2b3;</i><span class="tooltiptext" id="optLabel0">Check 1</span> <label id="opt0" class="check ochkl hide"><i class="icons">&#xe2b3;</i><span class="tooltiptext" id="optLabel0">Check 1</span>
<input type="checkbox" onchange="setOption(1, this.checked)"> <input id="checkO1" type="checkbox" onchange="setOption(1, this.checked)">
<span class="checkmark"></span> <span class="checkmark"></span>
</label> </label>
<label id="opt1" class="check ochkl hide"><i class="icons">&#xe34b;</i><span class="tooltiptext" id="optLabel1">Check 2</span> <label id="opt1" class="check ochkl hide"><i class="icons">&#xe34b;</i><span class="tooltiptext" id="optLabel1">Check 2</span>
<input type="checkbox" onchange="setOption(2, this.checked)"> <input id="checkO2" type="checkbox" onchange="setOption(2, this.checked)">
<span class="checkmark"></span> <span class="checkmark"></span>
</label> </label>
<label id="opt2" class="check ochkl hide"><i class="icons">&#xe04c;</i><span class="tooltiptext" id="optLabel2">Check 3</span> <label id="opt2" class="check ochkl hide"><i class="icons">&#xe04c;</i><span class="tooltiptext" id="optLabel2">Check 3</span>
<input type="checkbox" onchange="setOption(3, this.checked)"> <input id="checkO3" type="checkbox" onchange="setOption(3, this.checked)">
<span class="checkmark"></span> <span class="checkmark"></span>
</label> </label>
</div> </div>

View File

@ -1,6 +1,5 @@
//page js //page js
var loc = false, locip; var loc = false, locip;
var noNewSegs = false;
var isOn = false, nlA = false, isLv = false, isInfo = false, isNodes = false, syncSend = false, syncTglRecv = true; var isOn = false, nlA = false, isLv = false, isInfo = false, isNodes = false, syncSend = false, syncTglRecv = true;
var hasWhite = false, hasRGB = false, hasCCT = false; var hasWhite = false, hasRGB = false, hasCCT = false;
var nlDur = 60, nlTar = 0; var nlDur = 60, nlTar = 0;
@ -17,6 +16,7 @@ var d = document;
var palettesData; var palettesData;
var fxdata = []; var fxdata = [];
var pJson = {}, eJson = {}, lJson = {}; var pJson = {}, eJson = {}, lJson = {};
var plJson = {}; // array of playlists
var pN = "", pI = 0, pNum = 0; var pN = "", pI = 0, pNum = 0;
var pmt = 1, pmtLS = 0, pmtLast = 0; var pmt = 1, pmtLS = 0, pmtLast = 0;
var lastinfo = {}; var lastinfo = {};
@ -794,18 +794,14 @@ function populateSegments(s)
} }
gId('segcont').innerHTML = cn; gId('segcont').innerHTML = cn;
if (lowestUnused >= maxSeg) { let noNewSegs = (lowestUnused >= maxSeg);
gId('segutil').innerHTML = '<span class="h">Maximum number of segments reached.</span>'; resetUtil(noNewSegs);
noNewSegs = true; if (gId('selall')) gId('selall').checked = true;
} else if (noNewSegs) {
resetUtil();
noNewSegs = false;
}
for (var i = 0; i <= lSeg; i++) { for (var i = 0; i <= lSeg; i++) {
updateLen(i); updateLen(i);
updateTrail(gId(`seg${i}bri`)); updateTrail(gId(`seg${i}bri`));
gId(`segr${i}`).style.display = "none"; gId(`segr${i}`).style.display = "none";
if (!gId(`seg${i}sel`).checked) gId(`selall`).checked = false; if (!gId(`seg${i}sel`).checked && gId('selall')) gId('selall').checked = false; // uncheck if at least one is unselected.
} }
if (segCount < 2) gId(`segd${lSeg}`).style.display = "none"; if (segCount < 2) gId(`segd${lSeg}`).style.display = "none";
if (!isM && !noNewSegs && (cfg.comp.seglen?parseInt(gId(`seg${lSeg}s`).value):0)+parseInt(gId(`seg${lSeg}e`).value)<ledCount) gId(`segr${lSeg}`).style.display = "inline"; if (!isM && !noNewSegs && (cfg.comp.seglen?parseInt(gId(`seg${lSeg}s`).value):0)+parseInt(gId(`seg${lSeg}e`).value)<ledCount) gId(`segr${lSeg}`).style.display = "inline";
@ -1323,6 +1319,9 @@ function readState(s,command=false)
gId('sliderC1').value = i.c1 ? i.c1 : 0; gId('sliderC1').value = i.c1 ? i.c1 : 0;
gId('sliderC2').value = i.c2 ? i.c2 : 0; gId('sliderC2').value = i.c2 ? i.c2 : 0;
gId('sliderC3').value = i.c3 ? i.c3 : 0; gId('sliderC3').value = i.c3 ? i.c3 : 0;
gId('checkO1').checked = !(!i.o1);
gId('checkO2').checked = !(!i.o2);
gId('checkO3').checked = !(!i.o3);
if (s.error && s.error != 0) { if (s.error && s.error != 0) {
var errstr = ""; var errstr = "";
@ -1690,24 +1689,15 @@ function makeSeg()
gId('segutil').innerHTML = cn; gId('segutil').innerHTML = cn;
} }
function resetUtil() function resetUtil(off=false)
{ {
// gId('segutil').innerHTML = '<button class="btn btn-s" onclick="makeSeg()"><i class="icons btn-icon">&#xe18a;</i>segment</button>'; gId('segutil').innerHTML = `<div class="seg btn btn-s ${off?'off':''}" style="border-radius:24px;padding:0;">`
gId('segutil').innerHTML = '<div class="seg btn btn-s" style="border-radius:24px;padding:0;">'
+ '<label class="check schkl"><input type="checkbox" id="selall" onchange="selSegAll(this)"><span class="checkmark"></span></label>' + '<label class="check schkl"><input type="checkbox" id="selall" onchange="selSegAll(this)"><span class="checkmark"></span></label>'
+ '<div class="segname" onclick="makeSeg()"><i class="icons btn-icon">&#xe18a;</i>Add segment</div></div>'; + `<div class="segname" ${off?'':'onclick="makeSeg()"'}><i class="icons btn-icon">&#xe18a;</i>Add segment</div></div>`;
} }
var plJson = {"0":{ function makePlSel(el, incPl=false)
"ps": [0], {
"dur": [100],
"transition": [-1], // to be inited to default transition dur
"repeat": 0,
"r": false,
"end": 0
}};
function makePlSel(el, incPl=false) {
var plSelContent = ""; var plSelContent = "";
delete pJson["0"]; // remove filler preset delete pJson["0"]; // remove filler preset
var arr = Object.entries(pJson); var arr = Object.entries(pJson);
@ -1719,7 +1709,8 @@ function makePlSel(el, incPl=false) {
return plSelContent; return plSelContent;
} }
function refreshPlE(p) { function refreshPlE(p)
{
var plEDiv = gId(`ple${p}`); var plEDiv = gId(`ple${p}`);
if (!plEDiv) return; if (!plEDiv) return;
var content = "<div class=\"first c\">Playlist entries</div>"; var content = "<div class=\"first c\">Playlist entries</div>";
@ -1741,14 +1732,16 @@ function refreshPlE(p) {
} }
// p: preset ID, i: ps index // p: preset ID, i: ps index
function addPl(p,i) { function addPl(p,i)
{
plJson[p].ps.splice(i+1,0,0); plJson[p].ps.splice(i+1,0,0);
plJson[p].dur.splice(i+1,0,plJson[p].dur[i]); plJson[p].dur.splice(i+1,0,plJson[p].dur[i]);
plJson[p].transition.splice(i+1,0,plJson[p].transition[i]); plJson[p].transition.splice(i+1,0,plJson[p].transition[i]);
refreshPlE(p); refreshPlE(p);
} }
function delPl(p,i) { function delPl(p,i)
{
if (plJson[p].ps.length < 2) return; if (plJson[p].ps.length < 2) return;
plJson[p].ps.splice(i,1); plJson[p].ps.splice(i,1);
plJson[p].dur.splice(i,1); plJson[p].dur.splice(i,1);
@ -1756,21 +1749,25 @@ function delPl(p,i) {
refreshPlE(p); refreshPlE(p);
} }
function plePs(p,i,field) { function plePs(p,i,field)
{
plJson[p].ps[i] = parseInt(field.value); plJson[p].ps[i] = parseInt(field.value);
} }
function pleDur(p,i,field) { function pleDur(p,i,field)
{
if (field.validity.valid) if (field.validity.valid)
plJson[p].dur[i] = Math.floor(field.value*10); plJson[p].dur[i] = Math.floor(field.value*10);
} }
function pleTr(p,i,field) { function pleTr(p,i,field)
{
if (field.validity.valid) if (field.validity.valid)
plJson[p].transition[i] = Math.floor(field.value*10); plJson[p].transition[i] = Math.floor(field.value*10);
} }
function plR(p) { function plR(p)
{
var pl = plJson[p]; var pl = plJson[p];
pl.r = gId(`pl${p}rtgl`).checked; pl.r = gId(`pl${p}rtgl`).checked;
if (gId(`pl${p}rptgl`).checked) { // infinite if (gId(`pl${p}rptgl`).checked) { // infinite
@ -1784,9 +1781,18 @@ function plR(p) {
} }
} }
function makeP(i,pl) { function makeP(i,pl)
{
var content = ""; var content = "";
if (pl) { if (pl) {
if (i===0) plJson[0] = {
ps: [1],
dur: [100],
transition: [tr],
repeat: 0,
r: false,
end: 0
};
var rep = plJson[i].repeat ? plJson[i].repeat : 0; var rep = plJson[i].repeat ? plJson[i].repeat : 0;
content = content =
`<div id="ple${i}" style="margin-top:10px;"></div><label class="check revchkl">Shuffle `<div id="ple${i}" style="margin-top:10px;"></div><label class="check revchkl">Shuffle
@ -1909,7 +1915,6 @@ function makePlUtil()
if (pNum < 2) { if (pNum < 2) {
showToast("You need at least 2 presets to make a playlist!"); //return; showToast("You need at least 2 presets to make a playlist!"); //return;
} }
if (plJson[0].transition[0] < 0) plJson[0].transition[0] = tr;
let p = gId('putil'); let p = gId('putil');
p.classList.remove('staybot'); p.classList.remove('staybot');
p.classList.add('pres'); p.classList.add('pres');
@ -1961,7 +1966,7 @@ function selSegAll(o)
function selSegEx(s) function selSegEx(s)
{ {
gId(`selall`).checked = false; if (gId('selall')) gId('selall').checked = false;
var obj = {"seg":[]}; var obj = {"seg":[]};
for (let i=0; i<=lSeg; i++) obj.seg.push({"id":i,"sel":(i==s)}); for (let i=0; i<=lSeg; i++) obj.seg.push({"id":i,"sel":(i==s)});
obj.mainseg = s; obj.mainseg = s;
@ -1970,7 +1975,7 @@ function selSegEx(s)
function selSeg(s) function selSeg(s)
{ {
gId(`selall`).checked = false; if (gId('selall')) gId('selall').checked = false;
var sel = gId(`seg${s}sel`).checked; var sel = gId(`seg${s}sel`).checked;
var obj = {"seg": {"id": s, "sel": sel}}; var obj = {"seg": {"id": s, "sel": sel}};
requestJson(obj); requestJson(obj);
@ -2018,7 +2023,7 @@ function setSeg(s)
var startY = parseInt(sY.value); var startY = parseInt(sY.value);
var stopY = parseInt(eY.value); var stopY = parseInt(eY.value);
if (startY<sY.min || startY>sY.max) {sY.value=sY.min; return;} // prevent out of bounds if (startY<sY.min || startY>sY.max) {sY.value=sY.min; return;} // prevent out of bounds
if (stopY<eY.min || stop>eY.max) {eY.value=eY.max; return;} // prevent out of bounds if (stopY<eY.min || stopY>eY.max) {eY.value=eY.max; return;} // prevent out of bounds
obj.seg.startY = startY; obj.seg.startY = startY;
obj.seg.stopY = (cfg.comp.seglen?startY:0)+stopY; obj.seg.stopY = (cfg.comp.seglen?startY:0)+stopY;
} }
@ -2192,9 +2197,9 @@ function setPreset(i)
{ {
var obj = {"ps":i}; var obj = {"ps":i};
if (pJson && pJson[i] && (!pJson[i].win || pJson[i].win.indexOf("Please") <= 0)) { if (pJson && pJson[i] && (!pJson[i].win || pJson[i].win.indexOf("Please") <= 0)) {
// we will send complete preset content as to avoid delay introduced by // we will send the complete preset content as to avoid delay introduced by
// async nature of applyPreset(). json.cpp has to decide wether to call applyPreset() // async nature of applyPreset() and having to read the preset from file system.
// or not (by looking at the JSON content, if "ps" only) obj = {"pd":i}; // use "pd" instead of "ps" to indicate that we are sending the preset content directly
Object.assign(obj, pJson[i]); Object.assign(obj, pJson[i]);
delete obj.ql; // no need for quick load delete obj.ql; // no need for quick load
delete obj.n; // no need for name delete obj.n; // no need for name

View File

@ -43,6 +43,7 @@
} }
}; };
function gId(s) { return d.getElementById(s); } function gId(s) { return d.getElementById(s); }
function toggle(el) { gId(el).classList.toggle("hide"); gId('No'+el).classList.toggle("hide"); }
function isObject(item) { function isObject(item) {
return (item && typeof item === 'object' && !Array.isArray(item)); return (item && typeof item === 'object' && !Array.isArray(item));
} }
@ -247,7 +248,10 @@
<h2>Web Setup</h2> <h2>Web Setup</h2>
Server description: <input type="text" name="DS" maxlength="32"><br> Server description: <input type="text" name="DS" maxlength="32"><br>
Sync button toggles both send and receive: <input type="checkbox" name="ST"><br> Sync button toggles both send and receive: <input type="checkbox" name="ST"><br>
Enable simplified UI: <input type="checkbox" name="SU"><br> <div id="NoSimple" class="hide">
<em style="color:#fa0;">This firmware build does not include simplified UI support.<br></em>
</div>
<div id="Simple">Enable simplified UI: <input type="checkbox" name="SU"><br></div>
<i>The following UI customization settings are unique both to the WLED device and this browser.<br> <i>The following UI customization settings are unique both to the WLED device and this browser.<br>
You will need to set them again if using a different browser, device or WLED IP address.<br> You will need to set them again if using a different browser, device or WLED IP address.<br>
Refresh the main UI to apply changes.</i><br> Refresh the main UI to apply changes.</i><br>

View File

@ -105,8 +105,9 @@
} }
} }
function initCap(s) { function initCap(s) {
if (typeof s !== 'string') return '' if (typeof s !== 'string') return '';
return s.charAt(0).toUpperCase() + s.slice(1) // https://www.freecodecamp.org/news/how-to-capitalize-words-in-javascript/
return s.replace(/[\W_]/g,' ').replace(/(^\w{1})|(\s+\w{1})/g, l=>l.toUpperCase()); // replace - and _ with space, capitalize every 1st letter
} }
function addField(k,f,o,a=false) { //key, field, (sub)object, isArray function addField(k,f,o,a=false) { //key, field, (sub)object, isArray
if (isO(o)) { if (isO(o)) {

View File

@ -848,202 +848,207 @@ const uint8_t PAGE_settings_dmx[] PROGMEM = {
// Autogenerated from wled00/data/settings_ui.htm, do not edit!! // Autogenerated from wled00/data/settings_ui.htm, do not edit!!
const uint16_t PAGE_settings_ui_length = 3090; const uint16_t PAGE_settings_ui_length = 3181;
const uint8_t PAGE_settings_ui[] PROGMEM = { const uint8_t PAGE_settings_ui[] PROGMEM = {
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x13, 0xad, 0x59, 0x6b, 0x73, 0xda, 0x48, 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x13, 0xad, 0x59, 0x6d, 0x77, 0xda, 0x38,
0x16, 0xfd, 0xce, 0xaf, 0xe8, 0x74, 0x52, 0x1e, 0x54, 0x56, 0x04, 0x4e, 0x66, 0x6b, 0x13, 0x40, 0x16, 0xfe, 0xce, 0xaf, 0x50, 0xd5, 0x39, 0x19, 0x38, 0x71, 0x81, 0xb4, 0xb3, 0x67, 0x5b, 0xc0,
0x78, 0x63, 0xc7, 0x93, 0x78, 0xca, 0xd9, 0x64, 0x83, 0xbd, 0x99, 0xad, 0xac, 0xcb, 0x23, 0xa4, 0x64, 0x9b, 0x34, 0xd3, 0x66, 0x4e, 0x3a, 0xed, 0x96, 0x74, 0x3b, 0x73, 0xba, 0x3d, 0x19, 0x63,
0x06, 0x3a, 0x16, 0x92, 0x46, 0xdd, 0x32, 0x66, 0x09, 0xff, 0x7d, 0xcf, 0xed, 0x96, 0x40, 0x60, 0x0b, 0x50, 0x63, 0x5b, 0x1e, 0x4b, 0x0e, 0xc9, 0x52, 0xfe, 0xfb, 0x3e, 0x57, 0xb2, 0xc1, 0x90,
0x1b, 0x67, 0xa7, 0xf6, 0x8b, 0x0d, 0xfd, 0xb8, 0xef, 0x3e, 0xf7, 0x74, 0xd3, 0x7b, 0xf2, 0xf6, 0x84, 0x74, 0xe7, 0xec, 0x97, 0x04, 0xf4, 0x72, 0x5f, 0x1f, 0x3d, 0xf7, 0x4a, 0x0c, 0x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, 0x37, 0x1f, 0xd2, 0xff, 0xd5, 0x9e, 0x86, 0xed, 0xe6, 0x75, 0x16, 0xa4, 0xd6, 0x61, 0xd7,
0xdb, 0x3f, 0x77, 0xd9, 0x19, 0xc1, 0x2a, 0xb0, 0x86, 0x55, 0x50, 0x44, 0x94, 0x46, 0x44, 0x4f, 0xfd, 0x30, 0x1b, 0x22, 0x5c, 0x41, 0xec, 0x83, 0xc4, 0x34, 0x17, 0x22, 0xed, 0x97, 0x74, 0xd1,
0x10, 0x67, 0x08, 0xed, 0xb3, 0xba, 0x6c, 0xe2, 0x44, 0xac, 0xb1, 0x21, 0x1c, 0x04, 0xe3, 0xae, 0xb3, 0x94, 0x30, 0x6c, 0xec, 0x3d, 0x3e, 0xe8, 0x76, 0xbb, 0x3f, 0xf5, 0xd9, 0x19, 0xd1, 0x2a,
0x68, 0x4b, 0x94, 0x8e, 0xd3, 0x22, 0x8e, 0x58, 0x92, 0x6a, 0x16, 0x84, 0xa1, 0x50, 0x8a, 0x19, 0xb8, 0x86, 0x55, 0x54, 0x44, 0x2d, 0x8d, 0x88, 0x1e, 0x21, 0xce, 0x10, 0x3a, 0x64, 0x75, 0xd9,
0x04, 0xa7, 0x37, 0x1d, 0x03, 0xe1, 0xec, 0x43, 0x70, 0x2d, 0x98, 0x02, 0x8a, 0x32, 0x09, 0x2a, 0xd4, 0x13, 0xb1, 0xc6, 0x86, 0x70, 0x34, 0x18, 0xb7, 0x45, 0xbb, 0x46, 0xe9, 0x58, 0x15, 0x71,
0xa0, 0x80, 0xf8, 0xf4, 0xe2, 0x12, 0xd1, 0x75, 0x17, 0x38, 0x97, 0xb3, 0x21, 0xd2, 0x01, 0x95, 0xc4, 0x52, 0x65, 0x58, 0x10, 0x86, 0x42, 0x6b, 0x66, 0x19, 0x9c, 0xde, 0x8a, 0x2c, 0x85, 0xb3,
0x5e, 0xa3, 0x34, 0xa5, 0x37, 0xc9, 0xab, 0xd0, 0x4e, 0x5e, 0xf4, 0xbf, 0x88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3, 0xdb, 0x07, 0x5d, 0x45,
0xe8, 0xa7, 0xf3, 0xff, 0x02, 0x06, 0x8f, 0xcc, 0x7b, 0x50, 0x1f, 0x00, 0x00
}; };
@ -1635,179 +1640,180 @@ const uint8_t PAGE_settings_sec[] PROGMEM = {
// Autogenerated from wled00/data/settings_um.htm, do not edit!! // Autogenerated from wled00/data/settings_um.htm, do not edit!!
const uint16_t PAGE_settings_um_length = 2728; const uint16_t PAGE_settings_um_length = 2748;
const uint8_t PAGE_settings_um[] PROGMEM = { const uint8_t PAGE_settings_um[] PROGMEM = {
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x13, 0xcd, 0x59, 0xfb, 0x6f, 0xdb, 0x38, 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x13, 0xcd, 0x59, 0x6d, 0x6f, 0xdb, 0x38,
0x12, 0xfe, 0x3d, 0x7f, 0x85, 0xc2, 0x06, 0x89, 0x04, 0x2b, 0xb2, 0xd3, 0xee, 0x02, 0x5d, 0xdb, 0x12, 0xfe, 0x9e, 0x5f, 0xa1, 0xb0, 0x41, 0x22, 0xc1, 0x8a, 0xec, 0xb4, 0xbb, 0x40, 0xd7, 0xb6,
0x54, 0xae, 0x4d, 0xbb, 0x5b, 0x5f, 0x1f, 0x09, 0x90, 0x7d, 0xe0, 0x90, 0x0b, 0x1a, 0xd9, 0xa2, 0x94, 0x6b, 0xd3, 0xee, 0xd6, 0xd7, 0x97, 0x04, 0x48, 0xbb, 0x8b, 0x43, 0x9a, 0x6b, 0x64, 0x89,
0x6d, 0x36, 0x32, 0xa9, 0x93, 0xa8, 0x3c, 0xce, 0xf1, 0xff, 0x7e, 0xdf, 0x50, 0x0f, 0xcb, 0xa9, 0xb6, 0xd9, 0xc8, 0xa4, 0x4e, 0xa4, 0xf2, 0x72, 0x8e, 0xff, 0xfb, 0x3d, 0x43, 0x49, 0xb6, 0x9c,
0x53, 0xec, 0x16,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1, 0xfd, 0xc0, 0x47, 0x76, 0x5f, 0x2b, 0x44, 0xa3, 0x4a, 0x6d,
0x74, 0xe8, 0x06, 0xe2, 0x2f, 0x1a, 0xd8, 0x5e, 0x5a, 0x7c, 0x8f, 0x85, 0x2d, 0xa3, 0x75, 0xe9, 0xe7, 0xd3, 0x93, 0xd1, 0xdf, 0x6f, 0x5c, 0xba, 0x49, 0xf8, 0x8b, 0xd6, 0xb5, 0x97, 0x0f, 0x3f,
0xfb, 0xfe, 0xce, 0x9f, 0xdc, 0xb3, 0xf1, 0xe9, 0xfb, 0xef, 0x8c, 0x22, 0xe2, 0x2c, 0x91, 0x8b, 0x64, 0x5e, 0xcb, 0x19, 0x39, 0x74, 0x4f, 0xf1, 0x17, 0x0d, 0x6c, 0xaf, 0x36, 0x7e, 0xc4, 0xc2,
0x52, 0x15, 0x55, 0x22, 0xac, 0x2f, 0x2b, 0x6b, 0xe8, 0x0f, 0x82, 0xa0, 0x4e, 0xb5, 0xec, 0xef, 0x96, 0xd1, 0xba, 0xf4, 0x6d, 0x7f, 0xeb, 0x4f, 0xee, 0xb9, 0xf2, 0xe9, 0xdb, 0x1f, 0x8c, 0x22,
0xc1, 0x21, 0x60, 0x06, 0x21, 0x2e, 0x32, 0x9a, 0x50, 0x99, 0x20, 0x9a, 0xfe, 0xff, 0xf2, 0x3f, 0xe2, 0xac, 0x90, 0x8b, 0x52, 0x15, 0x55, 0x22, 0x6a, 0xae, 0x34, 0x1b, 0xe8, 0x0f, 0x82, 0xa0,
0x66, 0x3b, 0x04, 0x72, 0x95, 0x19, 0x00, 0x00 0x49, 0xb5, 0xe2, 0xef, 0xc1, 0x21, 0x60, 0x06, 0x21, 0x2e, 0x32, 0x9a, 0x50, 0x99, 0x20, 0x9a,
0xfe, 0x4b, 0xf3, 0x3f, 0x9a, 0x36, 0x30, 0x0b, 0xbb, 0x19, 0x00, 0x00
}; };

File diff suppressed because it is too large Load Diff

View File

@ -394,30 +394,24 @@ bool deserializeState(JsonObject root, byte callMode, byte presetId)
handleSet(nullptr, apireq, false); // may set stateChanged handleSet(nullptr, apireq, false); // may set stateChanged
} }
// applying preset (2 cases: a) API call includes all preset values, b) API only specifies preset ID) // applying preset (2 cases: a) API call includes all preset values ("pd"), b) API only specifies preset ID ("ps"))
if (!root["ps"].isNull()) { byte presetToRestore = 0;
ps = presetCycCurr;
if (stateChanged) {
// a) already applied preset content (requires "seg" or "win" but will ignore the rest) // a) already applied preset content (requires "seg" or "win" but will ignore the rest)
currentPreset = root["ps"] | currentPreset; if (!root["pd"].isNull() && stateChanged) {
// if preset contains HTTP API call do not change presetCycCurr currentPreset = root[F("pd")] | currentPreset;
if (root["win"].isNull()) presetCycCurr = currentPreset; if (root["win"].isNull()) presetCycCurr = currentPreset;
stateChanged = false; // cancel state change update (preset was set directly by applying values stored in UI JSON array) presetToRestore = currentPreset; // stateUpdated() will clear the preset, so we need to restore it after
} else if (root["win"].isNull() && getVal(root["ps"], &ps, 0, 0) && ps > 0 && ps < 251 && ps != currentPreset) { //unloadPlaylist(); // applying a preset unloads the playlist, may be needed here too?
} else if (!root["ps"].isNull()) {
ps = presetCycCurr;
if (root["win"].isNull() && getVal(root["ps"], &ps, 0, 0) && ps > 0 && ps < 251 && ps != currentPreset) {
// b) preset ID only or preset that does not change state (use embedded cycling limits if they exist in getVal()) // b) preset ID only or preset that does not change state (use embedded cycling limits if they exist in getVal())
presetCycCurr = ps; presetCycCurr = ps;
presetId = ps; unloadPlaylist(); // applying a preset unloads the playlist
root.remove("v"); // may be added in UI call applyPreset(ps, callMode); // async load from file system (only preset ID was specified)
root.remove("time"); // may be added in UI call
root.remove("ps");
root.remove("on"); // some exetrnal calls add "on" to "ps" call
if (root.size() == 0) {
unloadPlaylist(); // we need to unload playlist
applyPreset(ps, callMode); // async load (only preset ID was specified)
return stateResponse; return stateResponse;
} }
} }
}
JsonObject playlist = root[F("playlist")]; JsonObject playlist = root[F("playlist")];
if (!playlist.isNull() && loadPlaylist(playlist, presetId)) { if (!playlist.isNull() && loadPlaylist(playlist, presetId)) {
@ -427,6 +421,7 @@ bool deserializeState(JsonObject root, byte callMode, byte presetId)
} }
stateUpdated(callMode); stateUpdated(callMode);
if (presetToRestore) currentPreset = presetToRestore;
return stateResponse; return stateResponse;
} }
@ -570,8 +565,8 @@ void serializeInfo(JsonObject root)
#ifndef WLED_DISABLE_2D #ifndef WLED_DISABLE_2D
if (strip.isMatrix) { if (strip.isMatrix) {
JsonObject matrix = leds.createNestedObject("matrix"); JsonObject matrix = leds.createNestedObject("matrix");
matrix["w"] = strip.matrixWidth; matrix["w"] = Segment::maxWidth;
matrix["h"] = strip.matrixHeight; matrix["h"] = Segment::maxHeight;
} }
#endif #endif

View File

@ -1,11 +1,12 @@
#include "wled.h" #include "wled.h"
#ifdef WLED_ENABLE_LOXONE
/* /*
* Parser for Loxone formats * Parser for Loxone formats
*/ */
bool parseLx(int lxValue, byte rgbw[4]) bool parseLx(int lxValue, byte rgbw[4])
{ {
#ifdef WLED_ENABLE_LOXONE
DEBUG_PRINT(F("LX: Lox = ")); DEBUG_PRINT(F("LX: Lox = "));
DEBUG_PRINTLN(lxValue); DEBUG_PRINTLN(lxValue);
@ -42,7 +43,6 @@ bool parseLx(int lxValue, byte rgbw[4])
rgbw[3] = 0; rgbw[3] = 0;
return true; return true;
} }
#endif
return false; return false;
} }
@ -62,15 +62,10 @@ void parseLxJson(int lxValue, byte segId, bool secondary)
} }
bri = 255; bri = 255;
nightlightActive = false; //always disable nightlight when toggling nightlightActive = false; //always disable nightlight when toggling
if (segId == strip.getMainSegmentId()) {
DEBUG_PRINTLN(F("LX: main segment"));
if (secondary) for (byte i = 0; i < 4; i++) colSec[i] = rgbw[i];
else for (byte i = 0; i < 4; i++) col[i] = rgbw[i];
} else {
DEBUG_PRINT(F("LX: segment ")); DEBUG_PRINT(F("LX: segment "));
DEBUG_PRINTLN(segId); DEBUG_PRINTLN(segId);
strip.getSegment(segId).setColor(secondary, RGBW32(rgbw[0], rgbw[1], rgbw[2], rgbw[3])); strip.getSegment(segId).setColor(secondary, RGBW32(rgbw[0], rgbw[1], rgbw[2], rgbw[3])); // legacy values handled as well in json.cpp by stateUpdated()
}
} }
} }
#endif

View File

@ -107,8 +107,9 @@ bool PinManagerClass::allocateMultiplePins(const managed_pin_type * mptArray, by
} }
if (!isPinOk(gpio, mptArray[i].isOutput)) { if (!isPinOk(gpio, mptArray[i].isOutput)) {
#ifdef WLED_DEBUG #ifdef WLED_DEBUG
DEBUG_PRINT(F("PIN ALLOC: Invalid pin attempted to be allocated: ")); DEBUG_PRINT(F("PIN ALLOC: Invalid pin attempted to be allocated: GPIO "));
DEBUG_PRINT(gpio); DEBUG_PRINT(gpio);
DEBUG_PRINT(" as "); DEBUG_PRINT(mptArray[i].isOutput ? "output": "input");
DEBUG_PRINTLN(F("")); DEBUG_PRINTLN(F(""));
#endif #endif
shouldFail = true; shouldFail = true;
@ -142,6 +143,9 @@ bool PinManagerClass::allocateMultiplePins(const managed_pin_type * mptArray, by
// as this can greatly simplify configuration arrays // as this can greatly simplify configuration arrays
continue; continue;
} }
if (gpio >= WLED_NUM_PINS)
continue; // other unexpected GPIO => avoid array bounds violation
byte by = gpio >> 3; byte by = gpio >> 3;
byte bi = gpio - 8*by; byte bi = gpio - 8*by;
bitWrite(pinAlloc[by], bi, true); bitWrite(pinAlloc[by], bi, true);
@ -160,7 +164,7 @@ bool PinManagerClass::allocateMultiplePins(const managed_pin_type * mptArray, by
bool PinManagerClass::allocatePin(byte gpio, bool output, PinOwner tag) bool PinManagerClass::allocatePin(byte gpio, bool output, PinOwner tag)
{ {
// HW I2C & SPI pins have to be allocated using allocateMultiplePins variant since there is always SCL/SDA pair // HW I2C & SPI pins have to be allocated using allocateMultiplePins variant since there is always SCL/SDA pair
if (!isPinOk(gpio, output) || tag==PinOwner::HW_I2C || tag==PinOwner::HW_SPI) { if (!isPinOk(gpio, output) || (gpio >= WLED_NUM_PINS) || tag==PinOwner::HW_I2C || tag==PinOwner::HW_SPI) {
#ifdef WLED_DEBUG #ifdef WLED_DEBUG
if (gpio < 255) { // 255 (-1) is the "not defined GPIO" if (gpio < 255) { // 255 (-1) is the "not defined GPIO"
if (!isPinOk(gpio, output)) { if (!isPinOk(gpio, output)) {
@ -209,6 +213,7 @@ bool PinManagerClass::isPinAllocated(byte gpio, PinOwner tag)
{ {
if (!isPinOk(gpio, false)) return true; if (!isPinOk(gpio, false)) return true;
if ((tag != PinOwner::None) && (ownerTag[gpio] != tag)) return false; if ((tag != PinOwner::None) && (ownerTag[gpio] != tag)) return false;
if (gpio >= WLED_NUM_PINS) return false; // catch error case, to avoid array out-of-bounds access
byte by = gpio >> 3; byte by = gpio >> 3;
byte bi = gpio - (by<<3); byte bi = gpio - (by<<3);
return bitRead(pinAlloc[by], bi); return bitRead(pinAlloc[by], bi);
@ -265,6 +270,7 @@ bool PinManagerClass::isPinOk(byte gpio, bool output)
} }
PinOwner PinManagerClass::getPinOwner(byte gpio) { PinOwner PinManagerClass::getPinOwner(byte gpio) {
if (gpio >= WLED_NUM_PINS) return PinOwner::None; // catch error case, to avoid array out-of-bounds access
if (!isPinOk(gpio, false)) return PinOwner::None; if (!isPinOk(gpio, false)) return PinOwner::None;
return ownerTag[gpio]; return ownerTag[gpio];
} }

View File

@ -58,19 +58,22 @@ enum struct PinOwner : uint8_t {
UM_BME280 = USERMOD_ID_BME280, // 0x18 // Usermod "usermod_bme280.h -- Uses "standard" HW_I2C pins UM_BME280 = USERMOD_ID_BME280, // 0x18 // Usermod "usermod_bme280.h -- Uses "standard" HW_I2C pins
UM_BH1750 = USERMOD_ID_BH1750, // 0x19 // Usermod "usermod_bme280.h -- Uses "standard" HW_I2C pins UM_BH1750 = USERMOD_ID_BH1750, // 0x19 // Usermod "usermod_bme280.h -- Uses "standard" HW_I2C pins
UM_Audioreactive = USERMOD_ID_AUDIOREACTIVE, // 0x1E // Usermod "audio_reactive.h" UM_Audioreactive = USERMOD_ID_AUDIOREACTIVE, // 0x1E // Usermod "audio_reactive.h"
UM_SdCard = USERMOD_ID_SD_CARD // 0x24 // Usermod "usermod_sd_card.h" UM_SdCard = USERMOD_ID_SD_CARD, // 0x24 // Usermod "usermod_sd_card.h"
UM_PWM_OUTPUTS = USERMOD_ID_PWM_OUTPUTS // 0x21 // Usermod "usermod_pwm_outputs.h"
}; };
static_assert(0u == static_cast<uint8_t>(PinOwner::None), "PinOwner::None must be zero, so default array initialization works as expected"); static_assert(0u == static_cast<uint8_t>(PinOwner::None), "PinOwner::None must be zero, so default array initialization works as expected");
class PinManagerClass { class PinManagerClass {
private: private:
#ifdef ESP8266 #ifdef ESP8266
#define WLED_NUM_PINS 17
uint8_t pinAlloc[3] = {0x00, 0x00, 0x00}; //24bit, 1 bit per pin, we use first 17bits uint8_t pinAlloc[3] = {0x00, 0x00, 0x00}; //24bit, 1 bit per pin, we use first 17bits
PinOwner ownerTag[17] = { PinOwner::None }; PinOwner ownerTag[WLED_NUM_PINS] = { PinOwner::None };
#else #else
uint8_t pinAlloc[5] = {0x00, 0x00, 0x00, 0x00, 0x00}; //40bit, 1 bit per pin, we use all bits #define WLED_NUM_PINS 50
uint8_t pinAlloc[7] = {0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; // 56bit, 1 bit per pin, we use 50 bits on ESP32-S3
uint8_t ledcAlloc[2] = {0x00, 0x00}; //16 LEDC channels uint8_t ledcAlloc[2] = {0x00, 0x00}; //16 LEDC channels
PinOwner ownerTag[40] = { PinOwner::None }; PinOwner ownerTag[WLED_NUM_PINS] = { PinOwner::None }; // new MCU's have up to 50 GPIO
#endif #endif
struct { struct {
uint8_t i2cAllocCount : 4; // allow multiple allocation of I2C bus pins but keep track of allocations uint8_t i2cAllocCount : 4; // allow multiple allocation of I2C bus pins but keep track of allocations

View File

@ -16,13 +16,13 @@ static char quickLoad[9];
static char saveName[33]; static char saveName[33];
static bool includeBri = true, segBounds = true, selectedOnly = false, playlistSave = false;; static bool includeBri = true, segBounds = true, selectedOnly = false, playlistSave = false;;
static const char *getName(bool persist = true) { static const char *getFileName(bool persist = true) {
return persist ? "/presets.json" : "/tmp.json"; return persist ? "/presets.json" : "/tmp.json";
} }
static void doSaveState() { static void doSaveState() {
bool persist = (presetToSave < 251); bool persist = (presetToSave < 251);
const char *filename = getName(persist); const char *filename = getFileName(persist);
if (!requestJSONBufferLock(10)) return; // will set fileDoc if (!requestJSONBufferLock(10)) return; // will set fileDoc
@ -83,7 +83,7 @@ bool getPresetName(byte index, String& name)
{ {
if (!requestJSONBufferLock(9)) return false; if (!requestJSONBufferLock(9)) return false;
bool presetExists = false; bool presetExists = false;
if (readObjectFromFileUsingId(getName(), index, &doc)) if (readObjectFromFileUsingId(getFileName(), index, &doc))
{ {
JsonObject fdo = doc.as<JsonObject>(); JsonObject fdo = doc.as<JsonObject>();
if (fdo["n"]) { if (fdo["n"]) {
@ -97,12 +97,12 @@ bool getPresetName(byte index, String& name)
void initPresetsFile() void initPresetsFile()
{ {
if (WLED_FS.exists(getName())) return; if (WLED_FS.exists(getFileName())) return;
StaticJsonDocument<64> doc; StaticJsonDocument<64> doc;
JsonObject sObj = doc.to<JsonObject>(); JsonObject sObj = doc.to<JsonObject>();
sObj.createNestedObject("0"); sObj.createNestedObject("0");
File f = WLED_FS.open(getName(), "w"); File f = WLED_FS.open(getFileName(), "w");
if (!f) { if (!f) {
errorFlag = ERR_FS_GENERAL; errorFlag = ERR_FS_GENERAL;
return; return;
@ -127,14 +127,14 @@ void handlePresets()
return; return;
} }
if (presetToApply == 0 || fileDoc) return; // no preset waiting to apply, or JSON buffer is already allocated, return to loop until free
bool changePreset = false; bool changePreset = false;
uint8_t tmpPreset = presetToApply; // store temporary since deserializeState() may call applyPreset() uint8_t tmpPreset = presetToApply; // store temporary since deserializeState() may call applyPreset()
uint8_t tmpMode = callModeToApply; uint8_t tmpMode = callModeToApply;
if (tmpPreset == 0 || (fileDoc /*&& !force*/)) return; // JSON buffer already allocated and not force apply or no preset waiting
JsonObject fdo; JsonObject fdo;
const char *filename = getName(tmpPreset < 255); const char *filename = getFileName(tmpPreset < 255);
// allocate buffer // allocate buffer
if (!requestJSONBufferLock(9)) return; // will also assign fileDoc if (!requestJSONBufferLock(9)) return; // will also assign fileDoc
@ -181,7 +181,8 @@ void handlePresets()
#endif #endif
releaseJSONBufferLock(); // will also clear fileDoc releaseJSONBufferLock(); // will also clear fileDoc
colorUpdated(tmpMode); if (changePreset) notify(tmpMode); // force UDP notification
stateUpdated(tmpMode); // was colorUpdated() if anything breaks
updateInterfaces(tmpMode); updateInterfaces(tmpMode);
} }
@ -200,30 +201,28 @@ void savePreset(byte index, const char* pname, JsonObject sObj)
presetToSave = index; presetToSave = index;
playlistSave = false; playlistSave = false;
if (sObj[F("ql")].is<const char*>()) strlcpy(quickLoad, sObj[F("ql")].as<const char*>(), 9); // client limits QL to 2 chars, buffer for 8 bytes to allow unicode if (sObj[F("ql")].is<const char*>()) strlcpy(quickLoad, sObj[F("ql")].as<const char*>(), 9); // client limits QL to 2 chars, buffer for 8 bytes to allow unicode
sObj.remove("v");
sObj.remove("time"); if (sObj["o"].isNull()) { // no "o" means not a playlist or custom API call, saving of state is async (not immediately)
sObj.remove(F("error"));
sObj.remove(F("psave"));
if (sObj["o"].isNull()) { // "o" marks a playlist or manually entered API
includeBri = sObj["ib"].as<bool>() || index==255; // temporary preset needs brightness includeBri = sObj["ib"].as<bool>() || index==255; // temporary preset needs brightness
segBounds = sObj["sb"].as<bool>() || index==255; // temporary preset needs bounds segBounds = sObj["sb"].as<bool>() || index==255; // temporary preset needs bounds
selectedOnly = sObj[F("sc")].as<bool>(); selectedOnly = sObj[F("sc")].as<bool>();
saveLedmap = sObj[F("ledmap")] | -1; saveLedmap = sObj[F("ledmap")] | -1;
sObj.remove("ib");
sObj.remove("sb");
sObj.remove(F("sc"));
} else { } else {
// this is a playlist or API // this is a playlist or API call
sObj.remove("o");
if (sObj[F("playlist")].isNull()) { if (sObj[F("playlist")].isNull()) {
presetToSave = 0; // we will save API immediately // we will save API call immediately
if (index < 251 && fileDoc) { presetToSave = 0;
if (index > 250 || !fileDoc) return; // cannot save API calls to temporary preset (255)
sObj.remove("o");
sObj.remove("v");
sObj.remove("time");
sObj.remove(F("error"));
sObj.remove(F("psave"));
if (sObj["n"].isNull()) sObj["n"] = saveName; if (sObj["n"].isNull()) sObj["n"] = saveName;
initPresetsFile(); // just in case if someone deleted presets.json using /edit initPresetsFile(); // just in case if someone deleted presets.json using /edit
writeObjectToFileUsingId(getName(index), index, fileDoc); writeObjectToFileUsingId(getFileName(index), index, fileDoc);
presetsModifiedTime = toki.second(); //unix time presetsModifiedTime = toki.second(); //unix time
updateFSInfo(); updateFSInfo();
}
} else { } else {
// store playlist // store playlist
includeBri = true; // !sObj["on"].isNull(); includeBri = true; // !sObj["on"].isNull();
@ -234,7 +233,7 @@ void savePreset(byte index, const char* pname, JsonObject sObj)
void deletePreset(byte index) { void deletePreset(byte index) {
StaticJsonDocument<24> empty; StaticJsonDocument<24> empty;
writeObjectToFileUsingId(getName(), index, &empty); writeObjectToFileUsingId(getFileName(), index, &empty);
presetsModifiedTime = toki.second(); //unix time presetsModifiedTime = toki.second(); //unix time
updateFSInfo(); updateFSInfo();
} }

View File

@ -169,6 +169,18 @@ void handleSettingsSet(AsyncWebServerRequest *request, byte subPage)
if (pinManager.allocatePin(hw_btn_pin,false,PinOwner::Button)) { if (pinManager.allocatePin(hw_btn_pin,false,PinOwner::Button)) {
btnPin[i] = hw_btn_pin; btnPin[i] = hw_btn_pin;
buttonType[i] = request->arg(be).toInt(); buttonType[i] = request->arg(be).toInt();
#ifdef ARDUINO_ARCH_ESP32
// ESP32 only: check that analog button pin is a valid ADC gpio
if (((buttonType[i] == BTN_TYPE_ANALOG) || (buttonType[i] == BTN_TYPE_ANALOG_INVERTED)) && (digitalPinToAnalogChannel(btnPin[i]) < 0))
{
// not an ADC analog pin
if (btnPin[i] >= 0) DEBUG_PRINTF("PIN ALLOC error: GPIO%d for analog button #%d is not an analog pin!\n", btnPin[i], i);
btnPin[i] = -1;
pinManager.deallocatePin(hw_btn_pin,PinOwner::Button);
}
else
#endif
{
if (disablePullUp) { if (disablePullUp) {
pinMode(btnPin[i], INPUT); pinMode(btnPin[i], INPUT);
} else { } else {
@ -178,6 +190,7 @@ void handleSettingsSet(AsyncWebServerRequest *request, byte subPage)
pinMode(btnPin[i], INPUT_PULLUP); pinMode(btnPin[i], INPUT_PULLUP);
#endif #endif
} }
}
} else { } else {
btnPin[i] = -1; btnPin[i] = -1;
buttonType[i] = BTN_TYPE_NONE; buttonType[i] = BTN_TYPE_NONE;

View File

@ -14,9 +14,10 @@ Distributed as-is; no warranty is given.
******************************************************************************/ ******************************************************************************/
/* ----- LIBRARIES ----- */ /* ----- LIBRARIES ----- */
#ifdef ESP32 #if defined(ARDUINO_ARCH_ESP32)
#include <Arduino.h> #include <Arduino.h>
#if !defined(CONFIG_IDF_TARGET_ESP32C3) && !defined(CONFIG_IDF_TARGET_ESP32S2)
#include "SparkFunDMX.h" #include "SparkFunDMX.h"
#include <HardwareSerial.h> #include <HardwareSerial.h>
@ -29,28 +30,40 @@ Distributed as-is; no warranty is given.
#define BREAKSPEED 83333 #define BREAKSPEED 83333
#define BREAKFORMAT SERIAL_8N1 #define BREAKFORMAT SERIAL_8N1
int enablePin = -1; // disable the enable pin because it is not needed static const int enablePin = -1; // disable the enable pin because it is not needed
int rxPin = -1; // disable the receiving pin because it is not needed static const int rxPin = -1; // disable the receiving pin because it is not needed - softhack007: Pin=-1 means "use default" not "disable"
int txPin = 2; // transmit DMX data over this pin (default is pin 2) static const int txPin = 2; // transmit DMX data over this pin (default is pin 2)
//DMX value array and size. Entry 0 will hold startbyte //DMX value array and size. Entry 0 will hold startbyte
uint8_t dmxData[dmxMaxChannel] = {}; static uint8_t dmxData[dmxMaxChannel] = { 0 };
int chanSize; static int chanSize = 0;
int currentChannel = 0; #if !defined(DMX_SEND_ONLY)
static int currentChannel = 0;
#endif
HardwareSerial DMXSerial(2); // Some new MCUs (-S2, -C3) don't have HardwareSerial(2)
#if ESP_IDF_VERSION >= ESP_IDF_VERSION_VAL(4, 2, 0)
#if SOC_UART_NUM < 3
#error DMX output is not possible on your MCU, as it does not have HardwareSerial(2)
#endif
#endif
static HardwareSerial DMXSerial(2);
/* Interrupt Timer for DMX Receive */ /* Interrupt Timer for DMX Receive */
hw_timer_t * timer = NULL; #if !defined(DMX_SEND_ONLY)
portMUX_TYPE timerMux = portMUX_INITIALIZER_UNLOCKED; static hw_timer_t * timer = NULL;
static portMUX_TYPE timerMux = portMUX_INITIALIZER_UNLOCKED;
#endif
volatile int _interruptCounter; static volatile int _interruptCounter = 0;
volatile bool _startCodeDetected = false; static volatile bool _startCodeDetected = false;
#if !defined(DMX_SEND_ONLY)
/* Start Code is detected by 21 low interrupts */ /* Start Code is detected by 21 low interrupts */
void IRAM_ATTR onTimer() { void IRAM_ATTR onTimer() {
if (digitalRead(rxPin) == 1) if ((rxPin >= 0) && (digitalRead(rxPin) == 1))
{ {
_interruptCounter = 0; //If the RX Pin is high, we are not in an interrupt _interruptCounter = 0; //If the RX Pin is high, we are not in an interrupt
} }
@ -80,10 +93,13 @@ void SparkFunDMX::initRead(int chanQuant) {
chanQuant = defaultMax; chanQuant = defaultMax;
} }
chanSize = chanQuant; chanSize = chanQuant;
if (enablePin >= 0) {
pinMode(enablePin, OUTPUT); pinMode(enablePin, OUTPUT);
digitalWrite(enablePin, LOW); digitalWrite(enablePin, LOW);
pinMode(rxPin, INPUT);
} }
if (rxPin >= 0) pinMode(rxPin, INPUT);
}
#endif
// Set up the DMX-Protocol // Set up the DMX-Protocol
void SparkFunDMX::initWrite (int chanQuant) { void SparkFunDMX::initWrite (int chanQuant) {
@ -96,15 +112,19 @@ void SparkFunDMX::initWrite (int chanQuant) {
chanSize = chanQuant + 1; //Add 1 for start code chanSize = chanQuant + 1; //Add 1 for start code
DMXSerial.begin(DMXSPEED, DMXFORMAT, rxPin, txPin); DMXSerial.begin(DMXSPEED, DMXFORMAT, rxPin, txPin);
if (enablePin >= 0) {
pinMode(enablePin, OUTPUT); pinMode(enablePin, OUTPUT);
digitalWrite(enablePin, HIGH); digitalWrite(enablePin, HIGH);
} }
}
#if !defined(DMX_SEND_ONLY)
// Function to read DMX data // Function to read DMX data
uint8_t SparkFunDMX::read(int Channel) { uint8_t SparkFunDMX::read(int Channel) {
if (Channel > chanSize) Channel = chanSize; if (Channel > chanSize) Channel = chanSize;
return(dmxData[Channel - 1]); //subtract one to account for start byte return(dmxData[Channel - 1]); //subtract one to account for start byte
} }
#endif
// Function to send DMX data // Function to send DMX data
void SparkFunDMX::write(int Channel, uint8_t value) { void SparkFunDMX::write(int Channel, uint8_t value) {
@ -133,6 +153,7 @@ void SparkFunDMX::update() {
DMXSerial.flush(); DMXSerial.flush();
DMXSerial.end();//clear our DMX array, end the Hardware Serial port DMXSerial.end();//clear our DMX array, end the Hardware Serial port
} }
#if !defined(DMX_SEND_ONLY)
else if (_READWRITE == _READ)//In a perfect world, this function ends serial communication upon packet completion and attaches RX to a CHANGE interrupt so the start code can be read again else if (_READWRITE == _READ)//In a perfect world, this function ends serial communication upon packet completion and attaches RX to a CHANGE interrupt so the start code can be read again
{ {
if (_startCodeDetected == true) if (_startCodeDetected == true)
@ -153,8 +174,9 @@ void SparkFunDMX::update() {
} }
} }
} }
#endif
} }
// Function to update the DMX bus // Function to update the DMX bus
#endif
#endif #endif

View File

@ -19,19 +19,23 @@ Distributed as-is; no warranty is given.
#ifndef SparkFunDMX_h #ifndef SparkFunDMX_h
#define SparkFunDMX_h #define SparkFunDMX_h
#define DMX_SEND_ONLY // this disables DMX sending features, and saves us two GPIO pins
// ---- Methods ---- // ---- Methods ----
class SparkFunDMX { class SparkFunDMX {
public: public:
void initRead(int maxChan);
void initWrite(int maxChan); void initWrite(int maxChan);
#if !defined(DMX_SEND_ONLY)
void initRead(int maxChan);
uint8_t read(int Channel); uint8_t read(int Channel);
#endif
void write(int channel, uint8_t value); void write(int channel, uint8_t value);
void update(); void update();
private: private:
uint8_t _startCodeValue = 0xFF; const uint8_t _startCodeValue = 0xFF;
bool _READ = true; const bool _READ = true;
bool _WRITE = false; const bool _WRITE = false;
bool _READWRITE; bool _READWRITE;
}; };

View File

@ -160,6 +160,10 @@
#include "../usermods/ADS1115_v2/usermod_ads1115.h" #include "../usermods/ADS1115_v2/usermod_ads1115.h"
#endif #endif
#ifdef USERMOD_BOBLIGHT
#include "../usermods/boblight/boblight.h"
#endif
#if defined(WLED_USE_SD_MMC) || defined(WLED_USE_SD_SPI) #if defined(WLED_USE_SD_MMC) || defined(WLED_USE_SD_SPI)
// This include of SD.h and SD_MMC.h must happen here, else they won't be // This include of SD.h and SD_MMC.h must happen here, else they won't be
// resolved correctly (when included in mod's header only) // resolved correctly (when included in mod's header only)
@ -172,6 +176,15 @@
#include "../usermods/sd_card/usermod_sd_card.h" #include "../usermods/sd_card/usermod_sd_card.h"
#endif #endif
#ifdef USERMOD_PWM_OUTPUTS
#include "../usermods/pwm_outputs/usermod_pwm_outputs.h"
#endif
#ifdef USERMOD_SHT
#include "../usermods/sht/usermod_sht.h"
#endif
void registerUsermods() void registerUsermods()
{ {
/* /*
@ -320,7 +333,19 @@ void registerUsermods()
usermods.add(new ADS1115Usermod()); usermods.add(new ADS1115Usermod());
#endif #endif
#ifdef USERMOD_BOBLIGHT
usermods.add(new BobLightUsermod());
#endif
#ifdef SD_ADAPTER #ifdef SD_ADAPTER
usermods.add(new UsermodSdCard()); usermods.add(new UsermodSdCard());
#endif #endif
#ifdef USERMOD_PWM_OUTPUTS
usermods.add(new PwmOutputsUsermod());
#endif
#ifdef USERMOD_SHT
usermods.add(new ShtUsermod());
#endif
} }

View File

@ -269,9 +269,12 @@ void WLED::setup()
Serial.begin(115200); Serial.begin(115200);
Serial.setTimeout(50); Serial.setTimeout(50);
#if defined(WLED_DEBUG) && (defined(CONFIG_IDF_TARGET_ESP32S2) || defined(CONFIG_IDF_TARGET_ESP32C3)) #if defined(WLED_DEBUG) && defined(ARDUINO_ARCH_ESP32) && (defined(CONFIG_IDF_TARGET_ESP32S2) || defined(CONFIG_IDF_TARGET_ESP32C3) || ARDUINO_USB_CDC_ON_BOOT)
delay(2500); // allow CDC USB serial to initialise delay(2500); // allow CDC USB serial to initialise
#endif #endif
#if !defined(WLED_DEBUG) && defined(ARDUINO_ARCH_ESP32) && !defined(WLED_DEBUG_HOST) && ARDUINO_USB_CDC_ON_BOOT
Serial.setDebugOutput(false); // switch off kernel messages when using USBCDC
#endif
DEBUG_PRINTLN(); DEBUG_PRINTLN();
DEBUG_PRINT(F("---WLED ")); DEBUG_PRINT(F("---WLED "));
DEBUG_PRINT(versionString); DEBUG_PRINT(versionString);

View File

@ -8,7 +8,7 @@
*/ */
// version code in format yymmddb (b = daily build) // version code in format yymmddb (b = daily build)
#define VERSION 2211261 #define VERSION 2212180
//uncomment this if you have a "my_config.h" file you'd like to use //uncomment this if you have a "my_config.h" file you'd like to use
//#define WLED_USE_MY_CONFIG //#define WLED_USE_MY_CONFIG
@ -678,11 +678,37 @@ WLED_GLOBAL uint16_t ledMaps _INIT(0); // bitfield representation of available l
// Usermod manager // Usermod manager
WLED_GLOBAL UsermodManager usermods _INIT(UsermodManager()); WLED_GLOBAL UsermodManager usermods _INIT(UsermodManager());
WLED_GLOBAL int8_t i2c_sda _INIT(-1); // global I2C SDA pin [HW_PIN_SDA] (used for usermods) // global I2C SDA pin (used for usermods)
WLED_GLOBAL int8_t i2c_scl _INIT(-1); // global I2C SCL pin [HW_PIN_SCL] (used for usermods) #ifndef I2CSDAPIN
WLED_GLOBAL int8_t spi_mosi _INIT(-1); // global SPI DATA/MOSI pin [HW_PIN_DATASPI] (used for usermods) WLED_GLOBAL int8_t i2c_sda _INIT(-1);
WLED_GLOBAL int8_t spi_miso _INIT(-1); // global SPI DATA/MISO pin [HW_PIN_MISOSPI] (used for usermods) #else
WLED_GLOBAL int8_t spi_sclk _INIT(-1); // global SPI CLOCK/SCLK pin [HW_PIN_CLOCKSPI] (used for usermods) WLED_GLOBAL int8_t i2c_sda _INIT(I2CSDAPIN);
#endif
// global I2C SCL pin (used for usermods)
#ifndef I2CSCLPIN
WLED_GLOBAL int8_t i2c_scl _INIT(-1);
#else
WLED_GLOBAL int8_t i2c_scl _INIT(I2CSCLPIN);
#endif
// global SPI DATA/MOSI pin (used for usermods)
#ifndef SPIMOSIPIN
WLED_GLOBAL int8_t spi_mosi _INIT(-1);
#else
WLED_GLOBAL int8_t spi_mosi _INIT(SPIMOSIPIN);
#endif
// global SPI DATA/MISO pin (used for usermods)
#ifndef SPIMISOPIN
WLED_GLOBAL int8_t spi_miso _INIT(-1);
#else
WLED_GLOBAL int8_t spi_miso _INIT(SPIMISOPIN);
#endif
// global SPI CLOCK/SCLK pin (used for usermods)
#ifndef SPISCLKPIN
WLED_GLOBAL int8_t spi_sclk _INIT(-1);
#else
WLED_GLOBAL int8_t spi_sclk _INIT(SPISCLKPIN);
#endif
// global ArduinoJson buffer // global ArduinoJson buffer
WLED_GLOBAL StaticJsonDocument<JSON_BUFFER_SIZE> doc; WLED_GLOBAL StaticJsonDocument<JSON_BUFFER_SIZE> doc;

View File

@ -71,7 +71,7 @@ void createEditHandler(bool enable) {
editHandler = &server.addHandler(new SPIFFSEditor("","",WLED_FS));//http_username,http_password)); editHandler = &server.addHandler(new SPIFFSEditor("","",WLED_FS));//http_username,http_password));
#endif #endif
#else #else
editHandler = server.on("/edit", HTTP_GET, [](AsyncWebServerRequest *request){ editHandler = &server.on("/edit", HTTP_GET, [](AsyncWebServerRequest *request){
serveMessage(request, 501, "Not implemented", F("The FS editor is disabled in this build."), 254); serveMessage(request, 501, "Not implemented", F("The FS editor is disabled in this build."), 254);
}); });
#endif #endif

View File

@ -25,7 +25,7 @@ void wsEvent(AsyncWebSocket * server, AsyncWebSocketClient * client, AwsEventTyp
// data packet // data packet
AwsFrameInfo * info = (AwsFrameInfo*)arg; AwsFrameInfo * info = (AwsFrameInfo*)arg;
if(info->final && info->index == 0 && info->len == len){ if(info->final && info->index == 0 && info->len == len){
//the whole message is in a single frame and we got all of its data (max. 1450byte) // the whole message is in a single frame and we got all of its data (max. 1450 bytes)
if(info->opcode == WS_TEXT) if(info->opcode == WS_TEXT)
{ {
if (len > 0 && len < 10 && data[0] == 'p') { if (len > 0 && len < 10 && data[0] == 'p') {
@ -54,7 +54,7 @@ void wsEvent(AsyncWebSocket * server, AsyncWebSocketClient * client, AwsEventTyp
} }
releaseJSONBufferLock(); // will clean fileDoc releaseJSONBufferLock(); // will clean fileDoc
// force broadcast in 500ms after upadting client // force broadcast in 500ms after updating client
if (verboseResponse) { if (verboseResponse) {
sendDataWs(client); sendDataWs(client);
lastInterfaceUpdate = millis() - (INTERFACE_UPDATE_COOLDOWN -500); lastInterfaceUpdate = millis() - (INTERFACE_UPDATE_COOLDOWN -500);
@ -161,8 +161,8 @@ bool sendLiveLedsWs(uint32_t wsClient)
#ifndef WLED_DISABLE_2D #ifndef WLED_DISABLE_2D
if (strip.isMatrix) { if (strip.isMatrix) {
buffer[1] = 2; //version buffer[1] = 2; //version
buffer[2] = strip.matrixWidth; buffer[2] = Segment::maxWidth;
buffer[3] = strip.matrixHeight; buffer[3] = Segment::maxHeight;
} }
#endif #endif

View File

@ -471,6 +471,8 @@ void getSettingsJS(byte subPage, char* dest)
sappend('c',SET_F("ST"),syncToggleReceive); sappend('c',SET_F("ST"),syncToggleReceive);
#ifdef WLED_ENABLE_SIMPLE_UI #ifdef WLED_ENABLE_SIMPLE_UI
sappend('c',SET_F("SU"),simplifiedUI); sappend('c',SET_F("SU"),simplifiedUI);
#else
oappend(SET_F("toggle('Simple');")); // hide Simplified UI settings
#endif #endif
} }