Skip to content

Commit

Permalink
Add stream buffer and stream batching buffer difference
Browse files Browse the repository at this point in the history
Signed-off-by: Gaurav Aggarwal <[email protected]>
  • Loading branch information
aggarg committed Apr 17, 2024
1 parent e7de930 commit cd10aea
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions include/stream_buffer.h
Original file line number Diff line number Diff line change
Expand Up @@ -287,6 +287,14 @@ typedef void (* StreamBufferCallbackFunction_t)( StreamBufferHandle_t xStreamBuf
* configUSE_STREAM_BUFFERS must be set to 1 in for FreeRTOSConfig.h for
* xStreamBatchingBufferCreate() to be available.
*
* The difference between a stream buffer and a stream batching buffer is when
* a task performs read on a non-empty buffer:
* - The task reading from a non-empty stream buffer returns immediately
* regardless of the amount of data in the buffer.
* - The task reading from a non-empty steam batching buffer blocks until the
* amount of data in the buffer exceeds the trigger level or the block time
* expires.
*
* @param xBufferSizeBytes The total number of bytes the stream batching buffer
* will be able to hold at any one time.
*
Expand Down Expand Up @@ -367,6 +375,14 @@ typedef void (* StreamBufferCallbackFunction_t)( StreamBufferHandle_t xStreamBuf
* must be set to 1 in for FreeRTOSConfig.h for xStreamBatchingBufferCreateStatic()
* to be available.
*
* The difference between a stream buffer and a stream batching buffer is when
* a task performs read on a non-empty buffer:
* - The task reading from a non-empty stream buffer returns immediately
* regardless of the amount of data in the buffer.
* - The task reading from a non-empty steam batching buffer blocks until the
* amount of data in the buffer exceeds the trigger level or the block time
* expires.
*
* @param xBufferSizeBytes The size, in bytes, of the buffer pointed to by the
* pucStreamBufferStorageArea parameter.
*
Expand Down

0 comments on commit cd10aea

Please sign in to comment.