原文http://www.ros.org/wiki/ROS/Tutorials/InstallingandConfiguringROSEnvironment
1.安装ROS
(1)选择你的系统平台
http://www.ros.org/wiki/ROS/Installation
ROS对ubuntu支持最好,而本人习惯在ubuntu环境下工作,所以下面就以ubuntu上的安装为例.
(2) 在Ubuntu上安装ROS Groovy(此处安装的是ROS的Groovy版本)
1)配置好ROS的源,修改sources.list
选择对应的版本
-
Ubuntu 11.10 (Oneiric)
-
sudo sh -c 'echo "deb http://packages.ros.org/ros/ubuntu oneiric main" > /etc/apt/sources.list.d/ros-latest.list'
Ubuntu 12.04 (Precise)
-
sudo sh -c 'echo "deb http://packages.ros.org/ros/ubuntu precise main" > /etc/apt/sources.list.d/ros-latest.list'
Ubuntu 12.10 (Quantal)
-
sudo sh -c 'echo "deb http://packages.ros.org/ros/ubuntu quantal main" > /etc/apt/sources.list.d/ros-latest.list'
-
-
wget http://packages.ros.org/ros.key -O - | sudo apt-key add -
3)安装
-
sudo apt-get update
-
可以分别选择合适的ROS库和工具安装.
Desktop-Full Install: (Recommended) : ROS, rqt, rviz, robot-generic libraries, 2D/3D simulators, navigation and 2D/3D perception(桌面版全安装)
-
sudo apt-get install ros-groovy-desktop-full
or click here
Desktop Install: ROS, rqt, rviz, and robot-generic libraries(精简桌面版安装)
-
sudo apt-get install ros-groovy-desktop
or click here
ROS-Base: (Bare Bones) ROS package, build, and communication libraries. No GUI tools.(基本安装,包括ROS包,build工具和通信库,缺GUI工具)
-
sudo apt-get install ros-groovy-ros-base
or click here
Individual Package: You can also install a specific ROS package (replace underscores with dashes of the package name):(指定独立的ROS包安装)
-
sudo apt-get install ros-groovy-PACKAGE
e.g.sudo apt-get install ros-groovy-slam-gmapping
-
查找可用的包,可以用如下指令:
apt-cache search ros-groovy4) 初始化rosdep
使用ROS之前,需要初始化rosdpe.rosdep能使你在编译和运行某些ros核心组件的时候容易从源处安装系统依赖.
sudo rosdep init rosdep update
启动新的shell的时候,自动加载ROS的环境变量
source /opt/ros/groovy/setup.bash
6)安装rosinstall工具
rosinstall 是一个方便从ROS源下载的工具
sudo apt-get install python-rosinstall