@@ -911,6 +911,57 @@ BaseType_t xStreamBufferSendCompletedFromISR( StreamBufferHandle_t xStreamBuffer
911
911
BaseType_t xStreamBufferReceiveCompletedFromISR ( StreamBufferHandle_t xStreamBuffer ,
912
912
BaseType_t * pxHigherPriorityTaskWoken ) PRIVILEGED_FUNCTION ;
913
913
914
+ /**
915
+ * stream_buffer.h
916
+ *
917
+ * @code{c}
918
+ * UBaseType_t uxStreamBufferGetStreamBufferNotificationIndex( StreamBufferHandle_t xStreamBuffer );
919
+ * @endcode
920
+ *
921
+ * Get the task notification index used for the supplied stream buffer which can
922
+ * be set using vStreamBufferSetStreamBufferNotificationIndex. If the task
923
+ * notification index for the stream buffer is not changed using
924
+ * vStreamBufferSetStreamBufferNotificationIndex, this function returns the
925
+ * default value (tskDEFAULT_INDEX_TO_NOTIFY).
926
+ *
927
+ * @param xStreamBuffer The handle of the stream buffer for which the task
928
+ * notification index is retrieved.
929
+ *
930
+ * @return The task notification index for the stream buffer.
931
+ *
932
+ * \defgroup uxStreamBufferGetStreamBufferNotificationIndex uxStreamBufferGetStreamBufferNotificationIndex
933
+ * \ingroup StreamBufferManagement
934
+ */
935
+ UBaseType_t uxStreamBufferGetStreamBufferNotificationIndex ( StreamBufferHandle_t xStreamBuffer ) PRIVILEGED_FUNCTION ;
936
+
937
+ /**
938
+ * stream_buffer.h
939
+ *
940
+ * @code{c}
941
+ * void vStreamBufferSetStreamBufferNotificationIndex ( StreamBuffer_t xStreamBuffer, UBaseType_t uxNotificationIndex );
942
+ * @endcode
943
+ *
944
+ * Set the task notification index used for the supplied stream buffer.
945
+ * Successive calls to stream buffer APIs (like xStreamBufferSend or
946
+ * xStreamBufferReceive) for this stream buffer will use this new index for
947
+ * their task notifications.
948
+ *
949
+ * If this function is not called, the default index (tskDEFAULT_INDEX_TO_NOTIFY)
950
+ * is used for task notifications. It is recommended to call this function
951
+ * before attempting to send or receive data from the stream buffer to avoid
952
+ * inconsistencies.
953
+ *
954
+ * @param xStreamBuffer The handle of the stream buffer for which the task
955
+ * notification index is set.
956
+ *
957
+ * @param uxNotificationIndex The task notification index to set.
958
+ *
959
+ * \defgroup vStreamBufferSetStreamBufferNotificationIndex vStreamBufferSetStreamBufferNotificationIndex
960
+ * \ingroup StreamBufferManagement
961
+ */
962
+ void vStreamBufferSetStreamBufferNotificationIndex ( StreamBufferHandle_t xStreamBuffer ,
963
+ UBaseType_t uxNotificationIndex ) PRIVILEGED_FUNCTION ;
964
+
914
965
/* Functions below here are not part of the public API. */
915
966
StreamBufferHandle_t xStreamBufferGenericCreate ( size_t xBufferSizeBytes ,
916
967
size_t xTriggerLevelBytes ,
0 commit comments