ringbuffer_get

Get one byte from ring buffer, the user needs to handle the concurrent access on buffer via put/get/flush.

int32_t ringbuffer_get(
    struct ringbuffer *const rb,
    uint8_t * data
)

Parameters

rb

Type: struct ringbuffer Struct *const

The pointer to a ring buffer structure instance

data

Type: uint8_t *

One byte space to store the read data

Returns

Type: int32_t

ERR_NONE on success, or an error code on failure.