ChibiOS
21.6.0
|
Nil RTOS semaphores header file. More...
Go to the source code of this file.
Macros | |
Semaphores macros | |
#define | __SEMAPHORE_DATA(name, n) {n} |
Data part of a static semaphore initializer. More... | |
#define | SEMAPHORE_DECL(name, n) semaphore_t name = __SEMAPHORE_DATA(name, n) |
Static semaphore initializer. More... | |
Macro Functions | |
#define | chSemObjectInit(sp, n) ((sp)->cnt = (n)) |
Initializes a semaphore with the specified counter value. More... | |
#define | chSemReset(sp, n) chSemResetWithMessage(sp, n, MSG_RESET) |
Performs a reset operation on the semaphore. More... | |
#define | chSemResetI(sp, n) chSemResetWithMessageI(sp, n, MSG_RESET) |
Performs a reset operation on the semaphore. More... | |
#define | chSemWait(sp) chSemWaitTimeout(sp, TIME_INFINITE) |
Performs a wait operation on a semaphore. More... | |
#define | chSemWaitS(sp) chSemWaitTimeoutS(sp, TIME_INFINITE) |
Performs a wait operation on a semaphore. More... | |
#define | chSemFastWaitI(sp) ((sp)->cnt--) |
Decreases the semaphore counter. More... | |
#define | chSemFastSignalI(sp) ((sp)->cnt++) |
Increases the semaphore counter. More... | |
#define | chSemGetCounterI(sp) ((sp)->cnt) |
Returns the semaphore counter current value. More... | |
Functions | |
msg_t | chSemWaitTimeout (semaphore_t *sp, sysinterval_t timeout) |
Performs a wait operation on a semaphore with timeout specification. More... | |
msg_t | chSemWaitTimeoutS (semaphore_t *sp, sysinterval_t timeout) |
Performs a wait operation on a semaphore with timeout specification. More... | |
void | chSemSignal (semaphore_t *sp) |
Performs a signal operation on a semaphore. More... | |
void | chSemSignalI (semaphore_t *sp) |
Performs a signal operation on a semaphore. More... | |
void | chSemResetWithMessage (semaphore_t *sp, cnt_t n, msg_t msg) |
Performs a reset operation on the semaphore. More... | |
void | chSemResetWithMessageI (semaphore_t *sp, cnt_t n, msg_t msg) |
Performs a reset operation on the semaphore. More... | |
Nil RTOS semaphores header file.
Definition in file nil/include/chsem.h.