5 #include <freertos/FreeRTOS.h> 6 #include <freertos/stream_buffer.h> 28 size_t read(
void *data,
size_t len, TickType_t ticks_to_wait = 0);
40 size_t write(
void *data,
size_t len);
82 static std::unique_ptr<RingBuffer>
create(
size_t len);
size_t write_without_replacement(void *data, size_t len, TickType_t ticks_to_wait=0)
Writes to the ring buffer without overwriting oldest data.
size_t free() const
Returns the number of free bytes in the ring buffer.
StaticStreamBuffer_t structure_
BaseType_t reset()
Resets the ring buffer, discarding all stored data.
size_t read(void *data, size_t len, TickType_t ticks_to_wait=0)
Reads from the ring buffer, waiting up to a specified number of ticks if necessary.
size_t available() const
Returns the number of available bytes in the ring buffer.
Implementation of SPI Controller mode.
size_t write(void *data, size_t len)
Writes to the ring buffer, overwriting oldest data if necessary.
static std::unique_ptr< RingBuffer > create(size_t len)
StreamBufferHandle_t handle_