XBotInterface
2.4.1
XBotInterface provides a generic API to model and control a robot.
|
#include <XBotInterface.h>
Public Types | |
typedef std::shared_ptr< XBotInterface > | Ptr |
typedef std::shared_ptr< const XBotInterface > | ConstPtr |
Public Member Functions | |
XBotInterface () | |
XBotInterface (const XBotInterface &other) | |
XBotInterface & | operator= (const XBotInterface &rhs) |
virtual | ~XBotInterface () |
bool | init (const std::string &path_to_cfg) |
bool | init (const ConfigOptions &options) |
const ConfigOptions & | getConfigOptions () const |
Gets the configuration struct that has been used to build the XBotInterface. More... | |
const std::string & | getPathToConfig () const |
Gets the path to the YAML config file used to build the XBotInterface. More... | |
const urdf::ModelInterface & | getUrdf () const |
Getter for the robot URDF model corresponding to the URDF xml file specified in the YAML config file. More... | |
const std::string & | getUrdfPath () const |
getUrdfPath Getter for the path to the URDF model More... | |
const srdf_advr::Model & | getSrdf () const |
Getter fot the robot SRDF model corresponding to the SRDF xml file specified in the YAML config file. More... | |
const std::string & | getSrdfPath () const |
getSrdfPath Getter for the path to the SRDF model More... | |
const std::string & | getUrdfString () const |
Returns the robot URDF xml as a string. More... | |
const std::string & | getSrdfString () const |
Returns the robot SRDF xml as a string. More... | |
bool | getRobotState (const std::string &state_name, Eigen::VectorXd &q) const |
Gets the robot joints group state configuration as specified in the robot SRDF. More... | |
bool | getRobotState (const std::string &state_name, JointIdMap &q) const |
Gets the robot joints group state configuration as specified in the robot SRDF. More... | |
bool | getRobotState (const std::string &state_name, JointNameMap &q) const |
Gets the robot joints group state configuration as specified in the robot SRDF. More... | |
std::vector< std::string > | getChainNames () const |
Return a vector of available chain names as strings. More... | |
bool | hasChain (const std::string &chain_name) const |
A method for determining if a chain with name "chain_name" is defined inside the interface. More... | |
int | legs () const |
Returns the number of legs defined inside the interface. More... | |
int | arms () const |
Returns the number of arms defined inside the interface. More... | |
const std::vector< std::string > & | getEnabledJointNames () const |
Returns a vector of enabled joint names. More... | |
const std::vector< int > & | getEnabledJointId () const |
Returns a vector of enabled joint IDs. More... | |
bool | hasJoint (const std::string &joint_name) const |
Checks that a joint with name "joint_name" is defined as an enabled joint inside the interface. More... | |
bool | hasJoint (int joint_id) const |
Checks that a joint with ID "joint_id" is defined as an enabled joint inside the interface. More... | |
int | getJointNum () const |
Getter for the number of enabled joints. More... | |
XBot::Joint::ConstPtr | getJointByName (const std::string &joint_name) const |
Gets the joint with name "joint_name" if it is defined as enabled. More... | |
XBot::Joint::ConstPtr | getJointByID (int joint_id) const |
Gets the joint with ID "joint_id" if it is defined as enabled. More... | |
XBot::Joint::ConstPtr | getJointByDofIndex (int idx) const |
Gets the joint with the required dof index. More... | |
int | getDofIndex (const std::string &joint_name) const |
Gets the Eigen ID of the joint with name "joint_name". More... | |
int | getDofIndex (int joint_id) const |
Gets the Eigen ID of the joint with ID "joint_id". More... | |
bool | getDofIndex (const std::string &chain_name, std::vector< int > &ids) const |
Gets dof indices of all joints inside chain "chain_name". More... | |
void | initLog (MatLogger2::Ptr logger, int buffer_size=-1, int interleave=1, std::string prefix="") |
Pre-allocates memory for logging the robot state to a mat file. More... | |
void | log (MatLogger2::Ptr logger, double timestamp, const std::string &prefix="") const |
Logs the current robot state. More... | |
std::map< std::string, ForceTorqueSensor::ConstPtr > | getForceTorque () const |
Getter for the force-torque sensor map pertaining to the whole robot. More... | |
ForceTorqueSensor::ConstPtr | getForceTorque (const std::string &parent_link_name) const |
Returns a force-torque sensor given its parent-link name. More... | |
ForceTorqueSensor::ConstPtr | getForceTorque (int ft_id) const |
Returns a force-torque sensor given its sensor ID. More... | |
std::map< std::string, ImuSensor::ConstPtr > | getImu () |
Getter for the IMU sensor map pertaining to the chain. More... | |
ImuSensor::ConstPtr | getImu (const std::string &parent_link_name) const |
Returns an IMU sensor given its parent-link name. More... | |
ImuSensor::ConstPtr | getImu (int imu_id) const |
Returns an IMU sensor given its sensor ID. More... | |
std::map< std::string, Hand::Ptr > | getHand () |
Getter for the hands map pertaining to the whole robot. More... | |
Hand::Ptr | getHand (int hand_id) const |
Returns a hand given its hand ID. More... | |
bool | eigenToMap (const Eigen::VectorXd &vector, JointNameMap &name_map) const |
Converts a state vector for the whole robot to its JointNameMap representation. More... | |
bool | eigenToMap (const Eigen::VectorXd &vector, JointIdMap &id_map) const |
Converts a state vector for the whole robot to its JointIdMap representation. More... | |
bool | mapToEigen (const JointNameMap &map, Eigen::VectorXd &vector) const |
Converts a state vector for an arbitrary subset of the robot state (specified as a JointNameMap) to its Eigen representation. More... | |
bool | mapToEigen (const JointIdMap &map, Eigen::VectorXd &vector) const |
Converts a state vector for an arbitrary subset of the robot state (specified as a JointIdMap) to its Eigen representation. More... | |
bool | getJointPosition (Eigen::VectorXd &q) const |
Gets the robot joint positions as an Eigen vector. More... | |
bool | getMotorPosition (Eigen::VectorXd &q) const |
Gets the robot motor positions as an Eigen vector. More... | |
bool | getJointVelocity (Eigen::VectorXd &qdot) const |
Gets the robot joint velocities as an Eigen vector. More... | |
bool | getMotorVelocity (Eigen::VectorXd &qdot) const |
Gets the robot motor velocities as an Eigen vector. More... | |
bool | getJointAcceleration (Eigen::VectorXd &qddot) const |
Gets the robot joint accelerations as an Eigen vector. More... | |
bool | getJointEffort (Eigen::VectorXd &tau) const |
Gets the robot joint efforts as an Eigen vector. More... | |
bool | getTemperature (Eigen::VectorXd &temp) const |
Gets the robot joint temperatures as an Eigen vector. More... | |
bool | getJointPosition (JointIdMap &q) const |
Gets the robot joint positions as a JointIdMap, i.e. More... | |
bool | getMotorPosition (JointIdMap &q) const |
Gets the robot motor positions as a JointIdMap, i.e. More... | |
bool | getJointVelocity (JointIdMap &qdot) const |
Gets the robot joint velocities as a JointIdMap, i.e. More... | |
bool | getMotorVelocity (JointIdMap &qdot) const |
Gets the robot motor velocities as a JointIdMap, i.e. More... | |
bool | getJointAcceleration (JointIdMap &qddot) const |
Gets the robot joint accelerations as a JointIdMap, i.e. More... | |
bool | getJointEffort (JointIdMap &tau) const |
Gets the robot joint efforts as a JointIdMap, i.e. More... | |
bool | getTemperature (JointIdMap &temp) const |
Gets the robot joint temperatures as a JointIdMap, i.e. More... | |
bool | getJointPosition (JointNameMap &q) const |
Gets the robot joint postions as a JointNameMap, i.e. More... | |
bool | getMotorPosition (JointNameMap &q) const |
Gets the robot motor postions as a JointNameMap, i.e. More... | |
bool | getJointVelocity (JointNameMap &qdot) const |
Gets the robot joint velocities as a JointNameMap, i.e. More... | |
bool | getMotorVelocity (JointNameMap &qdot) const |
Gets the robot motor velocities as a JointNameMap, i.e. More... | |
bool | getJointAcceleration (JointNameMap &qddot) const |
Gets the robot joint accelerations as a JointNameMap, i.e. More... | |
bool | getJointEffort (JointNameMap &tau) const |
Gets the robot joint efforts as a JointNameMap, i.e. More... | |
bool | getTemperature (JointNameMap &temp) const |
Gets the robot joint temperatures as a JointNameMap, i.e. More... | |
bool | setJointPosition (const Eigen::VectorXd &q) |
Sets the XBotInterface internal joint positions according to the provided vector, which must be ordered as specified by the getEnabledJointNames/getEnabledJointId methods. More... | |
bool | setMotorPosition (const Eigen::VectorXd &q) |
Sets the XBotInterface internal motor positions according to the provided vector, which must be ordered as specified by the getEnabledJointNames/getEnabledJointId methods. More... | |
bool | setJointVelocity (const Eigen::VectorXd &qdot) |
Sets the XBotInterface internal joint velocities according to the provided vector, which must be ordered as specified by the getEnabledJointNames/getEnabledJointId methods. More... | |
bool | setMotorVelocity (const Eigen::VectorXd &qdot) |
Sets the XBotInterface internal motor velocities according to the provided vector, which must be ordered as specified by the getEnabledJointNames/getEnabledJointId methods. More... | |
bool | setJointAcceleration (const Eigen::VectorXd &qddot) |
Sets the XBotInterface internal joint accelerations according to the provided vector, which must be ordered as specified by the getEnabledJointNames/getEnabledJointId methods. More... | |
bool | setJointEffort (const Eigen::VectorXd &tau) |
Sets the XBotInterface internal joint efforts according to the provided vector, which must be ordered as specified by the getEnabledJointNames/getEnabledJointId methods. More... | |
bool | setTemperature (const Eigen::VectorXd &temp) |
Sets the XBotInterface internal joint temperatures according to the provided vector, which must be ordered as specified by the getEnabledJointNames/getEnabledJointId methods. More... | |
bool | setJointPosition (const JointIdMap &q) |
Sets the XBotInterface internal joint positions according to the input JointIdMap (i.e. More... | |
bool | setMotorPosition (const JointIdMap &q) |
Sets the XBotInterface internal motor positions according to the input JointIdMap (i.e. More... | |
bool | setJointVelocity (const JointIdMap &qdot) |
Sets the XBotInterface internal joint velocities according to the input JointIdMap (i.e. More... | |
bool | setMotorVelocity (const JointIdMap &qdot) |
Sets the XBotInterface internal motor velocities according to the input JointIdMap (i.e. More... | |
bool | setJointAcceleration (const JointIdMap &qddot) |
Sets the XBotInterface internal joint accelerations according to the input JointIdMap (i.e. More... | |
bool | setJointEffort (const JointIdMap &tau) |
Sets the XBotInterface internal joint efforts according to the input JointIdMap (i.e. More... | |
bool | setTemperature (const JointIdMap &temp) |
Sets the XBotInterface internal motor temperatures according to the input JointIdMap (i.e. More... | |
bool | setJointPosition (const JointNameMap &q) |
Sets the XBotInterface internal joint positions according to the input JointNameMap (i.e. More... | |
bool | setMotorPosition (const JointNameMap &q) |
Sets the XBotInterface internal motor positions according to the input JointNameMap (i.e. More... | |
bool | setJointVelocity (const JointNameMap &qdot) |
Sets the XBotInterface internal joint velocities according to the input JointNameMap (i.e. More... | |
bool | setMotorVelocity (const JointNameMap &qdot) |
Sets the XBotInterface internal motor velocities according to the input JointNameMap (i.e. More... | |
bool | setJointAcceleration (const JointNameMap &qddot) |
Sets the XBotInterface internal joint accelerations according to the input JointNameMap (i.e. More... | |
bool | setJointEffort (const JointNameMap &tau) |
Sets the XBotInterface internal joint efforts according to the input JointNameMap (i.e. More... | |
bool | setTemperature (const JointNameMap &temp) |
Sets the XBotInterface internal joint temperatures according to the input JointNameMap (i.e. More... | |
bool | getPositionReference (Eigen::VectorXd &q) const |
Gets the robot position references as an Eigen vector. More... | |
bool | getVelocityReference (Eigen::VectorXd &qdot) const |
Gets the robot velocity references as an Eigen vector. More... | |
bool | getEffortReference (Eigen::VectorXd &tau) const |
Gets the robot effort references as an Eigen vector. More... | |
bool | getStiffness (Eigen::VectorXd &K) const |
Gets the robot stiffness as an Eigen vector. More... | |
bool | getDamping (Eigen::VectorXd &D) const |
Gets the robot damping as an Eigen vector. More... | |
bool | getPositionReference (JointIdMap &q) const |
Gets the robot position references as a JointIdMap, i.e. More... | |
bool | getVelocityReference (JointIdMap &qdot) const |
Gets the robot velocity references as a JointIdMap, i.e. More... | |
bool | getEffortReference (JointIdMap &tau) const |
Gets the robot effort references as a JointIdMap, i.e. More... | |
bool | getStiffness (JointIdMap &K) const |
Gets the robot stiffness as a JointIdMap, i.e. More... | |
bool | getDamping (JointIdMap &D) const |
Gets the robot damping as a JointIdMap, i.e. More... | |
bool | getPositionReference (JointNameMap &q) const |
Gets the robot postion references as a JointNameMap, i.e. More... | |
bool | getVelocityReference (JointNameMap &qdot) const |
Gets the robot velocity references as a JointNameMap, i.e. More... | |
bool | getEffortReference (JointNameMap &tau) const |
Gets the robot effort references as a JointNameMap, i.e. More... | |
bool | getStiffness (JointNameMap &K) const |
Gets the robot stiffness as a JointNameMap, i.e. More... | |
bool | getDamping (JointNameMap &D) const |
Gets the robot damping as a JointNameMap, i.e. More... | |
bool | setPositionReference (const Eigen::VectorXd &q) |
Sets the XBotInterface internal joint position references according to the provided vector, which must be ordered as specified by the getEnabledJointNames/getEnabledJointId methods. More... | |
bool | setVelocityReference (const Eigen::VectorXd &qdot) |
Sets the XBotInterface internal joint velocity references according to the provided vector, which must be ordered as specified by the getEnabledJointNames/getEnabledJointId methods. More... | |
bool | setEffortReference (const Eigen::VectorXd &tau) |
Sets the XBotInterface internal joint effort references according to the provided vector, which must be ordered as specified by the getEnabledJointNames/getEnabledJointId methods. More... | |
bool | setStiffness (const Eigen::VectorXd &K) |
Sets the XBotInterface internal joint stiffness according to the provided vector, which must be ordered as specified by the getEnabledJointNames/getEnabledJointId methods. More... | |
bool | setDamping (const Eigen::VectorXd &D) |
Sets the XBotInterface internal joint damping according to the provided vector, which must be ordered as specified by the getEnabledJointNames/getEnabledJointId methods. More... | |
bool | setPositionReference (const JointIdMap &q) |
Sets the XBotInterface internal joint position references according to the input JointIdMap (i.e. More... | |
bool | setVelocityReference (const JointIdMap &qdot) |
Sets the XBotInterface internal joint velocity references according to the input JointIdMap (i.e. More... | |
bool | setEffortReference (const JointIdMap &tau) |
Sets the XBotInterface internal joint effort references according to the input JointIdMap (i.e. More... | |
bool | setStiffness (const JointIdMap &K) |
Sets the XBotInterface internal joint stiffness according to the input JointIdMap (i.e. More... | |
bool | setDamping (const JointIdMap &D) |
Sets the XBotInterface internal joint damping according to the input JointIdMap (i.e. More... | |
bool | setPositionReference (const JointNameMap &q) |
Sets the XBotInterface internal joint position references according to the input JointNameMap (i.e. More... | |
bool | setVelocityReference (const JointNameMap &qdot) |
Sets the XBotInterface internal joint velocity references according to the input JointNameMap (i.e. More... | |
bool | setEffortReference (const JointNameMap &tau) |
Sets the XBotInterface internal joint effort references according to the input JointNameMap (i.e. More... | |
bool | setStiffness (const JointNameMap &K) |
Sets the XBotInterface internal joint stiffness according to the input JointNameMap (i.e. More... | |
bool | setDamping (const JointNameMap &D) |
Sets the XBotInterface internal joint damping according to the input JointNameMap (i.e. More... | |
void | getJointLimits (Eigen::VectorXd &q_min, Eigen::VectorXd &q_max) const |
Gets a vector of the robot joint limits, as specified in the URDF file. More... | |
void | getVelocityLimits (Eigen::VectorXd &qdot_max) const |
Gets a vector of the robot joint velocity limits, as specified in the URDF file. More... | |
void | getEffortLimits (Eigen::VectorXd &tau_max) const |
Gets a vector of the robot joint effort limits, as specified in the URDF file. More... | |
bool | checkJointLimits (const Eigen::VectorXd &q, std::vector< std::string > &violating_joints) const |
Check the input joint position vector against joint limits. More... | |
bool | checkVelocityLimits (const Eigen::VectorXd &qdot, std::vector< std::string > &violating_joints) const |
Check the input joint velocity vector against joint limits. More... | |
bool | checkEffortLimits (const Eigen::VectorXd &tau, std::vector< std::string > &violating_joints) const |
Check the input joint effort vector against joint limits. More... | |
bool | checkJointLimits (const Eigen::VectorXd &q) const |
Check the input joint position vector against joint limits. More... | |
bool | checkVelocityLimits (const Eigen::VectorXd &qdot) const |
Check the input joint velocity vector against joint limits. More... | |
bool | checkEffortLimits (const Eigen::VectorXd &tau) const |
Check the input joint effort vector against joint limits. More... | |
bool | enforceJointLimits (JointIdMap &q) const |
Modifies the input joint position map by enforcing joint limits. More... | |
bool | enforceJointLimits (JointNameMap &q) const |
Modifies the input joint position map by enforcing joint limits. More... | |
bool | enforceJointLimits (Eigen::VectorXd &q) const |
Modifies the input joint position vector by enforcing joint limits. More... | |
bool | enforceEffortLimit (Eigen::VectorXd &tau) const |
Modifies the input joint effort vector by enforcing effort limits. More... | |
bool | enforceVelocityLimit (Eigen::VectorXd &qdot) const |
Modifies the input joint velcoity vector by enforcing joint limits. More... | |
template<typename... SyncFlags> | |
bool | sync (const XBotInterface &other, SyncFlags... flags) |
Synchronize the current XBotInterface with another XBotInterface object: only the common chains will be taken into account. More... | |
const std::map< std::string, XBot::KinematicChain::Ptr > & | getChainMap () const |
Getter for the chain map inside the XBotInterface. More... | |
void | print () const |
Print a pretty table about the robot state. More... | |
void | printTracking () const |
Print a pretty table about the robot tracking. More... | |
Protected Member Functions | |
Joint::Ptr | getJointByNameInternal (const std::string &joint_name) const |
Joint::Ptr | getJointByIdInternal (int joint_id) const |
Joint::Ptr | getJointByDofIndexInternal (int dof_index) const |
const std::map< std::string, ForceTorqueSensor::Ptr > & | getForceTorqueInternal () const |
const std::map< std::string, ImuSensor::Ptr > & | getImuInternal () const |
virtual bool | init_internal (const ConfigOptions &config) |
virtual bool | post_init () |
const std::vector< std::string > & | getModelOrderedChainName () const |
Protected Attributes | |
XBotCoreModel | _XBotModel |
std::map< std::string, XBot::KinematicChain::Ptr > | _chain_map |
std::vector< Joint::Ptr > | _ordered_joint_vector |
std::vector< Joint::Ptr > | _joint_vector |
std::map< std::string, ForceTorqueSensor::Ptr > | _ft_map |
std::map< int, ForceTorqueSensor::Ptr > | _ft_id_map |
std::map< std::string, ImuSensor::Ptr > | _imu_map |
std::map< int, ImuSensor::Ptr > | _imu_id_map |
std::map< std::string, Hand::Ptr > | _hand_map |
std::map< int, Hand::Ptr > | _hand_id_map |
std::vector< std::string > | _ordered_chain_names |
std::map< int, int > | _joint_id_to_eigen_id |
std::map< std::string, int > | _joint_name_to_eigen_id |
Friends | |
std::ostream & | operator<< (std::ostream &os, const XBot::XBotInterface &robot) |
typedef std::shared_ptr<const XBotInterface> XBot::XBotInterface::ConstPtr |
typedef std::shared_ptr<XBotInterface> XBot::XBotInterface::Ptr |
XBot::XBotInterface::XBotInterface | ( | ) |
XBot::XBotInterface::XBotInterface | ( | const XBotInterface & | other | ) |
|
virtual |
int XBot::XBotInterface::arms | ( | ) | const |
Returns the number of arms defined inside the interface.
This equals the number of elements of the "arms" group inside the SRDF which was provided in the YAML config file.
bool XBot::XBotInterface::checkEffortLimits | ( | const Eigen::VectorXd & | tau | ) | const |
Check the input joint effort vector against joint limits.
tau | A joint effort vector to be checked against joint limits. |
bool XBot::XBotInterface::checkEffortLimits | ( | const Eigen::VectorXd & | tau, |
std::vector< std::string > & | violating_joints | ||
) | const |
Check the input joint effort vector against joint limits.
The names of joints violating the limits are pushed into the violating_joints vector (which is not cleared before being filled)
tau | A joint position vector to be checked against joint limits. |
violating_joints | The vector of the names of joints violating the limits. Note that this is not cleared before use. |
bool XBot::XBotInterface::checkJointLimits | ( | const Eigen::VectorXd & | q | ) | const |
Check the input joint position vector against joint limits.
q | A joint position vector to be checked against joint limits. |
bool XBot::XBotInterface::checkJointLimits | ( | const Eigen::VectorXd & | q, |
std::vector< std::string > & | violating_joints | ||
) | const |
Check the input joint position vector against joint limits.
The names of joints violating the limits are pushed into the violating_joints vector (which is not cleared before being filled)
q | A joint position vector to be checked against joint limits. |
violating_joints | The vector of the names of joints violating the limits. Note that this is not cleared before use. |
bool XBot::XBotInterface::checkVelocityLimits | ( | const Eigen::VectorXd & | qdot | ) | const |
Check the input joint velocity vector against joint limits.
qdot | A joint velocity vector to be checked against joint limits. |
bool XBot::XBotInterface::checkVelocityLimits | ( | const Eigen::VectorXd & | qdot, |
std::vector< std::string > & | violating_joints | ||
) | const |
Check the input joint velocity vector against joint limits.
The names of joints violating the limits are pushed into the violating_joints vector (which is not cleared before being filled)
qdot | A joint position vector to be checked against joint limits. |
violating_joints | The vector of the names of joints violating the limits. Note that this is not cleared before use. |
bool XBot::XBotInterface::eigenToMap | ( | const Eigen::VectorXd & | vector, |
XBot::JointIdMap & | id_map | ||
) | const |
Converts a state vector for the whole robot to its JointIdMap representation.
Note that the output map is not cleared before it is filled. It is the responsibility of the user to do so if required.
vector | A state vector for the whole robot (its size must match getJointNum()) |
id_map | The output map to be filled |
bool XBot::XBotInterface::eigenToMap | ( | const Eigen::VectorXd & | vector, |
XBot::JointNameMap & | name_map | ||
) | const |
Converts a state vector for the whole robot to its JointNameMap representation.
Note that the output map is not cleared before it is filled. It is the responsibility of the user to do so if required.
vector | A state vector for the whole robot (its size must match getJointNum()) |
name_map | The output map to be filled |
bool XBot::XBotInterface::enforceEffortLimit | ( | Eigen::VectorXd & | tau | ) | const |
Modifies the input joint effort vector by enforcing effort limits.
tau | The input joint effort vector. Out-of-range components are set to the closest joint limit. |
bool XBot::XBotInterface::enforceJointLimits | ( | Eigen::VectorXd & | q | ) | const |
Modifies the input joint position vector by enforcing joint limits.
q | The input joint position vector. Out-of-range components are set to the closest joint limit. |
bool XBot::XBotInterface::enforceJointLimits | ( | XBot::JointIdMap & | q | ) | const |
Modifies the input joint position map by enforcing joint limits.
q | The input joint position map. Out-of-range components are set to the closest joint limit. |
bool XBot::XBotInterface::enforceJointLimits | ( | XBot::JointNameMap & | q | ) | const |
Modifies the input joint position map by enforcing joint limits.
q | The input joint position map. Out-of-range components are set to the closest joint limit. |
bool XBot::XBotInterface::enforceVelocityLimit | ( | Eigen::VectorXd & | qdot | ) | const |
Modifies the input joint velcoity vector by enforcing joint limits.
qdot | The input joint velocity vector. Out-of-range components are set to the closest joint limit. |
const std::map< std::string, XBot::KinematicChain::Ptr > & XBot::XBotInterface::getChainMap | ( | ) | const |
Getter for the chain map inside the XBotInterface.
std::vector< std::string > XBot::XBotInterface::getChainNames | ( | ) | const |
Return a vector of available chain names as strings.
const XBot::ConfigOptions & XBot::XBotInterface::getConfigOptions | ( | ) | const |
Gets the configuration struct that has been used to build the XBotInterface.
bool XBot::XBotInterface::getDamping | ( | Eigen::VectorXd & | D | ) | const |
Gets the robot damping as an Eigen vector.
The joint order inside the vector can be queried by calling the getEnabledJointNames/getEnabledJointId methods.
D | A reference to an Eigen vector to be filled with the requested joint state. If the provided vector has wrong size it is resized automatically. |
bool XBot::XBotInterface::getDamping | ( | JointIdMap & | D | ) | const |
Gets the robot damping as a JointIdMap, i.e.
a map whose key represents the joint ID and whose value represents the required joint state.
D | A reference to a JointIdMap to be filled with the requested joint state. It is the user responsibility to clear the map before it is filled (if required). |
bool XBot::XBotInterface::getDamping | ( | JointNameMap & | D | ) | const |
Gets the robot damping as a JointNameMap, i.e.
a map whose key represents the joint human-readable name and whose value represents the required joint state.
D | A reference to a JointIdMap to be filled with the requested joint state. It is the user responsibility to clear the map before it is filled (if required). |
bool XBot::XBotInterface::getDofIndex | ( | const std::string & | chain_name, |
std::vector< int > & | ids | ||
) | const |
Gets dof indices of all joints inside chain "chain_name".
chain_name | The name of the requested chain. |
ids | The output vector of dof indices. |
int XBot::XBotInterface::getDofIndex | ( | const std::string & | joint_name | ) | const |
Gets the Eigen ID of the joint with name "joint_name".
This means that the i-th entry of all Eigen vectors which are taken as arguments by XBotInterface methods refers to the joint namd "joint_name".
joint_name | The name of the required joint. |
int XBot::XBotInterface::getDofIndex | ( | int | joint_id | ) | const |
Gets the Eigen ID of the joint with ID "joint_id".
This means that the i-th entry of all Eigen vectors which are taken as arguments by XBotInterface methods refers to the joint with the given ID.
joint_id | The ID of the required joint. |
void XBot::XBotInterface::getEffortLimits | ( | Eigen::VectorXd & | tau_max | ) | const |
Gets a vector of the robot joint effort limits, as specified in the URDF file.
qdot_max | The output vector of the chain joints effort limits |
bool XBot::XBotInterface::getEffortReference | ( | Eigen::VectorXd & | tau | ) | const |
Gets the robot effort references as an Eigen vector.
The joint order inside the vector can be queried by calling the getEnabledJointNames/getEnabledJointId methods.
tau | A reference to an Eigen vector to be filled with the requested joint state. If the provided vector has wrong size it is resized automatically. |
bool XBot::XBotInterface::getEffortReference | ( | JointIdMap & | tau | ) | const |
Gets the robot effort references as a JointIdMap, i.e.
a map whose key represents the joint ID and whose value represents the required joint state.
tau | A reference to a JointIdMap to be filled with the requested joint state. It is the user responsibility to clear the map before it is filled (if required). |
bool XBot::XBotInterface::getEffortReference | ( | JointNameMap & | tau | ) | const |
Gets the robot effort references as a JointNameMap, i.e.
a map whose key represents the joint human-readable name and whose value represents the required joint state.
tau | A reference to a JointIdMap to be filled with the requested joint state. It is the user responsibility to clear the map before it is filled (if required). |
const std::vector< int > & XBot::XBotInterface::getEnabledJointId | ( | ) | const |
Returns a vector of enabled joint IDs.
const std::vector< std::string > & XBot::XBotInterface::getEnabledJointNames | ( | ) | const |
Returns a vector of enabled joint names.
std::map< std::string, XBot::ForceTorqueSensor::ConstPtr > XBot::XBotInterface::getForceTorque | ( | ) | const |
Getter for the force-torque sensor map pertaining to the whole robot.
XBot::ForceTorqueSensor::ConstPtr XBot::XBotInterface::getForceTorque | ( | const std::string & | parent_link_name | ) | const |
Returns a force-torque sensor given its parent-link name.
parent_link_name | Name of the link to which the sensor is attached |
XBot::ForceTorqueSensor::ConstPtr XBot::XBotInterface::getForceTorque | ( | int | ft_id | ) | const |
Returns a force-torque sensor given its sensor ID.
ft_id | Sensor ID as given by ForceTorqueSensor::getSensorId(). If the sensor fixed joint is listed inside the joint id map, then the sensor id is the one specified inside such a file. |
|
protected |
std::map< std::string, XBot::Hand::Ptr > XBot::XBotInterface::getHand | ( | ) |
Getter for the hands map pertaining to the whole robot.
XBot::Hand::Ptr XBot::XBotInterface::getHand | ( | int | hand_id | ) | const |
Returns a hand given its hand ID.
hand_id | hand ID as given by Hand::getHandId(). If the hand fixed joint is listed inside the joint id map, then the hand id is the one specified inside such a file. |
std::map< std::string, XBot::ImuSensor::ConstPtr > XBot::XBotInterface::getImu | ( | ) |
Getter for the IMU sensor map pertaining to the chain.
XBot::ImuSensor::ConstPtr XBot::XBotInterface::getImu | ( | const std::string & | parent_link_name | ) | const |
Returns an IMU sensor given its parent-link name.
parent_link_name | Name of the link to which the sensor is attached |
XBot::ImuSensor::ConstPtr XBot::XBotInterface::getImu | ( | int | imu_id | ) | const |
Returns an IMU sensor given its sensor ID.
imu_id | Sensor ID as given by ImuSensor::getSensorId(). If the sensor fixed joint is listed inside the joint id map, then the sensor id is the one specified inside such a file. |
|
protected |
bool XBot::XBotInterface::getJointAcceleration | ( | Eigen::VectorXd & | qddot | ) | const |
Gets the robot joint accelerations as an Eigen vector.
The joint order inside the vector can be queried by calling the getEnabledJointNames/getEnabledJointId methods.
qddot | A reference to an Eigen vector to be filled with the requested joint state. If the provided vector has wrong size it is resized automatically. |
bool XBot::XBotInterface::getJointAcceleration | ( | JointIdMap & | qddot | ) | const |
Gets the robot joint accelerations as a JointIdMap, i.e.
a map whose key represents the joint ID and whose value represents the required joint state.
qddot | A reference to a JointIdMap to be filled with the requested joint state. It is the user responsibility to clear the map before it is filled (if required). |
bool XBot::XBotInterface::getJointAcceleration | ( | JointNameMap & | qddot | ) | const |
Gets the robot joint accelerations as a JointNameMap, i.e.
a map whose key represents the joint human-readable name and whose value represents the required joint state.
qddot | A reference to a JointIdMap to be filled with the requested joint state. It is the user responsibility to clear the map before it is filled (if required). |
XBot::Joint::ConstPtr XBot::XBotInterface::getJointByDofIndex | ( | int | idx | ) | const |
Gets the joint with the required dof index.
This means that the idx-th entry of all Eigen vectors which are taken as arguments by XBotInterface methods refers to the returned joint.
idx | The dof index of the required joint. Valid indices span from 0 to getJointNum()-1. |
|
protected |
XBot::Joint::ConstPtr XBot::XBotInterface::getJointByID | ( | int | joint_id | ) | const |
Gets the joint with ID "joint_id" if it is defined as enabled.
Otherwise, a null pointer is returned and an error is printed to screen. Joint IDs are defined inside a YAML file which is specified in the config file which is used to initialize the interface.
joint_id | The ID of the required joint. |
|
protected |
XBot::Joint::ConstPtr XBot::XBotInterface::getJointByName | ( | const std::string & | joint_name | ) | const |
Gets the joint with name "joint_name" if it is defined as enabled.
Otherwise, a null pointer is returned and an error is printed to screen.
joint_name | The name of the required joint. |
|
protected |
bool XBot::XBotInterface::getJointEffort | ( | Eigen::VectorXd & | tau | ) | const |
Gets the robot joint efforts as an Eigen vector.
The joint order inside the vector can be queried by calling the getEnabledJointNames/getEnabledJointId methods.
tau | A reference to an Eigen vector to be filled with the requested joint state. If the provided vector has wrong size it is resized automatically. |
bool XBot::XBotInterface::getJointEffort | ( | JointIdMap & | tau | ) | const |
Gets the robot joint efforts as a JointIdMap, i.e.
a map whose key represents the joint ID and whose value represents the required joint state.
tau | A reference to a JointIdMap to be filled with the requested joint state. It is the user responsibility to clear the map before it is filled (if required). |
bool XBot::XBotInterface::getJointEffort | ( | JointNameMap & | tau | ) | const |
Gets the robot joint efforts as a JointNameMap, i.e.
a map whose key represents the joint human-readable name and whose value represents the required joint state.
tau | A reference to a JointIdMap to be filled with the requested joint state. It is the user responsibility to clear the map before it is filled (if required). |
void XBot::XBotInterface::getJointLimits | ( | Eigen::VectorXd & | q_min, |
Eigen::VectorXd & | q_max | ||
) | const |
Gets a vector of the robot joint limits, as specified in the URDF file.
q_min | The output vector of the chain joints lower limits. |
q_max | The output vector of the chain joints upper limits. |
int XBot::XBotInterface::getJointNum | ( | ) | const |
Getter for the number of enabled joints.
bool XBot::XBotInterface::getJointPosition | ( | Eigen::VectorXd & | q | ) | const |
Gets the robot joint positions as an Eigen vector.
The joint order inside the vector can be queried by calling the getEnabledJointNames/getEnabledJointId methods.
q | A reference to an Eigen vector to be filled with the requested joint state. If the provided vector has wrong size it is resized automatically. |
bool XBot::XBotInterface::getJointPosition | ( | JointIdMap & | q | ) | const |
Gets the robot joint positions as a JointIdMap, i.e.
a map whose key represents the joint ID and whose value represents the required joint state.
q | A reference to a JointIdMap to be filled with the requested joint state. It is the user responsibility to clear the map before it is filled (if required). |
bool XBot::XBotInterface::getJointPosition | ( | JointNameMap & | q | ) | const |
Gets the robot joint postions as a JointNameMap, i.e.
a map whose key represents the joint human-readable name and whose value represents the required joint state.
q | A reference to a JointIdMap to be filled with the requested joint state. It is the user responsibility to clear the map before it is filled (if required). |
bool XBot::XBotInterface::getJointVelocity | ( | Eigen::VectorXd & | qdot | ) | const |
Gets the robot joint velocities as an Eigen vector.
The joint order inside the vector can be queried by calling the getEnabledJointNames/getEnabledJointId methods.
qdot | A reference to an Eigen vector to be filled with the requested joint state. If the provided vector has wrong size it is resized automatically. |
bool XBot::XBotInterface::getJointVelocity | ( | JointIdMap & | qdot | ) | const |
Gets the robot joint velocities as a JointIdMap, i.e.
a map whose key represents the joint ID and whose value represents the required joint state.
qdot | A reference to a JointIdMap to be filled with the requested joint state. It is the user responsibility to clear the map before it is filled (if required). |
bool XBot::XBotInterface::getJointVelocity | ( | JointNameMap & | qdot | ) | const |
Gets the robot joint velocities as a JointNameMap, i.e.
a map whose key represents the joint human-readable name and whose value represents the required joint state.
qdot | A reference to a JointIdMap to be filled with the requested joint state. It is the user responsibility to clear the map before it is filled (if required). |
|
protected |
bool XBot::XBotInterface::getMotorPosition | ( | Eigen::VectorXd & | q | ) | const |
Gets the robot motor positions as an Eigen vector.
The joint order inside the vector can be queried by calling the getEnabledJointNames/getEnabledJointId methods.
q | A reference to an Eigen vector to be filled with the requested joint state. If the provided vector has wrong size it is resized automatically. |
bool XBot::XBotInterface::getMotorPosition | ( | JointIdMap & | q | ) | const |
Gets the robot motor positions as a JointIdMap, i.e.
a map whose key represents the joint ID and whose value represents the required joint state.
q | A reference to a JointIdMap to be filled with the requested joint state. It is the user responsibility to clear the map before it is filled (if required). |
bool XBot::XBotInterface::getMotorPosition | ( | JointNameMap & | q | ) | const |
Gets the robot motor postions as a JointNameMap, i.e.
a map whose key represents the joint human-readable name and whose value represents the required joint state.
q | A reference to a JointIdMap to be filled with the requested joint state. It is the user responsibility to clear the map before it is filled (if required). |
bool XBot::XBotInterface::getMotorVelocity | ( | Eigen::VectorXd & | qdot | ) | const |
Gets the robot motor velocities as an Eigen vector.
The joint order inside the vector can be queried by calling the getEnabledJointNames/getEnabledJointId methods.
qdot | A reference to an Eigen vector to be filled with the requested joint state. If the provided vector has wrong size it is resized automatically. |
bool XBot::XBotInterface::getMotorVelocity | ( | JointIdMap & | qdot | ) | const |
Gets the robot motor velocities as a JointIdMap, i.e.
a map whose key represents the joint ID and whose value represents the required joint state.
qdot | A reference to a JointIdMap to be filled with the requested joint state. It is the user responsibility to clear the map before it is filled (if required). |
bool XBot::XBotInterface::getMotorVelocity | ( | JointNameMap & | qdot | ) | const |
Gets the robot motor velocities as a JointNameMap, i.e.
a map whose key represents the joint human-readable name and whose value represents the required joint state.
qdot | A reference to a JointIdMap to be filled with the requested joint state. It is the user responsibility to clear the map before it is filled (if required). |
const std::string & XBot::XBotInterface::getPathToConfig | ( | ) | const |
Gets the path to the YAML config file used to build the XBotInterface.
bool XBot::XBotInterface::getPositionReference | ( | Eigen::VectorXd & | q | ) | const |
Gets the robot position references as an Eigen vector.
The joint order inside the vector can be queried by calling the getEnabledJointNames/getEnabledJointId methods.
q | A reference to an Eigen vector to be filled with the requested joint state. If the provided vector has wrong size it is resized automatically. |
bool XBot::XBotInterface::getPositionReference | ( | JointIdMap & | q | ) | const |
Gets the robot position references as a JointIdMap, i.e.
a map whose key represents the joint ID and whose value represents the required joint state.
q | A reference to a JointIdMap to be filled with the requested joint state. It is the user responsibility to clear the map before it is filled (if required). |
bool XBot::XBotInterface::getPositionReference | ( | JointNameMap & | q | ) | const |
Gets the robot postion references as a JointNameMap, i.e.
a map whose key represents the joint human-readable name and whose value represents the required joint state.
q | A reference to a JointIdMap to be filled with the requested joint state. It is the user responsibility to clear the map before it is filled (if required). |
bool XBot::XBotInterface::getRobotState | ( | const std::string & | state_name, |
Eigen::VectorXd & | q | ||
) | const |
Gets the robot joints group state configuration as specified in the robot SRDF.
state_name | The name of the requested group state. |
q | The chain joint configuration as Eigen vector of joint positions, This is an output parameter; any contents present in the vector will be overwritten in this function. |
bool XBot::XBotInterface::getRobotState | ( | const std::string & | state_name, |
JointIdMap & | q | ||
) | const |
Gets the robot joints group state configuration as specified in the robot SRDF.
state_name | The name of the requested group state. |
q | The robot joint configuration as a map with key representing the joint ID (i.e. numerical name of the joint) and value representing joint positions. This is an output parameter; it will not be cleared before being filled. |
bool XBot::XBotInterface::getRobotState | ( | const std::string & | state_name, |
JointNameMap & | q | ||
) | const |
Gets the robot joints group state configuration as specified in the robot SRDF.
state_name | The name of the requested group state. |
q | The robot joint configuration as a map with key representing the joint name and value representing joint positions. This is an output parameter; it will not be cleared before being filled. |
const srdf_advr::Model & XBot::XBotInterface::getSrdf | ( | ) | const |
Getter fot the robot SRDF model corresponding to the SRDF xml file specified in the YAML config file.
const std::string & XBot::XBotInterface::getSrdfPath | ( | ) | const |
getSrdfPath Getter for the path to the SRDF model
const std::string & XBot::XBotInterface::getSrdfString | ( | ) | const |
Returns the robot SRDF xml as a string.
The SRDF file is specified inside the YAML config file.
bool XBot::XBotInterface::getStiffness | ( | Eigen::VectorXd & | K | ) | const |
Gets the robot stiffness as an Eigen vector.
The joint order inside the vector can be queried by calling the getEnabledJointNames/getEnabledJointId methods.
K | A reference to an Eigen vector to be filled with the requested joint state. If the provided vector has wrong size it is resized automatically. |
bool XBot::XBotInterface::getStiffness | ( | JointIdMap & | K | ) | const |
Gets the robot stiffness as a JointIdMap, i.e.
a map whose key represents the joint ID and whose value represents the required joint state.
K | A reference to a JointIdMap to be filled with the requested joint state. It is the user responsibility to clear the map before it is filled (if required). |
bool XBot::XBotInterface::getStiffness | ( | JointNameMap & | K | ) | const |
Gets the robot stiffness as a JointNameMap, i.e.
a map whose key represents the joint human-readable name and whose value represents the required joint state.
K | A reference to a JointIdMap to be filled with the requested joint state. It is the user responsibility to clear the map before it is filled (if required). |
bool XBot::XBotInterface::getTemperature | ( | Eigen::VectorXd & | temp | ) | const |
Gets the robot joint temperatures as an Eigen vector.
The joint order inside the vector can be queried by calling the getEnabledJointNames/getEnabledJointId methods.
temp | A reference to an Eigen vector to be filled with the requested joint state. If the provided vector has wrong size it is resized automatically. |
bool XBot::XBotInterface::getTemperature | ( | JointIdMap & | temp | ) | const |
Gets the robot joint temperatures as a JointIdMap, i.e.
a map whose key represents the joint ID and whose value represents the required joint state.
temp | A reference to a JointIdMap to be filled with the requested joint state. It is the user responsibility to clear the map before it is filled (if required). |
bool XBot::XBotInterface::getTemperature | ( | JointNameMap & | temp | ) | const |
Gets the robot joint temperatures as a JointNameMap, i.e.
a map whose key represents the joint human-readable name and whose value represents the required joint state.
temp | A reference to a JointIdMap to be filled with the requested joint state. It is the user responsibility to clear the map before it is filled (if required). |
const urdf::ModelInterface & XBot::XBotInterface::getUrdf | ( | ) | const |
Getter for the robot URDF model corresponding to the URDF xml file specified in the YAML config file.
const std::string & XBot::XBotInterface::getUrdfPath | ( | ) | const |
getUrdfPath Getter for the path to the URDF model
const std::string & XBot::XBotInterface::getUrdfString | ( | ) | const |
Returns the robot URDF xml as a string.
The URDF file is specified inside the YAML config file.
void XBot::XBotInterface::getVelocityLimits | ( | Eigen::VectorXd & | qdot_max | ) | const |
Gets a vector of the robot joint velocity limits, as specified in the URDF file.
qdot_max | The output vector of the chain joints velocity limits |
bool XBot::XBotInterface::getVelocityReference | ( | Eigen::VectorXd & | qdot | ) | const |
Gets the robot velocity references as an Eigen vector.
The joint order inside the vector can be queried by calling the getEnabledJointNames/getEnabledJointId methods.
qdot | A reference to an Eigen vector to be filled with the requested joint state. If the provided vector has wrong size it is resized automatically. |
bool XBot::XBotInterface::getVelocityReference | ( | JointIdMap & | qdot | ) | const |
Gets the robot velocity references as a JointIdMap, i.e.
a map whose key represents the joint ID and whose value represents the required joint state.
qdot | A reference to a JointIdMap to be filled with the requested joint state. It is the user responsibility to clear the map before it is filled (if required). |
bool XBot::XBotInterface::getVelocityReference | ( | JointNameMap & | qdot | ) | const |
Gets the robot velocity references as a JointNameMap, i.e.
a map whose key represents the joint human-readable name and whose value represents the required joint state.
qdot | A reference to a JointIdMap to be filled with the requested joint state. It is the user responsibility to clear the map before it is filled (if required). |
bool XBot::XBotInterface::hasChain | ( | const std::string & | chain_name | ) | const |
A method for determining if a chain with name "chain_name" is defined inside the interface.
chain_name | The name of the chain whose existence has to be checked. |
bool XBot::XBotInterface::hasJoint | ( | const std::string & | joint_name | ) | const |
Checks that a joint with name "joint_name" is defined as an enabled joint inside the interface.
joint_name | The name of the joint we want to check existence for. |
bool XBot::XBotInterface::hasJoint | ( | int | joint_id | ) | const |
Checks that a joint with ID "joint_id" is defined as an enabled joint inside the interface.
joint_id | The ID of the joint we want to check existence for. |
bool XBot::XBotInterface::init | ( | const ConfigOptions & | options | ) |
bool XBot::XBotInterface::init | ( | const std::string & | path_to_cfg | ) |
|
inlineprotectedvirtual |
Reimplemented in XBot::ModelInterface.
void XBot::XBotInterface::initLog | ( | MatLogger2::Ptr | logger, |
int | buffer_size = -1 , |
||
int | interleave = 1 , |
||
std::string | prefix = "" |
||
) |
Pre-allocates memory for logging the robot state to a mat file.
logger | Shared pointer to MatLogger where logging data has to be saved. |
buffer_size | The number of log elements after which old data are overwritten. |
interleave | Data are actually logged every interleave calls to log(). |
prefix | Prefix which will be preponed to all logged variables (empty by default). |
int XBot::XBotInterface::legs | ( | ) | const |
Returns the number of legs defined inside the interface.
This equals the number of elements of the "legs" group inside the SRDF which was provided in the YAML config file.
void XBot::XBotInterface::log | ( | MatLogger2::Ptr | logger, |
double | timestamp, | ||
const std::string & | prefix = "" |
||
) | const |
Logs the current robot state.
logger | Shared pointer to MatLogger where logging data has to be saved. |
timestamp | Time stamp for current robot state. |
prefix | Prefix which will be preponed to all logged variables (empty by default). |
bool XBot::XBotInterface::mapToEigen | ( | const JointIdMap & | map, |
Eigen::VectorXd & | vector | ||
) | const |
Converts a state vector for an arbitrary subset of the robot state (specified as a JointIdMap) to its Eigen representation.
Note that the output vector is resized and set to zero if its size does not match the number of joints. Otherwise, unspecified components are left untouched.
map | A JointIdMap contaning the state of the robot (or a part of it) |
vector | The output vector to be filled. |
bool XBot::XBotInterface::mapToEigen | ( | const JointNameMap & | map, |
Eigen::VectorXd & | vector | ||
) | const |
Converts a state vector for an arbitrary subset of the robot state (specified as a JointNameMap) to its Eigen representation.
Note that the output vector is resized and set to zero if its size does not match the number of joints. Otherwise, unspecified components are left untouched.
map | A JointNameMap contaning the state of the robot (or a part of it) |
vector | The output vector to be filled. |
XBot::XBotInterface & XBot::XBotInterface::operator= | ( | const XBotInterface & | rhs | ) |
|
inlineprotectedvirtual |
Reimplemented in XBot::RobotInterface.
void XBot::XBotInterface::print | ( | ) | const |
Print a pretty table about the robot state.
void XBot::XBotInterface::printTracking | ( | ) | const |
Print a pretty table about the robot tracking.
bool XBot::XBotInterface::setDamping | ( | const Eigen::VectorXd & | D | ) |
Sets the XBotInterface internal joint damping according to the provided vector, which must be ordered as specified by the getEnabledJointNames/getEnabledJointId methods.
D | The vector of input joint states. |
bool XBot::XBotInterface::setDamping | ( | const JointIdMap & | D | ) |
Sets the XBotInterface internal joint damping according to the input JointIdMap (i.e.
a map whose key represents the joint ID and whose value represents the joint state), which can include joint states for an arbitrary subset of the whole robot.
K | The input JointIdMap |
bool XBot::XBotInterface::setDamping | ( | const JointNameMap & | D | ) |
Sets the XBotInterface internal joint damping according to the input JointNameMap (i.e.
a map whose key represents the joint name and whose value represents the joint state), which can include joint states for an arbitrary subset of the whole robot.
D | The input JointIdMap |
bool XBot::XBotInterface::setEffortReference | ( | const Eigen::VectorXd & | tau | ) |
Sets the XBotInterface internal joint effort references according to the provided vector, which must be ordered as specified by the getEnabledJointNames/getEnabledJointId methods.
tau | The vector of input joint states. |
bool XBot::XBotInterface::setEffortReference | ( | const JointIdMap & | tau | ) |
Sets the XBotInterface internal joint effort references according to the input JointIdMap (i.e.
a map whose key represents the joint ID and whose value represents the joint state), which can include joint states for an arbitrary subset of the whole robot.
tau | The input JointIdMap |
bool XBot::XBotInterface::setEffortReference | ( | const JointNameMap & | tau | ) |
Sets the XBotInterface internal joint effort references according to the input JointNameMap (i.e.
a map whose key represents the joint name and whose value represents the joint state), which can include joint states for an arbitrary subset of the whole robot.
tau | The input JointIdMap |
bool XBot::XBotInterface::setJointAcceleration | ( | const Eigen::VectorXd & | qddot | ) |
Sets the XBotInterface internal joint accelerations according to the provided vector, which must be ordered as specified by the getEnabledJointNames/getEnabledJointId methods.
qddot | The vector of input joint states. |
bool XBot::XBotInterface::setJointAcceleration | ( | const JointIdMap & | qddot | ) |
Sets the XBotInterface internal joint accelerations according to the input JointIdMap (i.e.
a map whose key represents the joint ID and whose value represents the joint state), which can include joint states for an arbitrary subset of the whole robot.
qddot | The input JointIdMap |
bool XBot::XBotInterface::setJointAcceleration | ( | const JointNameMap & | qddot | ) |
Sets the XBotInterface internal joint accelerations according to the input JointNameMap (i.e.
a map whose key represents the joint name and whose value represents the joint state), which can include joint states for an arbitrary subset of the whole robot.
qddot | The input JointIdMap |
bool XBot::XBotInterface::setJointEffort | ( | const Eigen::VectorXd & | tau | ) |
Sets the XBotInterface internal joint efforts according to the provided vector, which must be ordered as specified by the getEnabledJointNames/getEnabledJointId methods.
tau | The vector of input joint states. |
bool XBot::XBotInterface::setJointEffort | ( | const JointIdMap & | tau | ) |
Sets the XBotInterface internal joint efforts according to the input JointIdMap (i.e.
a map whose key represents the joint ID and whose value represents the joint state), which can include joint states for an arbitrary subset of the whole robot.
tau | The input JointIdMap |
bool XBot::XBotInterface::setJointEffort | ( | const JointNameMap & | tau | ) |
Sets the XBotInterface internal joint efforts according to the input JointNameMap (i.e.
a map whose key represents the joint name and whose value represents the joint state), which can include joint states for an arbitrary subset of the whole robot.
tau | The input JointIdMap |
bool XBot::XBotInterface::setJointPosition | ( | const Eigen::VectorXd & | q | ) |
Sets the XBotInterface internal joint positions according to the provided vector, which must be ordered as specified by the getEnabledJointNames/getEnabledJointId methods.
q | The vector of input joint states. |
bool XBot::XBotInterface::setJointPosition | ( | const JointIdMap & | q | ) |
Sets the XBotInterface internal joint positions according to the input JointIdMap (i.e.
a map whose key represents the joint ID and whose value represents the joint state), which can include joint states for an arbitrary subset of the whole robot.
q | The input JointIdMap |
bool XBot::XBotInterface::setJointPosition | ( | const JointNameMap & | q | ) |
Sets the XBotInterface internal joint positions according to the input JointNameMap (i.e.
a map whose key represents the joint name and whose value represents the joint state), which can include joint states for an arbitrary subset of the whole robot.
q | The input JointIdMap |
bool XBot::XBotInterface::setJointVelocity | ( | const Eigen::VectorXd & | qdot | ) |
Sets the XBotInterface internal joint velocities according to the provided vector, which must be ordered as specified by the getEnabledJointNames/getEnabledJointId methods.
qdot | The vector of input joint states. |
bool XBot::XBotInterface::setJointVelocity | ( | const JointIdMap & | qdot | ) |
Sets the XBotInterface internal joint velocities according to the input JointIdMap (i.e.
a map whose key represents the joint ID and whose value represents the joint state), which can include joint states for an arbitrary subset of the whole robot.
qdot | The input JointIdMap |
bool XBot::XBotInterface::setJointVelocity | ( | const JointNameMap & | qdot | ) |
Sets the XBotInterface internal joint velocities according to the input JointNameMap (i.e.
a map whose key represents the joint name and whose value represents the joint state), which can include joint states for an arbitrary subset of the whole robot.
qdot | The input JointIdMap |
bool XBot::XBotInterface::setMotorPosition | ( | const Eigen::VectorXd & | q | ) |
Sets the XBotInterface internal motor positions according to the provided vector, which must be ordered as specified by the getEnabledJointNames/getEnabledJointId methods.
q | The vector of input joint states. |
bool XBot::XBotInterface::setMotorPosition | ( | const JointIdMap & | q | ) |
Sets the XBotInterface internal motor positions according to the input JointIdMap (i.e.
a map whose key represents the joint ID and whose value represents the joint state), which can include joint states for an arbitrary subset of the whole robot.
q | The input JointIdMap |
bool XBot::XBotInterface::setMotorPosition | ( | const JointNameMap & | q | ) |
Sets the XBotInterface internal motor positions according to the input JointNameMap (i.e.
a map whose key represents the joint name and whose value represents the joint state), which can include joint states for an arbitrary subset of the whole robot.
q | The input JointIdMap |
bool XBot::XBotInterface::setMotorVelocity | ( | const Eigen::VectorXd & | qdot | ) |
Sets the XBotInterface internal motor velocities according to the provided vector, which must be ordered as specified by the getEnabledJointNames/getEnabledJointId methods.
qdot | The vector of input joint states. |
bool XBot::XBotInterface::setMotorVelocity | ( | const JointIdMap & | qdot | ) |
Sets the XBotInterface internal motor velocities according to the input JointIdMap (i.e.
a map whose key represents the joint ID and whose value represents the joint state), which can include joint states for an arbitrary subset of the whole robot.
qdot | The input JointIdMap |
bool XBot::XBotInterface::setMotorVelocity | ( | const JointNameMap & | qdot | ) |
Sets the XBotInterface internal motor velocities according to the input JointNameMap (i.e.
a map whose key represents the joint name and whose value represents the joint state), which can include joint states for an arbitrary subset of the whole robot.
qdot | The input JointIdMap |
bool XBot::XBotInterface::setPositionReference | ( | const Eigen::VectorXd & | q | ) |
Sets the XBotInterface internal joint position references according to the provided vector, which must be ordered as specified by the getEnabledJointNames/getEnabledJointId methods.
q | The vector of input joint states. |
bool XBot::XBotInterface::setPositionReference | ( | const JointIdMap & | q | ) |
Sets the XBotInterface internal joint position references according to the input JointIdMap (i.e.
a map whose key represents the joint ID and whose value represents the joint state), which can include joint states for an arbitrary subset of the whole robot.
q | The input JointIdMap |
bool XBot::XBotInterface::setPositionReference | ( | const JointNameMap & | q | ) |
Sets the XBotInterface internal joint position references according to the input JointNameMap (i.e.
a map whose key represents the joint name and whose value represents the joint state), which can include joint states for an arbitrary subset of the whole robot.
q | The input JointIdMap |
bool XBot::XBotInterface::setStiffness | ( | const Eigen::VectorXd & | K | ) |
Sets the XBotInterface internal joint stiffness according to the provided vector, which must be ordered as specified by the getEnabledJointNames/getEnabledJointId methods.
K | The vector of input joint states. |
bool XBot::XBotInterface::setStiffness | ( | const JointIdMap & | K | ) |
Sets the XBotInterface internal joint stiffness according to the input JointIdMap (i.e.
a map whose key represents the joint ID and whose value represents the joint state), which can include joint states for an arbitrary subset of the whole robot.
K | The input JointIdMap |
bool XBot::XBotInterface::setStiffness | ( | const JointNameMap & | K | ) |
Sets the XBotInterface internal joint stiffness according to the input JointNameMap (i.e.
a map whose key represents the joint name and whose value represents the joint state), which can include joint states for an arbitrary subset of the whole robot.
K | The input JointIdMap |
bool XBot::XBotInterface::setTemperature | ( | const Eigen::VectorXd & | temp | ) |
Sets the XBotInterface internal joint temperatures according to the provided vector, which must be ordered as specified by the getEnabledJointNames/getEnabledJointId methods.
temp | The vector of input joint states. |
bool XBot::XBotInterface::setTemperature | ( | const JointIdMap & | temp | ) |
Sets the XBotInterface internal motor temperatures according to the input JointIdMap (i.e.
a map whose key represents the joint ID and whose value represents the joint state), which can include joint states for an arbitrary subset of the whole robot.
temp | The input JointIdMap |
bool XBot::XBotInterface::setTemperature | ( | const JointNameMap & | temp | ) |
Sets the XBotInterface internal joint temperatures according to the input JointNameMap (i.e.
a map whose key represents the joint name and whose value represents the joint state), which can include joint states for an arbitrary subset of the whole robot.
temp | The input JointIdMap |
bool XBot::XBotInterface::setVelocityReference | ( | const Eigen::VectorXd & | qdot | ) |
Sets the XBotInterface internal joint velocity references according to the provided vector, which must be ordered as specified by the getEnabledJointNames/getEnabledJointId methods.
qdot | The vector of input joint states. |
bool XBot::XBotInterface::setVelocityReference | ( | const JointIdMap & | qdot | ) |
Sets the XBotInterface internal joint velocity references according to the input JointIdMap (i.e.
a map whose key represents the joint ID and whose value represents the joint state), which can include joint states for an arbitrary subset of the whole robot.
qdot | The input JointIdMap |
bool XBot::XBotInterface::setVelocityReference | ( | const JointNameMap & | qdot | ) |
Sets the XBotInterface internal joint velocity references according to the input JointNameMap (i.e.
a map whose key represents the joint name and whose value represents the joint state), which can include joint states for an arbitrary subset of the whole robot.
qdot | The input JointIdMap |
bool XBot::XBotInterface::sync | ( | const XBotInterface & | other, |
SyncFlags... | flags | ||
) |
Synchronize the current XBotInterface with another XBotInterface object: only the common chains will be taken into account.
flags | ... |
other | The XBotInterface object from which we synchronize the current object |
|
friend |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |