|
|
3 minggu lalu | |
|---|---|---|
| Dockerfile | 3 minggu lalu | |
| README.md | 3 minggu lalu | |
| bridge.py | 3 minggu lalu | |
| docker-compose.yml | 3 minggu lalu |
A containerized audio bridge that connects Lyrion Music Server (LMS) directly to WLED instances over UDP multicast for synchronized, sound-reactive LED lighting.
Instead of relying on physical I2S or analog microphones wired to microcontrollers—which suffer from room noise, drywall acoustics, and gain clipping—this bridge taps directly into the digital audio stream, calculates real-time FFT spectrum analysis on the host machine, and broadcasts native WLED AudioReactive sync packets across your local network.
239.0.0.1:11988), where any number of ESP8266 or ESP32 devices can consume it simultaneously.AudioReactive usermod enabled).The bridge is configured using standard environment variables passed into the container:
| Variable | Default | Description |
|---|---|---|
LMS_IP |
127.0.0.1 |
IP address of your LMS / Lyrion server. |
PLAYER_NAME |
WLED-Audio-Sync |
Name of the virtual audio player inside LMS. |
PLAYER_MAC |
02:00:00:11:98:88 |
Unique virtual MAC address for Squeezelite. |
FREQ_MIN |
100.0 |
Lower bound frequency (Hz) for Band 0. |
FREQ_MAX |
8000.0 |
Upper bound frequency (Hz) for Band 15. |
GAIN_MULT |
3500.0 |
Visual sensitivity multiplier for FFT bands. |
SILENCE_THRESHOLD |
0.5 |
Peak threshold (0–255 scale) below which the stream is gated. |
UDP_IP |
239.0.0.1 |
Multicast group IP for WLED AudioReactive. |
UDP_PORT |
11988 |
Target UDP port for WLED AudioReactive sync. |
Clone this repository and start the stack:
docker compose up -d
On each WLED instance, open the web UI and go to Config > Usermods > AudioReactive:
None / Generic I2S (Disabled) (disables hardware mic polling).None (logarithmic scaling is handled by the bridge).Off.40–60 ms and Fall to 400–600 ms for snappy visuals.Receive.11988.Save and power-cycle your microcontroller.
Open the LMS web interface and synchronize the new WLED-Audio-Sync player with your active music zone. Any track playing in that zone will now stream reactive lighting effects in real time.
00002 header).network_mode: host) so multicast traffic traverses directly onto the local subnet without being blocked by Docker NAT bridges.MIT License. Feel free to modify, distribute, and integrate into your home automation setups.