
Autonomously Navigating a Robot using RRT Path Planning algorithm in ROS
The project involves a robot being spawned in a restaurant world. The robot travels autonomously around the restaurant using a map of the environment and control commands generated by move_base package in ROS which uses the RRT algorithm for path plannning.
High level explanation of the system
slam_gmapping
package was used to create a map of the restaurant which is published continuously by the map_server
package so that it can be used for navigation. Using this map, local and global costmaps are created and published so that the robot can avoid obstacles on its way.
robot_state_publisher
and joint_state_publisher
packages publish the robot state and joint states of the robot continuously.
move_base
package is used to generate a path to the destination using the costmaps and generate control commands for the robot to reach the destination that can be given using 2D Nav Goal option in RViz. The default planners used by move_base
package were overridden to use a custom path planning algorithm i.e. RRT using a service-client mechanism in ROS.
The simulated restaurant world and robot can be seen in the Gazebo simulator. The RViz visualization tool can be used to visualize the costmaps, global and local paths, robot state, etc.
Following are the steps to run the code on your machine:-
- Close the repository on your machine.
- Copy the packages in your workspace.
- Terminal 1 - catkin_make
- Terminal 1 - source devel/setup.bash
- Terminal 1 - roslaunch path_planning simulation.launch
- Terminal 2 - roslaunch path_planning plan_path.launch
- Give a goal location using “2D Nav Goal” option in RViz
Restaurant World
RViz window
RViz window with planned path to the destination
Click here to access the code