-For semaphore related APIs refer MZ_sys_cmsis_os2.h file.
More...
-For semaphore related APIs refer MZ_sys_cmsis_os2.h file.
◆ mz_sem_create()
uint8_t mz_sem_create |
( |
mz_semaphore_t * |
c, |
|
|
uint8_t |
cnt, |
|
|
uint8_t |
init |
|
) |
| |
This function is used to create and initialize the semaphore object Create and Initialize a Semaphore object.
- Parameters
-
c | mz_mutex_t |
cnt | uint8_t |
init | uint8_t |
- Returns
- semaphore ID for reference by other functions or NULL in case of error.
◆ mz_sem_delete()
This function is used to delete a semaphore object Delete a Semaphore object.
- Parameters
-
- Returns
- status code that indicates the execution status of the function.
◆ mz_sem_wait()
This function is used to acquire a semaphore token or timout if no tokens are available Acquire a Semaphore token or timeout if no tokens are available.
- Parameters
-
c | mz_semaphore_t |
timeout | uint32_t |
- Returns
- status code that indicates the execution status of the function.
◆ mz_sem_release()
This function is used to acquire a semaphore token or timout if no tokens are available Release a Semaphore token up to the initial maximum count.
- Parameters
-
- Returns
- status code that indicates the execution status of the function.
◆ mz_sem_isvalid()
This functiion is used to check the semaphore object validity Check the Semaphore object validation.
- Parameters
-
- Returns
- status code that indicates the execution status of the function.
◆ mz_sem_invalid()
This function is used to invalidate the created semaphore Semaphore object is invalid.
- Parameters
-
- Returns
- status code that indicates the execution status of the function.