Home | Tutorials | Wiki | Issues
Ask Your Question
0

how to create launch file for my .urdf file and open it in gazebo

asked 2018-07-08 02:39:48 -0500

rukn gravatar image

i have created a .urdf file of simple robo model inside src/my_robo/urdf but i don't knw how to open it in gazebo , i need it to open using roslaunch

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2018-07-09 01:50:05 -0500

Raskkii gravatar image

updated 2018-07-11 06:49:37 -0500

For this you can use the spawn_model script from the gazebo_ros package. Assuming you have Gazebo already opened and "my_robo" is a package in your catkin workspace, you can use a script similar to this:

<?xml version="1.0"?>
  <launch>

    <param name="robot_description" command="cat '$(find my_robo)/urdf/robot.urdf'" />

    <node name="spawn_urdf" pkg="gazebo_ros" type="spawn_model" args="-param /robot_description -urdf -model robot" />
  </launch>
edit flag offensive delete link more
Login/Signup to Answer

Question Tools

1 follower

Stats

Asked: 2018-07-08 02:26:26 -0500

Seen: 59 times

Last updated: Jul 11