Fixed some bugs in documentation and made it look consistent

This commit is contained in:
the78mole 2020-05-30 16:37:14 +02:00
parent 4b353bfd7a
commit ffe1111646
6 changed files with 352 additions and 224 deletions

View file

@ -58,12 +58,13 @@ typedef struct corCoRoutineControlBlock
/**
* croutine. h
*<pre>
<pre>
BaseType_t xCoRoutineCreate(
crCOROUTINE_CODE pxCoRoutineCode,
UBaseType_t uxPriority,
UBaseType_t uxIndex
);</pre>
);
</pre>
*
* Create a new co-routine and add it to the list of co-routines that are
* ready to run.
@ -133,8 +134,9 @@ BaseType_t xCoRoutineCreate( crCOROUTINE_CODE pxCoRoutineCode, UBaseType_t uxPri
/**
* croutine. h
*<pre>
void vCoRoutineSchedule( void );</pre>
<pre>
void vCoRoutineSchedule( void );
</pre>
*
* Run a co-routine.
*
@ -174,8 +176,9 @@ void vCoRoutineSchedule( void );
/**
* croutine. h
* <pre>
crSTART( CoRoutineHandle_t xHandle );</pre>
<pre>
crSTART( CoRoutineHandle_t xHandle );
</pre>
*
* This macro MUST always be called at the start of a co-routine function.
*
@ -197,7 +200,8 @@ void vCoRoutineSchedule( void );
// Must end every co-routine with a call to crEND();
crEND();
}</pre>
}
</pre>
* \defgroup crSTART crSTART
* \ingroup Tasks
*/
@ -205,8 +209,9 @@ void vCoRoutineSchedule( void );
/**
* croutine. h
* <pre>
crEND();</pre>
<pre>
crEND();
</pre>
*
* This macro MUST always be called at the end of a co-routine function.
*
@ -228,7 +233,8 @@ void vCoRoutineSchedule( void );
// Must end every co-routine with a call to crEND();
crEND();
}</pre>
}
</pre>
* \defgroup crSTART crSTART
* \ingroup Tasks
*/
@ -243,8 +249,9 @@ void vCoRoutineSchedule( void );
/**
* croutine. h
*<pre>
crDELAY( CoRoutineHandle_t xHandle, TickType_t xTicksToDelay );</pre>
<pre>
crDELAY( CoRoutineHandle_t xHandle, TickType_t xTicksToDelay );
</pre>
*
* Delay a co-routine for a fixed period of time.
*
@ -283,7 +290,8 @@ void vCoRoutineSchedule( void );
// Must end every co-routine with a call to crEND();
crEND();
}</pre>
}
</pre>
* \defgroup crDELAY crDELAY
* \ingroup Tasks
*/
@ -295,14 +303,15 @@ void vCoRoutineSchedule( void );
crSET_STATE0( ( xHandle ) );
/**
* <pre>
<pre>
crQUEUE_SEND(
CoRoutineHandle_t xHandle,
QueueHandle_t pxQueue,
void *pvItemToQueue,
TickType_t xTicksToWait,
BaseType_t *pxResult
)</pre>
);
</pre>
*
* The macro's crQUEUE_SEND() and crQUEUE_RECEIVE() are the co-routine
* equivalent to the xQueueSend() and xQueueReceive() functions used by tasks.
@ -373,7 +382,8 @@ void vCoRoutineSchedule( void );
// Co-routines must end with a call to crEND().
crEND();
}</pre>
}
</pre>
* \defgroup crQUEUE_SEND crQUEUE_SEND
* \ingroup Tasks
*/
@ -394,14 +404,15 @@ void vCoRoutineSchedule( void );
/**
* croutine. h
* <pre>
<pre>
crQUEUE_RECEIVE(
CoRoutineHandle_t xHandle,
QueueHandle_t pxQueue,
void *pvBuffer,
TickType_t xTicksToWait,
BaseType_t *pxResult
)</pre>
);
</pre>
*
* The macro's crQUEUE_SEND() and crQUEUE_RECEIVE() are the co-routine
* equivalent to the xQueueSend() and xQueueReceive() functions used by tasks.
@ -465,7 +476,8 @@ void vCoRoutineSchedule( void );
}
crEND();
}</pre>
}
</pre>
* \defgroup crQUEUE_RECEIVE crQUEUE_RECEIVE
* \ingroup Tasks
*/
@ -486,12 +498,13 @@ void vCoRoutineSchedule( void );
/**
* croutine. h
* <pre>
<pre>
crQUEUE_SEND_FROM_ISR(
QueueHandle_t pxQueue,
void *pvItemToQueue,
BaseType_t xCoRoutinePreviouslyWoken
)</pre>
);
</pre>
*
* The macro's crQUEUE_SEND_FROM_ISR() and crQUEUE_RECEIVE_FROM_ISR() are the
* co-routine equivalent to the xQueueSendFromISR() and xQueueReceiveFromISR()
@ -574,7 +587,8 @@ void vCoRoutineSchedule( void );
// many characters are posted to the queue.
xCRWokenByPost = crQUEUE_SEND_FROM_ISR( xCommsRxQueue, &cRxedChar, xCRWokenByPost );
}
}</pre>
}
</pre>
* \defgroup crQUEUE_SEND_FROM_ISR crQUEUE_SEND_FROM_ISR
* \ingroup Tasks
*/
@ -583,12 +597,13 @@ void vCoRoutineSchedule( void );
/**
* croutine. h
* <pre>
<pre>
crQUEUE_SEND_FROM_ISR(
QueueHandle_t pxQueue,
void *pvBuffer,
BaseType_t * pxCoRoutineWoken
)</pre>
);
</pre>
*
* The macro's crQUEUE_SEND_FROM_ISR() and crQUEUE_RECEIVE_FROM_ISR() are the
* co-routine equivalent to the xQueueSendFromISR() and xQueueReceiveFromISR()
@ -687,7 +702,8 @@ void vCoRoutineSchedule( void );
SEND_CHARACTER( cCharToTx );
}
}
}</pre>
}
</pre>
* \defgroup crQUEUE_RECEIVE_FROM_ISR crQUEUE_RECEIVE_FROM_ISR
* \ingroup Tasks
*/

