62 msg_t *mb_buf,
const cnt_t mb_size);
uint8_t msg[10]
Buffer used for general comunication over SPI (out buffer)
const char * msgqueue_strerror(const MsgQueueStatus errno)
debug api
bool msgqueue_is_empty(MsgQueue *que)
test if queue is empty
int32_t msgqueue_pop_timeout(MsgQueue *que, void **msgPtr, const systime_t timout)
receive message specifying timeout
int32_t msgqueue_send(MsgQueue *que, void *msg, const uint16_t msgLen, const MsgQueueUrgency urgency)
send a buffer previously allocated by msgqueue_malloc_before_send
int32_t msgqueue_pop(MsgQueue *que, void **msgPtr)
wait then receive message
bool msgqueue_is_full(MsgQueue *que)
test if queue is full
void msgqueue_init(MsgQueue *que, tlsf_memory_heap_t *heap, msg_t *mb_buf, const cnt_t mb_size)
initialise MsgQueue
int32_t msgqueue_send_timeout(MsgQueue *que, void *msg, const uint16_t msgLen, const MsgQueueUrgency urgency, const systime_t timout)
send a buffer previously allocated by msgqueue_malloc_before_send
int32_t msgqueue_copy_send_timeout(MsgQueue *que, const void *msg, const uint16_t msgLen, const MsgQueueUrgency urgency, const systime_t timout)
send a buffer NOT previously allocated
int32_t msgqueue_copy_send(MsgQueue *que, const void *msg, const uint16_t msgLen, const MsgQueueUrgency urgency)
send a buffer NOT previously allocated
tlsf_memory_heap_t * heap
@ MsgQueue_MAILBOX_TIMEOUT
@ MsgQueue_MAILBOX_NOT_EMPTY
Dynamic memory allocation based on TLSF library.
unsigned short uint16_t
Typedef defining 16 bit unsigned short type.
int int32_t
Typedef defining 32 bit int type.