ARGoS  3
A parallel, multi-engine simulator for swarm robotics
plugins/robots/foot-bot/control_interface/ci_footbot_accelerometer_sensor.h
Go to the documentation of this file.
00001 
00009 #ifndef CCI_FOOTBOT_ACCELEROMETER_SENSOR_H
00010 #define CCI_FOOTBOT_ACCELEROMETER_SENSOR_H
00011 
00012 namespace argos {
00013    class CCI_FootBotAccelerometerSensor;
00014 }
00015 
00016 #include <argos3/core/control_interface/ci_sensor.h>
00017 #include <argos3/core/utility/math/vector2.h>
00018 
00019 namespace argos {
00020 
00021    class CCI_FootBotAccelerometerSensor : virtual public CCI_Sensor {
00022 
00023    public:
00024 
00025       struct SReading {
00026          SInt16 AxisX;
00027          SInt16 AxisY;
00028          SInt16 AxisZ;
00029 
00030          SReading() :
00031                  AxisX(0),
00032                  AxisY(0),
00033                  AxisZ(0){
00034          }
00035 
00036          SReading(SInt16 n_value_x_axis,
00037                   SInt16 n_value_y_axis,
00038                   SInt16 n_value_z_axis) :
00039                  AxisX(n_value_x_axis),
00040                  AxisY(n_value_y_axis),
00041                  AxisZ(n_value_z_axis){
00042          }
00043       };
00044 
00045    public:
00046 
00047       CCI_FootBotAccelerometerSensor() {}
00048 
00049       virtual ~CCI_FootBotAccelerometerSensor() {}
00050 
00051       inline const SReading& GetReading() const {
00052          return m_sReading;
00053       }
00054 
00055    protected:
00056 
00057       SReading m_sReading;
00058 
00059    };
00060 
00061 }
00062 
00063 #endif