Public Types | Public Member Functions | Protected Member Functions | Protected Attributes
SerRelayBoard Class Reference

#include <SerRelayBoard.h>

List of all members.

Public Types

enum  RelBoardCmd {
  CMD_SET_CHARGE_RELAY = 1, CMD_RESET_POS_CNT = 2, CMD_QUICK_STOP = 4, CMD_SET_RELAY1 = 8,
  CMD_SET_RELAY2 = 16, CMD_SET_RELAY3 = 32, CMD_SET_RELAY4 = 64, CMD_SET_RELAY5 = 128,
  CMD_SET_RELAY6 = 256, CMD_ZERO_GYRO = 512
}
enum  RelBoardConfig {
  CONFIG_HAS_IOBOARD = 1, CONFIG_HAS_USBOARD = 2, CONFIG_HAS_GYROBOARD = 4, CONFIG_HAS_RADARBOARD1 = 8,
  CONFIG_HAS_RADARBOARD2 = 16, CONFIG_HAS_DRIVES = 32
}
enum  RelBoardReturns {
  NO_ERROR = 0, NOT_INITIALIZED = 1, GENERAL_SENDING_ERROR = 2, TOO_LESS_BYTES_IN_QUEUE = 3,
  NO_MESSAGES = 4, CHECKSUM_ERROR = 5
}
enum  TypeLCD { LCD_20CHAR_TEXT, LCD_60CHAR_TEXT, RELAY_BOARD_1_4 }

Public Member Functions

int evalRxBuffer ()
int getAnalogIn (int *piAnalogIn)
int getBatteryVoltage ()
int getChargeCurrent ()
int getDigIn ()
bool init ()
bool isEMStop ()
bool isScannerStop ()
bool reset ()
int sendRequest ()
 SerRelayBoard (std::string ComPort, int ProtocolVersion=1)
int setDigOut (int iChannel, bool bOn)
bool shutdown ()
 ~SerRelayBoard ()

Protected Member Functions

void convDataToSendMsg (unsigned char cMsg[])
bool convRecMsgToData (unsigned char cMsg[])
void rxCharArray ()
void txCharArray ()

Protected Attributes

bool m_bComInit
char m_cDebugRearLeft [4]
char m_cDebugRearRight [4]
char m_cSoftEMStop
unsigned char m_cTextDisplay [60]
double m_dLastPosRearLeft
double m_dLastPosRearRight
int m_iChargeCurrent
int m_iCmdRelayBoard
int m_iConfigRelayBoard
int m_iDigIn
int m_iIOBoardDigOut
int m_iMotRearLeftStatus
int m_iMotRearRightStatus
int m_iNumBytesSend
int m_iPosMeasMotRearLeftEnc
int m_iPosMeasMotRearRightEnc
int m_iProtocolVersion
int m_iRelBoardAnalogIn [4]
int m_iRelBoardBattVoltage
int m_iRelBoardKeyPad
int m_iRelBoardStatus
int m_iRelBoardTempSensor
int m_iTypeLCD
int m_iUSBoardSensorActive
int m_iVelCmdMotLeftEncS
int m_iVelCmdMotRearLeftEncS
int m_iVelCmdMotRearRightEncS
int m_iVelCmdMotRightEncS
int m_iVelMeasMotRearLeftEncS
int m_iVelMeasMotRearRightEncS
Mutex m_Mutex
int m_NUM_BYTE_SEND
SerialIO m_SerIO
std::string m_sNumComPort

Detailed Description

Driver class for communication with a Neobotix RelayBoard. Uses RS422 with 420 kBaud.

Definition at line 32 of file SerRelayBoard.h.


Member Enumeration Documentation

Enumerator:
CMD_SET_CHARGE_RELAY 
CMD_RESET_POS_CNT 
CMD_QUICK_STOP 
CMD_SET_RELAY1 
CMD_SET_RELAY2 
CMD_SET_RELAY3 
CMD_SET_RELAY4 
CMD_SET_RELAY5 
CMD_SET_RELAY6 
CMD_ZERO_GYRO 

Definition at line 74 of file SerRelayBoard.h.

Enumerator:
CONFIG_HAS_IOBOARD 
CONFIG_HAS_USBOARD 
CONFIG_HAS_GYROBOARD 
CONFIG_HAS_RADARBOARD1 
CONFIG_HAS_RADARBOARD2 
CONFIG_HAS_DRIVES 

Definition at line 88 of file SerRelayBoard.h.

Enumerator:
NO_ERROR 
NOT_INITIALIZED 
GENERAL_SENDING_ERROR 
TOO_LESS_BYTES_IN_QUEUE 
NO_MESSAGES 
CHECKSUM_ERROR 

