Book Image

BeagleBone By Example

By : Pei JIA, Jayakarthigeyan Prabakar, Alexander Hiam
Book Image

BeagleBone By Example

By: Pei JIA, Jayakarthigeyan Prabakar, Alexander Hiam

Overview of this book

BeagleBone is a low cost, community-supported development platform to develop a variety of electronic projects. This book will introduce you to BeagleBone and get you building fun, cool, and innovative projects with it. Start with the specifications of BeagleBone Black and its operating systems, then get to grips with the GPIOs available in BeagleBone Black. Work through four types of exciting projects: building real-time physical computing systems, home automation, image processing for a security system, and building your own tele-controlled robot and learn the fundamentals of a variety of projects in a single book. By the end of this book, you will be able to write code for BeagleBone in order to operate hardware and impart decision-making capabilities with the help of efficient coding in Python.
Table of Contents (17 chapters)
BeagleBone By Example
Credits
About the Author
About the Reviewer
www.PacktPub.com
Preface
Index

GPIOs


As we discussed in Chapter 1, Getting Started with BeagleBone, BeagleBone boards have GPIO pin headers on either side of the board. In this section, we will be discussing what these GPIOs are and how we can use them to interface external electronic components to the board.

The following figure shows the GPIOs available and the pin mapping of each of them. This pin mapping or, in general, the names assigned to these pins will be helpful for us while accessing them from the software running on the operating system. You will see this in detail at the end of the chapter, when we will be accessing the GPIO from python:

So, these GPIOs are ports which can act either as input or output from our definition from software running on the operating system. There are several methods to define these pins as input and output, as well as to change the state of these pins when defined as outputs and read the state when defined as inputs. In this book, as we will be using python as the primary programming...