Problems while parsing <gazebo> URDF elements with Gazebo7 and ROS Jade

asked 2016-02-22 04:48:56 -0500

alextoind gravatar image

updated 2017-03-08 03:08:32 -0500

I use Gazebo 7 with ROS Jade for which ros-jade-gazebo7-ros-pkgs cannot yet be installed (due to the dependency to ros-jade-gazebo7-plugins which does not exist). Thus, I've cloned the jade-devel branch of the gazebo_ros_pkgs package in the catkin workspace and compiled it with catkin_make. EDITED after ros-jade-gazebo7-ros-pkgs release: still the same behaviour.

Issue created on 2016/03/08

Check the details in the issue and follow the linked repository:

Update 2016/03/01

I've been investigated more on this problem and I've found out that it could be due to the new naming convention from Gazebo 6 on.* I've tried the example below with ROS Jade and Gazebo 5, 6 and 7 and it works only with the first one (which relies on *sdformat2).

Using sdformat3 and sdformat4, <visual> and <collision> elements get augmented unique names when they are converted to SDF (which differ from those given in the URDF). Indeed, using <gazebo> tags it is possible to add any element which will not end in <visual> or <collision> elements, e.g. <enable_wind> or <velocity_decay> which are directly children of the <link> tag.

On the other hand, every element which has to be put inside <visual> or <collision> is completely ignored (without errors) from the parser. I think that it expects to use the URDF visual/collision names but they differ, e.g. visual_waist and collision_waist are the name in the URDF and the respectively SDF ones are waist_fixed_joint_lump__visual_waist_visual and waist_fixed_joint_lump__collision_waist_collision.

Should I report this bug on ?


I have made a simple example (download) to show that (at least with my configuration) elements inside <gazebo> urdf tags are not correctly parsed by either spawn_model or gz sdf -p commands.

I followed this Gazebo tutorial: Using a URDF in Gazebo.

This is the package structure inside my caktkin workspace:


where is a simple empty world and robot_world.launch contains the URDF spawner:

<param name="robot_description"
       command="$(find xacro)/xacro --inorder '$(find robot_description)/urdf/robot.xacro'"/>

<node name="urdf_spawner" pkg="gazebo_ros" type="spawn_model" respawn="false" output="screen" 
      args="-urdf -model robot -param robot_description"/>

and where the file in the /urdf folder are as follow:


<?xml version="1.0"?>
<robot name="robot" xmlns:xacro="">
  <!-- imports all Gazebo-customization elements, including Gazebo colors -->
  <xacro:include filename="$(find robot_description)/urdf/robot.gazebo"/>
  <!-- imports URDF robot model -->
  <xacro:include filename="$(find robot_description)/urdf/robot.urdf"/>


<?xml version="1.0"?>
<robot name="robot">

  <link name="pelvis">
      <origin xyz="-1e-06 0.060095 -0.014315" rpy="0 0 0"/>
      <mass value="2.468"/>
      <inertia ixx="0.015171" ixy="0" ixz="0" iyy="0.022628" iyz="0" izz="0.018252"/>
    <visual name="visual_pelvis">
      <origin xyz="-4.5e-05 0.021 -0.01302" rpy="0 0 0"/>
      <geometry ...
edit retag flag offensive close merge delete



I ue the same notation as your <gazebo reference="waist"> in Gazebo6 adn ros indigo and I have no problem.

Brosseau.F gravatar imageBrosseau.F ( 2016-02-26 01:57:58 -0500 )edit

Thank you. I've just made some tests again after the realease (this morning) of `ros-jade-gazebo7-ros-pkgs`, but it has still the same behaviour...

alextoind gravatar imagealextoind ( 2016-02-26 02:54:08 -0500 )edit

Same Problem here on Gazebo6 and Ros Indigo

Franzisdrak gravatar imageFranzisdrak ( 2016-09-23 03:31:37 -0500 )edit

dcconner gravatar imagedcconner ( 2017-03-07 19:16:18 -0500 )edit

Sorry for not updating the post, I've created an issue which describes the same behavior exactly one year ago, but it is still not assigned. You can find it here:

alextoind gravatar imagealextoind ( 2017-03-08 03:04:29 -0500 )edit