This class stores a message from a CAN BUS with the protocol J1939.
- See also
- CObservation
Definition at line 26 of file obs/CObservationCANBusJ1939.h.
#include <mrpt/obs/CObservationCANBusJ1939.h>
|
void | swap (CObservation &o) |
| Swap with another observation, ONLY the data defined here in the base class CObservation. It's protected since it'll be only called from child classes that should know what else to swap appart from these common data. More...
|
|
|
void | writeToStream (mrpt::utils::CStream &out, int *getVersion) const MRPT_OVERRIDE |
| Introduces a pure virtual method responsible for writing to a CStream. More...
|
|
void | readFromStream (mrpt::utils::CStream &in, int version) MRPT_OVERRIDE |
| Introduces a pure virtual method responsible for loading from a CStream This can not be used directly be users, instead use "stream >> object;" for reading it from a stream or "stream >> object_ptr;" if the class is unknown apriori. More...
|
|
◆ SmartPtr
◆ CObservationCANBusJ1939()
mrpt::obs::CObservationCANBusJ1939::CObservationCANBusJ1939 |
( |
| ) |
|
|
inline |
◆ ~CObservationCANBusJ1939()
virtual mrpt::obs::CObservationCANBusJ1939::~CObservationCANBusJ1939 |
( |
| ) |
|
|
inlinevirtual |
◆ _GetBaseClass()
◆ clone()
CObject* mrpt::utils::CObject::clone |
( |
| ) |
const |
|
inlineinherited |
Cloning interface for smart pointers.
Definition at line 139 of file CObject.h.
◆ Create()
static CObservationCANBusJ1939Ptr mrpt::obs::CObservationCANBusJ1939::Create |
( |
| ) |
|
|
static |
◆ CreateObject()
◆ duplicate()
◆ duplicateGetSmartPtr()
Returns a copy of the object, indepently of its class, as a smart pointer (the newly created object will exist as long as any copy of this smart pointer).
Definition at line 136 of file CObject.h.
◆ getDescriptionAsText()
void mrpt::obs::CObservationCANBusJ1939::getDescriptionAsText |
( |
std::ostream & |
o | ) |
const |
|
virtual |
Build a detailed, multi-line textual description of the observation contents and dump it to the output stream.
- Note
- If overried by derived classes, call base CObservation::getDescriptionAsText() first to show common information.
-
This is the text that appears in RawLogViewer when selecting an object in the dataset
Reimplemented from mrpt::obs::CObservation.
◆ getOriginalReceivedTimeStamp()
◆ GetRuntimeClass()
◆ getSensorPose() [1/2]
A general method to retrieve the sensor pose on the robot.
Note that most sensors will return a full (6D) CPose3D, but see the derived classes for more details or special cases.
- See also
- setSensorPose
◆ getSensorPose() [2/2]
◆ getTimeStamp()
◆ insertObservationInto()
template<class METRICMAP >
bool mrpt::obs::CObservation::insertObservationInto |
( |
METRICMAP * |
theMap, |
|
|
const mrpt::poses::CPose3D * |
robotPose = NULL |
|
) |
| const |
|
inlineinherited |
This method is equivalent to:
- Parameters
-
theMap | The map where this observation is to be inserted: the map will be updated. |
robotPose | The pose of the robot base for this observation, relative to the target metric map. Set to NULL (default) to use (0,0,0deg) |
- Returns
- Returns true if the map has been updated, or false if this observations has nothing to do with a metric map (for example, a sound observation).
- See also
- CMetricMap, CMetricMap::insertObservation
Definition at line 83 of file obs/CObservation.h.
◆ load()
virtual void mrpt::obs::CObservation::load |
( |
| ) |
const |
|
inlinevirtualinherited |
Makes sure all images and other fields which may be externally stored are loaded in memory.
Note that for all CImages, calling load() is not required since the images will be automatically loaded upon first access, so load() shouldn't be needed to be called in normal cases by the user. If all the data were alredy loaded or this object has no externally stored data fields, calling this method has no effects.
- See also
- unload
Reimplemented in mrpt::obs::CObservation3DRangeScan.
Definition at line 125 of file obs/CObservation.h.
◆ operator delete() [1/3]
void mrpt::obs::CObservationCANBusJ1939::operator delete |
( |
void * |
memory, |
|
|
void * |
ptr |
|
) |
| |
throw | ( | |
| ) | | |
|
inline |
◆ operator delete() [2/3]
void mrpt::obs::CObservationCANBusJ1939::operator delete |
( |
void * |
ptr | ) |
|
throw | ( | |
| ) | | |
|
inline |
◆ operator delete() [3/3]
void mrpt::obs::CObservationCANBusJ1939::operator delete |
( |
void * |
ptr, |
|
|
const std::nothrow_t & |
|
|
) |
| |
throw | ( | |
| ) | | |
|
inline |
◆ operator delete[]()
void mrpt::obs::CObservationCANBusJ1939::operator delete[] |
( |
void * |
ptr | ) |
|
throw | ( | |
| ) | | |
|
inline |
◆ operator new() [1/3]
void* mrpt::obs::CObservationCANBusJ1939::operator new |
( |
size_t |
size | ) |
|
|
inline |
◆ operator new() [2/3]
void* mrpt::obs::CObservationCANBusJ1939::operator new |
( |
size_t |
size, |
|
|
const std::nothrow_t & |
|
|
) |
| |
throw | ( | |
| ) | | |
|
inline |
◆ operator new() [3/3]
static void* mrpt::obs::CObservationCANBusJ1939::operator new |
( |
size_t |
size, |
|
|
void * |
ptr |
|
) |
| |
|
inlinestatic |
◆ operator new[]()
void* mrpt::obs::CObservationCANBusJ1939::operator new[] |
( |
size_t |
size | ) |
|
|
inline |
◆ readFromStream()
Introduces a pure virtual method responsible for loading from a CStream This can not be used directly be users, instead use "stream >> object;" for reading it from a stream or "stream >> object_ptr;" if the class is unknown apriori.
- Parameters
-
in | The input binary stream where the object data must read from. |
version | The version of the object stored in the stream: use this version number in your code to know how to read the incoming data. |
- Exceptions
-
std::exception | On any error, see CStream::ReadBuffer |
- See also
- CStream
Implements mrpt::utils::CSerializable.
◆ setSensorPose() [1/2]
A general method to change the sensor pose on the robot.
Note that most sensors will use the full (6D) CPose3D, but see the derived classes for more details or special cases.
- See also
- getSensorPose
◆ setSensorPose() [2/2]
void mrpt::obs::CObservationCANBusJ1939::setSensorPose |
( |
const mrpt::poses::CPose3D & |
newSensorPose | ) |
|
|
inlinevirtual |
◆ swap()
Swap with another observation, ONLY the data defined here in the base class CObservation. It's protected since it'll be only called from child classes that should know what else to swap appart from these common data.
◆ unload()
virtual void mrpt::obs::CObservation::unload |
( |
| ) |
|
|
inlinevirtualinherited |
◆ writeToMatlab()
virtual mxArray* mrpt::utils::CSerializable::writeToMatlab |
( |
| ) |
const |
|
inlinevirtualinherited |
Introduces a pure virtual method responsible for writing to a mxArray
Matlab object, typically a MATLAB struct
whose contents are documented in each derived class.
- Returns
- A new
mxArray
(caller is responsible of memory freeing) or NULL is class does not support conversion to MATLAB.
Definition at line 79 of file CSerializable.h.
◆ writeToStream()
void mrpt::obs::CObservationCANBusJ1939::writeToStream |
( |
mrpt::utils::CStream & |
out, |
|
|
int * |
getVersion |
|
) |
| const |
|
protectedvirtual |
Introduces a pure virtual method responsible for writing to a CStream.
This can not be used directly be users, instead use "stream << object;" for writing it to a stream.
- Parameters
-
out | The output binary stream where object must be dumped. |
getVersion | If NULL, the object must be dumped. If not, only the version of the object dump must be returned in this pointer. This enables the versioning of objects dumping and backward compatibility with previously stored data. |
- Exceptions
-
std::exception | On any error, see CStream::WriteBuffer |
- See also
- CStream
Implements mrpt::utils::CSerializable.
◆ _init_CObservationCANBusJ1939
◆ classCObject
◆ classCObservation
◆ classCObservationCANBusJ1939
◆ classCSerializable
◆ classinfo
◆ m_data
std::vector<uint8_t> mrpt::obs::CObservationCANBusJ1939::m_data |
◆ m_data_length
uint8_t mrpt::obs::CObservationCANBusJ1939::m_data_length |
◆ m_pdu_format
uint8_t mrpt::obs::CObservationCANBusJ1939::m_pdu_format |
◆ m_pdu_spec
uint8_t mrpt::obs::CObservationCANBusJ1939::m_pdu_spec |
◆ m_pgn
uint16_t mrpt::obs::CObservationCANBusJ1939::m_pgn |
◆ m_priority
uint8_t mrpt::obs::CObservationCANBusJ1939::m_priority |
◆ m_raw_frame
std::vector<char> mrpt::obs::CObservationCANBusJ1939::m_raw_frame |
◆ m_src_address
uint8_t mrpt::obs::CObservationCANBusJ1939::m_src_address |
◆ sensorLabel
std::string mrpt::obs::CObservation::sensorLabel |
|
inherited |
An arbitrary label that can be used to identify the sensor.
Definition at line 60 of file obs/CObservation.h.
◆ timestamp