Stream Wrapper which can be used to print the values as readable ASCII to the screen to be analyzed in the Serial Plotter The frames are separated by a new line. The channels in one frame are separated by a ,.
More...
#include <AudioOutput.h>
|
| CsvOutput (int buffer_size=DEFAULT_BUFFER_SIZE, bool active=true) |
|
| CsvOutput (Print &out, int channels=2, int buffer_size=DEFAULT_BUFFER_SIZE, bool active=true) |
| Constructor.
|
|
virtual AudioInfo | audioInfo () override |
|
int | availableForWrite () override |
|
bool | begin () override |
| (Re)start (e.g. if channels is set in constructor)
|
|
bool | begin (AudioInfo info) override |
| Starts the processing with the defined number of channels.
|
|
bool | begin (int channels) |
| Starts the processing with the defined number of channels.
|
|
AudioInfo | defaultConfig () |
| Provides the default configuration.
|
|
AudioInfo | defaultConfig (RxTxMode mode) |
|
const char * | delimiter () |
| Provides the current column delimiter.
|
|
virtual void | end () |
|
virtual void | flush () override |
|
virtual bool | isDeletable () |
| If true we need to release the related memory in the destructor.
|
|
| operator bool () |
|
virtual void | setAudioInfo (AudioInfo info) override |
| defines the number of channels
|
|
void | setDelimiter (const char *del) |
| Defines an alternative (column) delimiter. The default is ,.
|
|
virtual void | setNotifyAudioChange (AudioInfoSupport &bi) override |
|
virtual bool | validate (AudioInfo &info) |
|
virtual size_t | write (const uint8_t *data, size_t len) override |
| Writes the data - formatted as CSV - to the output stream.
|
|
virtual size_t | write (uint8_t ch) override |
|
virtual void | writeSilence (size_t len) |
|
|
void | writeFrames (T *data_ptr, int frameCount) |
|
|
AudioInfo | cfg |
|
int | channel = 0 |
|
T * | data_ptr |
|
const char * | delimiter_str = "," |
|
bool | is_active = false |
|
Print * | out_ptr = &Serial |
|
AudioInfoSupport * | p_notify = nullptr |
|
SingleBuffer< uint8_t > | tmp {MAX_SINGLE_CHARS} |
|
int | tmpPos = 0 |
|
template<typename T>
class audio_tools::CsvOutput< T >
Stream Wrapper which can be used to print the values as readable ASCII to the screen to be analyzed in the Serial Plotter The frames are separated by a new line. The channels in one frame are separated by a ,.
- Template Parameters
-
- Author
- Phil Schatzmann
- Copyright
- GPLv3
◆ writeSilence()
virtual void writeSilence |
( |
size_t |
len | ) |
|
|
inlinevirtualinherited |
Writes n 0 values (= silence)
- Parameters
-
The documentation for this class was generated from the following file: