本文作者:zhangrelay 英文视频教程Foxy:
依据01文档,查阅本地文档,实践操作演示视频在文末:
提供了Fedora/Ubuntu/Linux/MaxOS/Windows全系列的安装说明。 依据说明可以非常顺利的完成安装,这里不做搬运和翻译了。
补充一: 图形化安装说明,使用新立得安装ROS2功能包:
- sudo apt install synaptic
或者使用Ubuntu软件中心:
安装后打开即可使用:
相比终端直接安装的专业模式,这种模式更清晰,每个功能包的说明都是非常具体。 如需要了解rviz2的功能:
可知,rviz2是ROS的一个三维可视化工具,点击访问主页,可以得到更为详细的文档资料和使用说明。 补充二: 安装源,选择国内软件源对于提升安装速度有非常大的改善:
ROS2 镜像使用帮助
新建 /etc/apt/sources.list.d/ros2-latest.list
,内容为: 你的Debian/Ubuntu版本: Ubuntu 20.04 LTS
deb https://mirrors.tuna.tsinghua.edu.cn/ros2/ubuntu/ focal main
然后再输入如下命令,信任 ROS 的 GPG Key,并更新索引:
sudo apt install curl gnupg2
curl -s https://raw.githubusercontent.com/ros/rosdistro/master/ros.asc | sudo apt-key add -
sudo apt update
Reference: https://index.ros.org/doc/ros2/Installation/Foxy/Linux-Install-Binary/ 补充三: 更新(20200521):
- sudo apt update
- sudo apt upgrade -y
$ sudo apt upgrade
正在读取软件包列表... 完成
正在分析软件包的依赖关系树
正在读取状态信息... 完成
正在计算更新... 完成
下列软件包将被升级:
gir1.2-mutter-6 gnome-shell gnome-shell-common libignition-msgs5
libmutter-6-0 libsmbclient libwbclient0 mutter mutter-common
ros-foxy-action-tutorials-cpp ros-foxy-actionlib-msgs
ros-foxy-demo-nodes-cpp ros-foxy-demo-nodes-cpp-native
ros-foxy-demo-nodes-py ros-foxy-dummy-map-server
ros-foxy-dummy-robot-bringup ros-foxy-dummy-sensors
ros-foxy-examples-rclcpp-minimal-publisher
ros-foxy-examples-rclcpp-minimal-subscriber ros-foxy-geometry-msgs
ros-foxy-interactive-markers ros-foxy-laser-geometry
ros-foxy-launch-testing-ros ros-foxy-libstatistics-collector
ros-foxy-map-msgs ros-foxy-message-filters ros-foxy-nav-msgs ros-foxy-rclcpp
ros-foxy-rclcpp-action ros-foxy-rclcpp-components ros-foxy-rclcpp-lifecycle
ros-foxy-robot-state-publisher ros-foxy-ros2action ros-foxy-ros2bag
ros-foxy-ros2component ros-foxy-ros2doctor ros-foxy-ros2interface
ros-foxy-ros2launch ros-foxy-ros2lifecycle
ros-foxy-ros2lifecycle-test-fixtures ros-foxy-ros2node ros-foxy-ros2param
ros-foxy-ros2pkg ros-foxy-ros2run ros-foxy-ros2service ros-foxy-ros2test
ros-foxy-ros2topic ros-foxy-rosbag2-compression ros-foxy-rosbag2-cpp
ros-foxy-rosbag2-storage ros-foxy-rosbag2-transport
ros-foxy-rosidl-runtime-py ros-foxy-rqt ros-foxy-rqt-gui-cpp
ros-foxy-rqt-plot ros-foxy-rqt-robot-steering ros-foxy-rviz-common
ros-foxy-rviz-default-plugins ros-foxy-rviz2 ros-foxy-sensor-msgs
ros-foxy-std-msgs ros-foxy-std-srvs ros-foxy-tf2 ros-foxy-tf2-geometry-msgs
ros-foxy-tf2-msgs ros-foxy-tf2-py ros-foxy-tf2-ros ros-foxy-turtlesim
ros-foxy-visualization-msgs samba-libs
升级了 70 个软件包,新安装了 0 个软件包,要卸载 0 个软件包,有 0 个软件包未被升级。
需要下载 19.8 MB 的归档。
解压缩后会消耗 133 kB 的额外空间。
您希望继续执行吗? [Y/n] y
获取:1 http://mirrors.aliyun.com/ubuntu focal-updates/main amd64 libsmbclient amd64 2:4.11.6+dfsg-0ubuntu1.2 [59.1 kB]
获取:2 http://mirrors.aliyun.com/ubuntu focal-updates/main amd64 libwbclient0 amd64 2:4.11.6+dfsg-0ubuntu1.2 [221 kB]
获取:3 http://mirrors.aliyun.com/ubuntu focal-updates/main amd64 samba-libs amd64 2:4.11.6+dfsg-0ubuntu1.2 [5,272 kB]
获取:4 http://packages.osrfoundation.org/gazebo/ubuntu-stable focal/main amd64 libignition-msgs5 amd64 5.3.0-1~focal [719 kB]
获取:5 http://packages.ros.org/ros2-testing/ubuntu focal/main amd64 ros-foxy-std-msgs amd64 2.0.0-1focal.20200521.191834 [777 kB]
获取:6 http://mirrors.aliyun.com/ubuntu focal-updates/main amd64 mutter-common all 3.36.2-1ubuntu1~20.04.1 [12.8 kB]
获取:7 http://mirrors.aliyun.com/ubuntu focal-updates/main amd64 gir1.2-mutter-6 amd64 3.36.2-1ubuntu1~20.04.1 [109 kB]
获取:8 http://mirrors.aliyun.com/ubuntu focal-updates/main amd64 libmutter-6-0 amd64 3.36.2-1ubuntu1~20.04.1 [1,161 kB]
获取:9 http://mirrors.aliyun.com/ubuntu focal-updates/main amd64 gnome-shell amd64 3.36.2-1ubuntu1~20.04.1 [779 kB]
获取:10 http://mirrors.aliyun.com/ubuntu focal-updates/main amd64 gnome-shell-common all 3.36.2-1ubuntu1~20.04.1 [152 kB]
获取:11 http://mirrors.aliyun.com/ubuntu focal-updates/main amd64 mutter amd64 3.36.2-1ubuntu1~20.04.1 [128 kB]
获取:12 http://packages.ros.org/ros2-testing/ubuntu focal/main amd64 ros-foxy-libstatistics-collector amd64 1.0.0-2focal.20200521.192531 [81.6 kB]
获取:13 http://packages.ros.org/ros2-testing/ubuntu focal/main amd64 ros-foxy-rclcpp amd64 1.0.0-1focal.20200521.192912 [481 kB]
获取:14 http://packages.ros.org/ros2-testing/ubuntu focal/main amd64 ros-foxy-rclcpp-action amd64 1.0.0-1focal.20200521.194316 [52.5 kB]
获取:15 http://packages.ros.org/ros2-testing/ubuntu focal/main amd64 ros-foxy-rclcpp-components amd64 1.0.0-1focal.20200521.194701 [62.1 kB]
获取:16 http://packages.ros.org/ros2-testing/ubuntu focal/main amd64 ros-foxy-action-tutorials-cpp amd64 0.9.1-1focal.20200521.195254 [75.3 kB]
获取:17 http://packages.ros.org/ros2-testing/ubuntu focal/main amd64 ros-foxy-actionlib-msgs amd64 2.0.0-1focal.20200521.192847 [140 kB]
获取:18 http://packages.ros.org/ros2-testing/ubuntu focal/main amd64 ros-foxy-demo-nodes-cpp amd64 0.9.1-1focal.20200521.194808 [355 kB]
获取:19 http://packages.ros.org/ros2-testing/ubuntu focal/main amd64 ros-foxy-demo-nodes-cpp-native amd64 0.9.1-1focal.20200521.194807 [53.1 kB]