Contents
Components List
........................................................................................................................................................
1
Get Started
................................................................................................................................................................
10
Arduino
.......................................................................................................................................................
10
Description
................................................................................................................................................
10
SunFounder Arduino Board
..................................................................................................................
10
Install Arduino IDE
....................................................................................................................................
11
Plug in the Board
.....................................................................................................................................
12
Add libraries
..............................................................................................................................................
12
Lesson 1 Display by I2C LCD1602
.......................................................................................................................
16
Lesson 2 Analog Hall Sensor
.................................................................................................................................
20
Lesson 3 Switch Hall Sensor
...................................................................................................................................
23
Lesson 4 Analog Temperature Sensor
...............................................................................................................
26
Lesson 5 Temperature Detection by Thermistor
.............................................................................................
29
Lesson 6 Auto-flash LED
.........................................................................................................................................
31
Lesson 7 Barometer BMP280
................................................................................................................................
33
Lesson 8 Real-time Clock Module
......................................................................................................................
37
Lesson 9 Flame Alarm
............................................................................................................................................
40
Lesson 10 Flammable Gas Detection
...............................................................................................................
43
Lesson 11 Humiture Detection
.............................................................................................................................
45
Lesson 12 Joystick PS2
............................................................................................................................................
48
Lesson 13 Controlling an LED by Button
...........................................................................................................
51
Lesson 14 Mercury Switch
.....................................................................................................................................
53
Lesson 15 Touch Switch
.........................................................................................................................................
55
Lesson 16 Photo-interrupter
..................................................................................................................................
58
Lesson 17 Photoswitch
...........................................................................................................................................
61
Lesson 18 Reed Switch
...........................................................................................................................................
64
Lesson 19 Relay
........................................................................................................................................................
67