View file

@ -93,7 +93,7 @@ typedef TickType_t EventBits_t;
/**
* event_groups.h
*<pre>
<pre>
EventGroupHandle_t xEventGroupCreate( void );
</pre>
*
@ -149,7 +149,7 @@ typedef TickType_t EventBits_t;
/**
* event_groups.h
*<pre>
<pre>
EventGroupHandle_t xEventGroupCreateStatic( EventGroupHandle_t * pxEventGroupBuffer );
</pre>
*
@ -202,7 +202,7 @@ typedef TickType_t EventBits_t;
/**
* event_groups.h
*<pre>
<pre>
EventBits_t xEventGroupWaitBits( EventGroupHandle_t xEventGroup,
const EventBits_t uxBitsToWaitFor,
const BaseType_t xClearOnExit,
@ -296,7 +296,7 @@ EventBits_t xEventGroupWaitBits( EventGroupHandle_t xEventGroup, const EventBits
/**
* event_groups.h
*<pre>
<pre>
EventBits_t xEventGroupClearBits( EventGroupHandle_t xEventGroup, const EventBits_t uxBitsToClear );
</pre>
*
@ -353,7 +353,7 @@ EventBits_t xEventGroupClearBits( EventGroupHandle_t xEventGroup, const EventBit
/**
* event_groups.h
*<pre>
<pre>
BaseType_t xEventGroupClearBitsFromISR( EventGroupHandle_t xEventGroup, const EventBits_t uxBitsToSet );
</pre>
*
@ -412,7 +412,7 @@ EventBits_t xEventGroupClearBits( EventGroupHandle_t xEventGroup, const EventBit
/**
* event_groups.h
*<pre>
<pre>
EventBits_t xEventGroupSetBits( EventGroupHandle_t xEventGroup, const EventBits_t uxBitsToSet );
</pre>
*
@ -486,7 +486,7 @@ EventBits_t xEventGroupSetBits( EventGroupHandle_t xEventGroup, const EventBits_
/**
* event_groups.h
*<pre>
<pre>
BaseType_t xEventGroupSetBitsFromISR( EventGroupHandle_t xEventGroup, const EventBits_t uxBitsToSet, BaseType_t *pxHigherPriorityTaskWoken );
</pre>
*
@ -564,7 +564,7 @@ EventBits_t xEventGroupSetBits( EventGroupHandle_t xEventGroup, const EventBits_
/**
* event_groups.h
*<pre>
<pre>
EventBits_t xEventGroupSync( EventGroupHandle_t xEventGroup,
const EventBits_t uxBitsToSet,
const EventBits_t uxBitsToWaitFor,
@ -691,7 +691,7 @@ EventBits_t xEventGroupSync( EventGroupHandle_t xEventGroup, const EventBits_t u
/**
* event_groups.h
*<pre>
<pre>
EventBits_t xEventGroupGetBits( EventGroupHandle_t xEventGroup );
</pre>
*
@ -709,7 +709,7 @@ EventBits_t xEventGroupSync( EventGroupHandle_t xEventGroup, const EventBits_t u
/**
* event_groups.h
*<pre>
<pre>
EventBits_t xEventGroupGetBitsFromISR( EventGroupHandle_t xEventGroup );
</pre>
*
@ -726,7 +726,7 @@ EventBits_t xEventGroupGetBitsFromISR( EventGroupHandle_t xEventGroup ) PRIVILEG
/**
* event_groups.h
*<pre>
<pre>
void xEventGroupDelete( EventGroupHandle_t xEventGroup );
</pre>
*

View file

@ -215,7 +215,7 @@ size_t xMessageBufferSend( MessageBufferHandle_t xMessageBuffer,
const void *pvTxData,
size_t xDataLengthBytes,
TickType_t xTicksToWait );
<pre>
</pre>
*
* Sends a discrete message to the message buffer. The message can be any
* length that fits within the buffer's free space, and is copied into the
@ -314,7 +314,7 @@ size_t xMessageBufferSendFromISR( MessageBufferHandle_t xMessageBuffer,
const void *pvTxData,
size_t xDataLengthBytes,
BaseType_t *pxHigherPriorityTaskWoken );
<pre>
</pre>
*
* Interrupt safe version of the API function that sends a discrete message to
* the message buffer. The message can be any length that fits within the

View file

@ -76,12 +76,12 @@ typedef struct QueueDefinition * QueueSetMemberHandle_t;
/**
* queue. h
* <pre>
<pre>
QueueHandle_t xQueueCreate(
UBaseType_t uxQueueLength,
UBaseType_t uxItemSize
);
* </pre>
</pre>
*
* Creates a new queue instance, and returns a handle by which the new queue
* can be referenced.
@ -148,14 +148,14 @@ typedef struct QueueDefinition * QueueSetMemberHandle_t;
/**
* queue. h
* <pre>
<pre>
QueueHandle_t xQueueCreateStatic(
UBaseType_t uxQueueLength,
UBaseType_t uxItemSize,
uint8_t *pucQueueStorageBuffer,
StaticQueue_t *pxQueueBuffer
);
* </pre>
</pre>
*
* Creates a new queue instance, and returns a handle by which the new queue
* can be referenced.
@ -234,13 +234,13 @@ typedef struct QueueDefinition * QueueSetMemberHandle_t;
/**
* queue. h
* <pre>
<pre>
BaseType_t xQueueSendToToFront(
QueueHandle_t xQueue,
const void *pvItemToQueue,
TickType_t xTicksToWait
);
* </pre>
</pre>
*
* Post an item to the front of a queue. The item is queued by copy, not by
* reference. This function must not be called from an interrupt service
@ -314,13 +314,13 @@ typedef struct QueueDefinition * QueueSetMemberHandle_t;
/**
* queue. h
* <pre>
<pre>
BaseType_t xQueueSendToBack(
QueueHandle_t xQueue,
const void *pvItemToQueue,
TickType_t xTicksToWait
);
* </pre>
</pre>
*
* This is a macro that calls xQueueGenericSend().
*
@ -396,13 +396,13 @@ typedef struct QueueDefinition * QueueSetMemberHandle_t;
/**
* queue. h
* <pre>
<pre>
BaseType_t xQueueSend(
QueueHandle_t xQueue,
const void * pvItemToQueue,
TickType_t xTicksToWait
);
* </pre>
</pre>
*
* This is a macro that calls xQueueGenericSend(). It is included for
* backward compatibility with versions of FreeRTOS.org that did not
@ -480,12 +480,12 @@ typedef struct QueueDefinition * QueueSetMemberHandle_t;
/**
* queue. h
* <pre>
<pre>
BaseType_t xQueueOverwrite(
QueueHandle_t xQueue,
const void * pvItemToQueue
);
* </pre>
</pre>
*
* Only for use with queues that have a length of one - so the queue is either
* empty or full.
@ -564,14 +564,14 @@ typedef struct QueueDefinition * QueueSetMemberHandle_t;
/**
* queue. h
* <pre>
<pre>
BaseType_t xQueueGenericSend(
QueueHandle_t xQueue,
const void * pvItemToQueue,
TickType_t xTicksToWait
BaseType_t xCopyPosition
);
* </pre>
</pre>
*
* It is preferred that the macros xQueueSend(), xQueueSendToFront() and
* xQueueSendToBack() are used in place of calling this function directly.
@ -651,12 +651,13 @@ BaseType_t xQueueGenericSend( QueueHandle_t xQueue, const void * const pvItemToQ
/**
* queue. h
* <pre>
<pre>
BaseType_t xQueuePeek(
QueueHandle_t xQueue,
void * const pvBuffer,
TickType_t xTicksToWait
);</pre>
);
</pre>
*
* Receive an item from a queue without removing the item from the queue.
* The item is received by copy so a buffer of adequate size must be
@ -745,11 +746,12 @@ BaseType_t xQueuePeek( QueueHandle_t xQueue, void * const pvBuffer, TickType_t x
/**
* queue. h
* <pre>
<pre>
BaseType_t xQueuePeekFromISR(
QueueHandle_t xQueue,
void *pvBuffer,
);</pre>
);
</pre>
*
* A version of xQueuePeek() that can be called from an interrupt service
* routine (ISR).
@ -778,12 +780,13 @@ BaseType_t xQueuePeekFromISR( QueueHandle_t xQueue, void * const pvBuffer ) PRIV
/**
* queue. h
* <pre>
<pre>
BaseType_t xQueueReceive(
QueueHandle_t xQueue,
void *pvBuffer,
TickType_t xTicksToWait
);</pre>
);
</pre>
*
* Receive an item from a queue. The item is received by copy so a buffer of
* adequate size must be provided. The number of bytes copied into the buffer
@ -869,7 +872,9 @@ BaseType_t xQueueReceive( QueueHandle_t xQueue, void * const pvBuffer, TickType_
/**
* queue. h
* <pre>UBaseType_t uxQueueMessagesWaiting( const QueueHandle_t xQueue );</pre>
<pre>
UBaseType_t uxQueueMessagesWaiting( const QueueHandle_t xQueue );
</pre>
*
* Return the number of messages stored in a queue.
*
@ -884,7 +889,9 @@ UBaseType_t uxQueueMessagesWaiting( const QueueHandle_t xQueue ) PRIVILEGED_FUNC
/**
* queue. h
* <pre>UBaseType_t uxQueueSpacesAvailable( const QueueHandle_t xQueue );</pre>
<pre>
UBaseType_t uxQueueSpacesAvailable( const QueueHandle_t xQueue );
</pre>
*
* Return the number of free spaces available in a queue. This is equal to the
* number of items that can be sent to the queue before the queue becomes full
@ -901,7 +908,9 @@ UBaseType_t uxQueueSpacesAvailable( const QueueHandle_t xQueue ) PRIVILEGED_FUNC
/**
* queue. h
* <pre>void vQueueDelete( QueueHandle_t xQueue );</pre>
<pre>
void vQueueDelete( QueueHandle_t xQueue );
</pre>
*
* Delete a queue - freeing all the memory allocated for storing of items
* placed on the queue.
@ -915,7 +924,7 @@ void vQueueDelete( QueueHandle_t xQueue ) PRIVILEGED_FUNCTION;
/**
* queue. h
* <pre>
<pre>
BaseType_t xQueueSendToFrontFromISR(
QueueHandle_t xQueue,
const void *pvItemToQueue,
@ -986,7 +995,7 @@ void vQueueDelete( QueueHandle_t xQueue ) PRIVILEGED_FUNCTION;
/**
* queue. h
* <pre>
<pre>
BaseType_t xQueueSendToBackFromISR(
QueueHandle_t xQueue,
const void *pvItemToQueue,
@ -1056,13 +1065,13 @@ void vQueueDelete( QueueHandle_t xQueue ) PRIVILEGED_FUNCTION;
/**
* queue. h
* <pre>
<pre>
BaseType_t xQueueOverwriteFromISR(
QueueHandle_t xQueue,
const void * pvItemToQueue,
BaseType_t *pxHigherPriorityTaskWoken
);
* </pre>
</pre>
*
* A version of xQueueOverwrite() that can be used in an interrupt service
* routine (ISR).
@ -1143,7 +1152,7 @@ uint32_t ulVarToSend, ulValReceived;
/**
* queue. h
* <pre>
<pre>
BaseType_t xQueueSendFromISR(
QueueHandle_t xQueue,
const void *pvItemToQueue,
@ -1217,7 +1226,7 @@ uint32_t ulVarToSend, ulValReceived;
/**
* queue. h
* <pre>
<pre>
BaseType_t xQueueGenericSendFromISR(
QueueHandle_t xQueue,
const void *pvItemToQueue,
@ -1297,13 +1306,13 @@ BaseType_t xQueueGiveFromISR( QueueHandle_t xQueue, BaseType_t * const pxHigherP
/**
* queue. h
* <pre>
<pre>
BaseType_t xQueueReceiveFromISR(
QueueHandle_t xQueue,
void *pvBuffer,
BaseType_t *pxTaskWoken
);
* </pre>
</pre>
*
* Receive an item from a queue. It is safe to use this function from within an
* interrupt service routine.

View file

@ -43,7 +43,9 @@ typedef QueueHandle_t SemaphoreHandle_t;
/**
* semphr. h
* <pre>vSemaphoreCreateBinary( SemaphoreHandle_t xSemaphore )</pre>
<pre>
vSemaphoreCreateBinary( SemaphoreHandle_t xSemaphore );
</pre>
*
* In many usage scenarios it is faster and more memory efficient to use a
* direct to task notification in place of a binary semaphore!
@ -103,7 +105,9 @@ typedef QueueHandle_t SemaphoreHandle_t;
/**
* semphr. h
* <pre>SemaphoreHandle_t xSemaphoreCreateBinary( void )</pre>
<pre>
SemaphoreHandle_t xSemaphoreCreateBinary( void );
</pre>
*
* Creates a new binary semaphore instance, and returns a handle by which the
* new semaphore can be referenced.
@ -164,7 +168,9 @@ typedef QueueHandle_t SemaphoreHandle_t;
/**
* semphr. h
* <pre>SemaphoreHandle_t xSemaphoreCreateBinaryStatic( StaticSemaphore_t *pxSemaphoreBuffer )</pre>
<pre>
SemaphoreHandle_t xSemaphoreCreateBinaryStatic( StaticSemaphore_t *pxSemaphoreBuffer );
</pre>
*
* Creates a new binary semaphore instance, and returns a handle by which the
* new semaphore can be referenced.
@ -223,10 +229,12 @@ typedef QueueHandle_t SemaphoreHandle_t;
/**
* semphr. h
* <pre>xSemaphoreTake(
* SemaphoreHandle_t xSemaphore,
* TickType_t xBlockTime
* )</pre>
<pre>
xSemaphoreTake(
SemaphoreHandle_t xSemaphore,
TickType_t xBlockTime
);
</pre>
*
* <i>Macro</i> to obtain a semaphore. The semaphore must have previously been
* created with a call to xSemaphoreCreateBinary(), xSemaphoreCreateMutex() or
@ -290,10 +298,12 @@ typedef QueueHandle_t SemaphoreHandle_t;
/**
* semphr. h
* xSemaphoreTakeRecursive(
* SemaphoreHandle_t xMutex,
* TickType_t xBlockTime
* )
<pre>
xSemaphoreTakeRecursive(
SemaphoreHandle_t xMutex,
TickType_t xBlockTime
);
</pre>
*
* <i>Macro</i> to recursively obtain, or 'take', a mutex type semaphore.
* The mutex must have previously been created using a call to
@ -385,7 +395,9 @@ typedef QueueHandle_t SemaphoreHandle_t;
/**
* semphr. h
* <pre>xSemaphoreGive( SemaphoreHandle_t xSemaphore )</pre>
<pre>
xSemaphoreGive( SemaphoreHandle_t xSemaphore );
</pre>
*
* <i>Macro</i> to release a semaphore. The semaphore must have previously been
* created with a call to xSemaphoreCreateBinary(), xSemaphoreCreateMutex() or
@ -448,7 +460,9 @@ typedef QueueHandle_t SemaphoreHandle_t;
/**
* semphr. h
* <pre>xSemaphoreGiveRecursive( SemaphoreHandle_t xMutex )</pre>
<pre>
xSemaphoreGiveRecursive( SemaphoreHandle_t xMutex );
</pre>
*
* <i>Macro</i> to recursively release, or 'give', a mutex type semaphore.
* The mutex must have previously been created using a call to
@ -534,11 +548,12 @@ typedef QueueHandle_t SemaphoreHandle_t;
/**
* semphr. h
* <pre>
<pre>
xSemaphoreGiveFromISR(
SemaphoreHandle_t xSemaphore,
BaseType_t *pxHigherPriorityTaskWoken
)</pre>
);
</pre>
*
* <i>Macro</i> to release a semaphore. The semaphore must have previously been
* created with a call to xSemaphoreCreateBinary() or xSemaphoreCreateCounting().
@ -625,11 +640,12 @@ typedef QueueHandle_t SemaphoreHandle_t;
/**
* semphr. h
* <pre>
<pre>
xSemaphoreTakeFromISR(
SemaphoreHandle_t xSemaphore,
BaseType_t *pxHigherPriorityTaskWoken
)</pre>
);
</pre>
*
* <i>Macro</i> to take a semaphore from an ISR. The semaphore must have
* previously been created with a call to xSemaphoreCreateBinary() or
@ -659,7 +675,9 @@ typedef QueueHandle_t SemaphoreHandle_t;
/**
* semphr. h
* <pre>SemaphoreHandle_t xSemaphoreCreateMutex( void )</pre>
<pre>
SemaphoreHandle_t xSemaphoreCreateMutex( void );
</pre>
*
* Creates a new mutex type semaphore instance, and returns a handle by which
* the new mutex can be referenced.
@ -718,7 +736,9 @@ typedef QueueHandle_t SemaphoreHandle_t;
/**
* semphr. h
* <pre>SemaphoreHandle_t xSemaphoreCreateMutexStatic( StaticSemaphore_t *pxMutexBuffer )</pre>
<pre>
SemaphoreHandle_t xSemaphoreCreateMutexStatic( StaticSemaphore_t *pxMutexBuffer );
</pre>
*
* Creates a new mutex type semaphore instance, and returns a handle by which
* the new mutex can be referenced.
@ -780,7 +800,9 @@ typedef QueueHandle_t SemaphoreHandle_t;
/**
* semphr. h
* <pre>SemaphoreHandle_t xSemaphoreCreateRecursiveMutex( void )</pre>
<pre>
SemaphoreHandle_t xSemaphoreCreateRecursiveMutex( void );
</pre>
*
* Creates a new recursive mutex type semaphore instance, and returns a handle
* by which the new recursive mutex can be referenced.
@ -847,7 +869,9 @@ typedef QueueHandle_t SemaphoreHandle_t;
/**
* semphr. h
* <pre>SemaphoreHandle_t xSemaphoreCreateRecursiveMutexStatic( StaticSemaphore_t *pxMutexBuffer )</pre>
<pre>
SemaphoreHandle_t xSemaphoreCreateRecursiveMutexStatic( StaticSemaphore_t *pxMutexBuffer );
</pre>
*
* Creates a new recursive mutex type semaphore instance, and returns a handle
* by which the new recursive mutex can be referenced.
@ -920,7 +944,9 @@ typedef QueueHandle_t SemaphoreHandle_t;
/**
* semphr. h
* <pre>SemaphoreHandle_t xSemaphoreCreateCounting( UBaseType_t uxMaxCount, UBaseType_t uxInitialCount )</pre>
<pre>
SemaphoreHandle_t xSemaphoreCreateCounting( UBaseType_t uxMaxCount, UBaseType_t uxInitialCount );
</pre>
*
* Creates a new counting semaphore instance, and returns a handle by which the
* new counting semaphore can be referenced.
@ -1000,7 +1026,9 @@ typedef QueueHandle_t SemaphoreHandle_t;
/**
* semphr. h
* <pre>SemaphoreHandle_t xSemaphoreCreateCountingStatic( UBaseType_t uxMaxCount, UBaseType_t uxInitialCount, StaticSemaphore_t *pxSemaphoreBuffer )</pre>
<pre>
SemaphoreHandle_t xSemaphoreCreateCountingStatic( UBaseType_t uxMaxCount, UBaseType_t uxInitialCount, StaticSemaphore_t *pxSemaphoreBuffer );
</pre>
*
* Creates a new counting semaphore instance, and returns a handle by which the
* new counting semaphore can be referenced.
@ -1085,7 +1113,9 @@ typedef QueueHandle_t SemaphoreHandle_t;
/**
* semphr. h
* <pre>void vSemaphoreDelete( SemaphoreHandle_t xSemaphore );</pre>
<pre>
void vSemaphoreDelete( SemaphoreHandle_t xSemaphore );
</pre>
*
* Delete a semaphore. This function must be used with care. For example,
* do not delete a mutex type semaphore if the mutex is held by a task.
@ -1099,7 +1129,9 @@ typedef QueueHandle_t SemaphoreHandle_t;
/**
* semphr.h
* <pre>TaskHandle_t xSemaphoreGetMutexHolder( SemaphoreHandle_t xMutex );</pre>
<pre>
TaskHandle_t xSemaphoreGetMutexHolder( SemaphoreHandle_t xMutex );
</pre>
*
* If xMutex is indeed a mutex type semaphore, return the current mutex holder.
* If xMutex is not a mutex type semaphore, or the mutex is available (not held
@ -1114,7 +1146,9 @@ typedef QueueHandle_t SemaphoreHandle_t;
/**
* semphr.h
* <pre>TaskHandle_t xSemaphoreGetMutexHolderFromISR( SemaphoreHandle_t xMutex );</pre>
<pre>
TaskHandle_t xSemaphoreGetMutexHolderFromISR( SemaphoreHandle_t xMutex );
</pre>
*
* If xMutex is indeed a mutex type semaphore, return the current mutex holder.
* If xMutex is not a mutex type semaphore, or the mutex is available (not held
@ -1125,7 +1159,9 @@ typedef QueueHandle_t SemaphoreHandle_t;
/**
* semphr.h
* <pre>UBaseType_t uxSemaphoreGetCount( SemaphoreHandle_t xSemaphore );</pre>
<pre>
UBaseType_t uxSemaphoreGetCount( SemaphoreHandle_t xSemaphore );
</pre>
*
* If the semaphore is a counting semaphore then uxSemaphoreGetCount() returns
* its current count value. If the semaphore is a binary semaphore then

View file

@ -242,7 +242,7 @@ is used in assert() statements. */
/**
* task. h
*<pre>
<pre>
BaseType_t xTaskCreate(
TaskFunction_t pvTaskCode,
const char * const pcName,
@ -250,7 +250,8 @@ is used in assert() statements. */
void *pvParameters,
UBaseType_t uxPriority,
TaskHandle_t *pvCreatedTask
);</pre>
);
</pre>
*
* Create a new task and add it to the list of tasks that are ready to run.
*
@ -344,14 +345,15 @@ is used in assert() statements. */
/**
* task. h
*<pre>
<pre>
TaskHandle_t xTaskCreateStatic( TaskFunction_t pvTaskCode,
const char * const pcName,
uint32_t ulStackDepth,
void *pvParameters,
UBaseType_t uxPriority,
StackType_t *pxStackBuffer,
StaticTask_t *pxTaskBuffer );</pre>
StaticTask_t *pxTaskBuffer );
</pre>
*
* Create a new task and add it to the list of tasks that are ready to run.
*
@ -461,8 +463,9 @@ is used in assert() statements. */
/**
* task. h
*<pre>
BaseType_t xTaskCreateRestricted( TaskParameters_t *pxTaskDefinition, TaskHandle_t *pxCreatedTask );</pre>
<pre>
BaseType_t xTaskCreateRestricted( TaskParameters_t *pxTaskDefinition, TaskHandle_t *pxCreatedTask );
</pre>
*
* Only available when configSUPPORT_DYNAMIC_ALLOCATION is set to 1.
*
@ -537,8 +540,9 @@ TaskHandle_t xHandle;
/**
* task. h
*<pre>
BaseType_t xTaskCreateRestrictedStatic( TaskParameters_t *pxTaskDefinition, TaskHandle_t *pxCreatedTask );</pre>
<pre>
BaseType_t xTaskCreateRestrictedStatic( TaskParameters_t *pxTaskDefinition, TaskHandle_t *pxCreatedTask );
</pre>
*
* Only available when configSUPPORT_STATIC_ALLOCATION is set to 1.
*
@ -625,8 +629,9 @@ TaskHandle_t xHandle;
/**
* task. h
*<pre>
void vTaskAllocateMPURegions( TaskHandle_t xTask, const MemoryRegion_t * const pxRegions );</pre>
<pre>
void vTaskAllocateMPURegions( TaskHandle_t xTask, const MemoryRegion_t * const pxRegions );
</pre>
*
* Memory regions are assigned to a restricted task when the task is created by
* a call to xTaskCreateRestricted(). These regions can be redefined using
@ -673,7 +678,9 @@ void vTaskAllocateMPURegions( TaskHandle_t xTask, const MemoryRegion_t * const p
/**
* task. h
* <pre>void vTaskDelete( TaskHandle_t xTask );</pre>
<pre>
void vTaskDelete( TaskHandle_t xTask );
</pre>
*
* INCLUDE_vTaskDelete must be defined as 1 for this function to be available.
* See the configuration section for more information.
@ -718,7 +725,9 @@ void vTaskDelete( TaskHandle_t xTaskToDelete ) PRIVILEGED_FUNCTION;
/**
* task. h
* <pre>void vTaskDelay( const TickType_t xTicksToDelay );</pre>
<pre>
void vTaskDelay( const TickType_t xTicksToDelay );
</pre>
*
* Delay a task for a given number of ticks. The actual time that the
* task remains blocked depends on the tick rate. The constant
@ -766,7 +775,9 @@ void vTaskDelay( const TickType_t xTicksToDelay ) PRIVILEGED_FUNCTION;
/**
* task. h
* <pre>void vTaskDelayUntil( TickType_t *pxPreviousWakeTime, const TickType_t xTimeIncrement );</pre>
<pre>
void vTaskDelayUntil( TickType_t *pxPreviousWakeTime, const TickType_t xTimeIncrement );
</pre>
*
* INCLUDE_vTaskDelayUntil must be defined as 1 for this function to be available.
* See the configuration section for more information.
@ -825,7 +836,9 @@ void vTaskDelayUntil( TickType_t * const pxPreviousWakeTime, const TickType_t xT
/**
* task. h
* <pre>BaseType_t xTaskAbortDelay( TaskHandle_t xTask );</pre>
<pre>
BaseType_t xTaskAbortDelay( TaskHandle_t xTask );
</pre>
*
* INCLUDE_xTaskAbortDelay must be defined as 1 in FreeRTOSConfig.h for this
* function to be available.
@ -855,7 +868,9 @@ BaseType_t xTaskAbortDelay( TaskHandle_t xTask ) PRIVILEGED_FUNCTION;
/**
* task. h
* <pre>UBaseType_t uxTaskPriorityGet( const TaskHandle_t xTask );</pre>
<pre>
UBaseType_t uxTaskPriorityGet( const TaskHandle_t xTask );
</pre>
*
* INCLUDE_uxTaskPriorityGet must be defined as 1 for this function to be available.
* See the configuration section for more information.
@ -902,7 +917,9 @@ UBaseType_t uxTaskPriorityGet( const TaskHandle_t xTask ) PRIVILEGED_FUNCTION;
/**
* task. h
* <pre>UBaseType_t uxTaskPriorityGetFromISR( const TaskHandle_t xTask );</pre>
<pre>
UBaseType_t uxTaskPriorityGetFromISR( const TaskHandle_t xTask );
</pre>
*
* A version of uxTaskPriorityGet() that can be used from an ISR.
*/
@ -910,7 +927,9 @@ UBaseType_t uxTaskPriorityGetFromISR( const TaskHandle_t xTask ) PRIVILEGED_FUNC
/**
* task. h
* <pre>eTaskState eTaskGetState( TaskHandle_t xTask );</pre>
<pre>
eTaskState eTaskGetState( TaskHandle_t xTask );
</pre>
*
* INCLUDE_eTaskGetState must be defined as 1 for this function to be available.
* See the configuration section for more information.
@ -928,7 +947,9 @@ eTaskState eTaskGetState( TaskHandle_t xTask ) PRIVILEGED_FUNCTION;
/**
* task. h
* <pre>void vTaskGetInfo( TaskHandle_t xTask, TaskStatus_t *pxTaskStatus, BaseType_t xGetFreeStackSpace, eTaskState eState );</pre>
<pre>
void vTaskGetInfo( TaskHandle_t xTask, TaskStatus_t *pxTaskStatus, BaseType_t xGetFreeStackSpace, eTaskState eState );
</pre>
*
* configUSE_TRACE_FACILITY must be defined as 1 for this function to be
* available. See the configuration section for more information.
@ -984,7 +1005,9 @@ void vTaskGetInfo( TaskHandle_t xTask, TaskStatus_t *pxTaskStatus, BaseType_t xG
/**
* task. h
* <pre>void vTaskPrioritySet( TaskHandle_t xTask, UBaseType_t uxNewPriority );</pre>
<pre>
void vTaskPrioritySet( TaskHandle_t xTask, UBaseType_t uxNewPriority );
</pre>
*
* INCLUDE_vTaskPrioritySet must be defined as 1 for this function to be available.
* See the configuration section for more information.
@ -1026,7 +1049,9 @@ void vTaskPrioritySet( TaskHandle_t xTask, UBaseType_t uxNewPriority ) PRIVILEGE
/**
* task. h
* <pre>void vTaskSuspend( TaskHandle_t xTaskToSuspend );</pre>
<pre>
void vTaskSuspend( TaskHandle_t xTaskToSuspend );
</pre>
*
* INCLUDE_vTaskSuspend must be defined as 1 for this function to be available.
* See the configuration section for more information.
@ -1077,7 +1102,9 @@ void vTaskSuspend( TaskHandle_t xTaskToSuspend ) PRIVILEGED_FUNCTION;
/**
* task. h
* <pre>void vTaskResume( TaskHandle_t xTaskToResume );</pre>
<pre>
void vTaskResume( TaskHandle_t xTaskToResume );
</pre>
*
* INCLUDE_vTaskSuspend must be defined as 1 for this function to be available.
* See the configuration section for more information.
@ -1126,7 +1153,9 @@ void vTaskResume( TaskHandle_t xTaskToResume ) PRIVILEGED_FUNCTION;
/**
* task. h
* <pre>void xTaskResumeFromISR( TaskHandle_t xTaskToResume );</pre>
<pre>
void xTaskResumeFromISR( TaskHandle_t xTaskToResume );
</pre>
*
* INCLUDE_xTaskResumeFromISR must be defined as 1 for this function to be
* available. See the configuration section for more information.
@ -1159,7 +1188,9 @@ BaseType_t xTaskResumeFromISR( TaskHandle_t xTaskToResume ) PRIVILEGED_FUNCTION;
/**
* task. h
* <pre>void vTaskStartScheduler( void );</pre>
<pre>
void vTaskStartScheduler( void );
</pre>
*
* Starts the real time kernel tick processing. After calling the kernel
* has control over which tasks are executed and when.
@ -1188,7 +1219,9 @@ void vTaskStartScheduler( void ) PRIVILEGED_FUNCTION;
/**
* task. h
* <pre>void vTaskEndScheduler( void );</pre>
<pre>
void vTaskEndScheduler( void );
</pre>
*
* NOTE: At the time of writing only the x86 real mode port, which runs on a PC
* in place of DOS, implements this function.
@ -1244,7 +1277,9 @@ void vTaskEndScheduler( void ) PRIVILEGED_FUNCTION;
/**
* task. h
* <pre>void vTaskSuspendAll( void );</pre>
<pre>
void vTaskSuspendAll( void );
</pre>
*
* Suspends the scheduler without disabling interrupts. Context switches will
* not occur while the scheduler is suspended.
@ -1295,7 +1330,9 @@ void vTaskSuspendAll( void ) PRIVILEGED_FUNCTION;
/**
* task. h
* <pre>BaseType_t xTaskResumeAll( void );</pre>
<pre>
BaseType_t xTaskResumeAll( void );
</pre>
*
* Resumes scheduler activity after it was suspended by a call to
* vTaskSuspendAll().
@ -1485,7 +1522,9 @@ constant. */
#if configUSE_APPLICATION_TASK_TAG == 1
/**
* task.h
* <pre>void vTaskSetApplicationTaskTag( TaskHandle_t xTask, TaskHookFunction_t pxHookFunction );</pre>
<pre>
void vTaskSetApplicationTaskTag( TaskHandle_t xTask, TaskHookFunction_t pxHookFunction );
</pre>
*
* Sets pxHookFunction to be the task hook function used by the task xTask.
* Passing xTask as NULL has the effect of setting the calling tasks hook
@ -1495,7 +1534,9 @@ constant. */
/**
* task.h
* <pre>void xTaskGetApplicationTaskTag( TaskHandle_t xTask );</pre>
<pre>
void xTaskGetApplicationTaskTag( TaskHandle_t xTask );
</pre>
*
* Returns the pxHookFunction value assigned to the task xTask. Do not
* call from an interrupt service routine - call
@ -1505,7 +1546,9 @@ constant. */
/**
* task.h
* <pre>void xTaskGetApplicationTaskTagFromISR( TaskHandle_t xTask );</pre>
<pre>
void xTaskGetApplicationTaskTagFromISR( TaskHandle_t xTask );
</pre>
*
* Returns the pxHookFunction value assigned to the task xTask. Can
* be called from an interrupt service routine.
@ -1528,7 +1571,9 @@ constant. */
/**
* task.h
* <pre>BaseType_t xTaskCallApplicationTaskHook( TaskHandle_t xTask, void *pvParameter );</pre>
<pre>
BaseType_t xTaskCallApplicationTaskHook( TaskHandle_t xTask, void *pvParameter );
</pre>
*
* Calls the hook function associated with xTask. Passing xTask as NULL has
* the effect of calling the Running tasks (the calling task) hook function.
@ -2056,8 +2101,12 @@ BaseType_t xTaskGenericNotifyFromISR( TaskHandle_t xTaskToNotify, UBaseType_t ux
/**
* task. h
* <PRE>BaseType_t xTaskNotifyWaitIndexed( UBaseType_t uxIndexToWaitOn, uint32_t ulBitsToClearOnEntry, uint32_t ulBitsToClearOnExit, uint32_t *pulNotificationValue, TickType_t xTicksToWait );</pre>
* <PRE>BaseType_t xTaskNotifyWait( uint32_t ulBitsToClearOnEntry, uint32_t ulBitsToClearOnExit, uint32_t *pulNotificationValue, TickType_t xTicksToWait );</pre>
<pre>
BaseType_t xTaskNotifyWaitIndexed( UBaseType_t uxIndexToWaitOn, uint32_t ulBitsToClearOnEntry, uint32_t ulBitsToClearOnExit, uint32_t *pulNotificationValue, TickType_t xTicksToWait );
</pre>
<pre>
BaseType_t xTaskNotifyWait( uint32_t ulBitsToClearOnEntry, uint32_t ulBitsToClearOnExit, uint32_t *pulNotificationValue, TickType_t xTicksToWait );
</pre>
*
* Waits for a direct to task notification to be pending at a given index within
* an array of direct to task notifications.
@ -2315,8 +2364,12 @@ void vTaskGenericNotifyGiveFromISR( TaskHandle_t xTaskToNotify, UBaseType_t uxIn
/**
* task. h
* <PRE>uint32_t ulTaskNotifyTakeIndexed( UBaseType_t uxIndexToWaitOn, BaseType_t xClearCountOnExit, TickType_t xTicksToWait );</pre>
* <PRE>uint32_t ulTaskNotifyTake( BaseType_t xClearCountOnExit, TickType_t xTicksToWait );</pre>
<pre>
uint32_t ulTaskNotifyTakeIndexed( UBaseType_t uxIndexToWaitOn, BaseType_t xClearCountOnExit, TickType_t xTicksToWait );
</pre>
<pre>
uint32_t ulTaskNotifyTake( BaseType_t xClearCountOnExit, TickType_t xTicksToWait );
</pre>
*
* Waits for a direct to task notification on a particular index in the calling
* task's notification array in a manner similar to taking a counting semaphore.
@ -2414,8 +2467,12 @@ uint32_t ulTaskGenericNotifyTake( UBaseType_t uxIndexToWaitOn, BaseType_t xClear
/**
* task. h
* <PRE>BaseType_t xTaskNotifyStateClearIndexed( TaskHandle_t xTask, UBaseType_t uxIndexToCLear );</pre>
* <PRE>BaseType_t xTaskNotifyStateClear( TaskHandle_t xTask );</pre>
<pre>
BaseType_t xTaskNotifyStateClearIndexed( TaskHandle_t xTask, UBaseType_t uxIndexToCLear );
</pre>
<pre>
BaseType_t xTaskNotifyStateClear( TaskHandle_t xTask );
</pre>
*
* See http://www.FreeRTOS.org/RTOS-task-notifications.html for details.
*
@ -2472,8 +2529,12 @@ BaseType_t xTaskGenericNotifyStateClear( TaskHandle_t xTask, UBaseType_t uxIndex
/**
* task. h
* <PRE>uint32_t ulTaskNotifyValueClearIndexed( TaskHandle_t xTask, UBaseType_t uxIndexToClear, uint32_t ulBitsToClear );</pre>
* <PRE>uint32_t ulTaskNotifyValueClear( TaskHandle_t xTask, uint32_t ulBitsToClear );</pre>
<pre>
uint32_t ulTaskNotifyValueClearIndexed( TaskHandle_t xTask, UBaseType_t uxIndexToClear, uint32_t ulBitsToClear );
</pre>
<pre>
uint32_t ulTaskNotifyValueClear( TaskHandle_t xTask, uint32_t ulBitsToClear );
</pre>
*
* See http://www.FreeRTOS.org/RTOS-task-notifications.html for details.
*
@ -2531,7 +2592,9 @@ uint32_t ulTaskGenericNotifyValueClear( TaskHandle_t xTask, UBaseType_t uxIndexT
/**
* task.h
* <pre>void vTaskSetTimeOutState( TimeOut_t * const pxTimeOut )</pre>
<pre>
void vTaskSetTimeOutState( TimeOut_t * const pxTimeOut );
</pre>
*
* Capture the current time for future use with xTaskCheckForTimeOut().
*
@ -2545,7 +2608,9 @@ void vTaskSetTimeOutState( TimeOut_t * const pxTimeOut ) PRIVILEGED_FUNCTION;
/**
* task.h
* <pre>BaseType_t xTaskCheckForTimeOut( TimeOut_t * const pxTimeOut, TickType_t * const pxTicksToWait );</pre>
<pre>
BaseType_t xTaskCheckForTimeOut( TimeOut_t * const pxTimeOut, TickType_t * const pxTicksToWait );
</pre>
*
* Determines if pxTicksToWait ticks has passed since a time was captured
* using a call to vTaskSetTimeOutState(). The captured time includes the tick
@ -2628,7 +2693,9 @@ BaseType_t xTaskCheckForTimeOut( TimeOut_t * const pxTimeOut, TickType_t * const
/**
* task.h
* <pre>BaseType_t xTaskCatchUpTicks( TickType_t xTicksToCatchUp );</pre>
<pre>
BaseType_t xTaskCatchUpTicks( TickType_t xTicksToCatchUp );
</pre>
*
* This function corrects the tick count value after the application code has held
* interrupts disabled for an extended period resulting in tick interrupts having