6. Introduction to Programming

After you’ve wired up your Arduino, you still need to program it. This chapter provides a basic introduction to programming principles. You’ll check out the features of the Arduino development environment. Next, you’ll explore a basic Arduino sketch in detail, learning about its various functions and commands. This chapter also covers intermediate programming techniques, such as debugging and adapting code. Finally, we’ll add an ultrasonic sensor to our Cruiser robot (see Figure 6.1) and program it to react to an object that it detects.

Image

FIGURE 6.1 Adding an ultrasonic sensor to your Cruiser allows it to react to ...

Get Robot Builder: The Beginner’s Guide to Building Robots 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.