Preface |
|
vii | |
|
1 Getting Familiar with techBASIC and Built-in Sensors |
|
|
1 | (20) |
|
|
1 | (1) |
|
A Crash Course in techBASIC |
|
|
2 | (1) |
|
|
2 | (1) |
|
Running Your First Program |
|
|
3 | (2) |
|
|
5 | (3) |
|
|
8 | (13) |
|
2 Accessing the Other Built-in Sensors |
|
|
21 | (24) |
|
|
22 | (8) |
|
|
30 | (1) |
|
|
30 | (8) |
|
|
38 | (4) |
|
|
42 | (1) |
|
|
43 | (1) |
|
|
44 | (1) |
|
3 Creating a Metal Detector |
|
|
45 | (10) |
|
The iPhone/iPad Magnetometer |
|
|
45 | (1) |
|
The Earth's Magnetic Field |
|
|
46 | (2) |
|
Using the iPhone or iPad as a Metal Detector |
|
|
48 | (2) |
|
Converting the Magnetometer Sample into a Metal Detector |
|
|
50 | (2) |
|
|
52 | (2) |
|
|
54 | (1) |
|
|
55 | (18) |
|
|
55 | (2) |
|
|
57 | (4) |
|
External Power for HiJack |
|
|
61 | (2) |
|
|
63 | (2) |
|
|
65 | (1) |
|
|
65 | (6) |
|
|
71 | (2) |
|
5 Creating a Moisture Meter with HiJack |
|
|
73 | (20) |
|
Adding a Moisture Meter to the Tricorder |
|
|
73 | (1) |
|
Assembling the Moisture Meter |
|
|
74 | (1) |
|
|
75 | (1) |
|
Collecting the Calibration Data |
|
|
76 | (1) |
|
Moving Datafiles to and from techBASIC |
|
|
77 | (1) |
|
Using the Calibration Data |
|
|
78 | (3) |
|
|
81 | (8) |
|
The Complete Moisture Meter Source |
|
|
89 | (4) |
|
|
93 | (66) |
|
What Is Bluetooth Low Energy? |
|
|
93 | (2) |
|
|
95 | (2) |
|
Writing Bluetooth Low Energy Programs |
|
|
97 | (15) |
|
|
112 | (1) |
|
|
112 | (1) |
|
Accessing the Accelerometer |
|
|
113 | (2) |
|
|
115 | (2) |
|
|
117 | (4) |
|
|
121 | (1) |
|
|
121 | (5) |
|
|
126 | (4) |
|
|
130 | (1) |
|
|
130 | (3) |
|
|
133 | (1) |
|
|
133 | (4) |
|
|
137 | (1) |
|
Accessing the Magnetometer |
|
|
138 | (2) |
|
|
140 | (1) |
|
|
141 | (4) |
|
The Humidity Sensor (Hygrometer) |
|
|
145 | (1) |
|
|
145 | (2) |
|
|
147 | (4) |
|
|
151 | (1) |
|
Accessing the Thermometer |
|
|
151 | (3) |
|
|
154 | (1) |
|
|
154 | (4) |
|
|
158 | (1) |
|
7 Bluetooth Low Energy iPhone Rocket |
|
|
159 | (40) |
|
|
159 | (2) |
|
|
161 | (1) |
|
|
161 | (1) |
|
|
162 | (1) |
|
Other Items for Both Rockets |
|
|
163 | (1) |
|
|
164 | (1) |
|
|
164 | (1) |
|
ST-2: The iPhone/SensorTag Rocket |
|
|
164 | (7) |
|
ST-1: The SensorTag Rocket |
|
|
171 | (3) |
|
The Data Collection Program |
|
|
174 | (11) |
|
|
185 | (2) |
|
|
187 | (1) |
|
|
187 | (1) |
|
|
188 | (1) |
|
|
188 | (1) |
|
|
188 | (1) |
|
|
189 | (1) |
|
|
189 | (2) |
|
|
191 | (2) |
|
|
193 | (2) |
|
|
195 | (1) |
|
|
196 | (1) |
|
|
196 | (1) |
|
|
197 | (2) |
|
8 Hacking a Radio-Controlled Truck with Bluetooth Low Energy and Arduino |
|
|
199 | (42) |
|
Controlling a Truck with BLE |
|
|
200 | (2) |
|
|
202 | (1) |
|
|
202 | (5) |
|
|
207 | (1) |
|
|
207 | (2) |
|
|
209 | (2) |
|
Wiring the Complete Circuit |
|
|
211 | (8) |
|
Controlling the Arduino Uno |
|
|
219 | (1) |
|
|
219 | (2) |
|
|
221 | (4) |
|
|
225 | (1) |
|
|
225 | (2) |
|
|
227 | (12) |
|
|
239 | (2) |
|
9 Peer-to-Peer Bluetooth Low Energy |
|
|
241 | (14) |
|
Bluetooth Low Energy Slave Mode |
|
|
241 | (1) |
|
|
242 | (1) |
|
|
242 | (2) |
|
|
244 | (11) |
|
10 Paddles: A Bluetooth Pong Tribute |
|
|
255 | (20) |
|
|
255 | (1) |
|
|
256 | (2) |
|
|
258 | (4) |
|
The Paddles Console Software |
|
|
262 | (13) |
|
|
275 | (14) |
|
|
275 | (1) |
|
|
276 | (1) |
|
|
277 | (1) |
|
|
278 | (1) |
|
Establishing a Network Connection |
|
|
279 | (2) |
|
Communication with TCP/IP |
|
|
281 | (1) |
|
A Simple Terminal Program |
|
|
281 | (2) |
|
|
283 | (1) |
|
Loading Software onto the Arduino |
|
|
283 | (2) |
|
|
285 | (2) |
|
Communication Using the Terminal Program |
|
|
287 | (2) |
|
|
289 | (16) |
|
Servos: They're Where the Action Is |
|
|
289 | (2) |
|
The Pololu Serial Servo Controller |
|
|
291 | (3) |
|
|
294 | (1) |
|
|
295 | (1) |
|
|
295 | (5) |
|
|
300 | (1) |
|
Push and Pull with Servos |
|
|
300 | (3) |
|
|
303 | (2) |
Index |
|
305 | |