diff --git a/docs/en/ros-install.md b/docs/en/ros-install.md new file mode 100644 index 00000000..542261a5 --- /dev/null +++ b/docs/en/ros-install.md @@ -0,0 +1,66 @@ +# ROS Kinetic package installation and setup + +In order to use tools such as rqt, rviz and others as well as running the simulator (SITL), you will need to install and setup ROS package + +> **Hint** For more details on installation refer to [the main article](http://wiki.ros.org/kinetic/Installation/Ubuntu). + + + +> **Hint** If you are using Ubuntu 18.04, you will need to install ROS Melodic instead of ROS Kinetic. A complete guide of the installation is available [here](http://wiki.ros.org/melodic/Installation/Ubuntu). + +## ROS Kinetic installation on Ubuntu + +To find the correct package version, you will need to change the settings of your repositories. Go to "Software and updates" and enable `restricted`, `universe` and `multiverse`. + +Set up your system so that software form `packages.ros.org` can be installed : + +```bash +sudo sh -c 'echo "deb http://packages.ros.org/ros/ubuntu $(lsb_release -sc) main" > /etc/apt/sources.list.d/ros-latest.list' +``` + +Configure access keys in your system for correct download: + +```bash +sudo apt-key adv --keyserver hkp://ha.pool.sks-keyservers.net:80 --recv-key 421C365BD9FF1F717815A3895523BAEEB01FA116 +``` + +Make sure that your packages are up to date: + +```bash +sudo apt-get update +``` + +Now you can install the ROS package itself. + ++ If you plan to use ROS together with the simulator (also includes tools such as rqt, rviz and others): + + ```bash + sudo apt-get install ros-kinetic-desktop-full + ``` + ++ If you plan to use ROS exclusively for tools rqt, rviz etc.: + + ```bash + sudo apt-get install ros-kinetic-desktop + ``` + +After the package has installed, initialize `rosdep`. +Package `rosdep` will allow to easily install dependecies for the source files that you whish to compile. Running some essential components of ROS will as well require this package. + +```bash +sudo rosdep init +rosdep update +``` + +If you are not confortable with entering environment variables manually each time, you may configure it in a way that it add itself in your bash session on every new shell startup: + +```bash +echo "source /opt/ros/kinetic/setup.bash" >> ~/.bashrc +source ~/.bashrc +``` + +If you whish to install any additionnal packages for yout ROS Kinetic simply use: + +```bash +sudo apt-get install ros-kinetic-PACKAGE +``` diff --git a/docs/en/ros.md b/docs/en/ros.md index 5013a0e3..0c26ddfa 100644 --- a/docs/en/ros.md +++ b/docs/en/ros.md @@ -14,6 +14,8 @@ ROS is already installed on [the RPi image](microsd_images.md). To use ROS on a PC, we recommend using Ubuntu Linux (or a virtual machine such as Parallels Desktop Lite](https://itunes.apple.com/ru/app/parallels-desktop-lite/id1085114709?mt=12) or [VirtualBox](https://www.virtualbox.org)). +> **Note** For ROS Kinetic distribution, we recommend using Ubuntu 16.04. + Concepts --- @@ -23,9 +25,9 @@ Main article: http://wiki.ros.org/Nodes ROS node is a special program (usually written in Python or C++) that communicates with other nodes via ROS topics and ROS services. Dividing complex robotic systems into isolated nodes provides certain advantages: reduced coupling of the code, increases re-usability and reliability. -Many robotic libraries, and the driver are executed in the form of ROS-nodes. +Many robotic libraries and the drivers are executed in the form of ROS-nodes. -In order to turn an ordinary program into a ROS node, connect to it a `rospy` or `roscpp` library, and add the initialization code. +In order to turn an ordinary program into a ROS node, include a `rospy` or `roscpp` library, and insert the initialization code. An example of a ROS node in Python: @@ -43,7 +45,7 @@ Main article: http://wiki.ros.org/Topics A topic is a named data bus used by the nodes for exchanging messages. Any node can *post* a message in a random topic, and *subscribe* to an arbitrary topic. -An example of posting a message of type [`std_msgs/String`](http://docs.ros.org/api/std_msgs/html/msg/String.html) (line) in topic `/foo` in Python: +An example of [`std_msgs/String`](http://docs.ros.org/api/std_msgs/html/msg/String.html) (line) message type posting in topic `/foo` in Python: ```python from std_msgs.msg import String @@ -77,9 +79,9 @@ rostopic echo /mavros/state Main article: http://wiki.ros.org/Services -A service is an analogue to the function that can be called from one node, and processed in another one. The service has a name that is similar to the name of the topic, and 2 message types: request type and response type. +A service can be assimilated to the a function that can be called from one node, and processed in another one. The service has a name that is similar to the name of the topic, and 2 message types: request type and response type. -An example of invoking a ROS service from Python: +An example ROS service invoking from Python: ```python from clever.srv import GetTelemetry