|
arduino-snapclient
|
Snap Processor implementation which does not rely on FreeRTOS. More...
#include <SnapProcessor.h>
Public Member Functions | |
| SnapProcessor (SnapOutput &output) | |
| virtual bool | begin () |
| virtual void | doLoop () |
| Call via SnapClient in Arduino Loop! | |
| virtual void | end () |
| tv_t | getLatency () |
| void | setAudioInfo (AudioInfo info) |
| void | setClient (Client &client) |
| Defines an alternative client to the WiFiClient. | |
| void | setDecoder (AudioDecoder &dec) |
| Defines the decoder class. | |
| void | setMacAddress (const char *adr) |
| void | setOutput (AudioOutput &output) |
| Defines the output class. | |
| void | setServerIP (IPAddress address) |
| void | setServerPort (int port) |
| void | setSnapOutput (SnapOutput &out) |
| Defines the SnapOutput implementation. | |
| void | setStartOutput (bool start) |
| void | setStartTask (bool flag) |
| void | setVolumeFactor (float fact) |
| Adjust volume by factor e.g. 1.5. | |
| SnapOutput & | snapOutput () |
| float | volume (void) |
| Provides the volume (in the range of 0.0 to 1.0) | |
Protected Member Functions | |
| bool | audioBegin () |
| void | audioEnd () |
| bool | connectClient () |
| bool | processLoopStep () |
| bool | processMessageCodecHeader () |
| bool | processMessageCodecHeaderExt (codec_type codecType) |
| bool | processMessageCodecHeaderOpus (codec_type codecType) |
| bool | processMessageLoop () |
| bool | processMessageServerSettings () |
| bool | processMessageTime () |
| bool | processMessageWireChunk () |
| bool | readBaseMessage () |
| bool | readData () |
| bool | resizeData () |
| void | setMute (bool flag) |
| void | setVolume (float vol) |
| bool | wireChunk (SnapMessageWireChunk &wire_chunk_message) |
| virtual size_t | writeAudio (const uint8_t *data, size_t size) |
| size_t | writeAudioInfo (SnapAudioHeader &header) |
| bool | writeHallo () |
| bool | writeMessage () |
| bool | writeTimedMessage () |
Protected Attributes | |
| std::vector< int16_t > | audio |
| SnapMessageBase | base_message |
| std::vector< char > | base_message_serialized |
| uint16_t | channels = 2 |
| uint32_t | client_state_muted = 0 |
| codec_type | codec_from_server = NO_CODEC |
| int16_t | frame_size = 512 |
| bool | header_received = false |
| bool | http_task_start = true |
| int | id_counter = 0 |
| bool | is_time_set = false |
| uint64_t | last_time_sync = 0 |
| const char * | mac_address = "00-00-00-00-00" |
| timeval | now |
| bool | output_start = false |
| Client * | p_client = nullptr |
| SnapOutput * | p_snap_output = nullptr |
| std::vector< char > | send_receive_buffer |
| IPAddress | server_ip |
| int | server_port = CONFIG_SNAPCAST_SERVER_PORT |
| int | size = 0 |
| SnapTime & | snap_time = SnapTime::instance() |
| char * | start = nullptr |
| const char * | TAG = "SnapProcessor" |
| SnapMessageTime | time_message |
Snap Processor implementation which does not rely on FreeRTOS.