prcv_dtq

Outline

Receive from data queue (polling).

C format

 ER      prcv_dtq ( ID dtqid, VP_INT *p_data );


Assembly format

 MOVW    BC, #LOWW(_data)
 MOV     A,  #dtqid
 CALL    !!_prcv_dtq


Parameter(s)

I/O

Parameter

Description

I

 ID      dtqid;
ID number of the data queue from which a data element is received.

O

 VP_INT  *p_data;
Data element received from the data queue.



Explanation(s)

These service calls read data in the data queue area of the data queue specified by parameter dtqid and stores it to the area specified by parameter p_data.

If no data could be read from the data queue area of the target data queue (no data has been written to the data queue area) when either of these service calls is issued, the service call does not read data but E_TMOUT is returned.

Note If no data could be read from the data queue area of the target data queue (no data has been written to the data queue area) when either of these service calls is issued, the contents in the area specified by parameter p_data become undefined.

Return value

Macro

Value

Description

E_OK

0

Normal completion.

E_TMOUT

-50

Polling failure.

- No data exists in the target data queue.