23 #ifndef GAZEBO_ROS_FORCE_HH 24 #define GAZEBO_ROS_FORCE_HH 31 #include <geometry_msgs/Wrench.h> 34 #include <boost/thread.hpp> 35 #include <boost/thread/mutex.hpp> 37 #include <gazebo/physics/physics.hh> 38 #include <gazebo/transport/TransportTypes.hh> 39 #include <gazebo/common/Plugin.hh> 40 #include <gazebo/common/Events.hh> 80 protected:
void Load(physics::ModelPtr _model, sdf::ElementPtr _sdf);
96 private: physics::LinkPtr
link_;
void Load(physics::ModelPtr _model, sdf::ElementPtr _sdf)
geometry_msgs::Wrench wrench_msg_
Container for the wrench force that this plugin exerts on the body.
void QueueThread()
The custom callback queue thread function.
ros::CallbackQueue queue_
GazeboRosForce()
Constructor.
boost::mutex lock_
A mutex to lock access to fields that are used in ROS message callbacks.
std::string link_name_
The Link this plugin is attached to, and will exert forces on.
physics::WorldPtr world_
A pointer to the gazebo world.
virtual ~GazeboRosForce()
Destructor.
std::string robot_namespace_
for setting ROS name space
physics::LinkPtr link_
A pointer to the Link, where force is applied.
event::ConnectionPtr update_connection_
void UpdateObjectForce(const geometry_msgs::Wrench::ConstPtr &_msg)
call back when a Wrench message is published
virtual void UpdateChild()
std::string topic_name_
ROS Wrench topic name inputs.
ros::NodeHandle * rosnode_
A pointer to the ROS node. A node will be instantiated if it does not exist.
boost::thread callback_queue_thread_
Thead object for the running callback Thread.