树莓派3B+_Ubuntu Mate18.04_ROS Melodic(二):ROS Melodic的安装

详细的安装步骤请参考:
1、官网:Ubuntu install of ROS Melodic
2、Install ROS Melodic on Raspberry Pi 3
------------------------------------------------------------官方的为主,第二个为辅。

  1. 问题描述
    执行sudo rosdep init时,出现:rosdep command not found

解决办法:

sudo apt install python-rosdep python-rosinstall python-rosinstall-generator python-wstool build-essential
  1. 问题描述
$ sudo rosdep init
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.

以及

$ 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]:
     (https://raw.githubusercontent.com/ros/rosdistro/master/rosdep/osx-homebrew.yaml)
ERROR: unable to process source [https://raw.githubusercontent.com/ros/rosdistro/master/rosdep/base.yaml]:
     (https://raw.githubusercontent.com/ros/rosdistro/master/rosdep/base.yaml)
ERROR: unable to process source [https://raw.githubusercontent.com/ros/rosdistro/master/rosdep/python.yaml]:
     (https://raw.githubusercontent.com/ros/rosdistro/master/rosdep/python.yaml)
ERROR: unable to process source [https://raw.githubusercontent.com/ros/rosdistro/master/rosdep/ruby.yaml]:
     (https://raw.githubusercontent.com/ros/rosdistro/master/rosdep/ruby.yaml)
Hit https://raw.githubusercontent.com/ros/rosdistro/master/releases/fuerte.yaml
Query rosdistro index https://raw.githubusercontent.com/ros/rosdistro/master/index-v4.yaml
Add distro "ardent"
ERROR: error loading sources list:
     (https://raw.githubusercontent.com/ros/rosdistro/master/ardent/distribution.yaml)>

网上有很多种解释和解决办法,试了好几次都不成。X乎里有总结:ROS:sudo rosdep init出错常规方法都无效后解决办法记录。当然,某乎里的办法,我没试过,不知道结果会怎么样,也还没时间去仔细研究。

去搜了一下:。 然后,搜到这篇——ubuntu安装ROS进行到rosdep update时出现错误,如ERROR: unable to process source …

总结一下解决办法:

$ sudo gedit /etc/resolv.conf
->将原有的nameserver这一行注释,并添加以下两行:
nameserver 8.8.8.8 #google域名服务器
nameserver 8.8.4.4 #google域名服务器
保存退出,执行
$ sudo  apt-get update
然后再执行:
$ sudo rosdep init
$ rosdep update

--------------------------------------
如果出现:
$ sudo rosdep init
ERROR: default sources list file already exists:
/etc/ros/rosdep/sources.list.d/20-default.list
Please delete if you wish to re-initialize
解决办法:
执行以下命令,删除已经存在的初始化文件:
$ sudo rm /etc/ros/rosdep/sources.list.d/20-default.list
然后再重新运行
$ sudo rosdep init

此外,关于 “nameserver 8.8.8.8” 和 “nameserver 8.8.4.4” ,此处涉及DNS服务器问题。Linux上网时,很多时候会因为这个原因上不了网。上面这种是暂时修改DNS服务器,电脑重启后会失效。

参考:Linux 暂时和永久性修改DNS

  1. 问题描述
    待续…

你可能感兴趣的:(树莓派,raspberry-pi,ROS)