OceanDirectLighthouseC++ 3.1.3
OceanDirect Lighthouse C++/C API
oceandirect::api::EthernetAPI Class Reference

#include <EthernetAPI.h>

Public Member Functions

 EthernetAPI ()=default
 
virtual ~EthernetAPI ()=default
 
virtual bool getGigabitEthernetEnableStatus (long deviceID, int *errorCode, std::uint32_t interfaceIndex)
 
virtual void getMACAddress (long deviceID, int *errorCode, std::uint32_t interfaceIndex, std::uint8_t *macAddress, std::uint32_t macAddressLength)
 
virtual void setGigabitEthernetEnableStatus (long deviceID, int *errorCode, std::uint32_t interfaceIndex, bool enable)
 
virtual void setMACAddress (long deviceID, int *errorCode, std::uint32_t interfaceIndex, std::uint8_t *macAddress, std::uint32_t macAddressLength)
 

Static Public Member Functions

static EthernetAPIgetInstance ()
 
static void shutdown ()
 

Static Protected Attributes

static EthernetAPIinstance
 

Constructor & Destructor Documentation

◆ EthernetAPI()

oceandirect::api::EthernetAPI::EthernetAPI ( )
default

◆ ~EthernetAPI()

virtual oceandirect::api::EthernetAPI::~EthernetAPI ( )
virtualdefault

Member Function Documentation

◆ getGigabitEthernetEnableStatus()

virtual bool oceandirect::api::EthernetAPI::getGigabitEthernetEnableStatus ( long deviceID,
int * errorCode,
std::uint32_t interfaceIndex )
virtual

Read the gigabit ethernet status on a specified interface e.g. Ethernet. This function only applies to HDX/FX devices.

See also
setGigabitEthernetEnableStatus()
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.
interfaceIndexthe specified interface.
Returns
true if the gigabit ethernet is enabled on the specified interface, false otherwise.

◆ getInstance()

static EthernetAPI * oceandirect::api::EthernetAPI::getInstance ( )
static

◆ getMACAddress()

virtual void oceandirect::api::EthernetAPI::getMACAddress ( long deviceID,
int * errorCode,
std::uint32_t interfaceIndex,
std::uint8_t * macAddress,
std::uint32_t macAddressLength )
virtual

Read the mac address on a specified interface e.g. Ethernet. This function only applies to HDX/FX devices.

See also
setMACAddress()
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.
interfaceIndexthe specified interface.
macAddressoutput buffer for mac address.
macAddressLengthoutput buffer size.

◆ setGigabitEthernetEnableStatus()

virtual void oceandirect::api::EthernetAPI::setGigabitEthernetEnableStatus ( long deviceID,
int * errorCode,
std::uint32_t interfaceIndex,
bool enable )
virtual

Enable or disable the gigabit ethernet status on a specified interface e.g. Ethernet. This function only applies to HDX/FX devices.

See also
getGigabitEthernetEnableStatus()
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.
interfaceIndexthe specified interface.
enabletrue will enable the gigabit ethernet, false will disable otherwise.

◆ setMACAddress()

virtual void oceandirect::api::EthernetAPI::setMACAddress ( long deviceID,
int * errorCode,
std::uint32_t interfaceIndex,
std::uint8_t * macAddress,
std::uint32_t macAddressLength )
virtual

Write the mac address on a specified interface e.g. Ethernet. This function only applies to HDX/FX devices.

See also
setMACAddress()
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.
interfaceIndexthe specified interface.
macAddressthe new mac address.
macAddressLengththe mac address buffer size.

◆ shutdown()

static void oceandirect::api::EthernetAPI::shutdown ( )
static

Member Data Documentation

◆ instance

EthernetAPI* oceandirect::api::EthernetAPI::instance
staticprotected

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