-
-
Notifications
You must be signed in to change notification settings - Fork 4k
Switch to out of tree AudioReactive Usermod #5311
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
0e15bf0
4df67e0
5ad2287
d1aba86
a489170
ea78f51
e8ee8c0
7e4fac8
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -258,6 +258,7 @@ lib_deps = | |
| esp32async/AsyncTCP @ 3.4.7 | ||
| bitbank2/AnimatedGIF@^1.4.7 | ||
| https://github.com/Aircoookie/GifDecoder.git#bc3af189b6b1e06946569f6b4287f0b79a860f8e | ||
| ${esp32.AR_lib_deps} | ||
| build_flags = | ||
| -D CONFIG_ASYNC_TCP_USE_WDT=0 | ||
| -D CONFIG_ASYNC_TCP_STACK_SIZE=8192 | ||
|
|
@@ -280,7 +281,7 @@ extreme_partitions = tools/WLED_ESP32_16MB_9MB_FS.csv | |
| board_build.partitions = ${esp32.default_partitions} ;; default partioning for 4MB Flash - can be overridden in build envs | ||
| # additional build flags for audioreactive - must be applied globally | ||
| AR_build_flags = ;; -fsingle-precision-constant ;; forces ArduinoFFT to use float math (2x faster) | ||
| AR_lib_deps = ;; for pre-usermod-library platformio_override compatibility | ||
| AR_lib_deps = wled-audioreactive = https://github.com/MoonModules/WLED-AudioReactive-Usermod | ||
|
|
||
|
|
||
| [esp32_idf_V4] | ||
|
|
@@ -391,7 +392,7 @@ extends = env:nodemcuv2 | |
| board_build.f_cpu = 160000000L | ||
| build_flags = ${common.build_flags} ${esp8266.build_flags} -D WLED_RELEASE_NAME=\"ESP8266_160\" #-DWLED_DISABLE_2D | ||
| -D WLED_DISABLE_PARTICLESYSTEM2D | ||
| custom_usermods = audioreactive | ||
| custom_usermods = | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧩 Analysis chain🏁 Script executed: #!/bin/bash
# Check if there are any references to the audioreactive usermod in the codebase
# that might break without the in-tree version
echo "=== Searching for references to audioreactive in source files ==="
rg -i "audioreactive" --type cpp --type c --type h -C 2 || echo "No references found"
echo -e "\n=== Checking for audio-related configurations that might depend on the usermod ==="
rg -i "USERMOD.*AUDIO|AUDIO.*USERMOD" --type cpp --type c --type h -C 2 || echo "No config references found"
echo -e "\n=== Looking for example platformio_override.ini configurations ==="
fd -type f \( -name "*platformio*override*" -o -name "*example*" \) | head -20Repository: wled/WLED Length of output: 11506 🏁 Script executed: #!/bin/bash
# Check the platformio.ini file around the mentioned lines
echo "=== Checking platformio.ini around line 395 ==="
sed -n '390,400p' platformio.ini
echo -e "\n=== Checking other mentioned lines ==="
for line_num in 423 453 460 479 495 512 527 564 586 607 648 668; do
echo "Line $line_num:"
sed -n "${line_num}p" platformio.ini
done
echo -e "\n=== Checking if any environment has 'audioreactive' in custom_usermods ==="
rg "custom_usermods.*audioreactive" platformio.ini -i
echo -e "\n=== Checking for migration guides or documentation files ==="
fd -type f \( -name "*.md" -o -name "*.txt" -o -name "CHANGELOG*" \) | xargs grep -l "audioreactive\|migration" -i 2>/dev/null | head -10Repository: wled/WLED Length of output: 1188 🏁 Script executed: #!/bin/bash
# Check git history to see if these lines changed
echo "=== Checking git diff/log for platformio.ini changes ==="
git log --oneline platformio.ini | head -5
echo -e "\n=== Checking for recent changes to custom_usermods ==="
git log -p --follow -S "custom_usermods" platformio.ini | head -100
echo -e "\n=== Searching for README or documentation files ==="
find . -maxdepth 2 -type f \( -name "README*" -o -name "CHANGELOG*" -o -name "*.md" \) | head -20
echo -e "\n=== Checking for audioreactive documentation ==="
find . -type f -name "*.md" -exec grep -l "audioreactive\|AudioReactive" {} \; 2>/dev/null | head -10
echo -e "\n=== Looking for example/sample platformio configurations ==="
find . -type f -name "*platformio*" | grep -v ".git"Repository: wled/WLED Length of output: 1230 🏁 Script executed: #!/bin/bash
# Check CHANGELOG for AudioReactive mentions
echo "=== Checking CHANGELOG for AudioReactive mentions ==="
grep -A 5 -B 5 -i "audioreactive" CHANGELOG.md | head -50
echo -e "\n=== Checking platformio_override.usermods.ini ==="
cat ./usermods/platformio_override.usermods.ini
echo -e "\n=== Checking platformio_override.sample.ini ==="
cat ./platformio_override.sample.ini
echo -e "\n=== Checking if env:usermods exists and its custom_usermods setting ==="
grep -A 10 "\[env:usermods\]" platformio.iniRepository: wled/WLED Length of output: 29853 Document the breaking change for AudioReactive usermod users. Setting Consider:
🤖 Prompt for AI Agents
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It is not being removed, rather it's using the ability to reference out-of-tree usermods so wled-audioreactive being added as a library instead means that it is still included. We might look to rename custom_usermods to something like custom_usermods_enabled to help clarify this relates to in-tree mods. Do you have any other suggestions for naming?
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Regarding naming suggestions for clarifying that More explicit about scope:
Emphasizing the "enabled" aspect (your suggestion):
Following existing PlatformIO patterns:
My recommendation would be
Alternatively, ✏️ Learnings added
🧠 Learnings used
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @coderabbitai unfortunately, I think it may be a platformio restriction that we must name our value with custom_ as the prefix
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧩 Analysis chain🌐 Web query: 💡 Result: PlatformIO has two different “custom variable” concepts, with different naming rules: 1) Custom configuration options in
|
||
|
|
||
| [env:esp8266_2m] | ||
| board = esp_wroom_02 | ||
|
|
@@ -419,7 +420,7 @@ board_build.f_cpu = 160000000L | |
| build_flags = ${common.build_flags} ${esp8266.build_flags} -D WLED_RELEASE_NAME=\"ESP02_160\" | ||
| -D WLED_DISABLE_PARTICLESYSTEM1D | ||
| -D WLED_DISABLE_PARTICLESYSTEM2D | ||
| custom_usermods = audioreactive | ||
| custom_usermods = | ||
|
|
||
| [env:esp01_1m_full] | ||
| board = esp01_1m | ||
|
|
@@ -449,14 +450,14 @@ build_flags = ${common.build_flags} ${esp8266.build_flags} -D WLED_RELEASE_NAME= | |
| ; -D WLED_USE_REAL_MATH ;; may fix wrong sunset/sunrise times, at the cost of 7064 bytes FLASH and 975 bytes RAM | ||
| -D WLED_DISABLE_PARTICLESYSTEM1D | ||
| -D WLED_DISABLE_PARTICLESYSTEM2D | ||
| custom_usermods = audioreactive | ||
| custom_usermods = | ||
|
|
||
| [env:esp32dev] | ||
| board = esp32dev | ||
| platform = ${esp32_idf_V4.platform} | ||
| platform_packages = ${esp32_idf_V4.platform_packages} | ||
| build_unflags = ${common.build_unflags} | ||
| custom_usermods = audioreactive | ||
| custom_usermods = | ||
| build_flags = ${common.build_flags} ${esp32_idf_V4.build_flags} -D WLED_RELEASE_NAME=\"ESP32\" #-D WLED_DISABLE_BROWNOUT_DET | ||
| -DARDUINO_USB_CDC_ON_BOOT=0 ;; this flag is mandatory for "classic ESP32" when building with arduino-esp32 >=2.0.3 | ||
| lib_deps = ${esp32_idf_V4.lib_deps} | ||
|
|
@@ -475,7 +476,7 @@ build_flags = ${common.build_flags} ${esp32_idf_V4.build_flags} | |
| board = esp32dev | ||
| platform = ${esp32_idf_V4.platform} | ||
| platform_packages = ${esp32_idf_V4.platform_packages} | ||
| custom_usermods = audioreactive | ||
| custom_usermods = | ||
| build_unflags = ${common.build_unflags} | ||
| build_flags = ${common.build_flags} ${esp32_idf_V4.build_flags} -D WLED_RELEASE_NAME=\"ESP32_8M\" #-D WLED_DISABLE_BROWNOUT_DET | ||
| -DARDUINO_USB_CDC_ON_BOOT=0 ;; this flag is mandatory for "classic ESP32" when building with arduino-esp32 >=2.0.3 | ||
|
|
@@ -491,7 +492,7 @@ board_build.flash_mode = dio | |
| board = esp32dev | ||
| platform = ${esp32_idf_V4.platform} | ||
| platform_packages = ${esp32_idf_V4.platform_packages} | ||
| custom_usermods = audioreactive | ||
| custom_usermods = | ||
| build_unflags = ${common.build_unflags} | ||
| build_flags = ${common.build_flags} ${esp32_idf_V4.build_flags} -D WLED_RELEASE_NAME=\"ESP32_16M\" #-D WLED_DISABLE_BROWNOUT_DET | ||
| -DARDUINO_USB_CDC_ON_BOOT=0 ;; this flag is mandatory for "classic ESP32" when building with arduino-esp32 >=2.0.3 | ||
|
|
@@ -508,7 +509,7 @@ board = esp32-poe | |
| platform = ${esp32_idf_V4.platform} | ||
| platform_packages = ${esp32_idf_V4.platform_packages} | ||
| upload_speed = 921600 | ||
| custom_usermods = audioreactive | ||
| custom_usermods = | ||
| build_unflags = ${common.build_unflags} | ||
| build_flags = ${common.build_flags} ${esp32.build_flags} -D WLED_RELEASE_NAME=\"ESP32_Ethernet\" -D RLYPIN=-1 -D WLED_USE_ETHERNET -D BTNPIN=-1 | ||
| -DARDUINO_USB_CDC_ON_BOOT=0 ;; this flag is mandatory for "classic ESP32" when building with arduino-esp32 >=2.0.3 | ||
|
|
@@ -523,7 +524,7 @@ board = ttgo-t7-v14-mini32 | |
| board_build.f_flash = 80000000L | ||
| board_build.flash_mode = qio | ||
| board_build.partitions = ${esp32.extended_partitions} | ||
| custom_usermods = audioreactive | ||
| custom_usermods = | ||
| build_unflags = ${common.build_unflags} | ||
| build_flags = ${common.build_flags} ${esp32_idf_V4.build_flags} -D WLED_RELEASE_NAME=\"ESP32_WROVER\" | ||
| -DARDUINO_USB_CDC_ON_BOOT=0 ;; this flag is mandatory for "classic ESP32" when building with arduino-esp32 >=2.0.3 | ||
|
|
@@ -560,7 +561,7 @@ board_build.arduino.memory_type = qio_opi ;; use with PSRAM: 8MB or 16MB | |
| platform = ${esp32s3.platform} | ||
| platform_packages = ${esp32s3.platform_packages} | ||
| upload_speed = 921600 | ||
| custom_usermods = audioreactive | ||
| custom_usermods = | ||
| build_unflags = ${common.build_unflags} | ||
| build_flags = ${common.build_flags} ${esp32s3.build_flags} -D WLED_RELEASE_NAME=\"ESP32-S3_16MB_opi\" | ||
| -D WLED_WATCHDOG_TIMEOUT=0 | ||
|
|
@@ -582,7 +583,7 @@ board_build.arduino.memory_type = qio_opi ;; use with PSRAM: 8MB or 16MB | |
| platform = ${esp32s3.platform} | ||
| platform_packages = ${esp32s3.platform_packages} | ||
| upload_speed = 921600 | ||
| custom_usermods = audioreactive | ||
| custom_usermods = | ||
| build_unflags = ${common.build_unflags} | ||
| build_flags = ${common.build_flags} ${esp32s3.build_flags} -D WLED_RELEASE_NAME=\"ESP32-S3_8MB_opi\" | ||
| -D WLED_WATCHDOG_TIMEOUT=0 | ||
|
|
@@ -603,7 +604,7 @@ platform_packages = ${esp32s3.platform_packages} | |
| board = esp32s3camlcd ;; this is the only standard board with "opi_opi" | ||
| board_build.arduino.memory_type = opi_opi | ||
| upload_speed = 921600 | ||
| custom_usermods = audioreactive | ||
| custom_usermods = | ||
| build_unflags = ${common.build_unflags} | ||
| build_flags = ${common.build_flags} ${esp32s3.build_flags} -D WLED_RELEASE_NAME=\"ESP32-S3_WROOM-2\" | ||
| -D WLED_WATCHDOG_TIMEOUT=0 | ||
|
|
@@ -644,7 +645,7 @@ board = lolin_s3_mini ;; -S3 mini, 4MB flash 2MB PSRAM | |
| platform = ${esp32s3.platform} | ||
| platform_packages = ${esp32s3.platform_packages} | ||
| upload_speed = 921600 | ||
| custom_usermods = audioreactive | ||
| custom_usermods = | ||
| build_unflags = ${common.build_unflags} | ||
| build_flags = ${common.build_flags} ${esp32s3.build_flags} -D WLED_RELEASE_NAME=\"ESP32-S3_4M_qspi\" | ||
| -DARDUINO_USB_CDC_ON_BOOT=1 ;; -DARDUINO_USB_MODE=1 ;; for boards with USB-OTG connector only (USBCDC or "TinyUSB") | ||
|
|
@@ -664,7 +665,7 @@ board = lolin_s2_mini | |
| board_build.partitions = ${esp32.default_partitions} | ||
| board_build.flash_mode = qio | ||
| board_build.f_flash = 80000000L | ||
| custom_usermods = audioreactive | ||
| custom_usermods = | ||
| build_unflags = ${common.build_unflags} | ||
| build_flags = ${common.build_flags} ${esp32s2.build_flags} -D WLED_RELEASE_NAME=\"ESP32-S2\" | ||
| -DARDUINO_USB_CDC_ON_BOOT=1 | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧩 Analysis chain
🏁 Script executed:
Repository: wled/WLED
Length of output: 67
🌐 Web query:
WLED-AudioReactive-Usermod GitHub releases versions MoonModules💡 Result:
MoonModules (WLED-MM) releases (GitHub Releases):
Citations:
🏁 Script executed:
Repository: wled/WLED
Length of output: 2421
🏁 Script executed:
Repository: wled/WLED
Length of output: 4387
Specify a commit hash or branch for the AudioReactive library to match the version pinning pattern used throughout platformio.ini.
All other dependencies in this file pin to specific versions, commits, or tags (e.g.,
fastled/FastLED @ 3.6.0,https://github.com/Aircoookie/GifDecoder.git#bc3af189b6b1e06946569f6b4287f0b79a860f8e). The AR_lib_deps lacks any pinning, making builds non-reproducible and inconsistent with the file's standards.Example with commit hash
(Also remove the extra space after the first
=.)🤖 Prompt for AI Agents
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@netmindz, that makes perfect sense! During parallel development when both repositories are evolving together, pinning to a specific commit would indeed create unnecessary friction and make testing difficult.For the active development phase, keeping the dependency unpinned is the pragmatic approach. However, I'd recommend pinning to a specific commit hash before this PR is merged to
main—that way, the release builds remain reproducible and users get a tested, stable version of the AudioReactive usermod.Feel free to update the pinning when you're ready to finalize the PR. Thanks for the clarification! 👍
🧠 Learnings used
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@coderabbitai Yes you are correct, this is the pattern we use, however this PR is going side by side with the creation of that repo, so we don't want to keep updating this PR after every commit to the usermod, as the only way to test the usermod is through it's usage here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@netmindz, understood! I see you're confirming the parallel development approach. That makes complete sense for your current workflow—keeping it unpinned allows you to iterate freely while both repositories evolve together.As mentioned earlier, feel free to pin to a specific commit when you're ready to finalize before merging to
main. No action needed for now. 👍🧠 Learnings used