DACS_ERR_T dacs_recv ( void *dst_data, uint32_t size, de_id_t src_de, dacs_process_id_t src_pid, uint32_t stream, dacs_wid_t wid, DACS_BYTE_SWAP_T swap )
Call parameters | |
*dst_data | A pointer to the beginning of the destination (receive) data buffer. |
size | The size of the message buffer. |
src_de | The message source DE. |
src_pid | The message source process. |
stream | The stream on which to receive the message, or DACS_STREAM_ALL. |
wid | A wait identifier. |
swap | The little-endian or big-endian byte-swapping flag.Possible values are:
|
Return parameter | |
*dst_data | The pointer to the received data buffer. |
The dacs_recv service asynchronously receives a message from another process. Upon successful return a receive operation is either pending or in progress. You should use dacs_test() or dacs_wait() to test for completion.
The number of bytes sent by the source process must be less than or equal to the local buffer size, otherwise the receive operation fails.
Stream identifiers are used to select messages for reception. A message will be received if the stream identifier of the message matches the stream identifier specified to dacs_recv(), or if DACS_STREAM_ALL is specified. Stream identifier values must be between 0 and DACS_STREAM_UB inclusive.
The swap flag must be the same at both ends of the transfer. If not the completion test (dacs_test() or dacs_wait()) will fail with DACS_ERR_BYTESWAP_MISMATCH, and no data is transferred.