Function flipperzero_sys::furi_stream_buffer_alloc
source · pub unsafe extern "C" fn furi_stream_buffer_alloc(
size: usize,
trigger_level: usize
) -> *mut FuriStreamBufferExpand description
@brief Allocate stream buffer instance. Stream buffer implementation assumes there is only one task or interrupt that will write to the buffer (the writer), and only one task or interrupt that will read from the buffer (the reader).
@param size The total number of bytes the stream buffer will be able to hold at any one time. @param trigger_level The number of bytes that must be in the stream buffer before a task that is blocked on the stream buffer to wait for data is moved out of the blocked state. @return The stream buffer instance.