controldev
/build/rock-master-18.09-drivers-orogen-controldev-0.20180522/ControlDevTypes.hpp
Go to the documentation of this file.
1 #ifndef CONTROLDEVTYPES_HPP
2 #define CONTROLDEVTYPES_HPP
3 
4 #include <vector>
5 #include <string>
6 #include <base/Time.hpp>
7 
8 namespace controldev
9 {
10 
11  struct AxisPort
12  {
13  //name of the to be created port
14  std::string portName;
15  //axis number of the port that should be written out
16  int axisNr;
17  //scale factor that is applied to the output value
18  double scaleFactor;
19  //offset that will be applied to the output value
20  double offset;
21  };
22 
27  struct RawCommand
28  {
29  /*
30  * Device Type identifier like
31  */
32  std::string deviceIdentifier;
33 
34  /*
35  * The Timesamp
36  */
37  base::Time time;
38 
42  std::vector<double> axisValue;
43 
44  /*
45  * Switch/Key Values
46  * Three State switches are handles as two
47  * Comment, this has to be handeld as an bool vecotr.
48  * Sine bools are buggy in rock currently, workaround it with an uint8_t
49  * vecotr. For more details see http://rock.opendfki.de/ticket/187
50  */
51  std::vector<uint8_t> buttonValue;
52  };
53 }
54 
55 #endif /* CONTROLDEVTYPES_HPP */
base::Time time
Definition: ControlDevTypes.hpp:37
Definition: ControlDevTypes.hpp:11
double offset
Definition: ControlDevTypes.hpp:20
std::string portName
Definition: ControlDevTypes.hpp:14
Definition: ControlDevTypes.hpp:8
std::vector< double > axisValue
Axis values, scaled betwen 0 and 1.
Definition: ControlDevTypes.hpp:42
std::vector< uint8_t > buttonValue
Definition: ControlDevTypes.hpp:51
int axisNr
Definition: ControlDevTypes.hpp:16
std::string deviceIdentifier
Definition: ControlDevTypes.hpp:32
A data structure for raw data values of input devices.
Definition: ControlDevTypes.hpp:27
double scaleFactor
Definition: ControlDevTypes.hpp:18