Skip to content

Commit f28166b

Browse files
authored
Merge branch 'MoonModules:mdev' into gifplayer-html-MM
2 parents 02fd904 + daa8103 commit f28166b

File tree

4 files changed

+46
-73
lines changed

4 files changed

+46
-73
lines changed

platformio.ini

Lines changed: 37 additions & 66 deletions
Original file line numberDiff line numberDiff line change
@@ -48,19 +48,22 @@
4848
; ===================
4949

5050
default_envs =
51-
esp32_4MB_S ;; experimental, optimized for speed
52-
esp32_4MB_M ;; esp32 recommended default
53-
esp32_4MB_M_eth
54-
esp32_4MB_M_debug
55-
esp32_4MB_XL
56-
; esp32_16MB_S ;; experimental, optimized for speed
57-
esp32_16MB_M ;; esp32 recommended for boards with 16MB flash
58-
esp32_16MB_M_eth
59-
; esp32_16MB_M_debug
60-
; esp32_16MB_XL
61-
esp32_pico_4MB_M
51+
; Netmindz: Disable the non-V4 envs as we only build using V4 now, TBC if we rename thr _V4 to be without and delete existing
52+
; or maintain the _V4 as we have "trained" our users that certain things are _V4 only plus the bootloader issue if you OTA from V3 to a V4
53+
54+
; esp32_4MB_S ;; experimental, optimized for speed
55+
; esp32_4MB_M ;; esp32 recommended default
56+
; esp32_4MB_M_eth
57+
; esp32_4MB_M_debug
58+
; esp32_4MB_XL
59+
; ; esp32_16MB_S ;; experimental, optimized for speed
60+
; esp32_16MB_M ;; esp32 recommended for boards with 16MB flash
61+
; esp32_16MB_M_eth
62+
; ; esp32_16MB_M_debug
63+
; ; esp32_16MB_XL
64+
; esp32_pico_4MB_M
6265
;;
63-
wemos_shield_esp32_4MB_M
66+
; wemos_shield_esp32_4MB_M
6467
; wemos_shield_esp32_4MB_ICS4343x_M
6568
; wemos_shield_esp32_4MB_SPM1423_M
6669
; wemos_shield_esp32_4MB_LineIn_M
@@ -126,11 +129,6 @@ extra_configs =
126129
# arduino core 2.6.3 = platformIO 2.3.2
127130
# arduino core 2.7.0 = platformIO 2.5.0
128131
# ------------------------------------------------------------------------------
129-
arduino_core_2_6_3 = espressif8266@2.3.3
130-
arduino_core_2_7_4 = espressif8266@2.6.2
131-
arduino_core_3_0_0 = espressif8266@3.0.0
132-
arduino_core_3_2_0 = espressif8266@3.2.0
133-
arduino_core_4_1_0 = espressif8266@4.1.0
134132
arduino_core_3_1_2 = espressif8266@4.2.1
135133

136134
# Development platforms
@@ -145,13 +143,6 @@ platform_packages = platformio/toolchain-xtensa @ ~2.100300.220621 #2.40802.2005
145143
platformio/tool-esptool #@ ~1.413.0
146144
platformio/tool-esptoolpy #@ ~1.30000.0
147145

148-
## previous platform for 8266, in case of problems with the new one
149-
## you'll need makuna/NeoPixelBus@ 2.6.9 for arduino_core_3_2_0, which does not support Ucs890x
150-
;; platform_wled_default = ${common.arduino_core_3_2_0}
151-
;; platform_packages = tasmota/framework-arduinoespressif8266 @ 3.20704.7
152-
;; platformio/toolchain-xtensa @ ~2.40802.200502
153-
;; platformio/tool-esptool @ ~1.413.0
154-
;; platformio/tool-esptoolpy @ ~1.30000.0
155146

156147
# ------------------------------------------------------------------------------
157148
# FLAGS: DEBUG
@@ -212,7 +203,7 @@ build_flags =
212203
build_unflags =
213204

214205
build_flags_esp8266 = ${common.build_flags} ${esp8266.build_flags}
215-
build_flags_esp32 = ${common.build_flags} ${esp32.build_flags}
206+
build_flags_esp32 = ${common.build_flags} ${esp32_idf_V4.build_flags}
216207
build_flags_esp32_V4= ${common.build_flags} ${esp32_idf_V4.build_flags}
217208

