您的位置:首页 > 其它

ROS操作系统ubuntu12.04下安装

2015-09-14 13:39 369 查看
ROS操作系统在ubuntu12.04下按照wiki官网的操作进行安装。:http://ros.org/wiki/fuerte/Installation/Ubuntu本人在安装过程中遇到了如下问题:1、打开shell命令行执行如下操作:$ sudo sh -c 'echo "deb http://packages.ros.org/ros/ubuntu precise main" > /etc/apt/sources.list.d/ros-latest.list'如果执行该命令出现了错误,就需要先配置sources.list 。该文件的目录为:/etc/apt/sources.list需要在other Software下面添加APT line。2、为软件源添加密码,在shell命令行下添加如下命令:
$ wget http://packages.ros.org/ros.key -O - | sudo apt-key add -

3、安装ROS fuerte 。但在安装之前需要先升级一下ROS可能要用到的程序,执行如下命令:
$ sudo apt-get update

4、安装组件,最简单的方法就是完整安装,将安装 ROS、 Rx 工具箱、 rviz 可视化环境( 3D)、通用机器人库、 2D(如 stage)和 3D(如 Gazebo)仿真环境、导航功能包集(移动、定位、地图绘制、路径规划、机械臂控制)和其他感知库如视觉、激光雷达和 RGB-D 摄像头:
$ sudo apt-get install ros-fuerte-desktop-full

当然可以参照官网给出的几种只安装特定功能的安装包形式进行安装。5、环境的配置:打开一个新的shell命令,输入: $ roscore如果出现错误,如:roscore: command not found
则说明需要配置环境。输入以下命令:
$ echo "source /opt/ros/fuerte/setup.bash" >> ~/.bashrc
$ . ~/.bashrc

$ source /opt/ros/fuerte/setup.bash

前两条命令是source /opt/fuerte/setuo.sh这条命令行写入.bashrc文件中,这样在下次系统启动时,会自动运行该命令行,不然下次启动时roscore命令将不起作用。这样环境配置就已经完成,要检验是否配置成功,只需要运行如下命令:$ roscore出现如下信息:........started roslaunch server http://ubuntu:37122/ ros_comm version 1.8.11SUMMARY
========PARAMETERS
* /rosdistro
* /rosversionNODESauto-starting new master
process[master]: started with pid [20272]
ROS_MASTER_URI=http://ubuntu:11311/setting /run_id to 90c2ccf0-5b7f-11e5-9cb6-000c29a7db68
process[rosout-1]: started with pid [20285]
started core service [/rosout]6、虽然系统已经完成,但 rosinstall 和 rosdep 这两个工具在编译过程中经常用到,因此推荐将这两个工具也进行安装。在shell中运行如下命令:
$ sudo apt-get install python-rosinstall python-rosdep



                                            
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: