argos::CCI_FootBotDistanceScannerSensor Class Reference

#include <ci_footbot_distance_scanner_sensor.h>

Inheritance diagram for argos::CCI_FootBotDistanceScannerSensor:
Collaboration diagram for argos::CCI_FootBotDistanceScannerSensor:

Classes

struct  SReading
 The DTO of the distance scanner, it contains the measured distance and its angle. More...
 

Public Types

typedef std::vector< SReadingTReadings
 
typedef std::vector< TReadingsTLastReadings
 
typedef std::pair< CRadians, RealTMapPair
 
typedef std::map< CRadians, RealTReadingsMap
 
- Public Types inherited from argos::CCI_Sensor
typedef std::map< std::string, CCI_Sensor *, std::less< std::string > > TMap
 

Public Member Functions

 CCI_FootBotDistanceScannerSensor ()
 Constructor. More...
 
virtual ~CCI_FootBotDistanceScannerSensor ()
 Destructor. More...
 
const TReadingsMapGetReadingsMap ()
 Return a map of the readings of the ds A map of the readings of the ds in the following format: angle - value. More...
 
const TReadingsMapGetShortReadingsMap ()
 Return a map of the readings of the ds, short sensor readings A map of the readings of the ds short sensor readings in the following format: angle - value. More...
 
const TReadingsMapGetLongReadingsMap ()
 Return a map of the readings of the ds, long sensor readings A map of the readings of the ds long sensor readings in the following format: angle - value. More...
 
- Public Member Functions inherited from argos::CCI_Sensor
virtual ~CCI_Sensor ()
 Class destructor. More...
 
virtual void Init (TConfigurationNode &t_node)
 Initializes the sensor from the XML configuration tree. More...
 
virtual void Reset ()
 Resets the sensor to the state it had just after Init(). 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

TReadings m_tReadings
 A vector of sReadings. More...
 
TLastReadings m_tLastReadings
 Vector storing the last received packets. More...
 
TReadingsMap m_tReadingsMap
 Map storing all the last received packets. More...
 
TReadingsMap m_tShortReadingsMap
 Map storing the last received packets from the short distance sensors. More...
 
TReadingsMap m_tLongReadingsMap
 Map storing the last received packets from the long distance sensors. More...
 

Detailed Description

Definition at line 65 of file ci_footbot_distance_scanner_sensor.h.

Member Typedef Documentation

◆ TLastReadings

◆ TMapPair

◆ TReadings

◆ TReadingsMap

Constructor & Destructor Documentation

◆ CCI_FootBotDistanceScannerSensor()

argos::CCI_FootBotDistanceScannerSensor::CCI_FootBotDistanceScannerSensor ( )
inline

Constructor.

Definition at line 97 of file ci_footbot_distance_scanner_sensor.h.

◆ ~CCI_FootBotDistanceScannerSensor()

virtual argos::CCI_FootBotDistanceScannerSensor::~CCI_FootBotDistanceScannerSensor ( )
inlinevirtual

Destructor.

Definition at line 104 of file ci_footbot_distance_scanner_sensor.h.

Member Function Documentation

◆ GetLongReadingsMap()

const CCI_FootBotDistanceScannerSensor::TReadingsMap & argos::CCI_FootBotDistanceScannerSensor::GetLongReadingsMap ( )

Return a map of the readings of the ds, long sensor readings A map of the readings of the ds long sensor readings in the following format: angle - value.

The value is the distance wrt to a perceived obstacle. If the value is -1 it means that the sensor is saturated (the obstacle is too close, i.e. < 20cm from the robot border) If the value is -2 it means that the sensor is empy (obstacle too far / no obstacle, i.e. > 150cm from the robot border)

Definition at line 32 of file ci_footbot_distance_scanner_sensor.cpp.

◆ GetReadingsMap()

const CCI_FootBotDistanceScannerSensor::TReadingsMap & argos::CCI_FootBotDistanceScannerSensor::GetReadingsMap ( )

Return a map of the readings of the ds A map of the readings of the ds in the following format: angle - value.

The value is the distance wrt to a perceived obstacle. If the value is -1 it means that the sensor is saturated (the obstacle is too close) If the value is -2 it means that the sensor is empy (obstacle too far / no obstacle) The "too far / too close" have different meanings for the short sensors and long sensors. This map stores both long and short sensor readings. It is suggested to use the short/long maps instead.

Definition at line 18 of file ci_footbot_distance_scanner_sensor.cpp.

◆ GetShortReadingsMap()

const CCI_FootBotDistanceScannerSensor::TReadingsMap & argos::CCI_FootBotDistanceScannerSensor::GetShortReadingsMap ( )

Return a map of the readings of the ds, short sensor readings A map of the readings of the ds short sensor readings in the following format: angle - value.

The value is the distance wrt to a perceived obstacle. If the value is -1 it means that the sensor is saturated (the obstacle is too close, i.e. < 4cm from the robot border) If the value is -2 it means that the sensor is empy (obstacle too far / no obstacle, i.e. > 30cm from the robot border)

Definition at line 25 of file ci_footbot_distance_scanner_sensor.cpp.

Member Data Documentation

◆ m_tLastReadings

TLastReadings argos::CCI_FootBotDistanceScannerSensor::m_tLastReadings
protected

Vector storing the last received packets.

Definition at line 160 of file ci_footbot_distance_scanner_sensor.h.

◆ m_tLongReadingsMap

TReadingsMap argos::CCI_FootBotDistanceScannerSensor::m_tLongReadingsMap
protected

Map storing the last received packets from the long distance sensors.

Definition at line 169 of file ci_footbot_distance_scanner_sensor.h.

◆ m_tReadings

TReadings argos::CCI_FootBotDistanceScannerSensor::m_tReadings
protected

A vector of sReadings.

Definition at line 157 of file ci_footbot_distance_scanner_sensor.h.

◆ m_tReadingsMap

TReadingsMap argos::CCI_FootBotDistanceScannerSensor::m_tReadingsMap
protected

Map storing all the last received packets.

Definition at line 163 of file ci_footbot_distance_scanner_sensor.h.

◆ m_tShortReadingsMap

TReadingsMap argos::CCI_FootBotDistanceScannerSensor::m_tShortReadingsMap
protected

Map storing the last received packets from the short distance sensors.

Definition at line 166 of file ci_footbot_distance_scanner_sensor.h.