Chapter 8

Experimenting with BoneScript

In This Chapter

arrow Discovering how to interact with your circuits

arrow Adjusting the brightness of an RGB LED

arrow Moving a servomotor with a potentiometer

arrow Detecting whether someone entered your room

The more you know about BoneScript, the easier it gets to see the endless possibilities for playing around with this programming language. This chapter shows you how to turn on a light by pressing a pushbutton, how to control a motor’s rotation through the use of a potentiometer, and how to automatically turn on a light that warns you that someone has entered a room.

At first glance, all the projects in this chapter may seem straightforward and simple, just as most of the electronic devices you engage with are. For example, on a daily basis you encounter things that have buttons, knobs, and sensors that control some output. This chapter walks you through the most basic, yet most important, functions that BoneScript offers. Later, you’ll be able to incorporate the building blocks presented in this chapter into your own unique projects.

The instructions in ...

Get BeagleBone For Dummies now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.