Main MRPT website
>
C++ reference
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
mrpt
slam
CObservationOdometry.h
Go to the documentation of this file.
1
/* +---------------------------------------------------------------------------+
2
| The Mobile Robot Programming Toolkit (MRPT) C++ library |
3
| |
4
| http://www.mrpt.org/ |
5
| |
6
| Copyright (C) 2005-2012 University of Malaga |
7
| |
8
| This software was written by the Machine Perception and Intelligent |
9
| Robotics Lab, University of Malaga (Spain). |
10
| Contact: Jose-Luis Blanco <jlblanco@ctima.uma.es> |
11
| |
12
| This file is part of the MRPT project. |
13
| |
14
| MRPT is free software: you can redistribute it and/or modify |
15
| it under the terms of the GNU General Public License as published by |
16
| the Free Software Foundation, either version 3 of the License, or |
17
| (at your option) any later version. |
18
| |
19
| MRPT is distributed in the hope that it will be useful, |
20
| but WITHOUT ANY WARRANTY; without even the implied warranty of |
21
| MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
22
| GNU General Public License for more details. |
23
| |
24
| You should have received a copy of the GNU General Public License |
25
| along with MRPT. If not, see <http://www.gnu.org/licenses/>. |
26
| |
27
+---------------------------------------------------------------------------+ */
28
29
#ifndef CObservationOdometry_H
30
#define CObservationOdometry_H
31
32
#include <
mrpt/utils/CSerializable.h
>
33
#include <
mrpt/slam/CObservation.h
>
34
#include <
mrpt/poses/CPose2D.h
>
35
#include <
mrpt/poses/CPose3D.h
>
36
37
namespace
mrpt
38
{
39
namespace
slam
40
{
41
DEFINE_SERIALIZABLE_PRE_CUSTOM_BASE_LINKAGE
(
CObservationOdometry
,
CObservation
,
OBS_IMPEXP
)
42
43
/** An observation of the current (cumulative) odometry for a wheeled robot.
44
* This kind of observation will only occur in a "observation-only" rawlog file, otherwise
45
* odometry are modeled with actions. Refer to the <a href="http://www.mrpt.org/Rawlog_Format">page on rawlogs</a>.
46
*
47
* \sa CObservation, CActionRobotMovement2D
48
* \ingroup mrpt_obs_grp
49
*/
50
class
OBS_IMPEXP
CObservationOdometry
: public
CObservation
51
{
52
// This must be added to any CSerializable derived class:
53
DEFINE_SERIALIZABLE
(
CObservationOdometry
)
54
55
public:
56
/** Constructor
57
*/
58
CObservationOdometry
( );
59
60
poses::
CPose2D
odometry;
//!< The absolute odometry measurement (IT IS NOT INCREMENTAL)
61
62
bool
hasEncodersInfo;
//!< "true" means that "encoderLeftTicks" and "encoderRightTicks" contain valid values.
63
64
/** For odometry only: the ticks count for each wheel in ABSOLUTE VALUE (IT IS NOT INCREMENTAL) (positive means FORWARD, for both wheels);
65
* \sa hasEncodersInfo
66
*/
67
int32_t encoderLeftTicks,encoderRightTicks;
68
69
bool
hasVelocities;
//!< "true" means that "velocityLin" and "velocityAng" contain valid values.
70
71
/** The velocity of the robot, linear in meters/sec and angular in rad/sec.
72
*/
73
float
velocityLin, velocityAng;
74
75
76
/** A general method to retrieve the sensor pose on the robot.
77
* It has no effects in this class
78
* \sa setSensorPose
79
*/
80
void
getSensorPose(
CPose3D
&out_sensorPose )
const
{ out_sensorPose=
CPose3D
(0,0,0); }
81
82
/** A general method to change the sensor pose on the robot.
83
* It has no effects in this class
84
* \sa getSensorPose
85
*/
86
void
setSensorPose
(
const
CPose3D
& ) { }
87
88
};
// End of class def.
89
90
}
// End of namespace
91
}
// End of namespace
92
93
#endif
Page generated by
Doxygen 1.8.3
for MRPT 0.9.6 SVN: at Fri Feb 15 22:05:02 EST 2013