RobotReader Class Reference

The RobotReader class. More...

#include <RobotAPI/libraries/armem_robot_state/client/common/RobotReader.h>

+ Inheritance diagram for RobotReader:

Public Types

enum  Hand { Left, Right }
 
using JointTrajectory = std::map< armem::Time, RobotState::JointMap >
 

Public Member Functions

virtual void connect (armem::client::MemoryNameSystem &memoryNameSystem)
 
Robot get (const description::RobotDescription &description, const armem::Time &timestamp) const override
 
std::optional< Robotget (const std::string &name, const armem::Time &timestamp) const override
 
std::optional< description::RobotDescriptionqueryDescription (const std::string &name, const armem::Time &timestamp) const
 
std::vector< description::RobotDescriptionqueryDescriptions (const armem::Time &timestamp) const
 
std::optional< std::map< Hand, proprioception::ForceTorque > > queryForceTorque (const std::string &robotName, const armem::Time &timestamp) const
 
std::optional< std::map< RobotReader::Hand, std::map< armem::Time, proprioception::ForceTorque > > > queryForceTorques (const std::string &robotName, const armem::Time &start, const armem::Time &end) const
 
std::optional< RobotState::PosequeryGlobalPose (const std::string &robotName, const armem::Time &timestamp) const
 
std::optional< RobotStatequeryJointState (const std::string &robotName, const armem::Time &timestamp) const
 
JointTrajectory queryJointStates (const std::string &robotName, const armem::Time &begin, const armem::Time &end) const
 
std::optional<::armarx::armem::robot_state::localization::TransformqueryOdometryPose (const std::string &robotName, const armem::Time &timestamp) const
 retrieve the robot's pose in the odometry frame. More...
 
std::optional< PlatformStatequeryPlatformState (const std::string &robotName, const armem::Time &timestamp) const
 
std::optional< armarx::armem::arondto::Proprioception > queryProprioception (const std::string &robotName, const armem::Time &timestamp) const
 
std::optional< RobotStatequeryState (const std::string &robotName, const armem::Time &timestamp) const
 
std::optional< std::map< Hand, exteroception::ToF > > queryToF (const std::string &robotName, const armem::Time &timestamp) const
 
virtual void registerPropertyDefinitions (::armarx::PropertyDefinitionsPtr &def)
 
 RobotReader ()=default
 
 RobotReader (const RobotReader &)
 
void setSleepAfterSyncFailure (const armem::Duration &duration)
 
void setSyncTimeout (const armem::Duration &duration)
 
bool synchronize (Robot &obj, const armem::Time &timestamp) const override
 
virtual ~RobotReader ()=default
 
- Public Member Functions inherited from ReaderInterface
virtual ~ReaderInterface ()=default
 

Protected Attributes

armem::Duration sleepAfterFailure = armem::Duration::MicroSeconds(0)
 
armem::Duration syncTimeout = armem::Duration::MicroSeconds(0)
 

Detailed Description

The RobotReader class.

The purpose of this class is to synchronize the armem data structure armem::Robot with the memory.

Definition at line 43 of file RobotReader.h.

Member Typedef Documentation

◆ JointTrajectory

Definition at line 76 of file RobotReader.h.

Member Enumeration Documentation

◆ Hand

enum Hand
strong
Enumerator
Left 
Right 

Definition at line 91 of file RobotReader.h.

Constructor & Destructor Documentation

◆ RobotReader() [1/2]

RobotReader ( )
default

◆ RobotReader() [2/2]

RobotReader ( const RobotReader r)

Definition at line 33 of file RobotReader.cpp.

◆ ~RobotReader()

virtual ~RobotReader ( )
virtualdefault

Member Function Documentation

◆ connect()

void connect ( armem::client::MemoryNameSystem memoryNameSystem)
virtual

Definition at line 48 of file RobotReader.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ get() [1/2]

Robot get ( const description::RobotDescription description,
const armem::Time timestamp 
) const
overridevirtual

Implements ReaderInterface.

Definition at line 81 of file RobotReader.cpp.

+ Here is the call graph for this function:

◆ get() [2/2]

