arduino-audio-tools
|
#include <LEDOutput.h>
Public Member Functions | |
LEDOutput (AudioFFTBase &fft) | |
Default Constructor. More... | |
LEDOutput (VolumePrint &vol) | |
void | addEmptyColumn () |
Adds an empty column to the end shifting the content to the left. | |
bool | begin (LEDOutputConfig config) |
Setup Led matrix. | |
LEDOutputConfig & | config () |
LEDOutputConfig | defaultConfig () |
Provides the default config object. | |
virtual float | getMagnitude (int x) |
virtual float | getMaxMagnitude () |
Provodes the max magnitude. | |
CRGB & | led (uint8_t index) |
Determine the led with the help of the index pos. | |
int | ledCount () |
Provides the number of LEDs: call begin() first! | |
CRGB * | ledData () |
Provides the address fo the CRGB array: call begin() first! | |
CRGB & | ledXY (uint8_t x, uint8_t y) |
Determine the led with the help of the x and y pos. | |
virtual void | update () |
Updates the display: call this method in your loop. | |
void | updateColumn (int currY) |
Update the last column with the indicated bar. | |
void | updateColumn (int x, int currY) |
Update the indicated column with the indicated bar. | |
Protected Member Functions | |
uint16_t | xy (uint8_t x, uint8_t y) |
Static Protected Member Functions | |
static void | fftCallback (AudioFFTBase &fft) |
callback method which provides updated data from fft | |
Protected Attributes | |
LEDOutputConfig | cfg |
uint64_t | count = 0 |
Vector< CRGB > | leds {0} |
Vector< float > | magnitudes {0} |
CRGB | not_valid |
AudioFFTBase * | p_fft = nullptr |
VolumePrint * | p_vol = nullptr |
Friends | |
class | AudioFFTBase |
LEDOutput using the FastLED library. You write the data to the FFT Stream. This displays the result of the FFT to a LED matrix.
|
inline |
Default Constructor.
fft |
|
inline |
Provides access to the actual config object. E.g. to change the update logic
|
inlinevirtual |
Returns the magnitude for the indicated led x position. We might need to combine values from the magnitudes array if this is much bigger.