52 auto new_data_offset_it = output.begin() + telegram.size();
75 ROS_WARN(
"Could not open Cola2 session");
82 uint8_t heart_beat_time_out_seconds = 60;
88 uint32_t client_id = 1;
bool processReply()
Processes the return from the sensor. Checks if the request was successful.
void writeUint32BigEndian(std::vector< uint8_t >::iterator it, const uint32_t v)
Writes an unsigned 32-bit integer to a buffer at offset in big endian encoding.
void writeUint8BigEndian(std::vector< uint8_t >::iterator it, const uint8_t v)
Writes an unsigned 8-bit integer to a buffer at offset in big endian encoding.
uint8_t getCommandType() const
Returns the command type.
Base class for commands. Defines the base interface and does the common tasks.
uint32_t getSessionID() const
Returns the current session ID.
void writeClientIdToDataPtr(std::vector< uint8_t >::iterator it) const
std::vector< uint8_t > expandTelegram(const std::vector< uint8_t > &telegram, size_t additional_bytes) const
sick::cola2::Cola2Session & m_session
uint8_t getCommandMode() const
Returns the command mode.
void setSessionID(const uint32_t &session_id)
Sets the current session ID.
bool canBeExecutedWithoutSessionID() const
Returns true since creating a new session is possible without a session ID.
uint32_t getSessionID() const
Returns the current session ID.
std::vector< uint8_t > addTelegramData(const std::vector< uint8_t > &telegram) const
Adds the data to the telegram.
Establishes a cola2 session with a sensor and enables execution of commands in this session...
void writeHeartbeatTimeoutToDataPtr(std::vector< uint8_t >::iterator it) const
CreateSession(Cola2Session &session)
Constructor to create a new command to set up a new session.