218209
ldscript_1m128k = eagle.flash.1m128.ld
@@ -303,7 +294,8 @@ build_flags =
303294
; -D PIO_FRAMEWORK_ARDUINO_MMU_CACHE16_IRAM48_SECHEAP_SHARED ;; (experimental) adds some extra heap, but may cause slowdown
304295
-D USERMOD_AUDIOREACTIVE
305296
-D NON32XFER_HANDLER ;; ask forgiveness for PROGMEM misuse
306-
297+
-D WLED_DISABLE_PARTICLESYSTEM2D
298+
307299
lib_deps =
308300
#https://github.com/lorol/LITTLEFS.git
309301
ESPAsyncTCP @ 1.2.2
@@ -332,33 +324,12 @@ platform_packages_compat =
332324
platformio/tool-esptool #@ ~1.413.0
333325
platformio/tool-esptoolpy #@ ~1.30000.0
334326

335-
;; experimental - for using older NeoPixelBus 2.7.9
336-
lib_deps_compat =
337-
ESPAsyncTCP @ 1.2.2
338-
ESPAsyncUDP
339-
ESP8266PWM
340-
fastled/FastLED @ 3.6.0
341-
IRremoteESP8266 @ 2.8.2
342-
makuna/NeoPixelBus @ 2.7.9
343-
https://github.com/Aircoookie/ESPAsyncWebServer.git#v2.4.0
344327

345328

346329
[esp32]
347-
#platform = https://github.com/tasmota/platform-espressif32/releases/download/v2.0.2.3/platform-espressif32-2.0.2.3.zip
348-
platform = espressif32@3.5.0
349-
350-
platform_packages = framework-arduinoespressif32 @ https://github.com/Aircoookie/arduino-esp32.git#1.0.6.4
351-
352-
build_flags = -g
353-
-DARDUINO_ARCH_ESP32
354-
#-DCONFIG_LITTLEFS_FOR_IDF_3_2
355-
-D CONFIG_ASYNC_TCP_USE_WDT=0
356-
-D CONFIG_ASYNC_TCP_TASK_STACK_SIZE=9472 ;; WLEDMM increase stack by 1.25Kb, as audioreactive needs bigger SETTINGS_STACK_BUF_SIZE
357-
#use LITTLEFS library by lorol in ESP32 core 1.x.x instead of built-in in 2.x.x
358-
-D LOROL_LITTLEFS
359-
; -D WLEDMM_TWOPATH ;; use I2S1 as the second bus --> ~15% faster on "V3" builds - may flicker a bit more
360-
; -D WLEDMM_SLOWPATH ;; don't use I2S for LED bus
361-
; -DARDUINO_USB_CDC_ON_BOOT=0 ;; this flag is mandatory for "classic ESP32" when building with arduino-esp32 >=2.0.3
330+
platform = ${esp32_idf_V4.platform}
331+
platform_packages = ${esp32_idf_V4.platform_packages}
332+
build_flags = ${esp32_idf_V4.build_flags}
362333

363334
default_partitions = tools/WLED_ESP32_4MB_1MB_FS.csv ;; WLED standard for 4MB flash: 1.4MB firmware, 1MB filesystem
364335
;default_partitions = tools/WLED_ESP32_4MB_256KB_FS.csv ;; WLEDMM alternative for 4MB flash: 1.8MB firmware, 256KB filesystem (esptool erase_flash needed before changing)
@@ -369,14 +340,7 @@ big_partitions = tools/WLED_ESP32_4MB_256KB_FS.csv ;; 1.8MB firmware, 256KB
369340
large_partitions = tools/WLED_ESP32_8MB.csv
370341
extreme_partitions = tools/WLED_ESP32_16MB_9MB_FS.csv
371342

