搭建gmaping建图环境

下面介绍使用Rplidar a1激光雷达进行gmapping建图

安装依赖包

sudo apt-get install ros-indigo-serial ros-indigo-turtlebot-rviz-launchers
mkdir -p  ~/dashgo_ws/src
cd   ~/dashgo_ws/src

## dashgo SLAM版本
git clone https://github.com/EAIBOT/dashgo.git
cd dashgo
git checkout slam_01

## 激光雷达rplidar 一代驱动
git clone https://github.com/robopeak/rplidar_ros.git
cd rplidar_ros
git checkout 1.0.1


## 建图依赖包
git clone https://github.com/ros-perception/slam_gmapping
git clone https://github.com/ros-perception/openslam_gmapping
git clone https://github.com/ros-planning/navigation.git

然后编译

串口访问权限

创建dashgo和rplidar的串口别名的访问

roscd dashgo_bringup/startup
sudo sh create_dashgo_udev.sh
sudo sh create_rplidar_udev.sh

重新插拔连接电脑的USB线

运行

roslaunch dashgo_nav gmapping_demo.launch
rosrun dashgo_bringup teleop_twist_keyboard.py
roslaunch turtlebot_rviz_launchers view_navigation.launch

保存地图

roscd dashgo_nav/maps
rosrun map_server map_saver -f my_map

运行效果如下图:
搭建gmaping建图环境_第1张图片

你可能感兴趣的:(Dashgo,D1使用手册)