rcv_dtq
ER rcv_dtq (ID dtqid, VP_INT *p_data);
This service call processes as follows according to the situation of the data queue specified by the parameter dtqid.
- There is a data in the data queue.
This service call takes out the oldest data from the data queue and stores the data to the area specified by p_data.
When there is a task in the transmission wait queue, this service call stores the data sent by the task in the top of the transmission wait queue and moves it from the WAITING state (data transmission wait state) to the READY state.
This service call takes out the oldest data from the data queue and stores the data to the area specified by p_data.
When there is a task in the transmission wait queue, this service call stores the data sent by the task in the top of the transmission wait queue and moves it from the WAITING state (data transmission wait state) to the READY state.
- There is no data in the data queue and there is a task in the transmission wait queue.
This service call stores the data specified by the task in the top of the transmission wait queue to the area specified by p_data. As a result, the task is unlinked from the transmission wait queue and moves from the WAITING state (data transmission wait state) to the READY state, or from the WAITING-SUSPENDED state to the SUSPENDED state.
Note, this situation is caused only when the capacity of the data queue is 0.
This service call stores the data specified by the task in the top of the transmission wait queue to the area specified by p_data. As a result, the task is unlinked from the transmission wait queue and moves from the WAITING state (data transmission wait state) to the READY state, or from the WAITING-SUSPENDED state to the SUSPENDED state.
Note, this situation is caused only when the capacity of the data queue is 0.
- There is no data in the data queue and there is no task in the transmission wait queue.
This service call queues the invoking task to the reception wait queue of the target data queue and moves it from the RUNNING state to the WAITING state (data reception wait state).
The receiving WAITING state for a data queue is cancelled in the following cases.
This service call queues the invoking task to the reception wait queue of the target data queue and moves it from the RUNNING state to the WAITING state (data reception wait state).
The receiving WAITING state for a data queue is cancelled in the following cases.
Note Invoking tasks are queued to the reception wait queue of the target data queue in the order of the data reception request.