Ros Learning-016 arduino-for-ros-001 Build a connected development environment between Arduino and Ros

Source: Internet
Author: User
Arduino for ROS-001 -build a development environment for the ROS and Arduino connections

My ubuntu system:ubuntu 14.04.10 TLS 32-bit
Arduino version:Arduino 1.6.11 Linux 32-bit
Ros version used:Ros Indigo one. Download and install the relevant software

Step 0. If you have not installed Ros Indigo This version of the Ros robot operating system on Ubuntu , please refer to this blog for installation: Ros Learning-001 install Ros Indigo

Step 1. The first thing to do is to download and install the Arduino IDE development environment. (Please see this blog)

two. Build the ROS connection Arduino IDE Development Environment

Step 2. Then install the Arduino related packages for your ROS environment:

sudo apt-get install-y ros-indigo-rosserial-arduino
sudo apt-get install-y ros-indigo-rosserial
three. Build Arduino IDE connection to ROS development Environment

Step 3. Then install ros_lib Library for your Arduino development environment.

1. Open a new terminal, start the ROS master node:

$ roscore

2. Reopen a terminal and switch the path to/opt/arduino-1.6.11/libraries/this path:

~$ cd/opt/arduino-1.6.11/libraries/

3. See if there is a Ros_lib folder under this path. If yes, remove it first (the command to delete is sudo rm-rf ros_lib). (We are not here.) There's no first outfit. )

4. Execute the following command. The goal is to generate a ros_lib library within this/opt/arduino-1.6.11/libraries path.
Note: This command is followed by a small dot ".", which means that the Ros_lib library is built again under the current path.

/opt/arduino-1.6.11/libraries$ 
rosrun Rosserial_arduino make_libraries.py.

(Before executing this command, you must first execute $ roscore in a terminal.) This you understand, I do not explain. )

5. After the execution, let's check to see if the Ros_lib folder was successfully generated:

If you see the current path, the new student becomes a ros_lib folder, the description is successful.

Step 4. Now you're starting the Arduino IDE Software

$arduino

done

Summary:

The two development environments, ROS and Arduino , are now connected.

In this way, under the ROS , the successful establishment of the Arduino development environment. Ros -related library functions have also been successfully added under the Arduino IDE .

Next, introduce a Hello World program to describe how this Arduino and ROS are used.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.