All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
CLProtocol::CCLAllAdapter Class Reference

Wraps the CLAllSerial.dll. More...

#include <CLAllAdapter.h>

Inheritance diagram for CLProtocol::CCLAllAdapter:

Classes

struct  CLAllProxy
 

Static Public Member Functions

static void Destroy (ISerialAdapter *pAdapter)
 Destroy the factory and all its objects. More...
 

ISerialAdapter interface

hSerRef m_SerialRef
 handle of the serial port More...
 
CLUINT32 m_SerialIndex
 Index of the serial port. More...
 
lib_handle_t m_ClAlldllHandle
 handle to the loaded ClAllSerial DLL More...
 
CLAllProxy m_clallproxy
 CLALL functions pointers. More...
 
CLUINT32 m_PreviousBaudRate
 the previous baud rate as set via SetBaudRate; zero otherwise More...
 
static SerialPortMapg_pSerialPortMap
 
static void GetPortIDs (GENICAM_NAMESPACE::gcstring_vector &TheVector)
 used to copy the content of the SerialPort ma to a std::map More...
 
static ISerialAdapterGetSerialAdapter (GENICAM_NAMESPACE::gcstring PortID)
 used to copy the content of the SerialPort ma to a std::map More...
 
virtual CLINT32 CLPROTOCOL clSerialRead (CLINT8 *, CLUINT32 *, CLUINT32)
 calls clSerialRead as defined by the camera link standard More...
 
virtual CLINT32 CLPROTOCOL clSerialWrite (CLINT8 *, CLUINT32 *, CLUINT32)
 calls clSerialWrite as defined by the camera link standard More...
 
virtual CLINT32 CLPROTOCOL clGetSupportedBaudRates (CLUINT32 *)
 returns the valid baud rates of the current interface. More...
 
virtual CLINT32 CLPROTOCOL clSetBaudRate (CLUINT32)
 This function sets the baud rate for the serial port of the selected device. More...
 
virtual CLINT32 SerialInit (void)
 Opens the port. More...
 
virtual void SerialClose (void)
 Closes the port. More...
 
virtual void CheckError (CLINT32 ErrorCode)
 throws an exception if the ErrorCode describes an error More...
 
static void CheckError (CLINT32 ErrorCode, CLUINT32 SerialIndex, CLAllProxy &)
 
static void InternalGetPortMap (SerialPortMap &)
 retrieves the list of port mapped by PortID More...
 
 CCLAllAdapter (CLUINT32, CLAllProxy &)
 Object constructor. More...
 
virtual ~CCLAllAdapter ()
 Object destructor. More...
 

Additional Inherited Members

Detailed Description

Wraps the CLAllSerial.dll.

Definition at line 70 of file CLAllAdapter.h.

Constructor & Destructor Documentation

◆ CCLAllAdapter()

CLProtocol::CCLAllAdapter::CCLAllAdapter ( CLUINT32  ,
CLAllProxy  
)
private

Object constructor.

◆ ~CCLAllAdapter()

virtual CLProtocol::CCLAllAdapter::~CCLAllAdapter ( )
privatevirtual

Object destructor.

Member Function Documentation

◆ CheckError() [1/2]

virtual void CLProtocol::CCLAllAdapter::CheckError ( CLINT32  ErrorCode)
virtual

throws an exception if the ErrorCode describes an error

A CLErrException will be thrown.

Parameters
ErrorCodeThe error code to validate. If at he error is found,

Implements CLProtocol::ISerialAdapter.

◆ CheckError() [2/2]

static void CLProtocol::CCLAllAdapter::CheckError ( CLINT32  ErrorCode,
CLUINT32  SerialIndex,
CLAllProxy  
)
staticprivate

◆ clGetSupportedBaudRates()

virtual CLINT32 CLPROTOCOL CLProtocol::CCLAllAdapter::clGetSupportedBaudRates ( CLUINT32 baudRates)
virtual

returns the valid baud rates of the current interface.

as described by serialRefPtr. See Table B-2 of the Camera Link docu for more information on constants.

Parameters
baudRatesBitfield that describes all supported baud rates of the serial port

Implements ISerial.

◆ clSerialRead()

