INtime SDK Help
ntxReceiveRtData
INtime SDK v7.1 > About INtime > INtime Kernel > Mailboxes > ntxReceiveRtData

Waits for and then copies arbitrary data out of an RT data mailbox.

Note:   If the NTX application must operate on data that contains RTHANDLEs, you must convert the handles using ntxImportRtHandle. See Handle conversion.
WORD ntxReceiveRtData(

NTXHANDLE hMailbox,
LPVOID pMessage,
DWORD dwMilliseconds
);

Parameters

hMailbox
RT data mailbox to await the data from.
pMessage
Pointer to the place the data will be copied to. The number of bytes specified in NTX_DATA_MESSAGE_SIZE bytes must be available.
dwMilliseconds
The number of milliseconds the calling thread waits:
NO_WAIT The thread does not wait.
INFINITE The thread waits for its request to be fully satisfied.
Any positive integer Calling thread goes to sleep for this many milliseconds, after which it awakes.

Note: The kernel converts milliseconds to high-level ticks.

Return Values

The number of bytes received in this operation.
Success
NTX_ERROR
To determine the status, call ntxGetLastRtError

Status

E_OK 0x0000
No exceptional conditions occurred.
E_TIME 0x0001
Either the calling thread was not willing to wait and there was no message available, or the thread waited in the thread queue and its designated waiting period elapsed before the message arrived.
E_EXIST 0x0006
hMailbox is not a handle for an existing object.
E_TYPE 0x8002
Either hMailbox is not a handle for a mailbox or the mailbox is not a data mailbox.
E_BAD_ADDR 0x800F
pMessage is invalid.
E_NTX_INTERNAL_ERROR
The DLL could not contact the RT kernel to complete the request.

Requirements

Versions Defined in Include Link to
INtime 3.0 intime/nt/include/ntx.h ntx.h ntx.lib
INtime 4.01 (for 64-bit Windows) intime/nt/include/ntx.h ntx.h ntx64.lib

See Also

Mailbox system calls, ntxImportRtHandle, Handle conversion, high-level ticks