Ubuntu16.04安装ROS 解决ImportError: No module named rospy的问题

注:本文转载自:https://www.douban.com/note/636790523/ (侵删)

安装过程简介:
1.安装Ubuntu双系统,参考链接http://www.jianshu.com/p/2eebd6ad284d
其中第7步EasyBCD引导Ubuntu,可以不执行。
2.根据网站安装教程安装,http://wiki.ros.org/cn/indigo/Installation/Ubuntu
遇到的第一个问题是在执行命令
$ sudo apt-get install ros-indigo-desktop-full

安装ROS 时,提示错误

E: Unable to locate package ros-indigo-desktop

原因是:我按装的Ubuntu是16.04版本,不支持ros indigo,只能安装ros kinetic版本
执行命令

 $ sudo apt-get install ros-kinetic-desktop-full

即可。
3。在进行$ rosdep update时,出现错误
“reading in sources list data from /etc/ros/rosdep/sources.list.d
Hit https://raw.githubusercontent.com/ros/rosdistro/master/rosdep/osx-homebrew.yaml
Hit https://raw.githubusercontent.com/ros/rosdistro/master/rosdep/base.yaml
Hit https://raw.githubusercontent.com/ros/rosdistro/master/rosdep/python.yaml
Hit 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.yaml
Add distro “groovy”
ERROR: error loading sources list:
(‘The read operation timed out’,)”
解决办法参考链接:
https://answers.ros.org/question/247285/rosdep-update-errorthe-read-operation-timed-out/
这行命令是什么意思还不清楚,$ wget http://repositories.ros.org/rosdistro_cache/hydro-cache.yaml.gz,问题的根本原因是什么也不清楚,先依葫芦画瓢。
4。不知道操作了什么,每次打开Terminal,都会出现

bash: /opt/ros/indigo/setup.bash: No such file or directory
虽然不影响ros的正常运行,但是很很烦,影响心情,搜索解决办法,参考链接https://answers.ros.org/question/253480/bash-optroskineticsetupbash-no-such-file-or-directory/
打开根目录,ctrl+h显示隐藏文件,用gedit 打开.bashrc,找到bash: /opt/ros/indigo/setup.bash这行代码,删掉保存,done! feel very good!
5.更改Host name ,参考链接http://www.linuxidc.com/Linux/2013-11/92216.htm
大概过程是,用命令sudo gedit /etc/hostname,打开hostname文件,接下来,无论旧的计算机名字是什么,换一个新的吧。例如,我改为“Great”,先删除文件内容,输入 Great,然后保存文件。
然后,再输入下列命令来打开hosts文件,sudo gedit /etc/hosts
更改原来的名称,完成后保存文件。done!
今天学会了不少新技能

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

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值