372-
lib_deps =
373-
https://github.com/pbolduc/AsyncTCP.git @ 1.2.0 ;; WLEDMM this must be first in the list, otherwise Aircoookie/ESPAsyncWebServer pulls in an older version of AsyncTCP !!
374-
; https://github.com/lorol/LITTLEFS.git
375-
; WLEDMM specific: use patched version of lorol LittleFS
376-
https://github.com/softhack007/LITTLEFS-threadsafe.git#master
377-
makuna/NeoPixelBus @ 2.7.5
378-
;; makuna/NeoPixelBus @ 2.7.9 ;; experimental
379-
${env.lib_deps}
343+
lib_deps = ${esp32_idf_V4.lib_deps}
380344

381345
;; Compatibility with upstream --> you should prefer using ${common_mm.build_flags_S} and ${common_mm.lib_deps_S}
382346
AR_build_flags = ${common_mm.AR_build_flags}
@@ -419,9 +383,6 @@ lib_depsV4 =
419383
;; WLEDMM end
420384

421385
[esp32_idf_V4]
422-
;; experimental build environment for ESP32 using ESP-IDF 4.4.x / arduino-esp32 v2.0.5
423-
;; very similar to the normal ESP32 flags, but omitting Lorol LittleFS, as littlefs is included in the new framework already.
424-
;;
425386
;; please note that you can NOT update existing ESP32 installs with a "V4" build. Also updating by OTA will not work properly.
426387
;; You need to completely erase your device (esptool erase_flash) first, then install the "V4" build from VSCode+platformio.
427388

@@ -1616,6 +1577,9 @@ build_flags = ${common.build_flags_esp8266} -D WLED_DISABLE_OTA
16161577
-D WLED_DISABLE_HUESYNC
16171578
-D WLED_DISABLE_ESPNOW ;; exceeds flash size limits
16181579
-D WLED_DISABLE_INFRARED ;; exceeds flash size limits
1580+
-D WLED_DISABLE_PARTICLESYSTEM1D ;; exceeds flash size limit
1581+
-D WLED_DISABLE_PARTICLESYSTEM2D ;; exceeds flash size limit
1582+
16191583
lib_deps = ${esp8266.lib_deps}
16201584
lib_ignore = IRremoteESP8266 ; use with WLED_DISABLE_INFRARED for faster compilation
16211585
; RAM: [====== ] 60.6% (used 49616 bytes from 81920 bytes)
@@ -1646,6 +1610,7 @@ build_flags = ${esp32_4MB_V4_S_base.esp32_build_flags}
16461610
; -D SR_DEBUG
16471611
; -D MIC_LOGGER
16481612
${common_mm.HUB75_build_flags}
1613+
-D WLED_DISABLE_PARTICLESYSTEM1D ;; exceeds flash size limit
16491614
lib_deps = ${esp32_4MB_V4_S_base.esp32_lib_deps}
16501615
${common_mm.HUB75_lib_deps}
16511616
lib_ignore = IRremoteESP8266 ; use with WLED_DISABLE_INFRARED for faster compilation
@@ -2257,6 +2222,8 @@ build_flags = ${common.build_flags} ${esp32s3.build_flags} -Wno-misleading-inden
22572222
; -D WLED_DEBUG
22582223
; -D SR_DEBUG
22592224
; -D MIC_LOGGER
2225+
-D WLED_DISABLE_PARTICLESYSTEM1D ;; exceeds flash size limit
2226+
-D WLED_DISABLE_PARTICLESYSTEM2D ;; exceeds flash size limit
22602227
lib_deps = ${esp32s3.lib_deps} ${common_mm.lib_deps_S} ${common_mm.lib_deps_V4_M}
22612228
lib_ignore =
22622229
IRremoteESP8266 ; use with WLED_DISABLE_INFRARED for faster compilation
@@ -2465,7 +2432,8 @@ build_flags = ${common.build_flags} ${esp32c3.build_flags}
24652432
;-D HW_PIN_SDA=0 -D HW_PIN_SCL=1 ;; for I2C Qwiic connector
24662433
-D SR_DMTYPE=1 -D I2S_SDPIN=5 -D I2S_WSPIN=6 -D I2S_CKPIN=4 -D MCLK_PIN=7
24672434
; -D WLED_USE_MY_CONFIG
2468-
2435+
-D WLED_DISABLE_PARTICLESYSTEM1D ;; exceeds flash size limit
2436+
-D WLED_DISABLE_PARTICLESYSTEM2D ;; exceeds flash size limit
24692437
lib_deps = ${esp32c3.lib_deps} ${common_mm.lib_deps_S} ${common_mm.lib_deps_V4_M}
24702438
lib_ignore =
24712439
;IRremoteESP8266 ; use with WLED_DISABLE_INFRARED for faster compilation
@@ -2489,6 +2457,8 @@ build_flags = ${env:esp32c3dev_4MB_M.build_flags}
24892457
-D WLED_DISABLE_BROWNOUT_DET ;; the board only has a 500mA LDO, better to disable brownout detection
24902458
-D WLED_DISABLE_ADALIGHT ;; to disable serial protocols for boards with CDC USB (Serial RX will receive junk commands, unless its pulled down by resistor)
24912459
-D HW_PIN_SDA=0 -D HW_PIN_SCL=1 ;; avoid pin conflicts
2460+
-D WLED_DISABLE_PARTICLESYSTEM1D ;; exceeds flash size limit
2461+
-D WLED_DISABLE_PARTICLESYSTEM2D ;; exceeds flash size limit
24922462
; RAM: [== ] 24.6% (used 80556 bytes from 327680 bytes)
24932463
; Flash: [==========] 97.3% (used 1530346 bytes from 1572864 bytes)
24942464

