Skip to content

Commit 0ff4016

Browse files
committed
WLED 0.15.0-b4 release
- LED settings update (limit to available outputs) - minor fixes
1 parent e753f38 commit 0ff4016

File tree

15 files changed

+188
-71
lines changed

15 files changed

+188
-71
lines changed

CHANGELOG.md

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,44 @@
11
## WLED changelog
22

3+
#### Build 2405180
4+
5+
#### Build 2406290
6+
- WLED 0.15.0-b4 release
7+
- LED settings bus management update (WARNING only allow available outputs)
8+
- Add ETH support for LILYGO-POE-Pro (#4030 by @rorosaurus)
9+
- Update usermod_sn_photoresistor (#4017 by @xkvmoto)
10+
- Several internal fixes and optimisations
11+
- move LED_BUILTIN handling to BusManager class
12+
- reduce max panels (web server limitation)
13+
- edit WiFi TX power (ESP32)
14+
- keep current ledmap ID in UI
15+
- limit outputs in UI based on length
16+
- wifi.ap addition to JSON Info (JSON API)
17+
- relay pin init bugfix
18+
- file editor button in UI
19+
- ESP8266: update was restarting device on some occasions
20+
- a bit of throttling in UI (for ESP8266)
21+
22+
#### Build 2406120
23+
- Update NeoPixelBus to v2.8.0
24+
- Increased LED outputs one ESP32 using parallel I2S (up to 17)
25+
- use single/mono I2S + 4x RMT for 5 outputs or less
26+
- use parallel x8 I2S + 8x RMT for >5 outputs (limit of 300 LEDs per output)
27+
- Fixed code of Smartnest and updated documentation (#4001 by @DevilPro1)
28+
- ESP32-S3 WiFi fix (#4010 by @cstruck)
29+
- TetrisAI usermod fix (#3897 by @muebau)
30+
- ESP-NOW usermod hook
31+
- Update wled.h regarding OTA Password (#3993 by @gsieben)
32+
- Usermod BME68X Sensor Implementation (#3994 by @gsieben)
33+
- Add a usermod for AHT10, AHT15 and AHT20 temperature/humidity sensors (#3977 by @LordMike)
34+
- Update Battery usermod documentation (#3968 by @adamsthws)
35+
- Add INA226 usermod for reading current and power over i2c (#3986 by @LordMike)
36+
- Bugfixes: #3991
37+
- Several internal fixes and optimisations (WARNING: some effects may be broken that rely on overflow/narrow width)
38+
- replace uint8_t and uint16_t with unsigned
39+
- replace in8_t and int16_t with int
40+
- reduces code by 1kB
41+
342
#### Build 2405180
443
- Official 0.15.0-b3 release
544
- Merge 0.14.3 fixes

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "wled",
3-
"version": "0.15.0-b3",
3+
"version": "0.15.0-b4",
44
"description": "Tools for WLED project",
55
"main": "tools/cdata.js",
66
"directories": {

platformio_override.sample.ini

Lines changed: 20 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ default_envs = WLED_tasmota_1M # define as many as you need
1010
#----------
1111
# SAMPLE
1212
#----------
13-
[env:WLED_tasmota_1M]
13+
[env:WLED_generic8266_1M]
1414
extends = env:esp01_1m_full # when you want to extend the existing environment (define only updated options)
1515
; board = esp01_1m # uncomment when ou need different board
1616
; platform = ${common.platform_wled_default} # uncomment and change when you want particular platform
@@ -26,9 +26,9 @@ lib_deps = ${esp8266.lib_deps}
2626
; adafruit/Adafruit BME280 Library@^2.2.2
2727
; Wire
2828
; robtillaart/SHT85@~0.3.3
29-
; gmag11/QuickESPNow ;@ 0.6.2
29+
; ;gmag11/QuickESPNow @ ~0.7.0 # will also load QuickDebug
3030
; https://github.com/blazoncek/QuickESPNow.git#optional-debug ;; exludes debug library
31-
; https://github.com/kosme/arduinoFFT#develop @ 2.0.1 ;; used for USERMOD_AUDIOREACTIVE
31+
; ${esp32.AR_lib_deps} ;; used for USERMOD_AUDIOREACTIVE
3232
build_unflags = ${common.build_unflags}
3333
build_flags = ${common.build_flags} ${esp8266.build_flags}
3434
;
@@ -51,6 +51,11 @@ build_flags = ${common.build_flags} ${esp8266.build_flags}
5151
; -D WLED_DISABLE_ESPNOW
5252
; -D WLED_DISABLE_BROWNOUT_DET
5353
;
54+
; enable optional built-in features
55+
; -D WLED_ENABLE_PIXART
56+
; -D WLED_ENABLE_USERMOD_PAGE # if created
57+
; -D WLED_ENABLE_DMX
58+
;
5459
; PIN defines - uncomment and change, if needed:
5560
; -D LEDPIN=2
5661
; or use this for multiple outputs
@@ -64,6 +69,8 @@ build_flags = ${common.build_flags} ${esp8266.build_flags}
6469
;
6570
; Limit max buses
6671
; -D WLED_MAX_BUSSES=2
72+
; -D WLED_MAX_ANALOG_CHANNELS=3 # only 3 PWM HW pins available
73+
; -D WLED_MAX_DIGITAL_CHANNELS=2 # only 2 HW accelerated pins available
6774
;
6875
; Configure default WiFi
6976
; -D CLIENT_SSID='"MyNetwork"'
@@ -128,12 +135,12 @@ build_flags = ${common.build_flags} ${esp8266.build_flags}
128135
;
129136
; Use PIR sensor usermod and configure it to use GPIO4 and timer of 60s
130137
; -D USERMOD_PIRSWITCH
131-
; -D PIR_SENSOR_PIN=4
138+
; -D PIR_SENSOR_PIN=4 # use -1 to disable usermod
132139
; -D PIR_SENSOR_OFF_SEC=60
140+
; -D PIR_SENSOR_MAX_SENSORS=2 # max allowable sensors (uses OR logic for triggering)
133141
;
134142
; Use Audioreactive usermod and configure I2S microphone
135143
; -D USERMOD_AUDIOREACTIVE
136-
; -D UM_AUDIOREACTIVE_USE_NEW_FFT
137144
; -D AUDIOPIN=-1
138145
; -D DMTYPE=1 # 0-analog/disabled, 1-I2S generic, 2-ES7243, 3-SPH0645, 4-I2S+mclk, 5-I2S PDM
139146
; -D I2S_SDPIN=36
@@ -155,18 +162,22 @@ build_flags = ${common.build_flags} ${esp8266.build_flags}
155162
; -D DEFAULT_LED_COUNT=30
156163
; or this for multiple outputs
157164
; -D PIXEL_COUNTS=30,30
158-
;
159-
; set milliampere limit when using ESP pin to power leds
165+
;
166+
; set the default LED type
167+
; -D DEFAULT_LED_TYPE=22 # see const.h (TYPE_xxxx)
168+
;
169+
; set milliampere limit when using ESP power pin (or inadequate PSU) to power LEDs
160170
; -D ABL_MILLIAMPS_DEFAULT=850
171+
; -D LED_MILLIAMPS_DEFAULT=55
161172
;
162173
; enable IR by setting remote type
163-
; -D IRTYPE=0 ;0 Remote disabled | 1 24-key RGB | 2 24-key with CT | 3 40-key blue | 4 40-key RGB | 5 21-key RGB | 6 6-key black | 7 9-key red | 8 JSON remote
174+
; -D IRTYPE=0 # 0 Remote disabled | 1 24-key RGB | 2 24-key with CT | 3 40-key blue | 4 40-key RGB | 5 21-key RGB | 6 6-key black | 7 9-key red | 8 JSON remote
164175
;
165176
; set default color order of your led strip
166177
; -D DEFAULT_LED_COLOR_ORDER=COL_ORDER_GRB
167178
;
168179
; use PSRAM on classic ESP32 rev.1 (rev.3 or above has no issues)
169-
; -DBOARD_HAS_PSRAM -mfix-esp32-psram-cache-issue
180+
; -DBOARD_HAS_PSRAM -mfix-esp32-psram-cache-issue # needed only for classic ESP32 rev.1
170181
;
171182
; configure I2C and SPI interface (for various hardware)
172183
; -D I2CSDAPIN=33 # initialise interface

usermods/PIR_sensor_switch/usermod_PIR_sensor_switch.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,11 @@ class PIRsensorSwitch : public Usermod
5858
bool sensorPinState[PIR_SENSOR_MAX_SENSORS] = {LOW}; // current PIR sensor pin state
5959

6060
// configurable parameters
61+
#if PIR_SENSOR_PIN < 0
62+
bool enabled = false; // PIR sensor disabled
63+
#else
6164
bool enabled = true; // PIR sensor enabled
65+
#endif
6266
int8_t PIRsensorPin[PIR_SENSOR_MAX_SENSORS] = {PIR_SENSOR_PIN}; // PIR sensor pin
6367
uint32_t m_switchOffDelay = PIR_SENSOR_OFF_SEC*1000; // delay before switch off after the sensor state goes LOW (10min)
6468
uint8_t m_onPreset = 0; // on preset

usermods/usermod_v2_auto_save/usermod_v2_auto_save.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -122,9 +122,9 @@ class AutoSaveUsermod : public Usermod {
122122
* Da loop.
123123
*/
124124
void loop() {
125-
if (!autoSaveAfterSec || !enabled || strip.isUpdating() || currentPreset>0) return; // setting 0 as autosave seconds disables autosave
126-
125+
static unsigned long lastRun = 0;
127126
unsigned long now = millis();
127+
if (!autoSaveAfterSec || !enabled || currentPreset>0 || (strip.isUpdating() && now - lastRun < 240)) return; // setting 0 as autosave seconds disables autosave
128128
uint8_t currentMode = strip.getMainSegment().mode;
129129
uint8_t currentPalette = strip.getMainSegment().palette;
130130

wled00/FX_fcn.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1231,7 +1231,7 @@ void WS2812FX::finalizeInit(void) {
12311231
unsigned start = prevLen;
12321232
unsigned count = defCounts[(i < defNumCounts) ? i : defNumCounts -1];
12331233
prevLen += count;
1234-
BusConfig defCfg = BusConfig(DEFAULT_LED_TYPE, defPin, start, count, DEFAULT_LED_COLOR_ORDER, false, 0, RGBW_MODE_MANUAL_ONLY);
1234+
BusConfig defCfg = BusConfig(DEFAULT_LED_TYPE, defPin, start, count, DEFAULT_LED_COLOR_ORDER, false, 0, RGBW_MODE_MANUAL_ONLY, 0, useGlobalLedBuffer);
12351235
if (BusManager::add(defCfg) == -1) break;
12361236
}
12371237
}

wled00/bus_manager.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ struct BusConfig {
3737
uint8_t milliAmpsPerLed;
3838
uint16_t milliAmpsMax;
3939

40-
BusConfig(uint8_t busType, uint8_t* ppins, uint16_t pstart, uint16_t len = 1, uint8_t pcolorOrder = COL_ORDER_GRB, bool rev = false, uint8_t skip = 0, byte aw=RGBW_MODE_MANUAL_ONLY, uint16_t clock_kHz=0U, bool dblBfr=false, uint8_t maPerLed=55, uint16_t maMax=ABL_MILLIAMPS_DEFAULT)
40+
BusConfig(uint8_t busType, uint8_t* ppins, uint16_t pstart, uint16_t len = 1, uint8_t pcolorOrder = COL_ORDER_GRB, bool rev = false, uint8_t skip = 0, byte aw=RGBW_MODE_MANUAL_ONLY, uint16_t clock_kHz=0U, bool dblBfr=false, uint8_t maPerLed=LED_MILLIAMPS_DEFAULT, uint16_t maMax=ABL_MILLIAMPS_DEFAULT)
4141
: count(len)
4242
, start(pstart)
4343
, colorOrder(pcolorOrder)
@@ -129,7 +129,7 @@ class Bus {
129129
virtual uint32_t getPixelColor(uint16_t pix) { return 0; }
130130
virtual void setBrightness(uint8_t b) { _bri = b; };
131131
virtual uint8_t getPins(uint8_t* pinArray) { return 0; }
132-
virtual uint16_t getLength() { return _len; }
132+
virtual uint16_t getLength() { return isOk() ? _len : 0; }
133133
virtual void setColorOrder(uint8_t co) {}
134134
virtual uint8_t getColorOrder() { return COL_ORDER_RGB; }
135135
virtual uint8_t skippedLeds() { return 0; }

wled00/const.h

Lines changed: 42 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -46,36 +46,58 @@
4646

4747
#ifndef WLED_MAX_BUSSES
4848
#ifdef ESP8266
49-
#define WLED_MAX_BUSSES 3
49+
#define WLED_MAX_DIGITAL_CHANNELS 3
50+
#define WLED_MAX_ANALOG_CHANNELS 5
51+
#define WLED_MAX_BUSSES 4 // will allow 3 digital & 1 analog RGB
5052
#define WLED_MIN_VIRTUAL_BUSSES 2
5153
#else
5254
#if defined(CONFIG_IDF_TARGET_ESP32C3) // 2 RMT, 6 LEDC, only has 1 I2S but NPB does not support it ATM
53-
#define WLED_MAX_BUSSES 3 // will allow 2 digital & 1 analog (or the other way around)
55+
#define WLED_MAX_BUSSES 4 // will allow 2 digital & 2 analog RGB
56+
#define WLED_MAX_DIGITAL_CHANNELS 2
57+
#define WLED_MAX_ANALOG_CHANNELS 6
5458
#define WLED_MIN_VIRTUAL_BUSSES 3
5559
#elif defined(CONFIG_IDF_TARGET_ESP32S2) // 4 RMT, 8 LEDC, only has 1 I2S bus, supported in NPB
5660
// the 5th bus (I2S) will prevent Audioreactive usermod from functioning (it is last used though)
57-
#define WLED_MAX_BUSSES 7 // will allow 5 digital & 2 analog
61+
#define WLED_MAX_BUSSES 7 // will allow 5 digital & 2 analog RGB
62+
#define WLED_MAX_DIGITAL_CHANNELS 5
63+
#define WLED_MAX_ANALOG_CHANNELS 8
5864
#define WLED_MIN_VIRTUAL_BUSSES 3
5965
#elif defined(CONFIG_IDF_TARGET_ESP32S3) // 4 RMT, 8 LEDC, has 2 I2S but NPB does not support them ATM
60-
#define WLED_MAX_BUSSES 6 // will allow 4 digital & 2 analog
66+
#define WLED_MAX_BUSSES 6 // will allow 4 digital & 2 analog RGB
67+
#define WLED_MAX_DIGITAL_CHANNELS 4
68+
#define WLED_MAX_ANALOG_CHANNELS 8
6169
#define WLED_MIN_VIRTUAL_BUSSES 4
6270
#else
6371
// the last digital bus (I2S0) will prevent Audioreactive usermod from functioning
64-
#define WLED_MAX_BUSSES 17
65-
#define WLED_MIN_VIRTUAL_BUSSES 0
72+
#define WLED_MAX_BUSSES 20 // will allow 17 digital & 3 analog RGB
73+
#define WLED_MAX_DIGITAL_CHANNELS 17
74+
#define WLED_MAX_ANALOG_CHANNELS 10
75+
#define WLED_MIN_VIRTUAL_BUSSES 4
6676
#endif
6777
#endif
6878
#else
6979
#ifdef ESP8266
70-
#if WLED_MAX_BUSES > 5
80+
#if WLED_MAX_BUSSES > 5
7181
#error Maximum number of buses is 5.
7282
#endif
83+
#ifndef WLED_MAX_ANALOG_CHANNELS
84+
#error You must also define WLED_MAX_ANALOG_CHANNELS.
85+
#endif
86+
#ifndef WLED_MAX_DIGITAL_CHANNELS
87+
#error You must also define WLED_MAX_DIGITAL_CHANNELS.
88+
#endif
7389
#define WLED_MIN_VIRTUAL_BUSSES (5-WLED_MAX_BUSSES)
7490
#else
75-
#if WLED_MAX_BUSES > 17
76-
#error Maximum number of buses is 17.
91+
#if WLED_MAX_BUSSES > 20
92+
#error Maximum number of buses is 20.
93+
#endif
94+
#ifndef WLED_MAX_ANALOG_CHANNELS
95+
#error You must also define WLED_MAX_ANALOG_CHANNELS.
96+
#endif
97+
#ifndef WLED_MAX_DIGITAL_CHANNELS
98+
#error You must also define WLED_MAX_DIGITAL_CHANNELS.
7799
#endif
78-
#define WLED_MIN_VIRTUAL_BUSSES (17-WLED_MAX_BUSSES)
100+
#define WLED_MIN_VIRTUAL_BUSSES (20-WLED_MAX_BUSSES)
79101
#endif
80102
#endif
81103

@@ -480,6 +502,16 @@
480502
#endif
481503
#endif
482504

505+
#ifndef LED_MILLIAMPS_DEFAULT
506+
#define LED_MILLIAMPS_DEFAULT 55 // common WS2812B
507+
#else
508+
#if LED_MILLIAMPS_DEFAULT < 1 || LED_MILLIAMPS_DEFAULT > 100
509+
#warning "Unusual LED mA current, overriding with default value."
510+
#undef LED_MILLIAMPS_DEFAULT
511+
#define LED_MILLIAMPS_DEFAULT 55
512+
#endif
513+
#endif
514+
483515
// PWM settings
484516
#ifndef WLED_PWM_FREQ
485517
#ifdef ESP8266

wled00/data/index.js

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2794,8 +2794,9 @@ function getPalettesData(page, callback)
27942794
return res.json();
27952795
})
27962796
.then(json => {
2797+
retry = false;
27972798
palettesData = Object.assign({}, palettesData, json.p);
2798-
if (page < json.m) setTimeout(()=>{ getPalettesData(page + 1, callback); }, 50);
2799+
if (page < json.m) setTimeout(()=>{ getPalettesData(page + 1, callback); }, 75);
27992800
else callback();
28002801
})
28012802
.catch((error)=>{
@@ -2835,7 +2836,8 @@ function search(field, listId = null) {
28352836
if (gId("filters").querySelectorAll("input[type=checkbox]:checked").length) return;
28362837

28372838
// filter list items but leave (Default & Solid) always visible
2838-
gId(listId).querySelectorAll('.lstI').forEach((listItem,i)=>{
2839+
const listItems = gId("fxlist").querySelectorAll('.lstI');
2840+
listItems.forEach((listItem,i)=>{
28392841
if (listId!=='pcont' && i===0) return;
28402842
const listItemName = listItem.querySelector('.lstIname').innerText.toUpperCase();
28412843
const searchIndex = listItemName.indexOf(field.value.toUpperCase());
@@ -3058,7 +3060,7 @@ function size()
30583060

30593061
function togglePcMode(fromB = false)
30603062
{
3061-
let ap = (fromB && !lastinfo) || (lastinfo && lastinfo.wifi && lastinfo.witi.ap);
3063+
let ap = (fromB && !lastinfo) || (lastinfo && lastinfo.wifi && lastinfo.wifi.ap);
30623064
if (fromB) {
30633065
pcModeA = !pcModeA;
30643066
localStorage.setItem('pcm', pcModeA);

0 commit comments

Comments
 (0)