| UbixOS
    2.0
    | 

| Functions | |
| uint32_t | sys_arch_sem_wait (struct sys_sem **s, uint32_t timeout) | 
| void | sys_sem_free (sys_sem_t **sem) | 
| err_t | sys_sem_new (sys_sem_t **sem, u8_t count) | 
| void | sys_sem_set_invalid (struct sys_sem **s) | 
| void | sys_sem_signal (struct sys_sem **s) | 
| int | sys_sem_valid (struct sys_sem **s) | 
Wait for a semaphore for the specified timeout
| sem | the semaphore to wait for | 
| timeout | timeout in milliseconds to wait (0 = wait forever) | 
Definition at line 104 of file sys_arch.c.
References LWIP_ASSERT, mutex, NULL, signaled, and ubthread_mutex_lock().
Referenced by sys_msleep().

| void sys_sem_free | ( | sys_sem_t ** | sem | ) | 
Delete a semaphore
| sem | semaphore to delete | 
Definition at line 75 of file sys_arch.c.
References NULL, sem_destroy(), and SYS_SEM_NULL.
Referenced by sys_msleep().

Create a new semaphore
| sem | pointer to the semaphore to create | 
| count | initial count of the semaphore | 
Definition at line 52 of file sys_arch.c.
References cond, ERR_OK, kmalloc(), kprintf(), mutex, NULL, sem_init(), signaled, ubthread_cond_init(), and ubthread_mutex_init().
Referenced by sys_msleep(), and tcpip_api_call().

| void sys_sem_set_invalid | ( | struct sys_sem ** | s | ) | 
Set a semaphore invalid so that sys_sem_valid returns 0
Definition at line 139 of file sys_arch.c.
| void sys_sem_signal | ( | struct sys_sem ** | s | ) | 
Signals a semaphore
| sem | the semaphore to signal | 
Definition at line 88 of file sys_arch.c.
References cond, LWIP_ASSERT, mutex, NULL, signaled, ubthread_cond_broadcast(), ubthread_mutex_lock(), and ubthread_mutex_unlock().

| int sys_sem_valid | ( | struct sys_sem ** | s | ) | 
Check if a semaphore is valid/allocated: return 1 for valid, 0 for invalid
Definition at line 131 of file sys_arch.c.
Referenced by tcpip_send_msg_wait_sem().