Firmware SDK
twr_queue

Queue handling functions. More...

Functions

void twr_queue_init (twr_queue_t *queue, void *buffer, size_t size)
 Initialize queue. More...
 
bool twr_queue_put (twr_queue_t *queue, const void *buffer, size_t length)
 Put buffer to queue. More...
 
bool twr_queue_get (twr_queue_t *queue, void *buffer, size_t *length)
 Get queue to buffer. More...
 

Detailed Description

Queue handling functions.

Function Documentation

◆ twr_queue_get()

bool twr_queue_get ( twr_queue_t *  queue,
void *  buffer,
size_t *  length 
)

Get queue to buffer.

Parameters
[in]queueInstance
[in]bufferBuffer to be copied from the queue
[in]lengthLength of buffer
Returns
true On success
false On failure

Definition at line 45 of file twr_queue.c.

◆ twr_queue_init()

void twr_queue_init ( twr_queue_t *  queue,
void *  buffer,
size_t  size 
)

Initialize queue.

Parameters
[in]queueInstance
[in]bufferBuffer to store the queue
[in]sizeBuffer size

Definition at line 3 of file twr_queue.c.

Referenced by twr_radio_init().

Here is the caller graph for this function:

◆ twr_queue_put()

bool twr_queue_put ( twr_queue_t *  queue,
const void *  buffer,
size_t  length 
)

Put buffer to queue.

Parameters
[in]queueInstance
[in]bufferBuffer to be copied to queue
[in]lengthLength of buffer
Returns
true On success
false On failure

Definition at line 11 of file twr_queue.c.