Cartographer_ROS傻瓜式建图

Cartographer_ROS安装(需要)

日期 更新 编制
2020-03-12 首次搬运
参考 https://google-cartographer-ros.readthedocs.io/en/latest/compilation.html

文章目录

  • Cartographer_ROS安装(需要)
            • 参考 https://google-cartographer-ros.readthedocs.io/en/latest/compilation.html
    • 1. Install wstool and rosdep.
    • 2.Create a new workspace in'catkin_ws'.
    • 3.Merge the cartographer_ros.rosinstall file and fetch code for dependencies.
    • 4.Install deb dependencies.
    • 5.Build and install.
    • 6.在线建图

1. Install wstool and rosdep.

sudo apt-get update
sudo apt-get install -y python-wstool python-rosdep ninja-build

2.Create a new workspace in’catkin_ws’.

mkdir catkin_ws
cd catkin_ws
wstool init src

3.Merge the cartographer_ros.rosinstall file and fetch code for dependencies.

wstool merge -t src https://raw.githubusercontent.com/googlecartographer/cartographer_ros/master/cartographer_ros.rosinstall
wstool update -t src

4.Install deb dependencies.

rosdep init
rosdep update
rosdep install --from-paths src --ignore-src --rosdistro=${ROS_DISTRO} -y

5.Build and install.

catkin_make_isolated --install --use-ninja

6.在线建图

source install_isolated/setup.bash #加载环境
roslaunch cartographer_ros backpack_2d.launch #启动在线建图
rosbag play --clock ***.bag #播放建图.bag
rosrun map_server map_saver --free 20 --occ 60 -f * #保存建图后的地图.pgm
kolourpaint #使用修图工具

Cartographer_ROS傻瓜式建图_第1张图片

你可能感兴趣的:(ROS机器人)