* mic quality: When set to "low noise" or "perfect", only minimal smoothing is performed on the "Mic Volume" input.
Every filter adds a delay, so this option can lead to better on-spot responses from effects.
* cleanup: removed a few unused variables and unused code.
* introducing sliding window FFT, which effectively doubles the rate of samples - and FFT results - produced per second. As a side-effect, it also makes FFT a bit less noisy.
As sliding window FFT requires double the number of FFT runs, the feature is only enabled on esp32 and esp32-S3.
the JS string can be shortened, by putting the usermod into a variable `ux` that is used instead of repeating the string 'Aduioreactive'.
For now its just an experiment, to see if the idea works on several browsers.
* use last remaining two bytes in audioSyncPacket for transmitting soundPressure
* 0x0 is treated as "legacy value" --> soundPressure = volumeSmth;
* decodeAudioData: ensure receivedPacket struct members are correctly aligned -
strictly speaking it is not safe to cast a uint8_t* as it does not offer any alignment guarantees.
* remove 8266 special handling in audioreactive::setup()
Please note that these statements are included for clarification purposes only.
WLED-MM specific source code is always provided under GPLv3, see LICENSE.
* added ESP_INTR_FLAG_IRAM to reduce lost samples (only on ESP32 without PSRAM) --> may cause crash if used wrongly
* FFT_MajorPeak stabilized, by ignoring extreme results
* adding suspendPlaylist() to playlist engine code
* autoplaylist usermod calls suspendPlaylist() before switching to another preset
* fix a potential overflow on `lfc` (uint8_t -> uint16_t)
fftResult[] is indended to look good on GEQ, and has a very "twisted" representation of FFT results only. This change improves reconstruction of signal energy, by on-doing some of the "GEQ enhancements" in fftResults[].
fixing mis-optimized math when calculating energy.
energy = sum(amplitude^2). this is not the same as sum(amplitude)^2.
Example:
1+5+7 = 13; 13 * 13 = 169
1*1 + 5*5 + 7*7 = 75
* initialize slow and fast filters with current values (first call only) - reduces time for filter stabilization
* use slightly optimized variant of "rolling average" filter (result is exactly the same)
--> replaced `xX = xX * (1-a) + newX * a;` by `xX = xX + a * (newX - Xx);`
* use constants for filter parameters (for tinkering and improved readability)