You are previewing Learning BeagleBone.
O'Reilly logo
Learning BeagleBone

Book Description

Learn how to love and care for your BeagleBone and teach it tricks

In Detail

The BeagleBone is a microboard computer that offers all the possibilities of a larger PC in a miniaturized package. By learning embedded Linux for the BeagleBone, you can get started on the road to utilizing the power of the board to achieve its full potential.

This book covers right from unboxing, showing you the absolute basics of using your new BeagleBone to give you the knowledge you need to be a responsible BeagleBone owner and to integrate the microboard into your projects. Begin by learning about the software behind your purchase before moving on to your first simple project on building an LED flasher using the LEDs on the BeagleBone itself.

Get to grips with connecting and controlling your BeagleBone from a mobile device, practical guidance on hooking up simple hardware and toys to your BeagleBone, and troubleshooting tips on what to do when things go wrong.

Finally, learn the advanced topics such as real-time programming with the BeagleBone to get its full potential and connect it to expansion boards. By the end of the book, you'll know everything you need to get out and play!

What You Will Learn

  • Unbox, power up, and configure the BeagleBone with Linux
  • Hook up and interface the BeagleBone to a desktop
  • Develop software to interact with the outside world
  • Build and control LED flash patterns
  • Run Linux-based software on the BeagleBone
  • Get familiar with entire boot procedures from power on to running your own software
  • Expansion with your own cape/expansion board
  • Expand the BeagleBone for Bluetooth connectivity
  • Downloading the example code for this book. You can download the example code files for all Packt books you have purchased from your account at http://www.PacktPub.com. If you purchased this book elsewhere, you can visit http://www.PacktPub.com/support and register to have the files e-mailed directly to you.

    Table of Contents

    1. Learning BeagleBone
      1. Table of Contents
      2. Learning BeagleBone
      3. Credits
      4. About the Author
      5. About the Reviewers
      6. www.PacktPub.com
        1. Support files, eBooks, discount offers, and more
          1. Why subscribe?
          2. Free access for Packt account holders
      7. Preface
        1. What this book covers
        2. What you need for this book
        3. Who this book is for
        4. Conventions
        5. Reader feedback
        6. Customer support
          1. Downloading the color images of this book
          2. Errata
        7. Disclaimer
          1. Piracy
          2. Questions
      8. 1. Introducing the Beagle Boards
        1. The Beagle board family
        2. The Beagle boards
          1. BeagleBoard Classic
          2. BeagleBoard-xM
          3. BeagleBone
            1. BeagleBone White
            2. BeagleBone Black
        3. Summary of the Beagle board family
        4. Congratulations on selecting a BeagleBone board
        5. Unboxing and powering up your BeagleBone
        6. The Windows configuration
        7. The Linux configuration
        8. Useful PC software for your BeagleBone
        9. Accessing the BeagleBone
        10. Useful accessories
          1. The mains power adapter
          2. An SD card reader and microSD cards
            1. A serial debug cable
            2. A digital multimeter
            3. Using the DMM on the BBB
            4. Wireless interfacing accessories
        11. Summary
      9. 2. Software in the BeagleBone
        1. System software in the BeagleBone
        2. Distributions on the BeagleBone
          1. The Angström Linux distribution
          2. The Debian Linux distribution
        3. Installing a distribution in the BeagleBone
          1. Obtaining the image
            1. Windows users
            2. Linux users
          2. Writing the image
            1. Windows users
            2. Linux users
          3. Booting the image
          4. Flasher images
        4. Nonsystem software in the BeagleBone
        5. Summary
      10. 3. Building an LED Flasher
        1. Setting up a foundation for the exercises
          1. Selecting an editor
            1. Quick start with nano/pico
          2. Permissions
            1. Determining the current permission
              1. Meaning of the permissions field
            2. Converting permissions to the numeric form
            3. Setting up permissions
            4. Exercise format and notes
        2. Hello, World for the BeagleBone
          1. Exercise 1 – creating a Hello, World program
        3. Flashing the LEDs
          1. LEDs on the BeagleBone
          2. Exercise 2 – taking control of the LEDs
            1. Figuring out the LED controls
            2. Disconnecting the LEDs temporarily from the system
            3. Turning on an LED
        4. Using the controls in a program
          1. Exercise 3 – simple blinking
            1. Delays in the program
            2. Repeating things with loops
            3. Turning off an LED
              1. Blinking the LEDs
              2. Looking at the LEDs
            4. Troubleshooting
          2. Exercise 4 – advanced blinking
        5. Summary
      11. 4. Refining the LED Flasher
        1. The I2C bus
          1. Accessing I2C
          2. The I2C tools
          3. Exercise 1
        2. The I2C devices on the BeagleBone
          1. Exercise 2
        3. User interfaces
          1. Design
          2. Exercise 3
          3. Troubleshooting
        4. Loading your first web page
          1. Troubleshooting the BeagleBone web server access
          2. Exercise 4
            1. Shell variables
            2. Putting it all together
          3. Exercise 5
          4. Exercise 6
            1. Testing
            2. Troubleshooting
          5. Exercise 7
            1. Testing
        5. Summary
      12. 5. Connecting the BeagleBone to Mobile Devices
        1. Mobile devices
        2. Connectivity options
        3. Full network connection options
        4. Protocol-specific connectivity
        5. Mobile device connections
          1. Android devices
          2. iOS devices
        6. Carrier limitations
        7. Bluetooth wireless technology
          1. Bluetooth versions
          2. Bluetooth wireless connectivity
        8. Profiles
          1. Dial-up Networking
          2. Personal Area Network
        9. BLE options
        10. Near Field Communication and the BeagleBone
          1. The BeagleBone NFC expansion board options
            1. The BeagleBone NFC as a device
            2. The BeagleBone NFC with a fully featured controller
        11. Summary
      13. 6. Recovering from the Mistakes
        1. Symptoms of the mistakes
        2. Troubleshooting the BeagleBone
          1. Diagnosing with the help of LEDs
          2. Setting up the serial debug cable on the BBB
            1. Connecting to the serial port on the BeagleBone
          3. Troubleshooting with the serial port
            1. Troubleshooting with the BBB serial port
            2. Troubleshooting with the BBW serial port
          4. Evaluating the serial port output
            1. Simple serial port output
            2. Bootloader serial port output
            3. Linux serial output
            4. No serial output
          5. Advanced LED diagnostics
        3. Repairing the BeagleBone
        4. Summary
      14. 7. Interfacing with the BeagleBone
        1. Electrical engineering in a nutshell
          1. Electrical properties
            1. Serial and parallel circuits
          2. Measuring the electrical properties
            1. Voltage measurements
            2. Resistance measurements
            3. Current measurements
            4. BeagleBone voltages
        2. Expansion headers
        3. Transistors
          1. Bipolar transistors
            1. Example use of a bipolar transistor
          2. FETs or specifically MOSFETs
        4. Connecting LEDs to the BeagleBone
        5. Controlling relay with a BeagleBone
        6. Connecting switches to the BeagleBone
        7. I2C/SPI on the BeagleBone expansion connector
          1. Inter-Integrated Circuit
          2. Serial Peripheral Interface
        8. Summary
      15. 8. Advanced Software Topics
        1. The BeagleBone programming with the C and Linux APIs
          1. Building the BeagleBone applications with the Linux API
          2. Compiling the existing libraries on the BeagleBone
            1. Cross compiling software for the BeagleBone
          3. Examples of the BeagleBone C compilation
            1. Native BeagleBone compilation
            2. Cross compiling a program for the BeagleBone
        2. User space versus kernel space on the BeagleBone
        3. Kernel drivers on the BeagleBone
        4. Device trees on the BeagleBone
        5. Pinmuxing on the BeagleBone
        6. Figuring out the pinmux on the BeagleBone
        7. The BeagleBone and real-time performance
        8. Summary
      16. 9. Expansion Boards and Options
        1. The BeagleBone capes
          1. Capes on the BBB versus BBW
          2. Example capes
          3. Capes and software on the BeagleBone
        2. USB devices on the BeagleBone
          1. USB versus capes for expansion
          2. Custom hardware versus off-the-shelf hardware
        3. Summary
      17. A. The Boot Process
        1. What happens when the power is turned on
          1. Bootloader
          2. Flash memory/microSD
        2. Linux and beyond
        3. Alternative boot uses
        4. Summary
      18. B. Terms and Definitions
      19. Index