ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

Error in urdf

asked 2014-07-28 08:33:15 -0500

Moda gravatar image

I'm trying to do the urdf tutorial http://wiki.ros.org/urdf/Tutorials/Cr... So when i launch rosrun urdfdom check_urdf my_robot.urdf (I'm in groovy) I get this error

Error:   Could not find the 'robot' element in the xml file
         at line 59 in /tmp/buildd/ros-groovy-urdfdom-0.2.8-2precise-20140305-0755/urdf_parser/src/model.cpp
ERROR: Model Parsing the xml failed

However the element robot is there in the first line

<robot name="Mark1">

  <link name="base_link">
    <visual>
      <geometry>
        <box size="0.36 0.376 0.2"/>
      </geometry>
      <origin rpy="0 0 0" xyz="0.7 0 0"/>
      <material name="white">
        <color rgba="1 1 1 1"/>
      </material>
    </visual>
  </link>

  <link name="lwheel">
    <visual>
      <geometry>
        <cylinder length="0.028" radius="0.0625"/>
      </geometry>
      <origin rpy="0 0 0" xyz="0 0 0"/>
      <material name="black">
        <color rgba="0 0 0 1"/>
      </material>
    </visual>
  </link>

  <joint name="base_to_lwheel" type="fixed">
    <parent link="base_link"/>
    <child link="lwheel"/>
    <origin xyz="0 0.162 0" rpy="-1.5708 0 0"/>
  </joint>

  <link name="rwheel">
    <visual>
      <geometry>
        <cylinder length="0.028" radius="0.0625"/>
      </geometry>
      <origin rpy="0 0 0" xyz="0 0 0"/>
      <material name="black">
        <color rgba="0 0 0 1"/>
      </material>
    </visual>
  </link>

  <joint name="base_to_rwheel" type="fixed">
    <parent link="base_link"/>
    <child link="rwheel"/>
    <origin xyz="0 -0.162 0" rpy="1.5708 0 0"/>
  </joint>

  <link name="laser">
    <visual>
      <geometry>
        <box size="0.015 0.045 0.015"/>
      </geometry>
      <origin rpy="0 0 0" xyz="0.022 0 0.015"/>
      <material name="black">
        <color rgba="0 0 0 1"/>
      </material>
    </visual>
  </link>

  <joint name="base_to_scanner" type="fixed">
    <parent link="base_link"/>
    <child link="laser"/>
    <origin xyz="0.2 0 0.6125" rpy="0 0 0"/>


</robot>
edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2014-07-28 12:44:34 -0500

ahendrix gravatar image

It looks like your final <joint> tag is missing its close tag - perhaps that's preventing the XML parser from parsing the file properly?

edit flag offensive delete link more

Comments

It works!!! Thank you

Moda gravatar image Moda  ( 2014-07-29 03:06:28 -0500 )edit

Question Tools

1 follower

Stats

Asked: 2014-07-28 08:33:15 -0500

Seen: 2,634 times

Last updated: Jul 28 '14