fix example usage of xMessageBufferCreateStatic and xStreamBufferCrea… (#380)

Example usage is actually correct, so remove the -1. but update
the incorrect parameter description for pucStreamBufferStorageArea
and pucMessageBufferStorageArea.
pull/381/head^2
Paul Adelsbach 4 years ago committed by GitHub
parent d01801807d
commit d858d1ff36
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -165,7 +165,7 @@ typedef void * MessageBufferHandle_t;
* stored in the message buffer is actually (xBufferSizeBytes - 1). * stored in the message buffer is actually (xBufferSizeBytes - 1).
* *
* @param pucMessageBufferStorageArea Must point to a uint8_t array that is at * @param pucMessageBufferStorageArea Must point to a uint8_t array that is at
* least xBufferSizeBytes + 1 big. This is the array to which messages are * least xBufferSizeBytes big. This is the array to which messages are
* copied when they are written to the message buffer. * copied when they are written to the message buffer.
* *
* @param pxStaticMessageBuffer Must point to a variable of type * @param pxStaticMessageBuffer Must point to a variable of type
@ -194,8 +194,8 @@ typedef void * MessageBufferHandle_t;
* { * {
* MessageBufferHandle_t xMessageBuffer; * MessageBufferHandle_t xMessageBuffer;
* *
* xMessageBuffer = xMessageBufferCreateStatic( sizeof( ucBufferStorage ), * xMessageBuffer = xMessageBufferCreateStatic( sizeof( ucStorageBuffer ),
* ucBufferStorage, * ucStorageBuffer,
* &xMessageBufferStruct ); * &xMessageBufferStruct );
* *
* // As neither the pucMessageBufferStorageArea or pxStaticMessageBuffer * // As neither the pucMessageBufferStorageArea or pxStaticMessageBuffer

@ -172,7 +172,7 @@ typedef struct StreamBufferDef_t * StreamBufferHandle_t;
* that is greater than the buffer size. * that is greater than the buffer size.
* *
* @param pucStreamBufferStorageArea Must point to a uint8_t array that is at * @param pucStreamBufferStorageArea Must point to a uint8_t array that is at
* least xBufferSizeBytes + 1 big. This is the array to which streams are * least xBufferSizeBytes big. This is the array to which streams are
* copied when they are written to the stream buffer. * copied when they are written to the stream buffer.
* *
* @param pxStaticStreamBuffer Must point to a variable of type * @param pxStaticStreamBuffer Must point to a variable of type
@ -202,9 +202,9 @@ typedef struct StreamBufferDef_t * StreamBufferHandle_t;
* StreamBufferHandle_t xStreamBuffer; * StreamBufferHandle_t xStreamBuffer;
* const size_t xTriggerLevel = 1; * const size_t xTriggerLevel = 1;
* *
* xStreamBuffer = xStreamBufferCreateStatic( sizeof( ucBufferStorage ), * xStreamBuffer = xStreamBufferCreateStatic( sizeof( ucStorageBuffer ),
* xTriggerLevel, * xTriggerLevel,
* ucBufferStorage, * ucStorageBuffer,
* &xStreamBufferStruct ); * &xStreamBufferStruct );
* *
* // As neither the pucStreamBufferStorageArea or pxStaticStreamBuffer * // As neither the pucStreamBufferStorageArea or pxStaticStreamBuffer

Loading…
Cancel
Save