ChangeCommSettingsCommand.h
Go to the documentation of this file.
1 // this is for emacs file handling -*- mode: c++; indent-tabs-mode: nil -*-
2 
3 // -- BEGIN LICENSE BLOCK ----------------------------------------------
4 
24 // -- END LICENSE BLOCK ------------------------------------------------
25 
26 //----------------------------------------------------------------------
33 //----------------------------------------------------------------------
34 
35 
36 #ifndef SICK_SAFETYSCANNERS_COLA2_CHANGECOMMSETTINGSCOMMAND_H
37 #define SICK_SAFETYSCANNERS_COLA2_CHANGECOMMSETTINGSCOMMAND_H
38 
39 
42 
43 namespace sick {
44 namespace cola2 {
45 
46 
52 {
53 public:
58 
68 
69 
76 
77 
84  bool canBeExecutedWithoutSessionID() const;
85 
86 
93  bool processReply();
94 
95 
96 private:
97  std::shared_ptr<sick::data_processing::ReadWriteHelper> m_writer_ptr;
99 
100  uint8_t*
102  void writeDataToDataPtr(uint8_t*& data_ptr) const;
103  void writeChannelToDataPtr(uint8_t*& data_ptr) const;
104  void writeEnabledToDataPtr(uint8_t*& data_ptr) const;
105  void writeEInterfaceTypeToDataPtr(uint8_t*& data_ptr) const;
106  void writeIPAddresstoDataPtr(uint8_t*& data_ptr) const;
107  void writePortToDataPtr(uint8_t*& data_ptr) const;
108  void writeFrequencyToDataPtr(uint8_t*& data_ptr) const;
109  void writeStartAngleToDataPtr(uint8_t*& data_ptr) const;
110  void writeEndAngleToDataPtr(uint8_t*& data_ptr) const;
111  void writeFeaturesToDataPtr(uint8_t*& data_ptr) const;
112 };
113 
114 } // namespace cola2
115 } // namespace sick
116 
117 #endif // SICK_SAFETYSCANNERS_COLA2_CHANGECOMMSETTINGSCOMMAND_H
Command for method calls to the sensor.
Definition: MethodCommand.h:46
void writeEnabledToDataPtr(uint8_t *&data_ptr) const
bool processReply()
Processes the return from the sensor. Checks if the method was acknowledged by the sensor...
void writeIPAddresstoDataPtr(uint8_t *&data_ptr) const
sick::datastructure::CommSettings m_settings
Containing the communication settings for the sensor which can be changed on runtime.
Definition: CommSettings.h:48
Method command class for changing the settings in the sensor. Such as which data packages to enable...
void writeDataToDataPtr(uint8_t *&data_ptr) const
uint8_t * prepareTelegramAndGetDataPtr(sick::datastructure::PacketBuffer::VectorBuffer &telegram) const
void addTelegramData(sick::datastructure::PacketBuffer::VectorBuffer &telegram) const
Adds the settings as data to the packetbuffer.
bool canBeExecutedWithoutSessionID() const
Returns if the command can be executed without a session ID. Will return false for most commands exce...
void writeFeaturesToDataPtr(uint8_t *&data_ptr) const
void writeEndAngleToDataPtr(uint8_t *&data_ptr) const
void writeEInterfaceTypeToDataPtr(uint8_t *&data_ptr) const
void writeStartAngleToDataPtr(uint8_t *&data_ptr) const
std::shared_ptr< sick::data_processing::ReadWriteHelper > m_writer_ptr
void writeFrequencyToDataPtr(uint8_t *&data_ptr) const
ChangeCommSettingsCommand(Cola2Session &session, const datastructure::CommSettings &settings)
Constructor of the Command, takes the current session and the new set of parameters for the sensor...
sick::cola2::MethodCommand base_class
Typedef to reference the base class.
void writePortToDataPtr(uint8_t *&data_ptr) const
std::vector< uint8_t > VectorBuffer
Typedef for a vector buffer, to sort the incoming packets.
Definition: PacketBuffer.h:71
Establishes a cola2 session with a sensor and enables execution of commands in this session...
Definition: Cola2Session.h:72
void writeChannelToDataPtr(uint8_t *&data_ptr) const


sick_safetyscanners
Author(s): Lennart Puck
autogenerated on Thu May 9 2019 02:41:08