Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Launching Gazebo paused, setting the model configuration via a gazebo service, then unpausing is the best I have found. However, you can do this completely from the launch file, as "spawn_model" has an option to unpause gazebo.

  <node name="urdf_spawner" pkg="gazebo_ros" type="spawn_model" respawn="false" output="screen"
    args="-urdf -model rrbot -param robot_description
          -J joint1 1.0
          -unpause"/>

Note: If you have to spawn multiple models I would not use this method. The order of node launching isn't guaranteed, thus you might unpause gazebo before you indent.

Launching Gazebo paused, setting the model configuration via a gazebo service, then unpausing is the best I have found. However, you can do this completely from the launch file, as "spawn_model" has an option to unpause gazebo.

  <node name="urdf_spawner" pkg="gazebo_ros" type="spawn_model" respawn="false" output="screen"
    args="-urdf -model rrbot -param robot_description
          -J joint1 1.0
          -unpause"/>

Note: If you have to spawn multiple models I would not use this method. The order of node launching isn't guaranteed, thus you might unpause gazebo before you indent.intend.