Definition at line 64 of file SerRelayBoard.h.

Enumerator:
LCD_20CHAR_TEXT 
LCD_60CHAR_TEXT 
RELAY_BOARD_1_4 

Definition at line 98 of file SerRelayBoard.h.


Constructor & Destructor Documentation

SerRelayBoard::SerRelayBoard ( std::string  ComPort,
int  ProtocolVersion = 1 
)

Definition at line 43 of file SerRelayBoard.cpp.

Definition at line 70 of file SerRelayBoard.cpp.


Member Function Documentation

void SerRelayBoard::convDataToSendMsg ( unsigned char  cMsg[]) [protected]

Definition at line 312 of file SerRelayBoard.cpp.

bool SerRelayBoard::convRecMsgToData ( unsigned char  cMsg[]) [protected]

Definition at line 447 of file SerRelayBoard.cpp.

Definition at line 76 of file SerRelayBoard.cpp.

int SerRelayBoard::getAnalogIn ( int *  piAnalogIn)

Definition at line 292 of file SerRelayBoard.cpp.

Definition at line 54 of file SerRelayBoard.h.

Definition at line 58 of file SerRelayBoard.h.

Definition at line 307 of file SerRelayBoard.cpp.

Definition at line 144 of file SerRelayBoard.cpp.

Definition at line 181 of file SerRelayBoard.cpp.

Definition at line 194 of file SerRelayBoard.cpp.

Definition at line 159 of file SerRelayBoard.cpp.

void SerRelayBoard::rxCharArray ( ) [protected]

Definition at line 207 of file SerRelayBoard.cpp.

int SerRelayBoard::setDigOut ( int  iChannel,
bool  bOn 
)

Definition at line 231 of file SerRelayBoard.cpp.

Definition at line 170 of file SerRelayBoard.cpp.

void SerRelayBoard::txCharArray ( ) [protected]

Member Data Documentation

bool SerRelayBoard::m_bComInit [protected]

Definition at line 170 of file SerRelayBoard.h.

char SerRelayBoard::m_cDebugRearLeft[4] [protected]

Definition at line 131 of file SerRelayBoard.h.

char SerRelayBoard::m_cDebugRearRight[4] [protected]

Definition at line 127 of file SerRelayBoard.h.

char SerRelayBoard::m_cSoftEMStop [protected]

Definition at line 126 of file SerRelayBoard.h.

unsigned char SerRelayBoard::m_cTextDisplay[60] [protected]

Definition at line 121 of file SerRelayBoard.h.

Definition at line 136 of file SerRelayBoard.h.

Definition at line 135 of file SerRelayBoard.h.

Definition at line 158 of file SerRelayBoard.h.

Definition at line 143 of file SerRelayBoard.h.

Definition at line 142 of file SerRelayBoard.h.

int SerRelayBoard::m_iDigIn [protected]

Definition at line 164 of file SerRelayBoard.h.

Definition at line 146 of file SerRelayBoard.h.

Definition at line 134 of file SerRelayBoard.h.

Definition at line 133 of file SerRelayBoard.h.

Definition at line 118 of file SerRelayBoard.h.

Definition at line 130 of file SerRelayBoard.h.

Definition at line 128 of file SerRelayBoard.h.

Definition at line 165 of file SerRelayBoard.h.

Definition at line 161 of file SerRelayBoard.h.

Definition at line 159 of file SerRelayBoard.h.

Definition at line 160 of file SerRelayBoard.h.

Definition at line 157 of file SerRelayBoard.h.

Definition at line 162 of file SerRelayBoard.h.

int SerRelayBoard::m_iTypeLCD [protected]

Definition at line 119 of file SerRelayBoard.h.

Definition at line 153 of file SerRelayBoard.h.

Definition at line 150 of file SerRelayBoard.h.

Definition at line 125 of file SerRelayBoard.h.

Definition at line 124 of file SerRelayBoard.h.

Definition at line 149 of file SerRelayBoard.h.

Definition at line 132 of file SerRelayBoard.h.

Definition at line 129 of file SerRelayBoard.h.

Definition at line 116 of file SerRelayBoard.h.

Definition at line 166 of file SerRelayBoard.h.

Definition at line 168 of file SerRelayBoard.h.

std::string SerRelayBoard::m_sNumComPort [protected]

Definition at line 108 of file SerRelayBoard.h.


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


cob_relayboard
Author(s): Christian Connette
autogenerated on Sat Jun 8 2019 21:02:18