创建
SemaphoreHandle_t <b><font color="#64b5f6">xSemaphoreCreateMutex</font></b>( void );<br>
SemaphoreHandle_t <b><font color="#64b5f6">xSemaphoreCreateMutexStatic</font></b>( StaticSemaphore_t *<b>pxMutexBuffer</b>);
使用需定义 <span class="tag">##define</span> <b>configUSE_MUTEXES</b> 1
其他函数
void <b><font color="#64b5f6">vSemaphoreDelete</font></b>( SemaphoreHandle_t <b>xSemaphore </b>);
BaseType_t <b><font color="#64b5f6">xSemaphoreGive</font></b>( SemaphoreHandle_t <b>xSemaphore </b>);
BaseType_t <b><font color="#64b5f6">xSemaphoreGiveFromISR</font></b>(<br> SemaphoreHandle_t <b>xSemaphore</b>,<br> BaseType_t *<b>pxHigherPriorityTaskWoken</b><br> );<br>
BaseType_t <b><font color="#64b5f6">xSemaphoreTake</font></b>(<br> SemaphoreHandle_t <b>xSemaphore</b>,<br> TickType_t <b>xTicksToWait</b><br> );
BaseType_t <b><font color="#64b5f6">xSemaphoreGiveFromISR</font></b>(<br> SemaphoreHandle_t <b>xSemaphore</b>,<br> BaseType_t *<b>pxHigherPriorityTaskWoken</b><br> );<br><br>