Book Image

BeagleBone Robotic Projects - Second Edition

By : Richard Grimmett
Book Image

BeagleBone Robotic Projects - Second Edition

By: Richard Grimmett

Overview of this book

BeagleBone Blue is effectively a small, light, cheap computer in a similar vein to Raspberry Pi and Arduino. It has all of the extensibility of today’s desktop machines, but without the bulk, expense, or noise. This project guide provides step-by-step instructions that enable anyone to use this new, low-cost platform in some fascinating robotics projects. By the time you are finished, your projects will be able to see, speak, listen, detect their surroundings, and move in a variety of amazing ways. The book begins with unpacking and powering up the components. This includes guidance on what to purchase and how to connect it all successfully, and a primer on programming the BeagleBone Blue. You will add additional software functionality available from the open source community, including making the system see using a webcam, hear using a microphone, and speak using a speaker. You will then learn to use the new hardware capability of the BeagleBone Blue to make your robots move, as well as discover how to add sonar sensors to avoid or find objects. Later, you will learn to remotely control your robot through iOS and Android devices. At the end of this book, you will see how to integrate all of these functionalities to work together, before developing the most impressive robotics projects: Drone and Submarine.
Table of Contents (18 chapters)
Title Page
Credits
Foreword
About the Author
About the Reviewers
www.PacktPub.com
Customer Feedback
Preface

Accessing the compass on the BeagleBone Blue


Your platform can move around, but if you are going to do some automated movement, you're going to want some of the additional information that the BeagleBone Blue can provide. This will come in the form of a compass direction that the built-in IMU can measure and return programmatically.

In order to access this information, you'll first need to run two different calibration programs. The first is rc_calibrate_mag and the second is rc_calibrate_gyro. When you run rc_calibrate_mag, it will direct you to move your platform around in as many ways as possible for 15 seconds. It will then use this date to calibrate the magnetic fields so that it can give a valid compass reading. The rc_calibrate_gyro program will also calibrate the gyros.

Then, you can try the test program for the compass by running the rc_test_imu program. This will show you readings from the gyros and the compass and verify that it is working correctly.

Once your compass is calibrated...