Skip to content
Permalink
Browse files

added gazebo launch file

  • Loading branch information...
MohmadAyman committed Jun 3, 2018
1 parent b8931e8 commit cfb4a631f26d744d667ae1e77a32896519b67c64
@@ -489,6 +489,15 @@ bool ConfigurationFilesWidget::loadGenFiles()
file.write_on_changes = MoveItConfigData::GROUPS;
gen_files_.push_back(file);

// gazebo.launch ------------------------------------------------------------------
file.file_name_ = "gazebo.launch";
file.rel_path_ = config_data_->appendPaths(launch_path, file.file_name_);
template_path = config_data_->appendPaths(template_launch_path, "gazebo.launch");
file.description_ = "gazebo launch file";
file.gen_func_ = boost::bind(&ConfigurationFilesWidget::copyTemplate, this, template_path, _1);
file.write_on_changes = MoveItConfigData::GROUPS;
gen_files_.push_back(file);

// moveit.rviz ------------------------------------------------------------------
file.file_name_ = "moveit.rviz";
file.rel_path_ = config_data_->appendPaths(launch_path, file.file_name_);
@@ -0,0 +1,24 @@
<?xml version="1.0"?>
<launch>
<arg name="limited" default="false"/>
<arg name="paused" default="false"/>
<arg name="gui" default="true"/>

<!-- startup simulated world -->
<include file="$(find gazebo_ros)/launch/empty_world.launch">
<arg name="world_name" default="worlds/empty.world"/>
<arg name="paused" value="$(arg paused)"/>
<arg name="gui" value="$(arg gui)"/>
</include>

<!-- send robot urdf to param server -->
<param unless="$(arg limited)" name="robot_description" [URDF_LOAD_ATTRIBUTE] />

<param if="$(arg limited)" name="robot_description" [URDF_LOAD_ATTRIBUTE] />

<!-- push robot_description to factory and spawn robot in gazebo -->
<node name="spawn_gazebo_model" pkg="gazebo_ros" type="spawn_model" args="-urdf -param robot_description -model robot -z 0.1" respawn="false" output="screen" />

<include file="$(find [GENERATED_PACKAGE_NAME])/launch/ros_controllers.launch"/>

</launch>

0 comments on commit cfb4a63

Please sign in to comment.
You can’t perform that action at this time.