1. Chapter 1 Getting Started
  2. Introduction
  3. Installing the Integrated Development Environment (IDE)
  4. Setting Up the Arduino Board
  5. Using the Integrated Development Environment (IDE) to Prepare an Arduino Sketch
  6. Uploading and Running the Blink Sketch
  7. Creating and Saving a Sketch
  8. Using Arduino
  9. Chapter 2 Making the Sketch Do Your Bidding
  10. Introduction
  11. Structuring an Arduino Program
  12. Using Simple Primitive Types (Variables)
  13. Using Floating-Point Numbers
  14. Working with Groups of Values
  15. Using Arduino String Functionality
  16. Using C Character Strings
  17. Splitting Comma-Separated Text into Groups
  18. Converting a Number to a String
  19. Converting a String to a Number
  20. Structuring Your Code into Functional Blocks
  21. Returning More Than One Value from a Function
  22. Taking Actions Based on Conditions
  23. Repeating a Sequence of Statements
  24. Repeating Statements with a Counter
  25. Breaking Out of Loops
  26. Taking a Variety of Actions Based on a Single Variable
  27. Comparing Character and Numeric Values
  28. Comparing Strings
  29. Performing Logical Comparisons
  30. Performing Bitwise Operations
  31. Combining Operations and Assignment
  32. Chapter 3 Using Mathematical Operators
  33. Introduction
  34. Adding, Subtracting, Multiplying, and Dividing
  35. Incrementing and Decrementing Values
  36. Finding the Remainder After Dividing Two Values
  37. Determining the Absolute Value
  38. Constraining a Number to a Range of Values
  39. Finding the Minimum or Maximum of Some Values
  40. Raising a Number to a Power
  41. Taking the Square Root
  42. Rounding Floating-Point Numbers Up and Down
  43. Using Trigonometric Functions
  44. Generating Random Numbers
  45. Setting and Reading Bits
  46. Shifting Bits
  47. Extracting High and Low Bytes in an int or long
  48. Forming an int or long from High and Low Bytes
  49. Chapter 4 Serial Communications
  50. Introduction
  51. Sending Debug Information from Arduino to Your Computer
  52. Sending Formatted Text and Numeric Data from Arduino
  53. Receiving Serial Data in Arduino
  54. Sending Multiple Text Fields from Arduino in a Single Message
  55. Receiving Multiple Text Fields in a Single Message in Arduino
  56. Sending Binary Data from Arduino
  57. Receiving Binary Data from Arduino on a Computer
  58. Sending Binary Values from Processing to Arduino
  59. Sending the Value of Multiple Arduino Pins
  60. How to Move the Mouse Cursor on a PC or Mac
  61. Controlling Google Earth Using Arduino
  62. Logging Arduino Data to a File on Your Computer
  63. Sending Data to Two Serial Devices at the Same Time
  64. Receiving Serial Data from Two Devices at the Same Time
  65. Setting Up Processing on Your Computer to Send and Receive Serial Data
  66. Chapter 5 Simple Digital and Analog Input
  67. Introduction
  68. Using a Switch
  69. Using a Switch Without External Resistors
  70. Reliably Detecting the Closing of a Switch
  71. Determining How Long a Switch Is Pressed
  72. Reading a Keypad
  73. Reading Analog Values
  74. Changing the Range of Values
  75. Reading More Than Six Analog Inputs
  76. Displaying Voltages Up to 5V
  77. Responding to Changes in Voltage
  78. Measuring Voltages More Than 5V (Voltage Dividers)
  79. Chapter 6 Getting Input from Sensors
  80. Introduction
  81. Detecting Movement
  82. Detecting Light
  83. Detecting Motion (Integrating Passive Infrared Detectors)
  84. Measuring Distance
  85. Measuring Distance Accurately
  86. Detecting Vibration
  87. Detecting Sound
  88. Measuring Temperature
  89. Reading RFID Tags
  90. Tracking the Movement of a Dial
  91. Tracking the Movement of More Than One Rotary Encoder
  92. Tracking the Movement of a Dial in a Busy Sketch
  93. Using a Mouse
  94. Getting Location from a GPS
  95. Detecting Rotation Using a Gyroscope
  96. Detecting Direction
  97. Getting Input from a Game Control Pad (PlayStation)
  98. Reading Acceleration
  99. Chapter 7 Visual Output
  100. Introduction
  101. Connecting and Using LEDs
  102. Adjusting the Brightness of an LED
  103. Driving High-Power LEDs
  104. Adjusting the Color of an LED
  105. Sequencing Multiple LEDs: Creating a Bar Graph
  106. Sequencing Multiple LEDs: Making a Chase Sequence (Knight Rider)
  107. Controlling an LED Matrix Using Multiplexing
  108. Displaying Images on an LED Matrix
  109. Controlling a Matrix of LEDs: Charlieplexing
  110. Driving a 7-Segment LED Display
  111. Driving Multidigit, 7-Segment LED Displays: Multiplexing
  112. Driving Multidigit, 7-Segment LED Displays Using MAX7221 Shift Registers
  113. Controlling an Array of LEDs by Using MAX72xx Shift Registers
  114. Increasing the Number of Analog Outputs Using PWM Extender Chips (TLC5940)
  115. Using an Analog Panel Meter As a Display
  116. Chapter 8 Physical Output
  117. Introduction
  118. Controlling the Position of a Servo
  119. Controlling One or Two Servos with a Potentiometer or Sensor
  120. Controlling the Speed of Continuous Rotation Servos
  121. Controlling Servos from the Serial Port
  122. Driving a Brushless Motor (Using a Hobby Speed Controller)
  123. Controlling Solenoids and Relays
  124. Making an Object Vibrate
  125. Driving a Brushed Motor Using a Transistor
  126. Controlling the Direction of a Brushed Motor with an H-Bridge
  127. Controlling the Direction and Speed of a Brushed Motor with an H-Bridge
  128. Using Sensors to Control the Direction and Speed of Brushed Motors (L293 H-Bridge)
  129. Driving a Bipolar Stepper Motor
  130. Driving a Bipolar Stepper Motor (Using the EasyDriver Board)
  131. Driving a Unipolar Stepper Motor (ULN2003A)
  132. Chapter 9 Audio Output
  133. Introduction
  134. Playing Tones
  135. Playing a Simple Melody
  136. Generating More Than One Simultaneous Tone
  137. Generating Audio Tones and Fading an LED
  138. Playing a WAV File
  139. Controlling MIDI
  140. Making an Audio Synthesizer
  141. Chapter 10 Remotely Controlling External Devices
  142. Introduction
  143. Responding to an Infrared Remote Control
  144. Decoding Infrared Remote Control Signals
  145. Imitating Remote Control Signals
  146. Controlling a Digital Camera
  147. Controlling AC Devices by Hacking a Remote Controlled Switch
  148. Chapter 11 Using Displays
  149. Introduction
  150. Connecting and Using a Text LCD Display
  151. Formatting Text
  152. Turning the Cursor and Display On or Off
  153. Scrolling Text
  154. Displaying Special Symbols
  155. Creating Custom Characters
  156. Displaying Symbols Larger Than a Single Character
  157. Displaying Pixels Smaller Than a Single Character
  158. Connecting and Using a Graphical LCD Display
  159. Creating Bitmaps for Use with a Graphical Display
  160. Displaying Text on a TV
  161. Chapter 12 Using Time and Dates
  162. Introduction
  163. Creating Delays
  164. Using millis to Determine Duration
  165. More Precisely Measuring the Duration of a Pulse
  166. Using Arduino As a Clock
  167. Creating an Alarm to Periodically Call a Function
  168. Using a Real-Time Clock
  169. Chapter 13 Communicating Using I2C and SPI
  170. Introduction
  171. Controlling an RGB LED Using the BlinkM Module
  172. Using the WiiNunchuck Accelerometer
  173. Interfacing to an External Real-Time Clock
  174. Adding External EEPROM Memory
  175. Reading Temperature with a Digital Thermometer
  176. Driving Four 7-Segment LEDs Using Only Two Wires
  177. Integrating an I2C Port Expander
  178. Driving Multidigit, 7-Segment Displays Using SPI
  179. Communicating Between Two or More Arduino Boards
  180. Chapter 14 Wireless Communication
  181. Introduction
  182. Sending Messages Using Low-Cost Wireless Modules
  183. Connecting Arduino to a ZigBee or 802.15.4 Network
  184. Sending a Message to a Particular XBee
  185. Sending Sensor Data Between XBees
  186. Activating an Actuator Connected to an XBee
  187. Chapter 15 Ethernet and Networking
  188. Introduction
  189. Setting Up the Ethernet Shield
  190. Obtaining Your IP Address Automatically
  191. Resolving Hostnames to IP Addresses (DNS)
  192. Requesting Data from a Web Server
  193. Requesting Data from a Web Server Using XML
  194. Setting Up an Arduino to Be a Web Server
  195. Handling Incoming Web Requests
  196. Handling Incoming Requests for Specific Pages
  197. Using HTML to Format Web Server Responses
  198. Serving Web Pages Using Forms (POST)
  199. Serving Web Pages Containing Large Amounts of Data
  200. Sending Twitter Messages
  201. Sending and Receiving Simple Messages (UDP)
  202. Getting the Time from an Internet Time Server
  203. Monitoring Pachube Feeds
  204. Sending Information to Pachube
  205. Chapter 16 Using, Modifying, and Creating Libraries
  206. Introduction
  207. Using the Built-in Libraries
  208. Installing Third-Party Libraries
  209. Modifying a Library
  210. Creating Your Own Library
  211. Creating a Library That Uses Other Libraries
  212. Chapter 17 Advanced Coding and Memory Handling
  213. Introduction
  214. Understanding the Arduino Build Process
  215. Determining the Amount of Free and Used RAM
  216. Storing and Retrieving Numeric Values in Program Memory
  217. Storing and Retrieving Strings in Program Memory
  218. Using #define and const Instead of Integers
  219. Using Conditional Compilations
  220. Chapter 18 Using the Controller Chip Hardware
  221. Introduction
  222. Storing Data in Permanent EEPROM Memory
  223. Using Hardware Interrupts
  224. Setting Timer Duration
  225. Setting Timer Pulse Width and Duration
  226. Creating a Pulse Generator
  227. Changing a Timer’s PWM Frequency
  228. Counting Pulses
  229. Measuring Pulses More Accurately
  230. Measuring Analog Values Quickly
  231. Reducing Battery Drain
  232. Setting Digital Pins Quickly
  1. Appendix Electronic Components
  2. Capacitor
  3. Diode
  4. Integrated Circuit
  5. Keypad
  6. LED
  7. Motor (DC)
  8. Optocoupler
  9. Photocell (Photoresistor)
  10. Piezo
  11. Pot (Potentiometer)
  12. Relay
  13. Resistor
  14. Solenoid
  15. Speaker
  16. Stepper Motor
  17. Switch
  18. Transistor
  19. See Also
  20. Appendix Using Schematic Diagrams and Data Sheets
  21. How to Read a Data Sheet
  22. Choosing and Using Transistors for Switching
  23. Appendix Building and Connecting the Circuit
  24. Using a Breadboard
  25. Connecting and Using External Power Supplies and Batteries
  26. Using Capacitors for Decoupling
  27. Using Snubber Diodes with Inductive Loads
  28. Working with AC Line Voltages
  29. Appendix Tips on Troubleshooting Software Problems
  30. Code That Won’t Compile
  31. Code That Compiles but Does Not Work As Expected
  32. Troubleshooting Interrelated Hardware/Software Problems
  33. Appendix Tips on Troubleshooting Hardware Problems
  34. Still Stuck?
  35. Appendix Digital and Analog Pins
  36. Appendix ASCII and Extended Character Sets

Colophon