Excercise 2.8 - can't locate "object.urdf" to copy

I got an error when I ran: cp /home/simulations/public_sim_ws/src/ all/turtlebot/turtlebot_navigation_gazebo/urdf/object.urdf /home/user/catkin_ws/src
Looking manually, there isn’t a “tutlebot” director in the path /home/simulations/public_sim_ws/src/all/. There is a “turtle_3d” directory but that didn’t have the file. I did a “roscd” looking for a turtlebot package - found some but couldn’t find the file. Also tried find /home -name object.urdf , but got no return

Any suggestions?


I decided to try writing my own. In googling how to add “objects” as opposed to “robots” I came across this, which actually worked great and saved me the trouble.

<?xml version="1.0"?>
<!-- source: http://wiki.ros.org/simulator_gazebo/Tutorials/SpawningObjectInSimulation -->
<robot name="simple_box">
  <link name="my_box">
      <origin xyz="2 0 0" />
      <mass value="1.0" />
      <inertia  ixx="1.0" ixy="0.0"  ixz="0.0"  iyy="100.0"  iyz="0.0"  izz="1.0" />
      <origin xyz="2 0 1"/>
        <box size="1 1 2" />
      <origin xyz="2 0 1"/>
        <box size="1 1 2" />
  <gazebo reference="my_box">

Hope this helps someone else. The one think I thought was interesting is that it’s labeled a “robot” even though it’s just an object - I wasn’t sure what to call it. I also thought I’d have to include a joint to the world link based on another tutorial I had found. Obviously not for this purpose.


Hello @comm ,

Just for reference, this is the file the tutorial refers to: Bitbucket

It’s great that you were able to overcome the issue by creating your own file!

Thanks. I still think it should be fixed for future students. Either put the file somewhere it can be copied from (and change the lesson to include the right path), or just have the student create the file by cutting/pasting the code, as is done for other files. It shouldn’t be left so that a student who is following instructions gets an error with no clear way to resolve it (other than finding this thread in the support forum).

1 Like