argos::CDifferentialSteeringDefaultSensor Class Reference

#include <differential_steering_default_sensor.h>

Inheritance diagram for argos::CDifferentialSteeringDefaultSensor:
Collaboration diagram for argos::CDifferentialSteeringDefaultSensor:

Public Member Functions

 CDifferentialSteeringDefaultSensor ()
 
virtual ~CDifferentialSteeringDefaultSensor ()
 
virtual void SetRobot (CComposableEntity &c_entity)
 Sets the entity associated to this sensor. More...
 
virtual void Init (TConfigurationNode &t_tree)
 Initializes the sensor from the XML configuration tree. More...
 
virtual void Update ()
 Updates the state of the entity associated to this sensor, if the sensor is currently enabled. More...
 
virtual void Reset ()
 Resets the sensor to the state it had just after Init(). More...
 
- Public Member Functions inherited from argos::CSimulatedSensor
virtual ~CSimulatedSensor ()
 Class destructor. More...
 
- Public Member Functions inherited from argos::CCI_DifferentialSteeringSensor
 CCI_DifferentialSteeringSensor ()
 Constructor. More...
 
virtual ~CCI_DifferentialSteeringSensor ()
 Destructor. More...
 
const SReadingGetReading () const
 Returns the reading of the encoder sensor Returns the reading of the encoder sensor. More...
 
- Public Member Functions inherited from argos::CCI_Sensor
virtual ~CCI_Sensor ()
 Class destructor. More...
 
virtual void Destroy ()
 Destroys the sensor. More...
 
virtual void Enable ()
 Enables updating of sensor information in the event loop. More...
 
virtual void Disable ()
 Disables updating of sensor information in the event loop. More...
 
bool IsEnabled () const
 
bool IsDisabled () const
 
- Public Member Functions inherited from argos::CBaseConfigurableResource
virtual ~CBaseConfigurableResource ()
 Class destructor. More...
 

Protected Attributes

CWheeledEntitym_pcWheeledEntity
 Reference to wheeled entity associated to this sensor. More...
 
const Realm_pfWheelVelocities
 The wheel velocity taken from the wheeled entity. More...
 
CRandom::CRNGm_pcRNG
 Random number generator. More...
 
bool m_bAddNoise
 Whether to add noise or not. More...
 
CRange< Realm_cVelNoiseRange
 Noise range on velocity. More...
 
CRange< Realm_cDistNoiseRange
 Noise range on distance. More...
 
- Protected Attributes inherited from argos::CCI_DifferentialSteeringSensor
SReading m_sReading
 

Additional Inherited Members

- Public Types inherited from argos::CCI_Sensor
typedef std::map< std::string, CCI_Sensor *, std::less< std::string > > TMap
 

Detailed Description

Definition at line 26 of file differential_steering_default_sensor.h.

Constructor & Destructor Documentation

◆ CDifferentialSteeringDefaultSensor()

argos::CDifferentialSteeringDefaultSensor::CDifferentialSteeringDefaultSensor ( )

Definition at line 18 of file differential_steering_default_sensor.cpp.

◆ ~CDifferentialSteeringDefaultSensor()

virtual argos::CDifferentialSteeringDefaultSensor::~CDifferentialSteeringDefaultSensor ( )
inlinevirtual

Definition at line 33 of file differential_steering_default_sensor.h.

Member Function Documentation

◆ Init()

void argos::CDifferentialSteeringDefaultSensor::Init ( TConfigurationNode t_node)
virtual

Initializes the sensor from the XML configuration tree.

The default implementation of this method does nothing.

Parameters
t_nodeThe XML configuration tree relative to this sensor.
See also
Reset()
Destroy()

Reimplemented from argos::CCI_Sensor.

Definition at line 45 of file differential_steering_default_sensor.cpp.

◆ Reset()

void argos::CDifferentialSteeringDefaultSensor::Reset ( )
virtual

Resets the sensor to the state it had just after Init().

The default implementation of this method does nothing.

See also
Init()
Destroy()

Reimplemented from argos::CCI_Sensor.

Definition at line 87 of file differential_steering_default_sensor.cpp.

◆ SetRobot()

void argos::CDifferentialSteeringDefaultSensor::SetRobot ( CComposableEntity c_entity)
virtual

Sets the entity associated to this sensor.

When a controller is created, all the sensors and actuators are created, too. This function is called right before the Init() method of the sensor is called.

Parameters
c_entityThe entity to associate to this sensor.
See also
CComposableEntity
CControllableEntity::SetController()
CCI_Sensor::Init()

Implements argos::CSimulatedSensor.

Definition at line 26 of file differential_steering_default_sensor.cpp.

◆ Update()

void argos::CDifferentialSteeringDefaultSensor::Update ( )
virtual

Updates the state of the entity associated to this sensor, if the sensor is currently enabled.

If it is disabled, then this function should do nothing.

Implements argos::CSimulatedSensor.

Definition at line 67 of file differential_steering_default_sensor.cpp.

Member Data Documentation

◆ m_bAddNoise

bool argos::CDifferentialSteeringDefaultSensor::m_bAddNoise
protected

Whether to add noise or not.

Definition at line 55 of file differential_steering_default_sensor.h.

◆ m_cDistNoiseRange

CRange<Real> argos::CDifferentialSteeringDefaultSensor::m_cDistNoiseRange
protected

Noise range on distance.

Definition at line 61 of file differential_steering_default_sensor.h.

◆ m_cVelNoiseRange

CRange<Real> argos::CDifferentialSteeringDefaultSensor::m_cVelNoiseRange
protected

Noise range on velocity.

Definition at line 58 of file differential_steering_default_sensor.h.

◆ m_pcRNG

CRandom::CRNG* argos::CDifferentialSteeringDefaultSensor::m_pcRNG
protected

Random number generator.

Definition at line 52 of file differential_steering_default_sensor.h.

◆ m_pcWheeledEntity

CWheeledEntity* argos::CDifferentialSteeringDefaultSensor::m_pcWheeledEntity
protected

Reference to wheeled entity associated to this sensor.

Definition at line 46 of file differential_steering_default_sensor.h.

◆ m_pfWheelVelocities

const Real* argos::CDifferentialSteeringDefaultSensor::m_pfWheelVelocities
protected

The wheel velocity taken from the wheeled entity.

Definition at line 49 of file differential_steering_default_sensor.h.