Book Image

Learning BeagleBone

By : Hunyue Yau
Book Image

Learning BeagleBone

By: Hunyue Yau

Overview of this book

Table of Contents (18 chapters)
Learning BeagleBone
About the Author
About the Reviewers
Terms and Definitions

Chapter 3. Building an LED Flasher

Now that we have a basic foundation of what's on the BeagleBone and how to install the basic system software on it, we will proceed to the basic exercises on the BeagleBone with minimal fear of corrupting the BeagleBone. We'll get our feet wet with classic introductory exercises but, first, we'll write a Hello, World exercise to familiarize ourselves with the basics and then build our own embedded product—an LED flasher. This will be done in small steps, each introducing a set of skills needed for the LED flasher.

In this chapter, we will cover the following topics:

  • Use a simple editor on the BeagleBone itself

  • File permissions (what they are and how to determine them numerically)

  • Set and examine file permissions

  • Use sysfs to control the LEDs

  • Read and write files using the shell language

  • Loop and create delays in the shell language

  • Debug shell scripts

  • Flash LEDs