Arduino Workshop

Arduino Workshop

A Hands-On Introduction with 65 Projects
by John Boxall
May 2013, 392 pp.

Featured on Boing Boing (Read More)

Featured on Popular Mechanics (Read More)

The Arduino is a cheap, flexible, open source microcontroller platform designed to make it easy for hobbyists to use electronics in homemade projects. With an almost unlimited range of input and output add-ons, sensors, indicators, displays, motors, and more, the Arduino offers you countless ways to create devices that interact with the world around you.

In Arduino Workshop, you'll learn how these add-ons work and how to integrate them into your own projects. You'll start off with an overview of the Arduino system but quickly move on to coverage of various electronic components and concepts. Hands-on projects throughout the book reinforce what you've learned and show you how to apply that knowledge. As your understanding grows, the projects increase in complexity and sophistication.

Among the book's 65 projects are useful devices like:

  • A digital thermometer that charts temperature changes on an LCD
  • A GPS logger that records data from your travels, which can be displayed on Google Maps
  • A handy tester that lets you check the voltage of any single-cell battery
  • A keypad-controlled lock that requires a secret code to open

You'll also learn to build Arduino toys and games like:

  • An electronic version of the classic six-sided die
  • A binary quiz game that challenges your number conversion skills
  • A motorized remote control tank with collision detection to keep it from crashing

Arduino Workshop will teach you the tricks and design principles of a master craftsman. Whatever your skill level, you'll have fun as you learn to harness the power of the Arduino for your own DIY projects.

Uses the Arduino Uno board

Author Bio 

John Boxall has been writing Arduino tutorials, projects, and kit and accessory reviews for several years at Arduino Workshop is his first book.

Table of contents 

Chapter 1: Getting Started
Chapter 2: Exploring the Arduino Board and the IDE
Chapter 3: First Steps
Chapter 4: Building Blocks (PDF)
Chapter 5: Working with Functions
Chapter 6: Numbers, Variables, and Arithmetic
Chapter 7: Liquid Crystal Displays
Chapter 8: Expanding Your Arduino
Chapter 9: Numeric Keypads
Chapter 10: Accepting User Input with Touchscreens
Chapter 11: Meet the Arduino Family
Chapter 12: Motors and Movement
Chapter 13: Using GPS with Your Arduino
Chapter 14: Wireless Data
Chapter 15: Infrared Remote Control
Chapter 16: Reading RFID Tags
Chapter 17: Data Buses
Chapter 18: Real-time Clocks
Chapter 19: The Internet
Chapter 20: Cellular Communications

View the Index (PDF)
View the detailed Table of Contents (PDF)


"When it comes to technology, there's really something to be said for learning by example, and with each key point focused around a specific project, the information in this book is easy to learn and retain."
Dave Rankin, Open Source (Read More)

"Arduino Workshop was the first book I’ve read that helped me really make sense of the practical applications the Arduino is capable of." (Read More)

"A very thorough primer for those wishing to jump on the [Arduino] bandwagon."
Kevin Wierzbicki, Campus Circle (Read More)

"I’ve checked out several Arduino “primers,” and found the best one for my purposes to be Arduino Workshop: A Hands-On Introduction with 65 Projects by John Boxall."
Jeff Rowe, Blog (Read More)


Page 6:
Two suppliers to add to the list are:

Altronics (
Jaycar (

Page 13:
The first sentence on the page should read, "Copy the folder named arduino-1.0.5-windows (or something similar)..."

Page 27:
The first sentence on the page should read, "At the bottom right of the message area, you should see the name of your Arduino board type as well as its connected USB port- Arduino Uno on COM4 in this case."

Page 67:
The text for section 3 should read, “Connect one wire from the Arduino 5 V pin to the leftmost vertical column on the breadboard, and connect another wire from the Arduino GND pin to the vertical row to the right of the 5 V column, and another horizontal wire between the vertical GND column and the bottom-left pin of the button, as shown in Figure 4-22.”

Page 75:
In Figure 4-26, there should be a ground connection on the line that connects R7 with R8. Please see the following image for the correct figure:

Correction for page 75, figure 4-26

Page 76:
In the sketch for Project 5, the first line of code which reads "#define westButton 7" should instead read "#define westButton 3".

Page 85:
In the formula in the middle of the page, "R3" should instead read "R2".

Page 87:
At the bottom of the page, the text that reads "When alternating current is applied..." should instead read “When a pulsed current is applied..."

Page 121:
In the block of code at the top of the page, the line which reads "shiftOut(DATA, CLOCK, MSBFIRST, a);" should instead read "shiftOut(DATA, CLOCK, MSBFIRST, i);"

Page 133:
The bolded segment in the following text should be added to the sketch for program 19:

// Project 19 - Controlling Two Seven-Segment LED Display Modules
// set up the array with the segments for 0 to 9, A to F (from Table 6-2)

#define DATA 6 // connect to pin 14 on the 74HC595
#define LATCH 8 // connect to pin 12 on the 74HC595
#define CLOCK 10 // connect to pin 11 on the 74HC595

void setup()
pinMode(DATA, OUTPUT);

int digits[] = {
252, 96, 218, 242, 102, 182, 190, 224, 254, 246, 238, 62, 156, 122, 158, 142};
void displayNumber(int n)
int left, right=0;
if (n {
digitalWrite(LATCH, LOW);
shiftOut(DATA, CLOCK, LSBFIRST, digits[n]);
digitalWrite(LATCH, HIGH);
else if (n >= 10)
right = n % 10; // remainder of dividing the number to display by 10
left = n / 10; // quotient of dividing the number to display by 10
digitalWrite(LATCH, LOW);
shiftOut(DATA, CLOCK, LSBFIRST, digits[right]);
shiftOut(DATA, CLOCK, LSBFIRST, digits[left]);
digitalWrite(LATCH, HIGH);
void loop()
int i;
for ( i = 0 ; i {

Page 135:
The description under the heading "LED Matrix Display Modules" should also include that this specific LED matrix module is a common-cathode display.

Page 145:
In Project 23, the lines of code which read:
shiftOut(DATA, CLOCK, MSBFIRST, ~smile[a]); // columns
shiftOut(DATA, CLOCK, MSBFIRST, binary[a]); // rows

Should instead read:
shiftOut(DATA, CLOCK, MSBFIRST, ~smile[i]); // columns
shiftOut(DATA, CLOCK, LSBFIRST, binary[i]); // rows

Page 153:

In the last line of the code of the sketch for Project 25, "lcd.write(0);" should instead read "lcd.write(byte(0));"

Page 192:
The first line of code on the page which reads "if (attempt[q]==PIN[q])" should instead read "if (attempt[i]==PIN[i])"

Page 210:
The heading that reads "Atmel ATmega328-PU Microcontroller IC" should instead read “Atmel ATmega328P-PU Microcontroller IC". The same change can be made for every instance of "ATmega328” or "ATmega328P” in this project, which should instead read "ATmega328P-PU".

Page 235:
The Pololu RP5 has been discontinued, however the Dagu Rover 5 is an ideal replacement - for example:"

Page 260:
In the block of code for Listing 13-1, the line which reads "byte a" should instead read "byte a;"

Page 345:
Ignore the note which states that teleduino only works with an ATmega328 microcontroller. It now works on all microcontrollers.