< >
Home » ROS2与Turtlebot入门 » Turtlebot-ROS2入门教程-源码安装turtlebot2_demo

Turtlebot-ROS2入门教程-源码安装turtlebot2_demo

Turtlebot-ROS2入门教程-源码安装turtlebot2_demo

说明:

  • 介绍如何安装turtlebot2_demo包

安装turtlebot2_demo:

  • 下载代码
cd <YOUR_ROS2_WORKSPACE>
wget https://raw.githubusercontent.com/ros2/turtlebot2_demo/ardent/turtlebot2_demo.repos
vcs import src < turtlebot2_demo.repos
  • 安装一些依赖
sudo apt-get install --no-install-recommends -y libboost-iostreams-dev libboost-regex-dev libboost-system-dev libboost-thread-dev libceres-dev libgoogle-glog-dev liblua5.2-dev libpcl-dev libprotobuf-dev libsdl1.2-dev libsdl-image1.2-dev libsuitesparse-dev libudev-dev libusb-1.0-0-dev libyaml-cpp-dev protobuf-compiler python-sphinx ros-kinetic-kobuki-driver ros-kinetic-kobuki-ftdi
  • 对于资源受限的平台,我们会将构建分成2个步骤,以确保不会溢出内存:
  • 第一次编译:
ament.py build --isolated --symlink-install --parallel --skip-packages cartographer cartographer_ros ros1_bridge turtlebot2_amcl turtlebot2_drivers turtlebot2_follower turtlebot2_cartographer turtlebot2_teleop
  • 第二次编译,现在是资源密集型软件包和依赖于ROS1软件包的软件包:
source /opt/ros/kinetic/setup.bash
ament.py build --isolated --symlink-install --parallel --only cartographer cartographer_ros turtlebot2_amcl turtlebot2_cartographer turtlebot2_drivers turtlebot2_follower turtlebot2_teleop --make-flags -j2 -l2

参考:

  • https://github.com/ros2/turtlebot2_demo

纠错,疑问,交流: 请进入讨论区点击加入Q群

获取最新文章: 扫一扫右上角的二维码加入“创客智造”公众号


标签: turtlebot-ros2入门教程