Stupid-Robotics
📝 Table of Contents
📙 About
This project aims to apply the concepts of cognitive robotics to implement a Mapping with known pose and Simultaneous Localization and Mapping(SLAM) algorithm, and then apply it on Gazebo and RViz simulation tools using a real-life robot model in a realistic environment from scratch.
This simulation is done on SummitXL robot in Willow garage which is one the most popular indoor simulation environments in Gazebo.
This project is divides into four requirements:
- Control the robot using keyboard keys.
- control node to control the robot press W, A, S, D to move the robot and Q to exit
- Sensor Incorporating and Alignment.
- this to merge the two laser sensors of the robot front and rear this is done by rai_laser_tools package and also to merge with them the odometry sensor readings.
- Mapping with known pose.
- It's required to draw the map while knowing the robot pose you can move using the control module this is done using reflective map algorithm.
- Simultaneous Localization and Mapping(SLAM).
- It's required to draw the map without knowing the robot pose you can move using the control module also this is done using approximation and a small changes have been done on the third module.
💻 Technology
🔗 Dependencies
summit_xl_common
- Launch files that launch the complete simulation of the robot.
summit_xl_sim
- This package contains the different controllers and launch files for the SummitXL robot, shared for real robot and simulation.
robotnik_msgs
- Contains common messages and services used by some Robotnik's packages.
robotnik_sensors
- Contains Robotnik standard sensors description.
ira_laser_tools
- Listening to different laser scan sources and merging them in a single scan or generating virtual laser scans.
🏁 Get Started
- Setup ROS to do that follow the steps in this link
- Install some dependencies for ROS :
sudo apt-get install ros-noetic-navigation -y
sudo apt-get install ros-noetic-gmapping -y
sudo apt-get install ros-noetic-robot-localization -y
sudo apt-get install ros-noetic-mavros-msgs -y
sudo apt-get install ros-noetic-velocity-controllers -y
sudo apt-get install ros-noetic-twist-mux -y
sudo apt-get install ros-noetic-teleop-twist-keyboard -y
- Clone the repo :
https://github.com/Ahmed-Emad10/Stupid-Robotics.git
- Clone the dependencies in this directory /Stupid-Robotics/src :
git clone https://github.com/RobotnikAutomation/summit_xl_common.git
git clone https://github.com/RobotnikAutomation/summit_xl_sim.git
git clone https://github.com/RobotnikAutomation/robotnik_msgs.git
git clone https://github.com/RobotnikAutomation/robotnik_sensors.git
- In Stupid-Robotics open a terminal and write :
catkin_make
- Source ROS :
echo "source /devel/setup.bash" >> ~/.bashrc
source ~/.bashrc
- Source the project :
echo "source ~/Stupid-Robotics/devel/setup.bash" >> ~/.bashrc
source ~/.bashrc
💿 How to Run
- Launch the simulation open a new terminal :
roslaunch summit_xl_sim_bringup summit_xls_complete.launch
- note: if an error occurred while launching the simulation remove the following two lines from this file Stupid-Robotics/src/summit_xl_sim/summit_xl_gazebo/launch/summit_xl_one_robot.launch line 104 and 105 :
<arg name="arm_manufacturer" value="$(arg arm_manufacturer)"/> <arg name="arm_model" value="$(arg arm_model)"/>
- Control the robot using W, S, A, D and Q to quit :
*do each step in a new terminal
roslaunch summit_xl_sim_bringup summit_xls_complete.launch
rosrun project_reqs control.py
- Sensor Incorporating and Alignment :
*do each step in a new terminal
roslaunch summit_xl_sim_bringup summit_xls_complete.launch
roslaunch ira_laser_tools laserscan_multi_merger.launch
rosrun project_reqs sensor_incorporating_and_alignment.py
- Mapping with known pose :
*do each step in a new terminal
roslaunch summit_xl_sim_bringup summit_xls_complete.launch
roslaunch ira_laser_tools laserscan_multi_merger.launch
rosrun project_reqs sensor_incorporating_and_alignment.py
rosrun project_reqs mapping.py
rosrun project_reqs control.py
- You should go to RViz and click on Add then add new Map /map_topic
- Simultaneous Localization and Mapping(SLAM) :
*do each step in a new terminal
roslaunch summit_xl_sim_bringup summit_xls_complete.launch
roslaunch ira_laser_tools laserscan_multi_merger.launch
rosrun project_reqs sensor_incorporating_and_alignment.py
rosrun project_reqs slam.py
rosrun project_reqs control.py
- You should go to RViz and click on Add then add new Map /slam_topic