KinematicsWorld Class Reference

The KinematicsWorld class encapsulates the kinemtics simulation and the corresponding data. All real physics simulation is either approximated through simple kinemtics or disabled. More...

#include <ArmarXSimulation/components/Simulator/KinematicsWorld.h>

+ Inheritance diagram for KinematicsWorld:

Classes

struct  KinematicRobotInfo
 

Public Member Functions

void actuateRobotJoints (const std::string &robotName, const std::map< std::string, float > &angles, const std::map< std::string, float > &velocities) override
 ignoring velocity target More...
 
void actuateRobotJointsPos (const std::string &robotName, const std::map< std::string, float > &angles) override
 
void actuateRobotJointsTorque (const std::string &robotName, const std::map< std::string, float > &torques) override
 
void actuateRobotJointsVel (const std::string &robotName, const std::map< std::string, float > &velocities) override
 
void applyForceObject (const std::string &objectName, const Eigen::Vector3f &force) override
 
void applyForceRobotNode (const std::string &robotName, const std::string &robotNodeName, const Eigen::Vector3f &force) override
 
void applyTorqueObject (const std::string &objectName, const Eigen::Vector3f &torque) override
 
void applyTorqueRobotNode (const std::string &robotName, const std::string &robotNodeName, const Eigen::Vector3f &torque) override
 
std::vector< SimDynamics::DynamicsEngine::DynamicsContactInfo > copyContacts () override
 
void enableLogging (const std::string &robotName, const std::string &logFile) override
 
armarx::DistanceInfo getDistance (const std::string &robotName, const std::string &robotNodeName, const std::string &worldObjectName) override
 
int getFixedTimeStepMS () override
 
virtual VirtualRobot::SceneObjectPtr getObject (const std::string &objectName)
 
Eigen::Matrix4f getObjectPose (const std::string &objectName) override
 
std::vector< VirtualRobot::SceneObjectPtr > getObjects () override
 
std::vector< std::string > getObstacleNames () override
 
VirtualRobot::RobotPtr getRobot (const std::string &robotName) override
 
Eigen::Vector3f getRobotAngularVelocity (const std::string &robotName, const std::string &nodeName) override
 
ForceTorqueDataSeq getRobotForceTorqueSensors (const std::string &) override
 
float getRobotJointAngle (const std::string &robotName, const std::string &nodeName) override
 
std::map< std::string, floatgetRobotJointAngles (const std::string &robotName) override
 
float getRobotJointLimitHi (const std::string &robotName, const std::string &nodeName) override
 
float getRobotJointLimitLo (const std::string &robotName, const std::string &nodeName) override
 
std::map< std::string, floatgetRobotJointTorques (const std::string &) override
 
std::map< std::string, floatgetRobotJointVelocities (const std::string &robotName) override
 
float getRobotJointVelocity (const std::string &robotName, const std::string &nodeName) override
 
Eigen::Vector3f getRobotLinearVelocity (const std::string &robotName, const std::string &nodeName) override
 
float getRobotMass (const std::string &robotName) override
 
float getRobotMaxTorque (const std::string &robotName, const std::string &nodeName) override
 
std::vector< std::string > getRobotNames () override
 
armarx::DistanceInfo getRobotNodeDistance (const std::string &robotName, const std::string &robotNodeName1, const std::string &robotNodeName2) override
 
Eigen::Matrix4f getRobotNodePose (const std::string &robotName, const std::string &robotNodeName) override
 
Eigen::Matrix4f getRobotPose (const std::string &robotName) override
 
std::map< std::string, VirtualRobot::RobotPtrgetRobots () override
 
bool hasObject (const std::string &instanceName) override
 
bool hasRobot (const std::string &robotName) override
 
bool hasRobotNode (const std::string &robotName, const std::string &robotNodeName) override
 
virtual void initialize (int stepSizeMS, float maxRealTimeSimSpeed=1, bool floorPlane=false, std::string floorTexture=std::string())
 
 KinematicsWorld ()
 
void setObjectPose (const std::string &objectName, const Eigen::Matrix4f &globalPose) override
 
void setObjectSimType (const std::string &objectName, VirtualRobot::SceneObject::Physics::SimulationType simType) override
 
void setRobotAngularVelocity (const std::string &robotName, const std::string &robotNodeName, const Eigen::Vector3f &vel) override
 
void setRobotAngularVelocityRobotRootFrame (const std::string &robotName, const std::string &robotNodeName, const Eigen::Vector3f &vel) override
 
void setRobotLinearVelocity (const std::string &robotName, const std::string &robotNodeName, const Eigen::Vector3f &vel) override
 
void setRobotLinearVelocityRobotRootFrame (const std::string &robotName, const std::string &robotNodeName, const Eigen::Vector3f &vel) override
 
void setRobotMaxTorque (const std::string &robotName, const std::string &nodeName, float maxTorque) override
 
void setRobotNodeSimType (const std::string &robotName, const std::string &robotNodeName, VirtualRobot::SceneObject::Physics::SimulationType simType) override
 
void setRobotPose (const std::string &robotName, const Eigen::Matrix4f &globalPose) override
 
void stepPhysicsFixedTimeStep () override
 Perform one simulation step. More...
 
void stepPhysicsRealTime () override
 Perform one simulation step. More...
 
FramedPosePtr toFramedPose (const Eigen::Matrix4f &globalPose, const std::string &robotName, const std::string &frameName) override
 toFramedPose Constructs a framed pose More...
 
 ~KinematicsWorld () override
 
- Public Member Functions inherited from SimulatedWorld
virtual void activateObject (const std::string &objectName)
 
virtual VirtualRobot::RobotPtr adaptRobotToWorld (VirtualRobot::RobotPtr)
 
virtual bool addObstacle (const std::string &filename, const Eigen::Matrix4f &pose=Eigen::Matrix4f::Identity(), VirtualRobot::SceneObject::Physics::SimulationType simType=VirtualRobot::SceneObject::Physics::eUnknown, const std::string &localFilename="")
 Load and add an Obstacle (VirtualRobot xml file). More...
 
virtual bool addObstacle (VirtualRobot::SceneObjectPtr o, VirtualRobot::SceneObject::Physics::SimulationType simType=VirtualRobot::SceneObject::Physics::eUnknown, const std::string &filename="", const std::string &objectClassName="", ObjectVisuPrimitivePtr primitiveData={}, const std::string &project="")
 
virtual bool addRobot (std::string &robotInstanceName, const std::string &filename, Eigen::Matrix4f pose=Eigen::Matrix4f::Identity(), const std::string &filenameLocal="", double pid_p=10.0, double pid_i=0, double pid_d=0, bool staticRobot=false, float scaling=1.0f, bool colModel=false, const std::map< std::string, float > &initConfig={}, bool selfCollisions=false)
 Load and add a robot. More...
 
virtual bool addRobot (VirtualRobot::RobotPtr robot, double pid_p, double pid_i, double pid_d, const std::string &filename, bool staticRobot=false, float scaling=1.0f, bool colModel=false, bool selfCollisions=false)
 
virtual bool addScene (const std::string &filename, VirtualRobot::SceneObject::Physics::SimulationType simType=VirtualRobot::SceneObject::Physics::eUnknown)
 Load and add an Scene (VirtualRobot xml file). More...
 
virtual bool addScene (VirtualRobot::ScenePtr scene, VirtualRobot::SceneObject::Physics::SimulationType simType=VirtualRobot::SceneObject::Physics::eUnknown)
 
virtual SimulatedWorldData copyReportData ()
 
virtual SceneVisuData copySceneVisuData ()
 copySceneVisuData Creates a copy of the visualization data More...
 
virtual int getContactCount ()
 
virtual double getCurrentSimTime ()
 
virtual int getObjectCount ()
 
virtual SimulatedWorldDatagetReportData ()
 
virtual int getRobotJointAngleCount ()
 
virtual ScopedRecursiveLockPtr getScopedEngineLock (const std::string &callStr)
 
virtual ScopedRecursiveLockPtr getScopedSyncLock (const std::string &callStr)
 
virtual float getSimTime ()
 
virtual float getSimulationStepDuration ()
 getSimulationStepDuration More...
 
virtual float getSimulationStepTimeMeasured ()
 getSimulationStepTimeMeasured More...
 
virtual float getSyncEngineTime ()
 
virtual void objectGrasped (const std::string &robotName, const std::string &robotNodeName, const std::string &objectName)
 create a joint More...
 
virtual void objectReleased (const std::string &robotName, const std::string &robotNodeName, const std::string &objectName)
 remove a joint More...
 
virtual bool removeObstacle (const std::string &name)
 
virtual bool removeObstacles ()
 
virtual bool removeRobot (const std::string &robotName)
 
virtual bool removeRobots ()
 
virtual bool resetData ()
 resetData Clears all data More...
 
virtual void resetSimTime ()
 
virtual void setupFloor (bool enable, const std::string &floorTexture)
 
 SimulatedWorld ()
 
virtual bool synchronizeSimulationData ()
 synchronizeSimulationData Update the sim data according to the internal physics models. More...
 
virtual void updateContacts (bool enable)
 
virtual ~SimulatedWorld () override=default
 
- Public Member Functions inherited from Logging
SpamFilterDataPtr deactivateSpam (float deactivationDurationSec=10.0f, const std::string &identifier="", bool deactivate=true) const
 disables the logging for the current line for the given amount of seconds. More...
 
MessageTypeT getEffectiveLoggingLevel () const
 
 Logging ()
 
void setLocalMinimumLoggingLevel (MessageTypeT level)
 With setLocalMinimumLoggingLevel the minimum verbosity-level of log-messages can be set. More...
 
void setTag (const LogTag &tag)
 
void setTag (const std::string &tagName)
 
virtual ~Logging ()
 

Protected Member Functions

bool addObstacleEngine (VirtualRobot::SceneObjectPtr o, VirtualRobot::SceneObject::Physics::SimulationType simType) override
 
bool addRobotEngine (VirtualRobot::RobotPtr robot, double pid_p, double pid_i, double pid_d, const std::string &filename, bool staticRobot, bool selfCollisions) override
 
void calculateActualVelocities ()
 
virtual void createFloorPlane (const Eigen::Vector3f &pos, const Eigen::Vector3f &up)
 
float getDeltaTimeMilli ()
 
VirtualRobot::SceneObjectPtr getFloor () override
 
bool getRobotStatus (const std::string &robotName, NameValueMap &jointAngles, NameValueMap &jointVelocities, NameValueMap &jointTorques, Eigen::Vector3f &linearVelocity, Eigen::Vector3f &angularVelocity) override
 
bool objectGraspedEngine (const std::string &robotName, const std::string &robotNodeName, const std::string &objectName, Eigen::Matrix4f &storeLocalTransform) override
 create a joint More...
 
bool objectReleasedEngine (const std::string &robotName, const std::string &robotNodeName, const std::string &objectName) override
 remove a joint More...
 
bool removeObstacleEngine (const std::string &name) override
 
bool removeRobotEngine (const std::string &robotName) override
 
void setupFloorEngine (bool enable, const std::string &floorTexture) override
 
void stepStaticObjects (double deltaInSeconds)
 
void stepStaticRobots (double deltaInSeconds)
 
bool synchronizeObjects () override
 
bool synchronizeRobotNodePoses (const std::string &robotName, std::map< std::string, armarx::PoseBasePtr > &objMap) override
 
bool synchronizeSceneObjectPoses (VirtualRobot::SceneObjectPtr currentObjEngine, std::map< std::string, armarx::PoseBasePtr > &objMap) override
 
bool synchronizeSimulationDataEngine () override
 
bool updateForceTorqueSensor (ForceTorqueInfo &ftInfo) override
 
- Protected Member Functions inherited from SimulatedWorld
virtual bool synchronizeRobots ()
 
- Protected Member Functions inherited from Logging
bool checkLogLevel (MessageTypeT level) const
 
const LogSenderPtrgetLogSender () const
 Retrieve log sender. More...
 
LogSenderPtr loghelper (const char *file, int line, const char *function) const
 

Protected Attributes

std::map< VirtualRobot::RobotPtr, std::pair< IceUtil::Time, Eigen::Matrix4f > > angularVelocityFilters
 
VirtualRobot::SceneObjectPtr floor
 
double floorDepthMM
 
double floorExtendMM
 
Eigen::Vector3f floorPos
 
Eigen::Vector3f floorUp
 
VirtualRobot::ObstaclePtr groundObject
 
std::map< VirtualRobot::RobotNodePtr, std::pair< IceUtil::Time, float > > jointAngleDerivationFilters
 
std::vector< VirtualRobot::SceneObjectPtr > kinematicObjects
 
std::map< std::string, KinematicRobotInfokinematicRobots
 
IceUtil::Time lastTime
 
std::map< VirtualRobot::RobotPtr, std::pair< IceUtil::Time, Eigen::Vector3f > > linearVelocityFilters
 
int stepSizeMs
 
- Protected Attributes inherited from SimulatedWorld
std::vector< GraspingInfoattachedObjects
 
bool collectContacts
 
double currentSimTimeSec = 0.0
 
double currentSyncTimeSec = 0.0
 
std::map< std::string, int > engineMtxAccCalls
 
std::map< std::string, floatengineMtxAccTime
 
std::map< std::string, IceUtil::Time > engineMtxLastTime
 
MutexPtrType engineMutex
 
float maxRealTimeSimSpeed = 1
 
SimulatedWorldData simReportData
 
float simStepExecutionDurationMS
 
float simTimeStepMS
 
SceneVisuData simVisuData
 
float synchronizeDurationMS
 
MutexPtrType synchronizeMutex
 
std::map< std::string, int > syncMtxAccCalls
 
std::map< std::string, floatsyncMtxAccTime
 
std::map< std::string, IceUtil::Time > syncMtxLastTime
 
- Protected Attributes inherited from Logging
MessageTypeT minimumLoggingLevel
 
SpamFilterDataPtr spamFilter
 
LogTag tag
 

Additional Inherited Members

- Public Types inherited from SimulatedWorld
using MutexPtrType = typename argType< setMutexFunc >::type
 
using MutexType = MutexPtrType::element_type
 
using ScopedRecursiveLock = std::scoped_lock< MutexType >
 
using ScopedRecursiveLockPtr = std::shared_ptr< ScopedRecursiveLock >
 
using setMutexFunc = decltype(&SimDynamics::DynamicsEngine::setMutex)
 

Detailed Description

The KinematicsWorld class encapsulates the kinemtics simulation and the corresponding data. All real physics simulation is either approximated through simple kinemtics or disabled.

Definition at line 49 of file KinematicsWorld.h.

Constructor & Destructor Documentation

◆ KinematicsWorld()

Definition at line 45 of file KinematicsWorld.cpp.

◆ ~KinematicsWorld()

~KinematicsWorld ( )
overridedefault

Member Function Documentation

◆ actuateRobotJoints()

void actuateRobotJoints ( const std::string &  robotName,
const std::map< std::string, float > &  angles,
const std::map< std::string, float > &  velocities 
)
overridevirtual

ignoring velocity target

Implements SimulatedWorld.

Definition at line 115 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ actuateRobotJointsPos()

void actuateRobotJointsPos ( const std::string &  robotName,
const std::map< std::string, float > &  angles 
)
overridevirtual

Implements SimulatedWorld.

Definition at line 136 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ actuateRobotJointsTorque()

void actuateRobotJointsTorque ( const std::string &  robotName,
const std::map< std::string, float > &  torques 
)
overridevirtual

Implements SimulatedWorld.

Definition at line 181 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ actuateRobotJointsVel()

void actuateRobotJointsVel ( const std::string &  robotName,
const std::map< std::string, float > &  velocities 
)
overridevirtual

Implements SimulatedWorld.

Definition at line 161 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ addObstacleEngine()

bool addObstacleEngine ( VirtualRobot::SceneObjectPtr  o,
VirtualRobot::SceneObject::Physics::SimulationType  simType 
)
overrideprotectedvirtual

Implements SimulatedWorld.

Definition at line 1135 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ addRobotEngine()

bool addRobotEngine ( VirtualRobot::RobotPtr  robot,
double  pid_p,
double  pid_i,
double  pid_d,
const std::string &  filename,
bool  staticRobot,
bool  selfCollisions 
)
overrideprotectedvirtual

Implements SimulatedWorld.

Definition at line 824 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ applyForceObject()

void applyForceObject ( const std::string &  objectName,
const Eigen::Vector3f &  force 
)
overridevirtual

Implements SimulatedWorld.

Definition at line 216 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ applyForceRobotNode()

void applyForceRobotNode ( const std::string &  robotName,
const std::string &  robotNodeName,
const Eigen::Vector3f &  force 
)
overridevirtual

Implements SimulatedWorld.

Definition at line 204 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ applyTorqueObject()

void applyTorqueObject ( const std::string &  objectName,
const Eigen::Vector3f &  torque 
)
overridevirtual

Implements SimulatedWorld.

Definition at line 222 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ applyTorqueRobotNode()

void applyTorqueRobotNode ( const std::string &  robotName,
const std::string &  robotNodeName,
const Eigen::Vector3f &  torque 
)
overridevirtual

Implements SimulatedWorld.

Definition at line 210 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ calculateActualVelocities()

void calculateActualVelocities ( )
protected

Definition at line 911 of file KinematicsWorld.cpp.

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

◆ copyContacts()

std::vector< SimDynamics::DynamicsEngine::DynamicsContactInfo > copyContacts ( )
overridevirtual

Implements SimulatedWorld.

Definition at line 1381 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ createFloorPlane()

void createFloorPlane ( const Eigen::Vector3f &  pos,
const Eigen::Vector3f &  up 
)
protectedvirtual

Definition at line 77 of file KinematicsWorld.cpp.

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

◆ enableLogging()

void enableLogging ( const std::string &  robotName,
const std::string &  logFile 
)
overridevirtual

Reimplemented from SimulatedWorld.

Definition at line 1409 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ getDeltaTimeMilli()

float getDeltaTimeMilli ( )
protected

Definition at line 1459 of file KinematicsWorld.cpp.

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

◆ getDistance()

DistanceInfo getDistance ( const std::string &  robotName,
const std::string &  robotNodeName,
const std::string &  worldObjectName 
)
overridevirtual

Implements SimulatedWorld.

Definition at line 1509 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ getFixedTimeStepMS()

int getFixedTimeStepMS ( )
overridevirtual
Returns
The number of steps * the timestep in MS

Implements SimulatedWorld.

Definition at line 1376 of file KinematicsWorld.cpp.

◆ getFloor()

SceneObjectPtr getFloor ( )
overrideprotectedvirtual

Implements SimulatedWorld.

Definition at line 797 of file KinematicsWorld.cpp.

◆ getObject()

VirtualRobot::SceneObjectPtr getObject ( const std::string &  objectName)
virtual

Definition at line 687 of file KinematicsWorld.cpp.

+ Here is the caller graph for this function:

◆ getObjectPose()

Eigen::Matrix4f getObjectPose ( const std::string &  objectName)
overridevirtual

Implements SimulatedWorld.

Definition at line 704 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ getObjects()

std::vector< SceneObjectPtr > getObjects ( )
overridevirtual

Implements SimulatedWorld.

Definition at line 1387 of file KinematicsWorld.cpp.

◆ getObstacleNames()

std::vector< std::string > getObstacleNames ( )
overridevirtual

Implements SimulatedWorld.

Definition at line 1195 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ getRobot()

VirtualRobot::RobotPtr getRobot ( const std::string &  robotName)
overridevirtual

Implements SimulatedWorld.

Definition at line 662 of file KinematicsWorld.cpp.

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

◆ getRobotAngularVelocity()

Eigen::Vector3f getRobotAngularVelocity ( const std::string &  robotName,
const std::string &  nodeName 
)
overridevirtual

Implements SimulatedWorld.

