These codes are implemented only using OpenCV library! So It might be helpful for newbies to understand overall MCL procedures
Originally, it is RE510 materials at KAIST implemented by Seungwon Song as a TA.
Original author: Seungwon Song (sswan55@kaist.ac.kr)
Reviser : Hyungtae Lim (shapelim@kaist.ac.kr)
- Eigen (default version of ROS)
- opencv (default version of ROS)
$ roscore
-
Setting
- Download this repository
$ cd /home/$usr_name/catkin_ws/src
$ git clone https://github.com/LimHyungTae/mcl_2d_lidar_ros.git
- Build this ros code as follows.
$ cd /home/$usr_name/catkin_ws
$ catkin_make re510_slam
Or if you use catkin-tools, then type below line on the command
$ catkin build re510_slam
-
Mapgen
- Move to the repository e.g,
$ cd /home/$usr_name/catkin_ws/src/mcl_2d_lidar_ros
- Play rosbag re510_mapgen.bag
$ rosbag play rosbag/re510_mapgen.bag -r 3
- Run mapgen code
$ rosrun re510_slam rs_mapgen
-
MCL
- Move to the repository e.g,
$ cd /home/$usr_name/catkin_ws/src/mcl_2d_lidar_ros
- Play rosbag re510_mcl.bag
$ rosbag play rosbag/re510_mcl.bag
-
Change the paths of png: 7 and 8th lines on the re510_slam/rs_mcl/src/mcl.cpp
-
Run MCL code
$ rosrun re510_slam rs_mcl
/vrpn_client_node/turtleBot/pose: Pose captured from OptiTrack, which is a motion caputre system(Ground Truth).
/odom: 2D pose from Turtlebot2.
/scan: 2D LiDAR data measured by RP LiDAR A1M8.