RayComposer Device API Documentation  1.6
Public API for RayComposer laser show DAC interfaces.
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
Device Access

Open and Close devices. Read and Set the device label. More...

Typedefs

typedef int(RCCALLTRCOpenDevice )(const char *)
 
typedef int(RCCALLTRCCloseDevice )(int)
 
typedef int(RCCALLTRCDeviceLabel )(int, char *, unsigned int)
 
typedef int(RCCALLTRCSetDeviceLabel )(int, const char *)
 

Functions

int RCAPI RCOpenDevice (const char *deviceId)
 Open Device. More...
 
int RCAPI RCCloseDevice (int handle)
 Close Device. More...
 
int RCAPI RCDeviceLabel (int handle, char *deviceLabel, unsigned int maxLength)
 Read the device label. More...
 
int RCAPI RCSetDeviceLabel (int handle, const char *deviceLabel)
 Set the device label. More...
 

Detailed Description

Open and Close devices. Read and Set the device label.

Typedef Documentation

typedef int(RCCALL * TRCOpenDevice)(const char *)

Function type definition for RCOpenDevice()

typedef int(RCCALL * TRCCloseDevice)(int)

Function type definition for RCCloseDevice()

typedef int(RCCALL * TRCDeviceLabel)(int, char *, unsigned int)

Function type definition for RCDeviceLabel()

typedef int(RCCALL * TRCSetDeviceLabel)(int, const char *)

Function type definition for RCSetDeviceLabel()

Function Documentation

int RCAPI RCOpenDevice ( const char *  deviceId)

Open Device.

Open the device specified by the device ID string as returned by RCDeviceID().

Parameters
deviceIdDevice ID string as read with by RCDeviceID(). This is an UTF-8 encoded printable string with terminating nul character.
Returns
On success, a handle to the device. If the return value is negative an error has occured and the device has not been opened. The return value indicates one of the RCReturnCode error codes.
int RCAPI RCCloseDevice ( int  handle)

Close Device.

Close the device identified by its device handle.

Parameters
handleDevice handle as obtained by RCOpenDevice()
Returns
RCOk on success. If an error occured, a negative value indicating one of the RCReturnCode error codes.
int RCAPI RCDeviceLabel ( int  handle,
char *  deviceLabel,
unsigned int  maxLength 
)

Read the device label.

This function reads the device label for the device specified by handle. The device label is a UTF-8 encoded string that the user can set to further describe the device. For instance the user can set the device label "Projector left of stage" for the device controlling the projector located left of stage. The device label can be set using RCSetDeviceLabel()

Parameters
handleDevice handle as obtained by RCOpenDevice();
deviceLabelpointer
maxLengthLength of the buffer passes as deviceLabel
Returns
The number of characters written to deviceLabel. If an error occured, a negative value indicating one of the RCReturnCode error codes is returned.
int RCAPI RCSetDeviceLabel ( int  handle,
const char *  deviceLabel 
)

Set the device label.

This function sets the device label to the nul-terminated string passend in deviceLabel.

Parameters
handleDevice handle as obtained by RCOpenDevice()
deviceLabelUTF-8 encoded string containing the device label. The string must be end with a terminating nul character.
Returns
RCOk on success. If an error occured, a negative value indicating one of the RCReturnCode error codes is returned.