Getting ready

We will create a new file in the chapter7_tutorials/launch folder with the name move_base.launch and put the following code there:

<?xml version="1.0"?>
<launch>
<!-- Run the map server -->
<node name="map_server" pkg="map_server" type="map_server" args="$(find chapter7_tutorials)/maps/map.yaml" output="screen"/>
<include file="$(find amcl)/examples/amcl_diff.launch" >
</include>
<node pkg="move_base" type="move_base" respawn="false" name="move_base" output="screen">
<param name="controller_frequency" value="10.0"/>
<param name="controller_patiente" value="15.0"/>
<rosparam file="$(find chapter7_tutorials)/launch/costmap_common_params.yaml" command="load" ns="global_costmap" />
<rosparam file="$(find chapter7_tutorials)/launch/costmap_common_params.yaml" command="load" ns="local_costmap" />
<rosparam file="$(find chapter7_tutorials)/launch/local_costmap_params.yaml" command="load" />
<rosparam file="$(find chapter7_tutorials)/launch/global_costmap_params.yaml" command="load" />
<rosparam file="$(find chapter7_tutorials)/launch/base_local_planner_params.yaml" command="load" />
</node>
</launch>

You may have noticed that in this launch file, we have included all configuration files that were created in the previous section. Additionally, we will also launch a map server with a map, which was created in the previous The navigation stack in ROS and AMCL node section.

Since our robot has a differential drive model, the amcl node used here is for differential drive robots. If we have holonomic robots, we will need to use the amcl_omni.launch file.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.223.119.17