0
$\begingroup$

Gazebo Answers logo

I have just moved my code from Ubuntu 12.04 LTS and ROS Hydro to Ubuntu 14.04 LTS and ROS Indigo. My robot is using Gazebo contact sensors with the libgazebo_ros_bumper.so plugin. The sensors worked correctly with the version of Gazebo used by Hydro (1.9.6), but with Indigo I get the following error:

***** Internal Program Error - assertion (this->customContactPublishers.count(name) > 0)
failed in std::string gazebo::physics::ContactManager::CreateFilter(const string&, const
std::vector<std::basic_string<char> >&):
/tmp/buildd/gazebo2-2.2.3/gazebo/physics/ContactManager.cc(329): Failed to create a custom
filter
Service call failed: transport error completing service call: unable to receive data from
sender, check sender's logs for details
Aborted (core dumped)

Here is a contact specification from the robot's URDF file:

<gazebo reference="gripper_fixed_jaw">
  <sensor name="fixed_jaw_contact_sensor" type="contact">
    <always_on>true</always_on>
    <update_rate>${contact_sensor_update_rate}</update_rate>
    <contact>
      <collision>collision</collision>
    </contact>
    <plugin name="fixed_jaw_bumper" filename="libgazebo_ros_bumper.so">
      <bumperTopicName>fixed_jaw_contact_sensor_state</bumperTopicName>
      <frameName>gripper_fixed_jaw</frameName>
    </plugin>
  </sensor>
</gazebo>

Is there something that needs to be changed in this specification in order to work with Gazebo 2.2.3?


Originally posted by Jim Rothrock on Gazebo Answers with karma: 247 on 2014-08-30

Post score: 1

$\endgroup$

1 Answer 1

0
$\begingroup$

Gazebo Answers logo

I was given the solution to this problem by Felix Messmer. The name within the <collision> element must be of the form <link name>_collision. Here is a contact specification that works:

<gazebo reference="gripper_fixed_jaw">
  <sensor name="fixed_jaw_contact_sensor" type="contact">
    <always_on>true</always_on>
    <update_rate>${contact_sensor_update_rate}</update_rate>
    <contact>
      <!-- When using ROS Indigo and Gazebo 2.2.3, the name specified here
           must be <link name>_collision. -->
      <collision>gripper_fixed_jaw_collision</collision>
    </contact>
    <plugin name="fixed_jaw_bumper" filename="libgazebo_ros_bumper.so">
      <bumperTopicName>fixed_jaw_contact_sensor_state</bumperTopicName>
      <frameName>gripper_fixed_jaw</frameName>
    </plugin>
  </sensor>
</gazebo>

Originally posted by Jim Rothrock with karma: 247 on 2014-10-10

This answer was ACCEPTED on the original site

Post score: 5

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.