Install ROS Melodic on NanoPC-T4/zh

From FriendlyELEC WiKi
Revision as of 08:09, 29 August 2018 by Tzs (Talk | contribs) (Step2 -- 设置密钥)

Jump to: navigation, search

English

1 Step1 -- 配置Ubuntu软件库

将电脑设置为接受来自packages.ros.org的软件:

1.1 选项1:通用源

sudo sh -c 'echo "deb http://packages.ros.org/ros/ubuntu $(lsb_release -sc) main" > /etc/apt/sources.list.d/ros-latest.list'

1.2 选项2:中国大陆源

1.2.1 USTC (China)

sudo sh -c '. /etc/lsb-release && echo "deb http://mirrors.ustc.edu.cn/ros/ubuntu/ $DISTRIB_CODENAME main" > /etc/apt/sources.list.d/ros-latest.list'

1.2.2 Sun Yat-Sen University (China)

sudo sh -c '. /etc/lsb-release && echo "deb http://mirror.sysu.edu.cn/ros/ubuntu/ $DISTRIB_CODENAME main" > /etc/apt/sources.list.d/ros-latest.list'

1.2.3 ExBot Robotics Lab (China)

sudo sh -c '. /etc/lsb-release && echo "deb http://ros.exbot.net/rospackage/ros/ubuntu/ $DISTRIB_CODENAME main" > /etc/apt/sources.list.d/ros-latest.list'

2 Step2 - 设置密钥

sudo apt-key adv --keyserver hkp://ha.pool.sks-keyservers.net:80 --recv-key 421C365BD9FF1F717815A3895523BAEEB01FA116

如果遇到连接到密钥服务器的问题,可以尝试在前面的命令中替换hkp://pgp.mit.edu:80 或 hkp://keyserver.ubuntu.com:80。

3 Step3 - 安装

sudo apt-get update

ROS中有许多不同的库和工具。我们提供了四种默认配置来帮助入门,也可以单独安装ROS软件包。

3.1 选项1:桌面完整安装:(推荐)

包含了ROS,rqt,rviz,机器人通用库,2D / 3D模拟器,导航和2D / 3D感知:

sudo apt-get install ros-melodic-desktop-full

3.2 选项2:其他安装方式

3.2.1 桌面安装

包含了ROS,rqt,rviz和机器人通用库:

sudo apt-get install ros-melodic-desktop

3.2.2 ROS-Base:(Bare Bones)

包含了ROS包,构建和通信库。没有GUI工具:

sudo apt-get install ros-melodic-ros-base

3.2.3 独立软件包

您也可以安装特定的ROS软件包(用下划线替换下划线):

sudo apt-get install ros-melodic-PACKAGE

例如

sudo apt-get install ros-melodic-slam-gmapping

要查找可用包,请使用:

apt-cache search ros-melodic