ImFusion SDK 4.3
RobotModel Class Reference

#include <RoboticsPlugin/Include/ImFusion/Robotics/Model/RobotModel.h>

Holds the description of a robot arm as a tree of links, kept together by joints (fixed or mobile). More...

Detailed Description

Holds the description of a robot arm as a tree of links, kept together by joints (fixed or mobile).

Multiple kinematic chains can be defined on the tree, selecting a contiguous set of segments (combination of a joint and a link). A single kinematic chain can be active at a time, and it will be used for the kinematic queries.

Classes

struct  NotableFrames
 Name of frames that identify the base, flange and end effector links within the URDF link tree. More...
 

Public Types

enum class  ValidStateType { Minimum , Average , Maximum }
 Point of the joint range to be used to generate a joint state satisfying the limits.
 

Public Member Functions

 RobotModel (RobotModel &&)
 
RobotModeloperator= (RobotModel &&)
 
std::shared_ptr< const RobotTreerobotTree () const
 
const RobotTreerobotTreeRef () const
 
std::unique_ptr< RobotSolvergenerateSolver () const
 
std::unique_ptr< RobotSolverAsyncgenerateSolverAsync () const
 
std::optional< RobotArmCartesianStateforwardKinematics (const JointPosition &jointPosition) const
 
InverseKinematicsSolution inverseKinematics (const isom3 &base_T_effector_goal, JointPosition init={}) const
 
InverseKinematicsVelSolution inverseKinematicsVel (const mat4 &goalVelocity, const JointPosition &jointPosition) const
 
InverseKinematicsVelSolution inverseKinematicsVel (const vec3 &goalTranslVelocity, const vec3 &goalRotVelocity, const JointPosition &jointPosition) const
 
JacobianSolution computeJacobian (const JointPosition &jointPosition) const
 
GravitySolution computeGravity (const JointPosition &jointPosition) const
 
CoriolisSolution computeCoriolis (const JointPosition &jointPosition, const JointVelocity &jointVelocity) const
 
std::shared_ptr< const RobotGroupmainGroup () const
 
RobotGroupPtr group () const
 
const RobotGroupMap * groups () const
 
std::optional< RobotGroupPtr > group (const std::string &name) const
 
JointState validJointState (ValidStateType type=ValidStateType::Minimum) const
 
JointState validJointState (double initVal) const
 
std::shared_ptr< const RobotDescriptionrobotDescription () const
 
std::shared_ptr< const RobotGUIPropertiesguiProperties () const
 
std::shared_ptr< const std::vector< std::string > > linkNames () const
 
std::string baseName () const
 
std::optional< std::stringflangeName () const
 
std::string endEffectorName () const
 
std::vector< std::stringplanningGroupNames () const
 
virtual size_t numberOfJoints () const
 
std::vector< std::stringjointNames (bool onlyActive=true) const
 
const isom3 & base_T_controllerBase () const
 
isom3 flange_T_effector_original () const
 
std::map< std::string, SavedGroupStategroupStates () const
 
std::shared_ptr< const RobotDescriptiondescription () const
 

Static Public Member Functions

static RobotModel loadFromFiles (const Filesystem::Path &resourcePrefix, const Filesystem::Path &urdfPath, const Filesystem::Path &srdfPath, const std::string &group, const NotableFrames &baseFlangeEffectorLinks={"", "", ""})
 Constructs a RobotModel from a ROS URDF and an SRDF.
 
static RobotModel loadFromBuffers (const Filesystem::Path &resourcePrefix, const std::string &urdf, const std::string &srdf, const std::string &group, const NotableFrames &baseFlangeEffectorLinks={"", "", ""})
 

Member Function Documentation

◆ loadFromFiles()

static RobotModel loadFromFiles ( const Filesystem::Path & resourcePrefix,
const Filesystem::Path & urdfPath,
const Filesystem::Path & srdfPath,
const std::string & group,
const NotableFrames & baseFlangeEffectorLinks = {"", "", ""} )
static

Constructs a RobotModel from a ROS URDF and an SRDF.

Note: supports only one end effector.

Parameters
resourcePrefixIf any path to or in the URDF or the SRDF are relative, this prefix will be prepended
urdfPathPath to the URDF
srdfPathPath to the SRDF, used to determine the default kinematic chain, named joint positions and the joint limits
baseFlangeEffectorLinksCan be used to override the default kinematic chain

◆ groupStates()

std::map< std::string, SavedGroupState > groupStates ( ) const
Deprecated
"Use group(name)->states() instead"

◆ description()

std::shared_ptr< const RobotDescription > description ( ) const
inline
Deprecated
"Use robotDescription() instead"

The documentation for this class was generated from the following file:
Search Tab / S to search, Esc to close