ci_differential_steering_sensor.h
Go to the documentation of this file.
1 
7 #ifndef CCI_DIFFERENTIAL_STEERING_SENSOR_H
8 #define CCI_DIFFERENTIAL_STEERING_SENSOR_H
9 
10 namespace argos {
11  class CCI_DifferentialSteeringSensor;
12 }
13 
14 #include <argos3/core/control_interface/ci_sensor.h>
15 
16 namespace argos {
17 
19 
20  public:
21 
22  struct SReading {
28 
30  VelocityLeftWheel(0.0f),
31  VelocityRightWheel(0.0f),
34  WheelAxisLength(0.0f) {}
35 
36  SReading(Real f_velocity_left_wheel,
37  Real f_velocity_right_wheel,
38  Real f_covered_distance_left_wheel,
39  Real f_covered_distance_right_wheel,
40  Real f_wheel_axis_length) :
41  VelocityLeftWheel(f_velocity_left_wheel),
42  VelocityRightWheel(f_velocity_right_wheel),
43  CoveredDistanceLeftWheel(f_covered_distance_left_wheel),
44  CoveredDistanceRightWheel(f_covered_distance_right_wheel),
45  WheelAxisLength(f_wheel_axis_length) {
46  }
47 
48  };
49 
54 
59 
64  const SReading& GetReading() const;
65 
66 #ifdef ARGOS_WITH_LUA
67  virtual void CreateLuaState(lua_State* pt_lua_state);
68 
69  virtual void ReadingsToLuaState(lua_State* pt_lua_state);
70 #endif
71 
72  protected:
73 
75  };
76 
77 }
78 
79 #endif
float Real
Collects all ARGoS code.
Definition: datatypes.h:39
The namespace containing all the ARGoS related code.
Definition: ci_actuator.h:12
The basic interface for all sensors.
Definition: ci_sensor.h:34
const SReading & GetReading() const
Returns the reading of the encoder sensor Returns the reading of the encoder sensor.
SReading(Real f_velocity_left_wheel, Real f_velocity_right_wheel, Real f_covered_distance_left_wheel, Real f_covered_distance_right_wheel, Real f_wheel_axis_length)