OceanDirect  2.4.0
OceanDirect C++/C API
oceandirect::api::SerialPortAPI Class Reference

Public Member Functions

int getBaudRate (long deviceID, int *errorCode)
 
void saveSettingsToFlash (long deviceID, int *errorCode)
 
void setBaudRate (long deviceID, int *errorCode, int baudRate)
 

Static Public Member Functions

static SerialPortAPIgetInstance ()
 
static void shutdown ()
 

Member Function Documentation

◆ getBaudRate()

int oceandirect::api::SerialPortAPI::getBaudRate ( long  deviceID,
int *  errorCode 
)

Get the baud rate of the serial port.

Parameters
deviceIDthe ID of the device returned by getDeviceIDs.
errorCodea code indicating the result of the operation: ERROR_SUCCESS on success; ERROR_NO_DEVICE if the device does not exist; ERROR_FEATURE_NOT_FOUND the feature is not enabled on the specified device; ERROR_TRANSFER_ERROR the device protocol for the feature could not be found.
Returns
the baud rate of the serial port.

◆ saveSettingsToFlash()

void oceandirect::api::SerialPortAPI::saveSettingsToFlash ( long  deviceID,
int *  errorCode 
)

Save settings to flash memory.

Parameters
deviceIDthe ID of the device returned by getDeviceIDs.
errorCodea code indicating the result of the operation: ERROR_SUCCESS on success; ERROR_NO_DEVICE if the device does not exist; ERROR_FEATURE_NOT_FOUND the feature is not enabled on the specified device; ERROR_TRANSFER_ERROR the device protocol for the feature could not be found.

◆ setBaudRate()

void oceandirect::api::SerialPortAPI::setBaudRate ( long  deviceID,
int *  errorCode,
int  baudRate 
)

Set the baud rate of the serial port.

Parameters
deviceIDthe ID of the device returned by getDeviceIDs.
errorCodea code indicating the result of the operation: ERROR_SUCCESS on success; ERROR_NO_DEVICE if the device does not exist; ERROR_FEATURE_NOT_FOUND the feature is not enabled on the specified device; ERROR_TRANSFER_ERROR the device protocol for the feature could not be found.
baudRatethe desired baud rate of the serial port.

The documentation for this class was generated from the following file: