diff --git a/source/RobotAPI/interface/robotstate/RobotState.ice b/source/RobotAPI/interface/robotstate/RobotState.ice index e254732b9d7d01d50683b8184e34421c0f99c137..d58c6fdd691857a4d48867845001a1ddd11218a5 100644 --- a/source/RobotAPI/interface/robotstate/RobotState.ice +++ b/source/RobotAPI/interface/robotstate/RobotState.ice @@ -120,10 +120,16 @@ module armarx * @return proxy to the shared robot which constantly updates all joint values */ SharedRobotInterface* getSynchronizedRobot(); + /** * @return proxy to a copy of the shared robot with non updating joint values */ SharedRobotInterface* getRobotSnapshot(string time); + + /** + * @return the robot xml filename as specified in the configuration + */ + string getRobotFilename(); }; }; diff --git a/source/RobotAPI/libraries/robotstate/RobotStateComponent.cpp b/source/RobotAPI/libraries/robotstate/RobotStateComponent.cpp index cc50f66c194cd211365af7e739068e61c972ad3e..d5c81c859aab268f61e8f2de3d47f6858a472b3c 100644 --- a/source/RobotAPI/libraries/robotstate/RobotStateComponent.cpp +++ b/source/RobotAPI/libraries/robotstate/RobotStateComponent.cpp @@ -151,7 +151,12 @@ namespace armarx // ARMARX_VERBOSE_S << "duration: " << (IceUtil::Time::now() - start).toMilliSeconds() << " ms"; } - + std::string RobotStateComponent::getRobotFilename(const Ice::Current&) + { + std::string robotFile = getProperty<std::string>("RobotFileName").getValue(); + return robotFile; + } + void RobotStateComponent::reportControlModeChanged(const NameControlModeMap& jointModes, bool aValueChanged,const Current& c){} void RobotStateComponent::reportJointVelocities(const NameValueMap& jointVelocities, bool aValueChanged,const Current& c){} void RobotStateComponent::reportJointTorques(const NameValueMap& jointTorques, bool aValueChanged,const Current& c){} diff --git a/source/RobotAPI/libraries/robotstate/RobotStateComponent.h b/source/RobotAPI/libraries/robotstate/RobotStateComponent.h index d4dafacca64b65902fa00f4007275fcca091598e..8b1bc656aa501878b48d87da7b4363521f510eed 100644 --- a/source/RobotAPI/libraries/robotstate/RobotStateComponent.h +++ b/source/RobotAPI/libraries/robotstate/RobotStateComponent.h @@ -91,7 +91,11 @@ namespace armarx * \return clone of the internal synchronized robot */ virtual SharedRobotInterfacePrx getRobotSnapshot(const std::string & time, const Ice::Current&); - + + /** + * \return the robot xml filename as specified in the configuration + */ + virtual std::string getRobotFilename(const Ice::Current&); /** * Create an instance of RobotStatePropertyDefinitions.