/mcl_2d_lidar_ros

Monte Carlo Localization (MCL) using 2D LiDAR on Robot Operating System (ROS)

Primary LanguageC++

Monte Carlo localization using 2D LiDAR on Robot Operating System (ROS)


Explanation

Easy-implemented Monte Carlo Localization (MCL) code on ros-kinetic

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)

Dependency libraries

  • Eigen (default version of ROS)
  • opencv (default version of ROS)

Results

Mapgen

mapgen

MCL

mcl

Usage

$ roscore
  1. Setting

    1. Download this repository
    $ cd /home/$usr_name/catkin_ws/src
    $ git clone https://github.com/LimHyungTae/mcl_2d_lidar_ros.git
    1. 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
  2. Mapgen

    1. Move to the repository e.g,
    $ cd /home/$usr_name/catkin_ws/src/mcl_2d_lidar_ros
    1. Play rosbag re510_mapgen.bag
    $ rosbag play rosbag/re510_mapgen.bag -r 3
    1. Run mapgen code
    $ rosrun re510_slam rs_mapgen
  3. MCL

    1. Move to the repository e.g,
    $ cd /home/$usr_name/catkin_ws/src/mcl_2d_lidar_ros
    1. Play rosbag re510_mcl.bag
    $ rosbag play rosbag/re510_mcl.bag
    1. Change the paths of png: 7 and 8th lines on the re510_slam/rs_mcl/src/mcl.cpp

    2. Run MCL code

    $ rosrun re510_slam rs_mcl

Consideration

/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.