Definition at line 505 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ getRobotForceTorqueSensors()

ForceTorqueDataSeq getRobotForceTorqueSensors ( const std::string &  )
overridevirtual

Implements SimulatedWorld.

Definition at line 364 of file KinematicsWorld.cpp.

◆ getRobotJointAngle()

float getRobotJointAngle ( const std::string &  robotName,
const std::string &  nodeName 
)
overridevirtual

Implements SimulatedWorld.

Definition at line 290 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ getRobotJointAngles()

std::map< std::string, float > getRobotJointAngles ( const std::string &  robotName)
overridevirtual

Implements SimulatedWorld.

Definition at line 263 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ getRobotJointLimitHi()

float getRobotJointLimitHi ( const std::string &  robotName,
const std::string &  nodeName 
)
overridevirtual

Implements SimulatedWorld.

Definition at line 389 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ getRobotJointLimitLo()

float getRobotJointLimitLo ( const std::string &  robotName,
const std::string &  nodeName 
)
overridevirtual

Implements SimulatedWorld.

Definition at line 369 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ getRobotJointTorques()

std::map< std::string, float > getRobotJointTorques ( const std::string &  )
overridevirtual

Implements SimulatedWorld.

Definition at line 359 of file KinematicsWorld.cpp.

◆ getRobotJointVelocities()

std::map< std::string, float > getRobotJointVelocities ( const std::string &  robotName)
overridevirtual

Implements SimulatedWorld.

Definition at line 312 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ getRobotJointVelocity()

float getRobotJointVelocity ( const std::string &  robotName,
const std::string &  nodeName 
)
overridevirtual

Implements SimulatedWorld.

Definition at line 331 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ getRobotLinearVelocity()

Eigen::Vector3f getRobotLinearVelocity ( const std::string &  robotName,
const std::string &  nodeName 
)
overridevirtual

Implements SimulatedWorld.

Definition at line 488 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ getRobotMass()

float getRobotMass ( const std::string &  robotName)
overridevirtual

Implements SimulatedWorld.

Definition at line 249 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ getRobotMaxTorque()

float getRobotMaxTorque ( const std::string &  robotName,
const std::string &  nodeName 
)
overridevirtual

Implements SimulatedWorld.

Definition at line 424 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ getRobotNames()

std::vector< std::string > getRobotNames ( )
overridevirtual

Implements SimulatedWorld.

Definition at line 1150 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ getRobotNodeDistance()

DistanceInfo getRobotNodeDistance ( const std::string &  robotName,
const std::string &  robotNodeName1,
const std::string &  robotNodeName2 
)
overridevirtual

Implements SimulatedWorld.

Definition at line 1477 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ getRobotNodePose()

Eigen::Matrix4f getRobotNodePose ( const std::string &  robotName,
const std::string &  robotNodeName 
)
overridevirtual

Implements SimulatedWorld.

Definition at line 466 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ getRobotPose()

Eigen::Matrix4f getRobotPose ( const std::string &  robotName)
overridevirtual

Implements SimulatedWorld.

Definition at line 409 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ getRobots()

std::map< std::string, RobotPtr > getRobots ( )
overridevirtual

Implements SimulatedWorld.

Definition at line 675 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ getRobotStatus()

bool getRobotStatus ( const std::string &  robotName,
NameValueMap &  jointAngles,
NameValueMap &  jointVelocities,
NameValueMap &  jointTorques,
Eigen::Vector3f &  linearVelocity,
Eigen::Vector3f &  angularVelocity 
)
overrideprotectedvirtual

Implements SimulatedWorld.

Definition at line 1032 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ hasObject()

bool hasObject ( const std::string &  instanceName)
overridevirtual

Implements SimulatedWorld.

Definition at line 229 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ hasRobot()

bool hasRobot ( const std::string &  robotName)
overridevirtual

Implements SimulatedWorld.

Definition at line 630 of file KinematicsWorld.cpp.

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

◆ hasRobotNode()

bool hasRobotNode ( const std::string &  robotName,
const std::string &  robotNodeName 
)
overridevirtual

