
B–61863E–1/06
2. PMC SYSTEM CALLPMC LIBRARY
151
SC/SC3/SC4 NB/NB2 16i/18i/21i 15i–A
f f f f
[Name]
os_wait_flg
[Description]
Waits for an event flag signal.
[Format]
ret = os_wait_flg(event_flag_id, wait_message,
and_or, wait_limit, return_message);
unsigned short ret ;
unsigned char event_flag_id ;
unsigned long wait_message ;
unsigned short and_or ;
long wait_limit ;
unsigned long *return_message ;
[Input]
event_flag_id Event flag ID (10 to 39)
wait_message Wait message
and_or AND 0, OR 1
wait_limit When a positive value is specified, the limit time
waiting state is set (one count: eight milliseconds).
When a negative value or 0 is specified, the waiting
state continues until the event flag is signaled.
[Output]
return_message
[Returns]
ret Completion code
0 ; The event flag signaling wait was released.
0107H ; The event flag ID is out of range (other than 10 to 39).
0112H ; There is no specified event flag ID.
0117H ; The event flag was deleted.
011AH ; The specified limit time has elapsed (for wait_limit > 0).
[Remarks]
When the and_or is the AND (0), AND is awaited. It waits for all the
flags specified by the wait_message to be signaled. 0 is always
returned for the return_message.
When it is the OR (1), OR is awaited. It waits for at least one of the
flags specified by the wait_message to be signaled. The signaled flag
is returned for the return message.
2.9
EVENT FLAG SIGNAL
WAIT