Function esp_idf_svc::sys::xRingbufferReceiveFromISR
source ยท pub unsafe extern "C" fn xRingbufferReceiveFromISR(
xRingbuffer: *mut c_void,
pxItemSize: *mut usize,
) -> *mut c_void
Expand description
@brief Retrieve an item from the ring buffer in an ISR
Attempt to retrieve an item from the ring buffer. This function returns immediately if there are no items available for retrieval
@param[in] xRingbuffer Ring buffer to retrieve the item from @param[out] pxItemSize Pointer to a variable to which the size of the retrieved item will be written.
@note A call to vRingbufferReturnItemFromISR() is required after this to free the item retrieved. @note Byte buffers do not allow multiple retrievals before returning an item @note Two calls to RingbufferReceiveFromISR() are required if the bytes wrap around the end of the ring buffer. @note It is possible to receive items with a pxItemSize of 0 on no-split/allow split buffers.
@return - Pointer to the retrieved item on success; *pxItemSize filled with the length of the item. - NULL when the ring buffer is empty, *pxItemSize is untouched in that case.