
2. PMC SYSTEM CALL
B–61863E–1/06
PMC LIBRARY
172
SC/SC3/SC4 NB/NB2 16i/18i/21i 15i–A
f f f f
[Name]
os_recv_pkt
[Description]
Receives the packet from the sending destination task.
[Format]
ret = os_recv_pkt(packet_id,timeout_value,packet_address,
recv_packet_id,recv_packet_type,marking) ;
unsigned short ret ;
unsigned long packet_id ;
long timeout_value ;
unsigned char **packet_address ;
unsigned long *recv_packet_id ;
unsigned char *recv_packet_type ;
unsigned char *marking ;
[Input]
packet_id Specified packet ID
timeout_value If the packet queue is empty:
S For a positive value, the limit time waiting state is
set (one count: eight milliseconds).
S For 0, there is no limit time waiting state.
S For a negative value, the permanent waiting state
is set.
[Output]
*packet_address
recv_packet_id
recv_packet_type
marking NO 0/YES 1
[Returns]
ret Completion code
0 ; The packet has been received normally.
011AH ; The specified limit time has elapsed (for timeout_value > 0).
[Remarks]
packet_id specifies the ID of the packet to be received. For 0, the
packet at the beginning of the packet queue is received. The ID of the
received packet is returned to recv_packet_id.
The type of received packet is returned to recv_packet_type. Whether
there is a packet mark is returned to marking.
If the packet queue is empty, the task enters the wait state.
2.30
RECEIVING THE
PACKET