next up previous
Next: RTDX_Service Listing Up: RTDX_Service Previous: RTDX_Service


RTDX_Service API

RTDX_Service Creator of an instance of class RTDX_Service. The initialization is done in the member function Init in order to prevent member initialization before a GUI is ready.
   
RTDX_Init It initializes the COM-interface, then instantiates four RTDX-channels, writes the board- and CPU-name to the channels and configures the RTDX interface for continuous mode with 8 buffers of 2048 byte each.
   
RTDX_OpenCommandChannel Opens the command channel 'cchan' for output to the client.
   
RTDX_OpenResponseChannel Opens the response channel 'rchan' for input from the client.
   
RTDX_OpenWriteChannel Opens the write channel 'ichan' for output to the client.
   
RTDX_OpenReadChannel Opens the read channel 'ochan' for input from the client.
   
RTDX_CloseCommandChannel Closes the command channel.
   
RTDX_CloseResponseChannel Closes the response channel.
   
RTDX_CloseWriteChannel Closes the write channel.
   
RTDX_CloseReadChannel Closes the read channel.
   
RTDX_OpenAllChannels Opens the command, response, write and read channels.
   
RTDX_CloseAllChannels Closes the command, response, write and read channels.
   
RTDX_CommandToClient Sends a command to the client via the command-channel.
   
RTDX_ResponseFromClient Receives a response from the client via the response channel.
   
RTDX_DataToClient Sends data to the client via the write-channel.
   
RTDX_DataFromClient Reads data from the client via the read-channel.
   

RTDX_Service


RTDX_Service( )

The class instance creator. It has no parameters.
Returns:


Init


long Init( w_chr* boardName, w_chr* processorName )

Init initializes the COM-interface, then instantiates four RTDX-channels, writes the board- and processor-name to the channels and configures the RTDX interface for continuous mode with 8 buffers of 2048 byte each.

Parameters:

boardName Name of the processor on the DSP-board.
boardName Name of the DSP-board.



Returns:

0 success
-1 instantiation error 'cchan'-channel
-2 instantiation error 'rchan'-channel
-3 instantiation error 'ichan'-channel
-4 instantiation error 'ochan'-channel
-11 board/cpu-name error 'cchan'-channel
-12 board/cpu-name error 'rchan'-channel
-13 board/cpu-name error 'ichan'-channel
-14 board/cpu-name error 'ochan'-channel
-21 RTDX-disable error
-22 RTDX-configuration error
-23 RTDX-enable error


OpenCommandChannel


long OpenCommandChannel( )

The OpenCommandChannel opens the command channel 'cchan' for output to the client.
Returns:

long - Success / Failure


OpenResponseChannel


long OpenResponseChannel( )

The OpenResponseChannel opens the response channel 'rchan' for input from the client.
Returns:

long - Success / Failure


OpenWriteChannel


long OpenWriteChannel( )

The OpenWriteChannel opens the write channel 'ichan' for output to the client.
Returns:

long - Success / Failure


OpenReadChannel


long OpenReadChannel( )

The OpenReadChannel opens the read channel 'ochan' for input from the client.
Returns:

long - Success / Failure


CloseCommandChannel


long CloseCommandChannel( )

CloseCommandChannel closes the command channel 'cchan'. No further operations may be performed using this channel.

Returns:

long - Success / Failure


CloseResponseChannel


long CloseResponseChannel( )

CloseResponseChannel closes the response channel 'rchan'. No further operations may be performed using this channel.

Returns:

long - Success / Failure


CloseWriteChannel


long CloseWriteChannel( )

CloseWriteChannel closes the write channel 'ichan'. No further operations may be performed using this channel.

Returns:

long - Success / Failure


CloseReadChannel


long CloseReadChannel( )

CloseReadChannel closes the read channel 'cchan'. No further operations may be performed using this channel.

Returns:

long - Success / Failure


OpenAllChannels


long OpenAllChannels( )

The OpenAllChannels opens all 4 channels.

Returns:

0 success
1 error when opening channel 'cchan'
-2 error when opening channel 'rchan'
-3 error when opening channel 'ichan'
-4 error when opening channel 'ochan'


CloseAllChannels


long CloseAllChannels( )

The CloseAllChannels closes all 4 channels.

Returns:

0 success
1 error when closing channel 'cchan'
-2 error when closing channel 'rchan'
-3 error when closing channel 'ichan'
-4 error when closing channel 'ochan'


Command To Client


long CommandToClient( long nCommand )

Send command code to client.

Parameters:

nCommand command code as 'long'-integer.



Returns:

long Success - Sending of Command is valid.
  Failure - Error occurred during sending.


Response From Client


long ResponseFromClient( long* pResponse )

Receive response code from client.

Parameters:

pResponse pointer to storage location for response code ('long'-integer).



Returns:

long Success - Data read is valid.
  Failure - Error occurred during read.


Data To Client


long DataToClient( PARAMETER pData)

Send data to client. This is a heavily overloaded member function for different parameter types. 'pData' is a pointer to a storage location containing data of type PARAMETER.

Parameter Type (any of the following) :

long* pointer to long.



Returns:

long Success - Sending of data is succeeded.
  Failure - Error occurred during sending.


Data From Client


long DataFromClient( PARAMETER pData)

Receive data from client. This is a heavily overloaded member function for different parameter types. 'pData' is a pointer to a storage location containing data of type PARAMETER.

Parameter Type (any of the following) :

long* pointer to long.



Returns:

long Success - Receiving of data is succeeded.
  Failure - Error occurred during receiving.



next up previous
Next: RTDX_Service Listing Up: RTDX_Service Previous: RTDX_Service
H. Rogalla 2005-12-07