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

I cant find my parsed urdf model in rviz

asked 2015-12-11 09:57:21 -0600

Kishore Kumar gravatar image

I built a robot model in solidworks and exported using plug-in as urdf. Then i parsed the file successfully and tried to visualize it in rviz but it failed to show up the model. below is my urdf file and result in rviz

    <robot
  name="JMbot">
  <link
    name="Base ">
    <inertial>
      <origin
        xyz="-0.331696074009627 -0.719586942429273 -0.402589887484249"
        rpy="0 0 0" />
      <mass
        value="1.56817866517859" />
      <inertia
        ixx="0.0108679476987914"
        ixy="-0.00179135853312012"
        ixz="-2.19999020357412E-16"
        iyy="0.0327160610863439"
        iyz="1.02118292120978E-17"
        izz="0.041347577825996" />
    </inertial>
    <visual>
      <origin
        xyz="0 0 0"
        rpy="0 0 0" />
      <geometry>
        <mesh
          filename="package://JMbot/meshes/Base .STL" />
      </geometry>
      <material
        name="">
        <color
          rgba="0.752941176470588 0.752941176470588 0.752941176470588 1" />
      </material>
    </visual>
    <collision>
      <origin
        xyz="0 0 0"
        rpy="0 0 0" />
      <geometry>
        <mesh
          filename="package://JMbot/meshes/Base .STL" />
      </geometry>
    </collision>
  </link>
  <link
    name="Base plate">
    <inertial>
      <origin
        xyz="5.55111512312578E-17 2.22044604925031E-16 0.00236910483921671"
        rpy="0 0 0" />
      <mass
        value="0.553781193313651" />
      <inertia
        ixx="0.00613802647719325"
        ixy="-7.04731412115578E-19"
        ixz="-7.48283062994103E-18"
        iyy="0.00414996381570526"
        iyz="-1.53613068073911E-17"
        izz="0.0102825986842358" />
    </inertial>
    <visual>
      <origin
        xyz="0 0 0"
        rpy="0 0 0" />
      <geometry>
        <mesh
          filename="package://JMbot/meshes/Base plate.STL" />
      </geometry>
      <material
        name="">
        <color
          rgba="0.749019607843137 0.749019607843137 0.749019607843137 1" />
      </material>
    </visual>
    <collision>
      <origin
        xyz="0 0 0"
        rpy="0 0 0" />
      <geometry>
        <mesh
          filename="package://JMbot/meshes/Base plate.STL" />
      </geometry>
    </collision>
  </link>
  <joint
    name="Base plate"
    type="fixed">
    <origin
      xyz="-0.3317 0.39256 -0.71959"
      rpy="1.5708 0.081268 -4.9871E-18" />
    <parent
      link="Base " />
    <child
      link="Base plate" />
    <axis
      xyz="0 0 0" />
  </joint>
  <link
    name="WheelR">
    <inertial>
      <origin
        xyz="-0.039049 1.1102E-16 2.2204E-16"
        rpy="0 0 0" />
      <mass
        value="0.45064" />
      <inertia
        ixx="0.00091608"
        ixy="-1.27E-19"
        ixz="1.0926E-18"
        iyy="0.00053395"
        iyz="-1.2197E-19"
        izz="0.00053395" />
    </inertial>
    <visual>
      <origin
        xyz="0 0 0"
        rpy="0 0 0" />
      <geometry>
        <mesh
          filename="package://JMbot/meshes/WheelR.STL" />
      </geometry>
      <material
        name="">
        <color
          rgba="0.74902 0.74902 0.74902 1" />
      </material>
    </visual>
    <collision>
      <origin
        xyz="0 0 0"
        rpy="0 0 0" />
      <geometry>
        <mesh
          filename="package://JMbot/meshes/WheelR.STL" />
      </geometry>
    </collision>
  </link>
  <joint
    name="WheelR"
    type="continuous">
    <origin
      xyz="0.13543 0 -0.015"
      rpy="-1.1419 -2.4633E-15 -3.1416" />
    <parent
      link="Base plate" />
    <child
      link="WheelR" />
    <axis
      xyz="1 0 0" />
  </joint>
  <link
    name="WheelL">
    <inertial>
      <origin
        xyz="-0.039049 2.2204E-16 2.498E-15"
        rpy="0 0 0" />
      <mass
        value="0.45064" />
      <inertia
        ixx="0.00091608"
        ixy="-9.7209E-19"
        ixz="-1.737E-18"
        iyy="0.00053395"
        iyz="0"
        izz="0.00053395" />
    </inertial>
    <visual>
      <origin
        xyz="0 0 0"
        rpy="0 0 0" />
      <geometry>
        <mesh
          filename="package://JMbot/meshes/WheelL.STL" />
      </geometry>
      <material
        name="">
        <color
          rgba="0.74902 0.74902 0.74902 1" />
      </material>
    </visual>
    <collision>
      <origin
        xyz="0 0 0"
        rpy="0 0 0" />
      <geometry>
        <mesh
          filename="package://JMbot/meshes/WheelL.STL" />
      </geometry>
    </collision>
  </link>
  <joint
    name="WheelL"
    type="continuous">
    <origin
      xyz="-0.13543 0 -0.015"
      rpy="0 ...
(more)
edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2015-12-11 10:12:28 -0600

gvdhoorn gravatar image

As you can see in your screenshot (under Global Status), you have Fixed Frame set to map, but there is no such (TF) frame.

Set if to something else and you'll probably see your robot.

edit flag offensive delete link more

Comments

I tried changing the frame to "base" which is in transform but that doesn't help, refer the result here

Kishore Kumar gravatar image Kishore Kumar  ( 2015-12-12 05:11:58 -0600 )edit

I'm pretty sure it was there before, but you don't have an instance of the Robot Model display plugin there. Without that, RViz will not have anything to show you other than that grid you're seeing right now ..

gvdhoorn gravatar image gvdhoorn  ( 2015-12-12 05:30:06 -0600 )edit

Where have i gone wrong. How to fix this, should i do any changes in my URDF file?

Kishore Kumar gravatar image Kishore Kumar  ( 2015-12-12 07:43:12 -0600 )edit

No, just add the Robot Model display plugin to your RViz. Click Add, scroll down to where it says Robot Model, then add it. Your robot should appear.

gvdhoorn gravatar image gvdhoorn  ( 2015-12-12 07:45:33 -0600 )edit

Great !, That helped thank you.

Kishore Kumar gravatar image Kishore Kumar  ( 2015-12-12 09:48:09 -0600 )edit

Question Tools

1 follower

Stats

Asked: 2015-12-11 09:57:21 -0600

Seen: 1,067 times

Last updated: Dec 11 '15