xRingbufferSendAcquire() function
Acquire memory from the ring buffer to be written to by an external source and to be sent later. Attempt to allocate buffer for an item to be sent into the ring buffer. This function will block until enough free space is available or until it times out. The item, as well as the following items ``SendAcquire`` or ``Send`` after it, will not be able to be read from the ring buffer until this item is actually sent into the ring buffer.
Arguments
xRingbuffer
Ring buffer to allocate the memory
ppvItem
Double pointer to memory acquired (set to NULL if no memory were retrieved)
xItemSize
Size of item to acquire.
xTicksToWait
Ticks to wait for room in the ring buffer.
Return value
- pdTRUE if succeeded - pdFALSE on time-out or when the data is larger than the maximum permissible size of the buffer
Notes
Only applicable for no-split ring buffers now, the actual size of memory that the item will occupy will be rounded up to the nearest 32-bit aligned size. This is done to ensure all items are always stored in 32-bit aligned fashion. An xItemSize of 0 will result in a buffer being acquired, but the buffer will have a size of 0.