MRPT  2.0.3
CObservationBatteryState.h
Go to the documentation of this file.
1 /* +------------------------------------------------------------------------+
2  | Mobile Robot Programming Toolkit (MRPT) |
3  | https://www.mrpt.org/ |
4  | |
5  | Copyright (c) 2005-2020, Individual contributors, see AUTHORS file |
6  | See: https://www.mrpt.org/Authors - All rights reserved. |
7  | Released under BSD License. See: https://www.mrpt.org/License |
8  +------------------------------------------------------------------------+ */
9 #pragma once
10 
12 #include <mrpt/obs/CObservation.h>
13 #include <mrpt/poses/CPose2D.h>
14 #include <mrpt/poses/CPose3D.h>
16 
17 namespace mrpt::obs
18 {
19 /** This represents a measurement of the batteries on the robot.
20  * The battery levels are in volts in the form of the public members:
21  * - voltageMainRobotBattery
22  * - voltageMainRobotComputer
23  * - voltageOtherBatteries
24  *
25  * There are boolean flags for signaling when the corresponding values have
26  *been filled out or not.
27  *
28  * \sa CObservation
29  * \ingroup mrpt_obs_grp
30  */
32 {
34 
35  public:
36  /** Constructor
37  */
39 
40  /** The data members
41  * \sa voltageMainRobotBatteryIsValid,voltageMainRobotComputerIsValid
42  */
44 
45  /** These values must be true if the corresponding fields contain valid
46  * values.
47  * \sa voltageMainRobotBattery,voltageMainRobotComputer
48  */
51 
52  /** The users can use this vector for any arbitrary number of batteries or
53  * any other analog measurements.
54  * \sa voltageOtherBatteriesValid
55  */
57 
58  /** These values must be true if the corresponding fields contain valid
59  * values (it MUST has the same size than voltageOtherBatteries)
60  */
61  std::vector<bool> voltageOtherBatteriesValid;
62 
63  void getSensorPose(mrpt::poses::CPose3D& out_sensorPose)
64  const override; // See base class docs.
65  void setSensorPose(const mrpt::poses::CPose3D& newSensorPose)
66  override; // See base class docs.
68  std::ostream& o) const override; // See base class docs
69 
70 }; // End of class def.
71 
72 } // namespace mrpt::obs
mrpt::obs::CObservationBatteryState
This represents a measurement of the batteries on the robot.
Definition: CObservationBatteryState.h:31
DEFINE_SERIALIZABLE
#define DEFINE_SERIALIZABLE(class_name, NS)
This declaration must be inserted in all CSerializable classes definition, within the class declarati...
Definition: CSerializable.h:152
mrpt::obs::CObservationBatteryState::getDescriptionAsText
void getDescriptionAsText(std::ostream &o) const override
Build a detailed, multi-line textual description of the observation contents and dump it to the outpu...
Definition: CObservationBatteryState.cpp:82
mrpt::obs::CObservationBatteryState::voltageMainRobotComputer
double voltageMainRobotComputer
Definition: CObservationBatteryState.h:43
CPose2D.h
mrpt::obs
This namespace contains representation of robot actions and observations.
Definition: CParticleFilter.h:17
CVectorDynamic.h
mrpt::obs::CObservationBatteryState::voltageOtherBatteriesValid
std::vector< bool > voltageOtherBatteriesValid
These values must be true if the corresponding fields contain valid values (it MUST has the same size...
Definition: CObservationBatteryState.h:61
mrpt::poses::CPose3D
A class used to store a 3D pose (a 3D translation + a rotation in 3D).
Definition: CPose3D.h:85
mrpt::obs::CObservationBatteryState::getSensorPose
void getSensorPose(mrpt::poses::CPose3D &out_sensorPose) const override
A general method to retrieve the sensor pose on the robot.
Definition: CObservationBatteryState.cpp:71
mrpt::math::CVectorDynamic< double >
CPose3D.h
mrpt::obs::CObservationBatteryState::CObservationBatteryState
CObservationBatteryState()
Constructor.
Definition: CObservationBatteryState.cpp:25
mrpt::obs::CObservationBatteryState::voltageMainRobotBattery
double voltageMainRobotBattery
The data members.
Definition: CObservationBatteryState.h:43
CObservation.h
mrpt::obs::CObservationBatteryState::voltageOtherBatteries
mrpt::math::CVectorDouble voltageOtherBatteries
The users can use this vector for any arbitrary number of batteries or any other analog measurements.
Definition: CObservationBatteryState.h:56
mrpt::obs::CObservation
Declares a class that represents any robot's observation.
Definition: CObservation.h:43
CSerializable.h
mrpt::obs::CObservationBatteryState::voltageMainRobotComputerIsValid
bool voltageMainRobotComputerIsValid
Definition: CObservationBatteryState.h:50
mrpt::obs::CObservationBatteryState::voltageMainRobotBatteryIsValid
bool voltageMainRobotBatteryIsValid
These values must be true if the corresponding fields contain valid values.
Definition: CObservationBatteryState.h:49
mrpt::obs::CObservationBatteryState::setSensorPose
void setSensorPose(const mrpt::poses::CPose3D &newSensorPose) override
A general method to change the sensor pose on the robot.
Definition: CObservationBatteryState.cpp:77



Page generated by Doxygen 1.8.17 for MRPT 2.0.3 at Fri May 15 23:51:15 UTC 2020