Add in the vSemaphoreDelete() macro.

This commit is contained in:
Richard Barry 2011-07-27 14:12:35 +00:00
parent fc99c14905
commit 6fa8cd4302

View file

@ -711,6 +711,19 @@ typedef xQueueHandle xSemaphoreHandle;
*/
#define xSemaphoreCreateCounting( uxMaxCount, uxInitialCount ) xQueueCreateCountingSemaphore( ( uxMaxCount ), ( uxInitialCount ) )
/**
* semphr. h
* <pre>void vSemaphoreDelete( xSemaphoreHandle 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.
*
* @param xSemaphore A handle to the semaphore to be deleted.
*
* \page vSemaphoreDelete vSemaphoreDelete
* \ingroup Semaphores
*/
#define vSemaphoreDelete( xSemaphore ) vQueueDelete( ( xQueueHandle ) xSemaphore )
#endif /* SEMAPHORE_H */