smurf
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
smurf::Robot Class Reference

#include <Robot.hpp>

Public Member Functions

 Robot ()
 
 ~Robot ()
 
const std::vector< smurf::StaticTransformation * > & getStaticTransforms () const
 
const std::vector< smurf::DynamicTransformation * > & getDynamicTransforms () const
 
const std::vector< smurf::Joint * > & getJoints () const
 
const std::vector< smurf::Motor * > & getMotors () const
 
const std::vector< smurf::Sensor * > & getSensors () const
 
const std::vector< smurf::Frame * > & getFrames () const
 
const FramegetRootFrame () const
 
const ContactParams getContactParams (const std::string &collisionName, const std::string &linkName)
 
void loadCollidables ()
 
void loadCollisions ()
 
void loadInertials ()
 
void loadJoints ()
 
void loadMotors ()
 
void loadSensors ()
 
void loadVisuals ()
 
void loadFrames (urdf::ModelInterfaceSharedPtr model)
 
void loadFromSmurf (const std::string &path, std::string prefix="")
 

Protected Member Functions

FramegetFrameByName (const std::string &name)
 
configmaps::ConfigMap getAnnotations (const urdf::JointSharedPtr &joint)
 
configmaps::ConfigMap getJointConfigMap (const urdf::JointSharedPtr &joint)
 

Protected Attributes

FramerootFrame
 
urdf::ModelInterfaceSharedPtr model
 
configmaps::ConfigMap * smurfMap
 
std::vector< smurf::Frame * > availableFrames
 
std::vector< smurf::StaticTransformation * > staticTransforms
 
std::vector< smurf::DynamicTransformation * > dynamicTransforms
 
std::vector< smurf::Joint * > joints
 
std::vector< smurf::Sensor * > sensors
 
std::vector< smurf::Motor * > motors
 
const bool debug = false
 
std::string prefix
 

Constructor & Destructor Documentation

smurf::Robot::Robot ( )
smurf::Robot::~Robot ( )

Member Function Documentation

configmaps::ConfigMap smurf::Robot::getAnnotations ( const urdf::JointSharedPtr &  joint)
protected
const smurf::ContactParams smurf::Robot::getContactParams ( const std::string &  collisionName,
const std::string &  linkName 
)
const std::vector<smurf::DynamicTransformation *>& smurf::Robot::getDynamicTransforms ( ) const
inline
smurf::Frame * smurf::Robot::getFrameByName ( const std::string &  name)
protected
const std::vector<smurf::Frame *>& smurf::Robot::getFrames ( ) const
inline
configmaps::ConfigMap smurf::Robot::getJointConfigMap ( const urdf::JointSharedPtr &  joint)
protected
const std::vector<smurf::Joint *>& smurf::Robot::getJoints ( ) const
inline
const std::vector<smurf::Motor *>& smurf::Robot::getMotors ( ) const
inline
const Frame* smurf::Robot::getRootFrame ( ) const
inline
const std::vector<smurf::Sensor *>& smurf::Robot::getSensors ( ) const
inline
const std::vector<smurf::StaticTransformation *>& smurf::Robot::getStaticTransforms ( ) const
inline
void smurf::Robot::loadCollidables ( )

Loads the SMURF Collidable objects in their correspondent frames

The smurf collidable contains the urdf collision object. Therefore if loadCollidables is executed, loadCollisions in no needed.

void smurf::Robot::loadCollisions ( )

Loads the URDF collision objects in their correspondent frames

void smurf::Robot::loadFrames ( urdf::ModelInterfaceSharedPtr  model)
void smurf::Robot::loadFromSmurf ( const std::string &  path,
std::string  prefix = "" 
)

Loads all the information from the Smurf model in the Robot object.

  • Creates the frames (from the links and from the visuals)
  • Loads the joints
  • Loads the sensors
  • Loads the collidables
  • Loads the inertials
void smurf::Robot::loadInertials ( )

Loads the SMURF Inertial objects in their correspondent frames

The smurf inertial object contains the urdf inertial object.

void smurf::Robot::loadJoints ( )

Loads the different joints of the model in the correspondent frames.

  • Fixed joints are loaded as staticTransforms
  • Floating, revolute and prismatic joints as dynamicTransforms and as Joints.
void smurf::Robot::loadMotors ( )
void smurf::Robot::loadSensors ( )
void smurf::Robot::loadVisuals ( )

Member Data Documentation

std::vector<smurf::Frame *> smurf::Robot::availableFrames
protected
const bool smurf::Robot::debug = false
protected
std::vector<smurf::DynamicTransformation *> smurf::Robot::dynamicTransforms
protected
std::vector<smurf::Joint *> smurf::Robot::joints
protected
urdf::ModelInterfaceSharedPtr smurf::Robot::model
protected
std::vector<smurf::Motor *> smurf::Robot::motors
protected
std::string smurf::Robot::prefix
protected
Frame* smurf::Robot::rootFrame
protected
std::vector<smurf::Sensor *> smurf::Robot::sensors
protected
configmaps::ConfigMap* smurf::Robot::smurfMap
protected
std::vector<smurf::StaticTransformation *> smurf::Robot::staticTransforms
protected

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