TN_RCode
Result code returned by kernel services.
TN_ObjId
Magic number for object validity verification.
unsigned long TN_Timeout
The value representing maximum number of system ticks to wait.
enum TN_RCode tn_sem_signal(struct TN_Sem *sem)
Signal the semaphore.
enum TN_RCode tn_sem_acquire_polling(struct TN_Sem *sem)
The same as tn_sem_acquire() with zero timeout.
Definitions used through the whole kernel.
enum TN_RCode tn_sem_acquire(struct TN_Sem *sem, TN_Timeout timeout)
Acquire the semaphore.
struct TN_ListItem wait_queue
List of tasks that wait to acquire a semaphore.
enum TN_ObjId id_sem
id for object validity verification
enum TN_RCode tn_sem_iacquire_polling(struct TN_Sem *sem)
The same as tn_sem_acquire() with zero timeout, but for using in the ISR.
enum TN_RCode tn_sem_delete(struct TN_Sem *sem)
Destruct the semaphore.
enum TN_RCode tn_sem_isignal(struct TN_Sem *sem)
The same as tn_sem_signal() but for using in the ISR.
enum TN_RCode tn_sem_create(struct TN_Sem *sem, int start_count, int max_count)
Construct the semaphore.
int count
Current semaphore counter value.
int max_count
Max value of count