Adding Contact Sensor to a Gazebo Plugin
Hey guys,
I am writing a Gazebo plugin which will go through a robot model (sdf file) and iterate through the links using the joints and add a contact sensor to all the collisions present in those links. Currently, I have all the links, joints and collisions in the custom plugin.
I am stuck at adding a contact sensor to all of those collisions. There is a function AddContact in
gazebo::physics::Collision
but it is deprecated. Any suggestions on how can I add a contact sensor to those collisions in the plugin code itself?
PS: I know I can just add it in the model file but I don't want that because the model will keep changing and I don't want to keep on updating it with the contact sensor tag.
Thanks in advance.
I am just being curious. Can you tell me why would anybody tag their question on the Gazebo discussion server
gazebo
? What additional information do you wish to provide with this tag? Thank you.