/WLEDAudioSync-Chataigne-Module

Stream music/audio to WLED Sound Reactive. Real time audio data analysis: volume, FFT, pitch detection etc..

Primary LanguageJavaScriptMIT LicenseMIT

image

WLEDAudioSync Module for Chataigne.

Stream music/audio to WLED Audio reactive.

Real time audio analysis : the real time audio datas are not supposed to be fully accurate but enough for light show creation.

- Send your music from any computer to WLED sound reactive LED.

- Should Work on any OS where Chataigne run ( Win/Mac/Linux/Pi ). 

- You only need to have WLED Sound Reactive version installed. 
  No Hardware( micro: analog or digital) required. 

- Use UDP Multicast, so your LED strip can be anywhere.
  adjustable rate let you choose between bandwidth / reactivity

- Send different message version, to different UDP port with different settings at same time
  thanks to Chataigne's Multiple Instances feature. 
  
- Capture audio datas ( snapshot ) and replay them ( replay ). 

- All WLED Sound Reactive effects supported: volume based or FFT based.

- Real time FFT Analysis fully customisable by GUI
  this provide different way for effects customisation.
  
- Real Time Beat and BPM  via OSC
  thanks to https://github.com/DrLuke/aubio-beat-osc
  
- Real time pitch detection : freq / pitch / note / octave
  thanks to Chataigne...

- Message version 1 (V1) and version 2 (V2) included, so can stream even to ESP8266 

GitHub: https://github.com/benkuper/Chataigne --> min version 1.9.14b11

For beat / BPM see : https://github.com/DrLuke/aubio-beat-osc

Installation :

Manual

Take all from this repository and 
Copy  to <MyDocuments>\chataigne\modules\WLEDAudioSync.

Nota:
You will need additional step for beat / BPM if you want to use this feature. 

Use it :

Open  Chataigne.

Go to Modules, right click, Protocol/Community Modules, WLEDAudioSync.

image

On Inspector:

  Multicast Mode: need to be checked
  IP Address to bind: select the computer IP address if more than one.
  Send Test Message: if more than one network interface and had trouble to send data to MulticastGroup, click on it to send a test message.
  Live : use real time audio data, uncheck when want to use the replay feature.
  Audio V1 : V1 message format
  Audio V2 : V2 message format ( to be used mainly )
  Delay : delay in ms before sending audio data. audio data during delay are lost.
  Volume Multiplier : multiply Chataigne volume audio data before sent
  Frequency Magnitude Multiplier : multiply Chataigne FFT Magnitude data before sent
  Take snapshot : This will take audio datas snapshot and save them to file. Used by the replay feature.
  
  Local : send to local IP (127.0.0.1). This will freeze audio data to send.
  Remote Host : MulticastGroup address
  Remote Port : port number to bind
  
  Use BPM : will create corresponding process for Beat via OSC
    if unchecked and aubio-beat-osc process is running, this will kill it.
  Input audio : audio devices detected by aubio-beat-osc list command 
    the one selected will be used when 'Force reload' clicked.
  Script file : script file name location for OSC module
    use OSCBPM.js under modules folder.
  Force reload : kill (if running) and create a new aubio-beat-osc process.
  
  Update Rate : frequence to send audio data message to WLED (fps)
    set rate from 1 fps to 1000 (for test stress: dangerous), 50 is recommended.
  

image

image

On Command Tester, Replay / FFT : all WLEDAudioSync available commands

    Replay / Snapshot : provide you the possibility to 'replay' audio data from snapshot with defined duration (max 1500 ms).
        The snapshot is not limited to the played effect, you can change settings and/or effect.

image

image

   FFT / WLED : got two choices on how FFT data will be captured. OLD or NEW. 
      / Custom : custom FFT data analysis capture with variable size.

image

image


Let see that on the FFT Analysis Chataigne sound card Module. You can even do any modification you like afterward.

NEW image

OLD image

Custom / size 0.10 image


Audio Configuration (Win)

For audio control, Voicemeeter is one of the best tools : https://voicemeeter.com/

2023-03-24.18-20-57.mp4


Real Time audio analysis

2023-04-08.00-49-54.mp4

***Info ***

This module use WLED Audio Sync feature to send data via UDP / Multicast. Message version 1 & 2 are provided. // On 10/03/2023: Multicast do not work as expected on Chataigne, mainly when more than one network card. Small python utility provided to bind on UDP port on specified IP address and join the MulticastGroup in case of.

On 26/03/2023: for ESP8266, old SR WLED fw version required : 0.3.0b3 https://wled-install.github.io/. Port to the 0.14.xx version is on TO DO list...