Simox
2.3.74.0
|
Data Structures | |
struct | ContactInfo |
Public Types | |
typedef std::vector< ContactInfo, Eigen::aligned_allocator< ContactInfo > > | ContactInfoVector |
We need an Eigen::aligned_allocator here, otherwise access to a std::vector could crash. More... | |
Public Member Functions | |
EndEffector (const std::string &nameString, const std::vector< EndEffectorActorPtr > &actorsVector, const std::vector< RobotNodePtr > &staticPartVector, RobotNodePtr baseNodePtr, RobotNodePtr tcpNodePtr, RobotNodePtr gcpNodePtr=RobotNodePtr(), std::vector< RobotConfigPtr > preshapes=std::vector< RobotConfigPtr >()) | |
virtual | ~EndEffector () |
EndEffectorPtr | clone (RobotPtr newRobot) |
std::string | getName () |
std::string | getBaseNodeName () |
std::string | getTcpName () |
RobotNodePtr | getTcp () |
RobotNodePtr | getBase () |
RobotNodePtr | getGCP () |
RobotPtr | getRobot () |
CollisionCheckerPtr | getCollisionChecker () |
std::string | getRobotType () |
void | getActors (std::vector< EndEffectorActorPtr > &actors) |
const std::vector< EndEffectorActorPtr > & | getActors () |
void | getStatics (std::vector< RobotNodePtr > &statics) |
const std::vector< RobotNodePtr > & | getStatics () |
ContactInfoVector | closeActors (SceneObjectSetPtr obstacles=SceneObjectSetPtr(), float stepSize=0.02, float stepSizeSpeedFactor=1, std::uint64_t steps=0) |
ContactInfoVector | closeActors (SceneObjectPtr obstacle, float stepSize=0.02, float stepSizeSpeedFactor=1, std::uint64_t steps=0) |
ContactInfoVector | closeActors (std::nullptr_t, float stepSize=0.02, float stepSizeSpeedFactor=1, std::uint64_t steps=0) |
ContactInfoVector | closeActors (float stepSize, float stepSizeSpeedFactor=1, std::uint64_t steps=0) |
bool | allActorsClosed () const |
bool | allActorsOpen () const |
void | openActors (SceneObjectSetPtr obstacles=SceneObjectSetPtr(), float stepSize=0.02, float stepSizeSpeedFactor=1) |
void | openActors (float stepSize, float stepSizeSpeedFactor) |
SceneObjectSetPtr | createSceneObjectSet (CollisionCheckerPtr colChecker=CollisionCheckerPtr()) |
RobotPtr | createEefRobot (const std::string &newRobotType, const std::string &newRobotName, CollisionCheckerPtr collisionChecker=CollisionCheckerPtr()) |
void | registerPreshape (RobotConfigPtr preshape) |
RobotConfigPtr | getPreshape (const std::string &name) |
bool | hasPreshape (const std::string &name) |
bool | setPreshape (const std::string &name) |
std::vector< std::string > | getPreshapes () |
bool | hasNode (RobotNodePtr node) |
void | print () |
RobotConfigPtr | getConfiguration () |
std::vector< RobotNodePtr > | getAllNodes () |
Return all associated robot nodes. More... | |
bool | nodesSufficient (std::vector< RobotNodePtr > nodes) const |
Returns true, if nodes (only name strings are checked) are sufficient for building this eef. More... | |
float | getApproximatedLength () |
virtual std::string | toXML (int ident=1) |
int | addStaticPartContacts (SceneObjectPtr obstacle, ContactInfoVector &contacts, const Eigen::Vector3f &approachDirGlobal, float maxDistance=3.0f) |
typedef std::vector< ContactInfo, Eigen::aligned_allocator<ContactInfo> > VirtualRobot::EndEffector::ContactInfoVector |
We need an Eigen::aligned_allocator here, otherwise access to a std::vector could crash.
VirtualRobot::EndEffector::EndEffector | ( | const std::string & | nameString, |
const std::vector< EndEffectorActorPtr > & | actorsVector, | ||
const std::vector< RobotNodePtr > & | staticPartVector, | ||
RobotNodePtr | baseNodePtr, | ||
RobotNodePtr | tcpNodePtr, | ||
RobotNodePtr | gcpNodePtr = RobotNodePtr() , |
||
std::vector< RobotConfigPtr > | preshapes = std::vector< RobotConfigPtr >() |
||
) |
|
virtualdefault |
int VirtualRobot::EndEffector::addStaticPartContacts | ( | SceneObjectPtr | obstacle, |
EndEffector::ContactInfoVector & | contacts, | ||
const Eigen::Vector3f & | approachDirGlobal, | ||
float | maxDistance = 3.0f |
||
) |
bool VirtualRobot::EndEffector::allActorsClosed | ( | ) | const |
bool VirtualRobot::EndEffector::allActorsOpen | ( | ) | const |
EndEffectorPtr VirtualRobot::EndEffector::clone | ( | RobotPtr | newRobot | ) |
Clones this eef and performs all necessary registrations. (Be careful: no need to call registerEEF with newly created eef, since this is already done)
EndEffector::ContactInfoVector VirtualRobot::EndEffector::closeActors | ( | SceneObjectSetPtr | obstacles = SceneObjectSetPtr() , |
float | stepSize = 0.02 , |
||
float | stepSizeSpeedFactor = 1 , |
||
std::uint64_t | steps = 0 |
||
) |
Closes each actor until a joint limit is hit or a collision occurred. This method is intended for gripper or hand-like end-effectors.
ContactInfoVector VirtualRobot::EndEffector::closeActors | ( | SceneObjectPtr | obstacle, |
float | stepSize = 0.02 , |
||
float | stepSizeSpeedFactor = 1 , |
||
std::uint64_t | steps = 0 |
||
) |
EndEffector::ContactInfoVector VirtualRobot::EndEffector::closeActors | ( | std::nullptr_t | , |
float | stepSize = 0.02 , |
||
float | stepSizeSpeedFactor = 1 , |
||
std::uint64_t | steps = 0 |
||
) |
EndEffector::ContactInfoVector VirtualRobot::EndEffector::closeActors | ( | float | stepSize, |
float | stepSizeSpeedFactor = 1 , |
||
std::uint64_t | steps = 0 |
||
) |
VirtualRobot::RobotPtr VirtualRobot::EndEffector::createEefRobot | ( | const std::string & | newRobotType, |
const std::string & | newRobotName, | ||
CollisionCheckerPtr | collisionChecker = CollisionCheckerPtr() |
||
) |
Construct a robot that consists only of this eef. All corresponding robot nodes with visualization and collision models are cloned. The resulting robot will have one end effector defined which is identical to this object.
VirtualRobot::SceneObjectSetPtr VirtualRobot::EndEffector::createSceneObjectSet | ( | CollisionCheckerPtr | colChecker = CollisionCheckerPtr() | ) |
Build a SceneObjectSet that covers all RobotNodes of this EndEffector.
void VirtualRobot::EndEffector::getActors | ( | std::vector< EndEffectorActorPtr > & | actors | ) |
const std::vector< EndEffectorActorPtr > & VirtualRobot::EndEffector::getActors | ( | ) |
std::vector< RobotNodePtr > VirtualRobot::EndEffector::getAllNodes | ( | ) |
Return all associated robot nodes.
float VirtualRobot::EndEffector::getApproximatedLength | ( | ) |
returns an approximation about the length of this eef.
VirtualRobot::RobotNodePtr VirtualRobot::EndEffector::getBase | ( | ) |
std::string VirtualRobot::EndEffector::getBaseNodeName | ( | ) |
Return name of Base RobotNode.
VirtualRobot::CollisionCheckerPtr VirtualRobot::EndEffector::getCollisionChecker | ( | ) |
VirtualRobot::RobotConfigPtr VirtualRobot::EndEffector::getConfiguration | ( | ) |
Return current configuration as robot config.
VirtualRobot::RobotNodePtr VirtualRobot::EndEffector::getGCP | ( | ) |
Returns the grasp center point. If it was not defined, the TCP is returned.
std::string VirtualRobot::EndEffector::getName | ( | ) |
VirtualRobot::RobotConfigPtr VirtualRobot::EndEffector::getPreshape | ( | const std::string & | name | ) |
std::vector< std::string > VirtualRobot::EndEffector::getPreshapes | ( | ) |
Returns vector of all registered preshape names.
VirtualRobot::RobotPtr VirtualRobot::EndEffector::getRobot | ( | ) |
Return associated robot
std::string VirtualRobot::EndEffector::getRobotType | ( | ) |
Return the type of the associated robot
void VirtualRobot::EndEffector::getStatics | ( | std::vector< RobotNodePtr > & | statics | ) |
const std::vector< RobotNodePtr > & VirtualRobot::EndEffector::getStatics | ( | ) |
VirtualRobot::RobotNodePtr VirtualRobot::EndEffector::getTcp | ( | ) |
std::string VirtualRobot::EndEffector::getTcpName | ( | ) |
Return name of TCP RobotNode.
bool VirtualRobot::EndEffector::hasNode | ( | RobotNodePtr | node | ) |
Check, if node is part of this eef.
bool VirtualRobot::EndEffector::hasPreshape | ( | const std::string & | name | ) |
bool VirtualRobot::EndEffector::nodesSufficient | ( | std::vector< RobotNodePtr > | nodes | ) | const |
Returns true, if nodes (only name strings are checked) are sufficient for building this eef.
void VirtualRobot::EndEffector::openActors | ( | SceneObjectSetPtr | obstacles = SceneObjectSetPtr() , |
float | stepSize = 0.02 , |
||
float | stepSizeSpeedFactor = 1 |
||
) |
Opens each actor until a joint limit is hit or a collision occurred. This method is intended for hand-like end-effectors. Note that the same effect can be realized by calling closeActors with a negative step size
|
inline |
void VirtualRobot::EndEffector::print | ( | ) |
void VirtualRobot::EndEffector::registerPreshape | ( | RobotConfigPtr | preshape | ) |
Register a preshape to this EEF. An exception is thrown if preshape covers joints that are not part of this eef. If there is already a preshape with name preshape->getName(), it is replaced.
bool VirtualRobot::EndEffector::setPreshape | ( | const std::string & | name | ) |
Set joints of this eef to preshape with given name.
name | The name of the registered preshape. |
|
virtual |
Creates an XML string of this EEF.