@@ -2515,7 +2485,8 @@ build_flags = ${env:esp32c3dev_4MB_M.build_flags}
25152485
-D WLED_DISABLE_BROWNOUT_DET ;; the board only has a 500mA LDO, better to disable brownout detection
25162486
-D WLED_DISABLE_ADALIGHT ;; to disable serial protocols for boards with CDC USB (Serial RX will receive junk commands, unless its pulled down by resistor)
25172487
-D HW_PIN_SDA=0 -D HW_PIN_SCL=1 ;; avoid pin conflicts
2518-
2488+
-D WLED_DISABLE_PARTICLESYSTEM1D ;; exceeds flash size limit
2489+
-D WLED_DISABLE_PARTICLESYSTEM2D ;; exceeds flash size limit
25192490
; RAM: [== ] 24.0% (used 78676 bytes from 327680 bytes)
25202491
; Flash: [==========] 96.4% (used 1516068 bytes from 1572864 bytes)
25212492

@@ -2751,7 +2722,7 @@ build_flags = ${esp32_4MB_S_base.build_flags}
27512722
[env:esp32_pico_4MB_M]
27522723
extends = esp32_4MB_M_base
27532724
board = pico32
2754-
board_build.flash_mode = dout ;; (dout = dual out; more compatible than qio = quad i/o)
2725+
board_build.flash_mode = dio ;; (dout = dual out; more compatible than qio = quad i/o)
27552726
upload_speed = 256000 ;; or 115200 ;; or 460800 ; or 921600 (slower speeds are better when flashing without a soldered connection)
27562727

27572728
build_flags = ${esp32_4MB_M_base.build_flags}
@@ -2841,7 +2812,7 @@ build_flags = ${common.build_flags} ${esp32s3.build_flags} -Wno-misleading-inden
28412812
; Serial debug enabled -DARDUINO_USB_MODE=1 -DARDUINO_USB_CDC_ON_BOOT=1 -DARDUINO_USB_MSC_ON_BOOT=0 -DARDUINO_USB_DFU_ON_BOOT=1 ;; for Hardware-CDC USB mode
28422813
-D ARDUINO_USB_CDC_ON_BOOT=0
28432814
-D WLED_DISABLE_ADALIGHT ;; disables serial protocols - recommended for Hardware-CDC USB (Serial RX will receive junk commands when RX pin is unconnected, unless its pulled down by resistor)
2844-
${common_mm.animartrix_build_flags}
2815+
; ${common_mm.animartrix_build_flags}
28452816
${common_mm.build_disable_sync_interfaces}
28462817
-D LOLIN_WIFI_FIX ;; try this in case Wifi does not work
28472818
-D WLED_WATCHDOG_TIMEOUT=0 -D CONFIG_ASYNC_TCP_USE_WDT=0
@@ -2851,7 +2822,7 @@ build_flags = ${common.build_flags} ${esp32s3.build_flags} -Wno-misleading-inden
28512822
${common_mm.HUB75_build_flags}
28522823
-D DEFAULT_LED_TYPE=101
28532824
lib_deps = ${esp32s3.lib_deps} ${common_mm.lib_deps_S} ;; ;; do not include ${esp32.lib_depsV4} !!!!
2854-
${common_mm.animartrix_lib_deps}
2825+
; ${common_mm.animartrix_lib_deps}
28552826
${common_mm.HUB75_lib_deps}
28562827

28572828
lib_ignore = IRremoteESP8266 ; use with WLED_DISABLE_INFRARED for faster compilation

usermods/BME280_v2/usermod_bme280.h

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,7 @@ class UsermodBME280 : public Usermod
245245
// from the UI and values read from sensor, then publish to broker
246246
if (temperature != lastTemperature || PublishAlways)
247247
{
248-
publishMqtt("temperature", String(temperature, TemperatureDecimals).c_str());
248+
publishMqtt("temperature", String(temperature, (unsigned)TemperatureDecimals).c_str());
249249
}
250250

251251
lastTemperature = temperature; // Update last sensor temperature for next loop
@@ -258,17 +258,17 @@ class UsermodBME280 : public Usermod
258258

259259
if (humidity != lastHumidity || PublishAlways)
260260
{
261-
publishMqtt("humidity", String(humidity, HumidityDecimals).c_str());
261+
publishMqtt("humidity", String(humidity, (unsigned)HumidityDecimals).c_str());
262262
}
263263

264264
if (heatIndex != lastHeatIndex || PublishAlways)
265265
{
266-
publishMqtt("heat_index", String(heatIndex, TemperatureDecimals).c_str());
266+
publishMqtt("heat_index", String(heatIndex, (unsigned)TemperatureDecimals).c_str());
267267
}
268268

269269
if (dewPoint != lastDewPoint || PublishAlways)
270270
{
271-
publishMqtt("dew_point", String(dewPoint, TemperatureDecimals).c_str());
271+
publishMqtt("dew_point", String(dewPoint, (unsigned)TemperatureDecimals).c_str());
272272
}
273273

274274
lastHumidity = humidity;
@@ -285,7 +285,7 @@ class UsermodBME280 : public Usermod
285285

286286
if (pressure != lastPressure || PublishAlways)
287287
{
288-
publishMqtt("pressure", String(pressure, PressureDecimals).c_str());
288+
publishMqtt("pressure", String(pressure, (unsigned)PressureDecimals).c_str());
289289
}
290290

291291
lastPressure = pressure;

wled00/FXparticleSystem.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -590,7 +590,7 @@ void ParticleSystem2D::render() {
590590
}
591591
else {
592592
brightness = min((particles[i].ttl << 1), (int)255);
593-
baseRGB = ColorFromPalette(SEGPALETTE, particles[i].hue, blend);
593+
baseRGB = ColorFromPalette(SEGPALETTE, particles[i].hue, 255, blend);
594594
if (particles[i].sat < 255) {
595595
CHSV baseHSV = rgb2hsv_approximate(baseRGB); // convert to HSV
596596
baseHSV.s = particles[i].sat; // set the saturation
@@ -1452,7 +1452,7 @@ void ParticleSystem1D::render() {
14521452

14531453
// generate RGB values for particle
14541454
brightness = min(particles[i].ttl << 1, (int)255);
1455-
baseRGB = ColorFromPalette(SEGPALETTE, particles[i].hue, blend);
1455+
baseRGB = ColorFromPalette(SEGPALETTE, particles[i].hue, 255, blend);
14561456

14571457
if (advPartProps) { //saturation is advanced property in 1D system
14581458
if (advPartProps[i].sat < 255) {

wled00/data/index.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3326,6 +3326,8 @@ function genPresets()
33263326
}
33273327
addToPlaylist("All", ef.id, "ALL");
33283328
if(ef.name.startsWith("Y💡")) addToPlaylist("AnimARTrix", ef.id, "AM");
3329+
if(ef.name.startsWith("PS ")) addToPlaylist("Particle System", ef.id, "PS");
3330+
33293331
if (m.includes("1")) addToPlaylist("All 1D", ef.id, "1D");
33303332
if (m.includes("2")) addToPlaylist("All 2D", ef.id, "2D");
33313333

0 commit comments

Comments
 (0)