The book \"Arduino Advanced Development Authoritative Guide (Original Book 2nd Edition)\" written by Barrett is divided into two parts. The first part explains how to use Arduino for programming and further develop embedded systems; the second part explains the concepts of serial port communication, ADC, interrupts, timing, etc. of Arduino controller in a simple way, so that readers can have a deep understanding of Arduino\'s architecture. 1.1 Overview 1 1.2 Getting Started 1 1.3 Arduino UNO R3 3 1.4 Example: Autonomous Maze Navigation Robot 5 1.4.1 Structure Diagram 6 1.4.2 UML Activity Diagram 7 1.4.3 Arduino UNO R3 System 7 1.5 Arduino Open Source Schematic 7 1.6 Other Arduino-based Hardware Platforms 9 1.7 Expanding the Hardware Features of the Arduino Platform 9 1.8 Arduino Software 10 1.9 Arduino UNO R3/ATmega328 Chip Hardware Features 10 1.9.1 Memory Unit 12 1.9.2 Port System 12 1.9.3 Internal System 13 1.10 Application: Arduino Device Kit 16 1.11 Summary 17 1.12 References 17 1.13 Exercises 17 Chapter 2 Programming 18 2.1 Overview 18 2.2 2.3.1 Comments 21 2.3.2 Include files 21 2.3.3 Functions 22 2.3.4 Program constants 24 2.3.5 Interrupt handler definitions 24 2.3.6 Variables 24 2.3.7 Main program 25 2.4 Basic programming concepts 25 2.4.1 Operators 25 2.4.2 Programming structures 29 2.4.3 Decision making 30 2.5 Arduino development environment 32 2.5.1 Background 33 2.5.2 Introduction to the Arduino development environment 33 2.5.3 Sketchbook concept 34 2.5.4 Arduino software, libraries and Arduino language reference 34 2.6 Application 1: Robotic infrared distance sensor 36 2.7 Application 2: Artistic lighting system 39 2.8 Summary 39 2.9 References 40 2.10 Chapter Exercises 40 Chapter 3 Embedded System Design 41 3.1 What is an Embedded System 41 3.2 Embedded System Design Process 42 3.2.1 Project Description 42 3.2.2 Background Research 42 3.2.3 Preliminary Design 43 3.2.4 Design 43 3.2.5 Prototype 45 3.2.6 Preliminary Testing 45 3.2.7 Complete and Accurate Documentation 46 3.3 Case: Blinky 602A Autonomous Maze Navigation Robot System Design 46 3.4 Application: Blinky 602A Robot Control Algorithm 51 3.5 Summary 57 3.6 References 58 3.7 Chapter Exercises 58 Chapter 4 Serial Data Communication Subsystem 59 4.1 Overview 59 4.2 Serial Communication 59 4.3 Serial Communication Terminology 60 4.4 Serial USART 62 4.5 4.6 Serial System Operation and Functional Programming Using the Arduino Development Environment 68 4.7 SPI Programming in the Arduino Development Environment 71 4.8 SPI Programming in the C Development Environment 72 4.9 Two-Wire Serial Interface - TWI 73 4.10 Application 1: SD/MMC Card Module via USART Expansion 73 4.11 Application 2: Programming the ATmega328 Chip of the ArduinoUNO R3 Control Board via ISP 76 4.12 Summary 78 4.13 References 78 4.14 Exercises in this Chapter 78 Chapter 5 Analog-to-Digital Converter 79 5.1 Overview 79 5.2 Sampling, Quantization and Encoding 80 5.3 Analog-to-Digital Conversion Process 83 5.3.1 Transducer Interface Design Circuit 83 5.3.2 Operational Amplifier 85 5.4 Analog-to-Digital Conversion Technology 88 5.5 Atmel\'s ATmega328 Chip ADC System 89 5.5.1 Block Diagram 89 5.5.2 Registers 90 5.6 Programming the Analog-to-Digital Conversion Function Using the Arduino Development Environment 92 5.7 Programming the Analog-to-Digital Conversion Function Using the C Development Environment 92 5.8 Example: ADC Rain Gauge Indicator 93 5.8.1 ADC Rain Gauge Indicator (Using the Arduino Development Environment) 94 5.8.2 ADC Rain Gauge Indicator (Using the C Development Environment) 97 5.8.3 ADC Rain Gauge Indicator (Mixed Optimization of C Programming Based on the Arduino Development Environment) 102 5.9 One-Bit Analog-to-Digital Conversion (Threshold Detector) 103 5.10 Digital-to-Analog Converter (DAC) 105 5.10.1 Digital-to-Analog Converter (Using the Arduino Development Environment) 106 5.10.2 Digital-to-Analog Converter (External Converter) 106 5.11 Application: Artwork Lighting System - Optimization 107 5.12 Summary 109 5.13 6.1 Overview 112 6.2 ATmega328 Interrupt System 113 6.3 Interrupt Programming 113 6.4 Interrupt Programming Based on C Language and Arduino Development Environment 114 6.4.1 External Interrupt Programming 114 6.4.2 Internal Interrupt Programming 117 6.5 Foreground Processing and Background Processing 121 6.6 Interrupt Routines 121 6.6.1 Real-Time Clock in C Language 121 6.6.2 Real-Time Clock in Arduino Development Environment 123 6.6.3 USART Driven by C Language Interrupts 125 6.7 Summary 134 6.8 References 134 6.9 Exercises 134 Chapter 7 Timer Subsystem 136 7.1 Overview 136 7.2 Terminology Related to Timers 136 7.2.1 7.2.1 Timer 1 Registers 146 7.8 Timer 2 151 7.9 Programming the Arduino UNO R3 Board Using the Built-in Clock Functionality in the Arduino Development Environment 154 7.10 7.10.1 Precise Delay in C 154 7.10.2 PWM in C 156 7.10.3 Input Capture Mode in C 157 7.11 PWM System for Servo Motor Control Based on C 158 7.12 Summary 162 7.13 References 162 7.14 Exercises 163 Chapter 8 Operating Parameters and Interfaces of Atmel AVR Series Microcontrollers 164 8.1 Overview 164 8.2 Operating Parameters 165 8.3 Battery Power 167 8.3.1 Voltage and Current Consumption Specifications of Embedded Systems 167 8.3.2 Battery Characteristics 167 8.4 Input Devices 168 8.4.1 Switches 168 8.4.2 Pull-up Resistors in Switch Interface Circuits 169 8.4.3 Switch Debounce 169 8.4.4 Keyboards 170 8.4.5 Sensors 174 8.4.6 LM34 Temperature Sensor Example 176 8.5 Output Devices 176 8.5.1 Light Emitting Diodes 176 8.5.2 Seven-segment LED Display 176 8.5.3 Code Examples 178 8.5.4 Three-state LED Indicator 179 8.5.5 Dot Matrix Display 180 8.5.6 Programming LCD with C 182 8.5.7 Programming LCD with Arduino 188 8.5.8 High-power DC Devices 189 8.6 DC Solenoid Valve Control 189 8.7 DC Motor Speed and Direction Control 190 8.7.1 DC Motor Operating Parameters 191 8.7.2 H-bridge Direction Control 191 8.7.3 Servo Motor Interface 192 8.7.4 Stepper Motor Control 192 8.7.5 AC Devices 198 8.8 Driving Other Devices 199 8.8.1 Alarms and Buzzers 199 8.8.2 Vibration Motors 199 8.9 8.13 Extended Example 5: Weather Station 237 8.13.1 Requirements 237 8.13.2 Structure Diagram 238 8.13.3 Circuit Diagram 238 8.13.4 UML Activity Diagram 240 8.13.5 Microcontroller Program 241 8.14 Summary 248 8.15 References 248 8.16 Chapter Exercises 249 Appendix A ATmega328 Register Settings 252 Appendix B ATmega328 Header Files 256
You Might Like
Recommended ContentMore
Open source project More
Popular Components
Searched by Users
Just Take a LookMore
Trending Downloads
Trending ArticlesMore