virtual CLINT32 CLPROTOCOL CLProtocol::CCLAllAdapter::clSerialRead ( CLINT8 buffer,
CLUINT32 bufferSize,
CLUINT32  serialTimeOut 
)
virtual

calls clSerialRead as defined by the camera link standard

Parameters
bufferPoints to a user-allocated buffer. Upon a successful call, buffer contains the data read from the serial device. Upon failure, this buffer is not affected. Caller should ensure that buffer is at least numBytes in size.
bufferSizeThis is the number of bytes requested by the caller.
serialTimeOutIndicates the timeout in milliseconds.

Implements ISerial.

◆ clSerialWrite()

virtual CLINT32 CLPROTOCOL CLProtocol::CCLAllAdapter::clSerialWrite ( CLINT8 buffer,
CLUINT32 bufferSize,
CLUINT32  serialTimeOut 
)
virtual

calls clSerialWrite as defined by the camera link standard

Parameters
bufferContains data to write to the serial device.
bufferSizeContains the buffer size indicating the number of bytes to be written. Upon a successful call, bufferSize contains the number of bytes written to the serial device.
serialTimeOutIndicates the timeout in milliseconds.

Implements ISerial.

◆ clSetBaudRate()

virtual CLINT32 CLPROTOCOL CLProtocol::CCLAllAdapter::clSetBaudRate ( CLUINT32  baudRate)
virtual

This function sets the baud rate for the serial port of the selected device.

values represented by the CL_BAUDRATE constants in table B-2. By default, the baud rate for serial communication is 9600.

Parameters
baudRateThe baud rate you want to use. This parameter expects the

Implements ISerial.

◆ Destroy()

static void CLProtocol::CCLAllAdapter::Destroy ( ISerialAdapter pAdapter)
static

Destroy the factory and all its objects.

◆ GetPortIDs()

static void CLProtocol::CCLAllAdapter::GetPortIDs ( GENICAM_NAMESPACE::gcstring_vector &  TheVector)
static

used to copy the content of the SerialPort ma to a std::map

◆ GetSerialAdapter()

static ISerialAdapter* CLProtocol::CCLAllAdapter::GetSerialAdapter ( GENICAM_NAMESPACE::gcstring  PortID)
static

used to copy the content of the SerialPort ma to a std::map

◆ InternalGetPortMap()

static void CLProtocol::CCLAllAdapter::InternalGetPortMap ( SerialPortMap )
staticprivate

retrieves the list of port mapped by PortID

◆ SerialClose()

virtual void CLProtocol::CCLAllAdapter::SerialClose ( void  )
virtual

Closes the port.

Implements CLProtocol::ISerialAdapter.

◆ SerialInit()

virtual CLINT32 CLProtocol::CCLAllAdapter::SerialInit ( void  )
virtual

Opens the port.

Implements CLProtocol::ISerialAdapter.

Member Data Documentation

◆ g_pSerialPortMap

SerialPortMap* CLProtocol::CCLAllAdapter::g_pSerialPortMap
staticprivate

Definition at line 141 of file CLAllAdapter.h.

◆ m_ClAlldllHandle

lib_handle_t CLProtocol::CCLAllAdapter::m_ClAlldllHandle
private

handle to the loaded ClAllSerial DLL

Definition at line 144 of file CLAllAdapter.h.

◆ m_clallproxy

CLAllProxy CLProtocol::CCLAllAdapter::m_clallproxy
private

CLALL functions pointers.

Definition at line 147 of file CLAllAdapter.h.

◆ m_PreviousBaudRate

CLUINT32 CLProtocol::CCLAllAdapter::m_PreviousBaudRate
private

the previous baud rate as set via SetBaudRate; zero otherwise

Definition at line 150 of file CLAllAdapter.h.

◆ m_SerialIndex

CLUINT32 CLProtocol::CCLAllAdapter::m_SerialIndex
private

Index of the serial port.

Definition at line 134 of file CLAllAdapter.h.

◆ m_SerialRef

hSerRef CLProtocol::CCLAllAdapter::m_SerialRef
private

handle of the serial port

Definition at line 128 of file CLAllAdapter.h.


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


rc_genicam_api
Author(s): Heiko Hirschmueller
autogenerated on Wed Dec 4 2024 03:10:12