31 #define NUMBER_OF_RETRIES_SEND 3 // Number of retries after a failing in the Communication 32 #define NUMBER_OF_RETRIES_RECV 3 // Number of retries after a failing in the Communication 60 _command_char(command) {}
102 virtual bool load_tbl() = 0;
103 virtual void defineProtocol(
byte _kataddr) = 0;
140 virtual bool load_tbl();
141 virtual void defineProtocol(
byte _kataddr);
142 virtual void send(
byte* send_buf,
byte write_sz,
short retries = 3);
150 virtual bool init(
CCdlBase* _device,
byte _kataddr = 24);
156 virtual void comm(
const byte* pack,
byte* buf,
byte* size);
162 virtual void getMasterFirmware(
short* fw,
short* rev);
167 #endif //_CPLSERIALZERO_H_ unsigned char byte
type specification (8 bit)
byte send_sz
send size of the packet
Abstract base class for protocol definiton.
Implement the Serial-Zero protocol.
Exception(const std::string &message, const int error_number)
Exception reported by the firmware.
CRC check for the answer package failed.
FirmwareException(const std::string &error, const int error_number, const int axis, const char command)
char _command_char
the command that caused the error
const int KATANA_ERROR_FLAG
defines the error flag number
char command_char() const
int _axis_number
axis number, if any
byte read_sz
read size of the packet
Base class of two different serial protocols.
Abstract base class for devices.