Ubuntu18.04 melodic 安装与下载ROS

标题(Ubuntu18.04 melodic 安装与下载ROS

Ubuntu系统允许restricted(不完全的自由软件)、universe(Ubuntu官方不提供支持与补丁,全靠社区支持)、multiverse(非自由软件,完全不提供支持和补丁)这三种软件源。
sources.list是Ubuntu系统保存软件源地址的文件,位于/etc/apt/目录下,在这一步中我们需要将 ROS的软件源地址添加到该文件中。

1 添加ROS软件源

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

  1. 添加密钥
sudo apt-key adv --keyserver 'hkp://keyserver.ubuntu.com:80' --recv-key C1CF6E31E6BADE8868B172B4F42ED6FBAB17C654

3 安装ROS


$ sudo apt update
$ sudo apt install ros-melodic-desktop-full

4.初始化rosdep

sudo rosdep init
rosdep update

ubantu18.04安装rose出现常见问题

ERROR:cannot download default sources list from:

https://raw.githubusercontent.com/ros/rosdistro/master/rosdep/sources.list.d/20-default.list

Website may be down
解决方法1
sudo gedit /etc/hosts
#在文件末尾添加
151.101.84.133 raw.githubusercontent.com
保存后

sudo rosdep init

解决方法2

sudo c_rehash /etc/ssl/certs
sudo -E rosdep init
rosdep update

如果还是出错更换清华源mirrors.tuna.tsinghua.edu.cn
网络切位手机热点

sudo apt update
rosdep update

出错
reading in sources list data from /etc/ros/rosdep/sources.list.d
ERROR: unable to process source [https://raw.githubusercontent.com/ros/rosdistro/master/rosdep/osx-homebrew.yaml]:

输入
sudo apt-get update

sudo apt-get install python-rosdep
  1. 设置环境变量
  2. echo "source /opt/ros/melodic/setup.bash" >> ~/.bashrc source ~/.bashrc

6 安装rosinstall,便利的工具

sudo apt install python-rosinstall python-rosinstall-generator python-wstool build-essential

  • 1
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值