std::optional< Robot > get ( const std::string &  name,
const armem::Time timestamp 
) const
overridevirtual

Implements ReaderInterface.

Definition at line 67 of file RobotReader.cpp.

+ Here is the call graph for this function:

◆ queryDescription()

std::optional< description::RobotDescription > queryDescription ( const std::string &  name,
const armem::Time timestamp 
) const

Definition at line 138 of file RobotReader.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ queryDescriptions()

std::vector< description::RobotDescription > queryDescriptions ( const armem::Time timestamp) const

Definition at line 850 of file RobotReader.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ queryForceTorque()

std::optional< std::map< RobotReader::Hand, proprioception::ForceTorque > > queryForceTorque ( const std::string &  robotName,
const armem::Time timestamp 
) const

Definition at line 524 of file RobotReader.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ queryForceTorques()

std::optional< std::map< RobotReader::Hand, std::map< armem::Time, proprioception::ForceTorque > > > queryForceTorques ( const std::string &  robotName,
const armem::Time start,
const armem::Time end 
) const

Definition at line 566 of file RobotReader.cpp.

+ Here is the call graph for this function:

◆ queryGlobalPose()

std::optional< RobotState::Pose > queryGlobalPose ( const std::string &  robotName,
const armem::Time timestamp 
) const

Definition at line 378 of file RobotReader.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ queryJointState()

std::optional< RobotState > queryJointState ( const std::string &  robotName,
const armem::Time timestamp 
) const

Definition at line 206 of file RobotReader.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ queryJointStates()

RobotReader::JointTrajectory queryJointStates ( const std::string &  robotName,
const armem::Time begin,
const armem::Time end 
) const

Definition at line 295 of file RobotReader.cpp.

+ Here is the call graph for this function:

◆ queryOdometryPose()

std::optional<::armarx::armem::robot_state::localization::Transform > queryOdometryPose ( const std::string &  robotName,
const armem::Time timestamp 
) const

retrieve the robot's pose in the odometry frame.

This pose is an integration of the robot's platform velocity and undergoes a significant drift.

Parameters
description
timestamp
Returns
std::optional<RobotState::Pose>

Definition at line 226 of file RobotReader.cpp.

+ Here is the call graph for this function:

◆ queryPlatformState()

std::optional< PlatformState > queryPlatformState ( const std::string &  robotName,
const armem::Time timestamp 
) const

Definition at line 336 of file RobotReader.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ queryProprioception()

std::optional< armarx::armem::arondto::Proprioception > queryProprioception ( const std::string &  robotName,
const armem::Time timestamp 
) const

Definition at line 253 of file RobotReader.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ queryState()

std::optional< RobotState > queryState ( const std::string &  robotName,
const armem::Time timestamp 
) const

Definition at line 186 of file RobotReader.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ queryToF()

std::optional< std::map< RobotReader::Hand, exteroception::ToF > > queryToF ( const std::string &  robotName,
const armem::Time timestamp 
) const

Definition at line 608 of file RobotReader.cpp.

+ Here is the call graph for this function:

◆ registerPropertyDefinitions()

void registerPropertyDefinitions ( ::armarx::PropertyDefinitionsPtr def)
virtual

Definition at line 42 of file RobotReader.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setSleepAfterSyncFailure()

void setSleepAfterSyncFailure ( const armem::Duration duration)

Definition at line 101 of file RobotReader.cpp.

+ Here is the call graph for this function:

◆ setSyncTimeout()

void setSyncTimeout ( const armem::Duration duration)

Definition at line 95 of file RobotReader.cpp.

◆ synchronize()

bool synchronize ( Robot obj,
const armem::Time timestamp 
) const
overridevirtual

Implements ReaderInterface.

Definition at line 108 of file RobotReader.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Member Data Documentation

◆ sleepAfterFailure

armem::Duration sleepAfterFailure = armem::Duration::MicroSeconds(0)
protected

Definition at line 125 of file RobotReader.h.

◆ syncTimeout

armem::Duration syncTimeout = armem::Duration::MicroSeconds(0)
protected

Definition at line 124 of file RobotReader.h.


The documentation for this class was generated from the following files: