semInit (Function) |
Top Previous Next |
The semInit() function will initialize a SEMAPHORE variable with the specified initial value. The semInit() function must be called before any other operations can be performed on the semaphore.
Input: initval : INT The initial value for the semaphore.
Returns: SEMAPHORE The initialized semaphore.
Declaration: FUNCTION semInit : SEMAPHORE;
Example: INCLUDE rtcu.inc |