From 4316024dc73a1f369dda1032ffc7c3db9015978f Mon Sep 17 00:00:00 2001 From: wled-install <96419931+wled-install@users.noreply.github.com> Date: Tue, 30 Jan 2024 22:51:18 +0100 Subject: [PATCH 1/5] Update audio_reactive.h --- usermods/audioreactive/audio_reactive.h | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/usermods/audioreactive/audio_reactive.h b/usermods/audioreactive/audio_reactive.h index 4725c097ca..8787b9980e 100644 --- a/usermods/audioreactive/audio_reactive.h +++ b/usermods/audioreactive/audio_reactive.h @@ -73,7 +73,11 @@ static uint8_t audioSyncEnabled = 0; // bit field: bit 0 - send, bit 1 static bool udpSyncConnected = false; // UDP connection status -> true if connected to multicast group // user settable parameters for limitSoundDynamics() -static bool limiterOn = true; // bool: enable / disable dynamics limiter +#ifdef UM_AUDIOREACTIVE_RISE_FALL_LIMITER_OFF +static bool limiterOn = false; // bool: enable / disable dynamics limiter +#else +static bool limiterOn = true; +#endif static uint16_t attackTime = 80; // int: attack time in milliseconds. Default 0.08sec static uint16_t decayTime = 1400; // int: decay time in milliseconds. Default 1.40sec // user settable options for FFTResult scaling @@ -612,7 +616,12 @@ class AudioReactive : public Usermod { }; // set your config variables to their boot default value (this can also be done in readFromConfig() or a constructor if you prefer) + #ifdef UM_AUDIOREACTIVE_ENABLE + bool enabled = true; + #else bool enabled = false; + #endif + bool initDone = false; // variables for UDP sound sync From f1c27e1798b630981ff38db1a25ccfead6f3236e Mon Sep 17 00:00:00 2001 From: wled-install <96419931+wled-install@users.noreply.github.com> Date: Tue, 30 Jan 2024 22:56:09 +0100 Subject: [PATCH 2/5] Update readme.md --- usermods/audioreactive/readme.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/usermods/audioreactive/readme.md b/usermods/audioreactive/readme.md index 1dd5f5d9cf..fefbf4d3b1 100644 --- a/usermods/audioreactive/readme.md +++ b/usermods/audioreactive/readme.md @@ -55,6 +55,11 @@ If you want to define default GPIOs during compile time, use the following (defa - `-D ES7243_SDAPIN` : GPIO for I2C SDA pin on ES7243 microphone (-1) - `-D ES7243_SCLPIN` : GPIO for I2C SCL pin on ES7243 microphone (-1) +Other options: + +- `-D UM_AUDIOREACTIVE_ENABLE` : makes msermod default enabled +- `-D UM_AUDIOREACTIVE_RISE_FALL_LIMITER_OFF` : disables rise/fall limiter default + **NOTE** I2S is used for analog audio sampling. Hence, the analog *buttons* (i.e. potentiometers) are disabled when running this usermod with an analog microphone. ### Advanced Compile-Time Options From 345346315abdb76675528f27011bbc3349e20115 Mon Sep 17 00:00:00 2001 From: wled-install <96419931+wled-install@users.noreply.github.com> Date: Tue, 30 Jan 2024 22:59:29 +0100 Subject: [PATCH 3/5] Update readme.md --- usermods/audioreactive/readme.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/usermods/audioreactive/readme.md b/usermods/audioreactive/readme.md index fefbf4d3b1..09bfc483e9 100644 --- a/usermods/audioreactive/readme.md +++ b/usermods/audioreactive/readme.md @@ -57,7 +57,7 @@ If you want to define default GPIOs during compile time, use the following (defa Other options: -- `-D UM_AUDIOREACTIVE_ENABLE` : makes msermod default enabled +- `-D UM_AUDIOREACTIVE_ENABLE` : makes usermod default enabled (not the same as include into build option!) - `-D UM_AUDIOREACTIVE_RISE_FALL_LIMITER_OFF` : disables rise/fall limiter default **NOTE** I2S is used for analog audio sampling. Hence, the analog *buttons* (i.e. potentiometers) are disabled when running this usermod with an analog microphone. From 89f8b6060f5966bc046acfffd1da033fc10f41e0 Mon Sep 17 00:00:00 2001 From: wled-install <96419931+wled-install@users.noreply.github.com> Date: Wed, 31 Jan 2024 06:33:48 +0100 Subject: [PATCH 4/5] Update readme.md --- usermods/audioreactive/readme.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/usermods/audioreactive/readme.md b/usermods/audioreactive/readme.md index 09bfc483e9..47804b611f 100644 --- a/usermods/audioreactive/readme.md +++ b/usermods/audioreactive/readme.md @@ -58,7 +58,7 @@ If you want to define default GPIOs during compile time, use the following (defa Other options: - `-D UM_AUDIOREACTIVE_ENABLE` : makes usermod default enabled (not the same as include into build option!) -- `-D UM_AUDIOREACTIVE_RISE_FALL_LIMITER_OFF` : disables rise/fall limiter default +- `-D UM_AUDIOREACTIVE_DYNAMICS_LIMITER_OFF` : disables rise/fall limiter default **NOTE** I2S is used for analog audio sampling. Hence, the analog *buttons* (i.e. potentiometers) are disabled when running this usermod with an analog microphone. From 917a98109663ee21c17dd651b01442e4e77e4751 Mon Sep 17 00:00:00 2001 From: wled-install <96419931+wled-install@users.noreply.github.com> Date: Wed, 31 Jan 2024 06:34:15 +0100 Subject: [PATCH 5/5] Update audio_reactive.h --- usermods/audioreactive/audio_reactive.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/usermods/audioreactive/audio_reactive.h b/usermods/audioreactive/audio_reactive.h index 8787b9980e..fec0525ec7 100644 --- a/usermods/audioreactive/audio_reactive.h +++ b/usermods/audioreactive/audio_reactive.h @@ -73,7 +73,7 @@ static uint8_t audioSyncEnabled = 0; // bit field: bit 0 - send, bit 1 static bool udpSyncConnected = false; // UDP connection status -> true if connected to multicast group // user settable parameters for limitSoundDynamics() -#ifdef UM_AUDIOREACTIVE_RISE_FALL_LIMITER_OFF +#ifdef UM_AUDIOREACTIVE_DYNAMICS_LIMITER_OFF static bool limiterOn = false; // bool: enable / disable dynamics limiter #else static bool limiterOn = true;