how to insert a force or torque sensor to gazebo model?
as title thanks a lot
Hi Skhan, sorry for the late reply, one way to do this is to create a model plugin, for example, see this tutorial on how to create a model plugin. In the plugin update loop, you can get the force torque information from one of the joints in the model by calling:
physics::JointWrench wrench = this->model->GetJoint("...your model joint name...")->GetForceTorque(0u);
On the SDF side, in your model, you must set <provide_feedback>
to true for this to work.
you can also create a contact sensor as described in this tutorial: http://gazebosim.org/wiki/Tutorials/1.5/sensors/contact
http://www.gazebosim.org/tutorials?tut=contact_sensor&cat=sensors is the new link to the sensor contact tutorial, the above wiki link is dead now.
Asked: 2012-11-18 20:09:57 -0600
Seen: 4,476 times
Last updated: Apr 05 '13
problem with including a model
Insert model programmatically and get its model pointer
How to add/delete a object mutliple times from a single model file using a plug-in
Adding torque sensors to my robot
failed to spawn a model by calling service [closed]
Gazebo / URDF human model (with joints, not an actor)
How do I get the IMU to use the NED reference frame?
What does the "w" in an IMU messag stand for?
No one is here to answer it =(