Implements SimulatedWorld.

Definition at line 647 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ initialize()

void initialize ( int  stepSizeMS,
float  maxRealTimeSimSpeed = 1,
bool  floorPlane = false,
std::string  floorTexture = std::string() 
)
virtual

Definition at line 59 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ objectGraspedEngine()

bool objectGraspedEngine ( const std::string &  robotName,
const std::string &  robotNodeName,
const std::string &  objectName,
Eigen::Matrix4f &  storeLocalTransform 
)
overrideprotectedvirtual

create a joint

Implements SimulatedWorld.

Definition at line 754 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ objectReleasedEngine()

bool objectReleasedEngine ( const std::string &  robotName,
const std::string &  robotNodeName,
const std::string &  objectName 
)
overrideprotectedvirtual

remove a joint

Implements SimulatedWorld.

Definition at line 719 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ removeObstacleEngine()

bool removeObstacleEngine ( const std::string &  name)
overrideprotectedvirtual

Implements SimulatedWorld.

Definition at line 1210 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ removeRobotEngine()

bool removeRobotEngine ( const std::string &  robotName)
overrideprotectedvirtual

Implements SimulatedWorld.

Definition at line 804 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ setObjectPose()

void setObjectPose ( const std::string &  objectName,
const Eigen::Matrix4f &  globalPose 
)
overridevirtual

Implements SimulatedWorld.

Definition at line 234 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ setObjectSimType()

void setObjectSimType ( const std::string &  objectName,
VirtualRobot::SceneObject::Physics::SimulationType  simType 
)
overridevirtual

Implements SimulatedWorld.

Definition at line 1165 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ setRobotAngularVelocity()

void setRobotAngularVelocity ( const std::string &  robotName,
const std::string &  robotNodeName,
const Eigen::Vector3f &  vel 
)
overridevirtual

Implements SimulatedWorld.

Definition at line 562 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ setRobotAngularVelocityRobotRootFrame()

void setRobotAngularVelocityRobotRootFrame ( const std::string &  robotName,
const std::string &  robotNodeName,
const Eigen::Vector3f &  vel 
)
overridevirtual

Implements SimulatedWorld.

Definition at line 606 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ setRobotLinearVelocity()

void setRobotLinearVelocity ( const std::string &  robotName,
const std::string &  robotNodeName,
const Eigen::Vector3f &  vel 
)
overridevirtual

Implements SimulatedWorld.

Definition at line 545 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ setRobotLinearVelocityRobotRootFrame()

void setRobotLinearVelocityRobotRootFrame ( const std::string &  robotName,
const std::string &  robotNodeName,
const Eigen::Vector3f &  vel 
)
overridevirtual

Implements SimulatedWorld.

Definition at line 581 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ setRobotMaxTorque()

void setRobotMaxTorque ( const std::string &  robotName,
const std::string &  nodeName,
float  maxTorque 
)
overridevirtual

Implements SimulatedWorld.

Definition at line 445 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ setRobotNodeSimType()

void setRobotNodeSimType ( const std::string &  robotName,
const std::string &  robotNodeName,
VirtualRobot::SceneObject::Physics::SimulationType  simType 
)
overridevirtual

Implements SimulatedWorld.

Definition at line 1177 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ setRobotPose()

void setRobotPose ( const std::string &  robotName,
const Eigen::Matrix4f &  globalPose 
)
overridevirtual

Implements SimulatedWorld.

Definition at line 189 of file KinematicsWorld.cpp.

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

◆ setupFloorEngine()

void setupFloorEngine ( bool  enable,
const std::string &  floorTexture 
)
overrideprotectedvirtual

Implements SimulatedWorld.

Definition at line 1392 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ stepPhysicsFixedTimeStep()

void stepPhysicsFixedTimeStep ( )
overridevirtual

Perform one simulation step.

This updates all models.

Implements SimulatedWorld.

Definition at line 1265 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ stepPhysicsRealTime()

void stepPhysicsRealTime ( )
overridevirtual

Perform one simulation step.

Calculates the delta update time from the time that has passed since the last call. This updates all models.

Implements SimulatedWorld.

Definition at line 1239 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ stepStaticObjects()

void stepStaticObjects ( double  deltaInSeconds)
protected

Definition at line 1344 of file KinematicsWorld.cpp.

+ Here is the caller graph for this function:

◆ stepStaticRobots()

void stepStaticRobots ( double  deltaInSeconds)
protected

Definition at line 1301 of file KinematicsWorld.cpp.

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

◆ synchronizeObjects()

bool synchronizeObjects ( )
overrideprotectedvirtual

Implements SimulatedWorld.

Definition at line 1105 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ synchronizeRobotNodePoses()

bool synchronizeRobotNodePoses ( const std::string &  robotName,
std::map< std::string, armarx::PoseBasePtr > &  objMap 
)
overrideprotectedvirtual

Implements SimulatedWorld.

Definition at line 888 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ synchronizeSceneObjectPoses()

bool synchronizeSceneObjectPoses ( VirtualRobot::SceneObjectPtr  currentObjEngine,
std::map< std::string, armarx::PoseBasePtr > &  objMap 
)
overrideprotectedvirtual

Implements SimulatedWorld.

Definition at line 1417 of file KinematicsWorld.cpp.

+ Here is the caller graph for this function:

◆ synchronizeSimulationDataEngine()

bool synchronizeSimulationDataEngine ( )
overrideprotectedvirtual

Implements SimulatedWorld.

Definition at line 1440 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ toFramedPose()

armarx::FramedPosePtr toFramedPose ( const Eigen::Matrix4f &  globalPose,
const std::string &  robotName,
const std::string &  frameName 
)
overridevirtual

toFramedPose Constructs a framed pose

Parameters
globalPose
robotName
frameName
Returns

Implements SimulatedWorld.

Definition at line 863 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

◆ updateForceTorqueSensor()

bool updateForceTorqueSensor ( ForceTorqueInfo ftInfo)
overrideprotectedvirtual

Implements SimulatedWorld.

Definition at line 1095 of file KinematicsWorld.cpp.

+ Here is the call graph for this function:

Member Data Documentation

◆ angularVelocityFilters

std::map<VirtualRobot::RobotPtr, std::pair<IceUtil::Time, Eigen::Matrix4f> > angularVelocityFilters
protected

Definition at line 203 of file KinematicsWorld.h.

◆ floor

VirtualRobot::SceneObjectPtr floor
protected

Definition at line 204 of file KinematicsWorld.h.

◆ floorDepthMM

double floorDepthMM
protected

Definition at line 208 of file KinematicsWorld.h.

◆ floorExtendMM

double floorExtendMM
protected

Definition at line 207 of file KinematicsWorld.h.

◆ floorPos

Eigen::Vector3f floorPos
protected

Definition at line 205 of file KinematicsWorld.h.

◆ floorUp

Eigen::Vector3f floorUp
protected

Definition at line 206 of file KinematicsWorld.h.

◆ groundObject

VirtualRobot::ObstaclePtr groundObject
protected

Definition at line 209 of file KinematicsWorld.h.

◆ jointAngleDerivationFilters

std::map<VirtualRobot::RobotNodePtr, std::pair<IceUtil::Time, float> > jointAngleDerivationFilters
protected

Definition at line 201 of file KinematicsWorld.h.

◆ kinematicObjects

std::vector<VirtualRobot::SceneObjectPtr> kinematicObjects
protected

Definition at line 200 of file KinematicsWorld.h.

◆ kinematicRobots

std::map<std::string, KinematicRobotInfo> kinematicRobots
protected

Definition at line 199 of file KinematicsWorld.h.

◆ lastTime

IceUtil::Time lastTime
protected

Definition at line 212 of file KinematicsWorld.h.

◆ linearVelocityFilters

std::map<VirtualRobot::RobotPtr, std::pair<IceUtil::Time, Eigen::Vector3f> > linearVelocityFilters
protected

Definition at line 202 of file KinematicsWorld.h.

◆ stepSizeMs

int stepSizeMs
protected

Definition at line 180 of file KinematicsWorld.h.


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