Skip to Content
ROS Programming: Building Powerful Robots
book

ROS Programming: Building Powerful Robots

by Anil Mahtani, Luis Sanchez, Enrique Fernandez, Aaron Martinez, Lentin Joseph
March 2018
Intermediate to advanced content levelIntermediate to advanced
1396 pages
42h 14m
English
Packt Publishing
Content preview from ROS Programming: Building Powerful Robots

Controlling GPIO pins from ROS

In Arduino and other controller boards, what we have created a did was make a hardware ROS node. But RPi and Odroid are single-board computers, so we can run ROS on the board itself. We can run ROS on these two boards in three ways. We can run ROS on the same board, or we can run the ROS master on the board and connect other ROS nodes from the PC or make the PC the ROS master and make the board the client.

In this section, we are going to create a simple demo to blink an LED using ROS topics from the same board. To work with Raspberry Pi and Odroid, we have to use a library called wiringpi.

Here are the commands to install wiringpi on Raspberry Pi:

    $ git clone git clone git://git.drogon.net/wiringPi
    $ cd wiringPi ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Programming Robots with ROS

Programming Robots with ROS

Morgan Quigley, Brian Gerkey, William D. Smart
Machine Learning Design Patterns

Machine Learning Design Patterns

Valliappa Lakshmanan, Sara Robinson, Michael Munn

Publisher Resources

ISBN: 9781788627436Supplemental Content