c076dd9df6cf04827988b71e67538b56f21c7c30
[challenge-bot] / curriculum / challenge-bot.scm
1 ;; tldr; AGPLv3+
2 ;; copyright info at bottom
3
4 (document
5 :title [challenge-bot]
6 (chapter
7 :title [mechanical]
8 (section
9 :title [arduino to deck]
10 (subsection
11 :title [required materials]
12 (p [you will need the things in this picture.
13 ,(figure :legend "arduino to deck / required materials"
14 (image :file "arduino-to-deck/0-required-materials.png"))
15 ,(itemize
16 (item [medical kit with bandages])
17 (item [safety goggles])
18 (item [drill bit \(we will determine size in a moment\)])
19 (item [drill])
20 (item [alan wrench])
21 (item [wood block])
22 (item [arduino])
23 (item [#6-32x3/8\", four of them]))]))
24 (subsection
25 :title [first hole]
26 (subsubsection
27 :title [choosing drill bit]
28 (p [choosing the right drill bit depends on what job you are doing.
29 right now, we are making holes for screws to hold the
30 arduino to the deck.
31 this means the hole needs to be big enough for the
32 screw body to fit through.
33 we want the screw to stay put once it's in place.
34 we also want the drill bit to be smaller than the
35 diameter of the thread.
36 the screw was chosen so that the hole on the arduino
37 was bigger than the body and smaller than the thread.
38 we will choose the biggest drill bit that fits through
39 the hole on the arduino.])
40 (p [here's a cross section of a screw in the deck]
41 (figure :legend "screw cross section"
42 (image :file
43 "arduino-to-deck/screw-cross-section.png"))))
44 (subsubsection
45 :title [inserting drill bit]
46 (p (figure :legend "arduino to deck / insert bit"
47 (image :file "arduino-to-deck/1-insert-bit.png"))
48 [insert the drill bit into the teeth of the drill.
49 insert it far enough that the teeth will clamp on the
50 smooth part of the bit when they are tightened.])
51 (p (figure
52 :legend "arduino to deck / twist tighten drill teeth"
53 (image :file "arduino-to-deck/2-twist-tighten-drill-teeth.png"))
54 [while holding the drill bit, twist end of the drill to tighten
55 the teeth.
56 make sure that the teeth end up gripping the flat part of
57 the drill bit.]))
58 (subsubsection
59 :title [holding drill]
60 (p [hold the drill with one hand on the handle and trigger.
61 put the other hand on the orange nozzle, before the
62 black spinning part.]))
63 (subsubsection
64 :title [arduino placement]
65 (p [the arduino should be placed as shown in this picture.]
66 (figure :legend "arduino to deck / place arduino"
67 (image :file "arduino-to-deck/3-place-arduino.png")))
68 (p [here's a closeup]
69 (figure :legend "arduino to deck / place arduino closeup"
70 (image :file
71 "arduino-to-deck/4-place-arduino-closeup.png"))
72 [the picture above shows where to place the arduino on the deck.
73 the arduino should line up with the holes on the deck.
74 this alignment line is highlighted in pink.
75 on the arduino, there's a hole on the top left, between the
76 orange reset button and black headers.
77 the green circle shows where the hole is.
78 the blue box encloses the arduino hole and two deck holes.
79 place the arduino hole mid-way between the two
80 deck holes.]))
81 (subsubsection
82 :title [drilling]))
83 (subsection
84 :title [first screw]
85 (subsubsection
86 :title [fastening arduino to deck using #6-32x3/8\" screw]
87 (p [the "#6" part of "#6-32x3/8\"" is how big around the bolt is.
88 it is related to wire gauge.
89 bigger numbers mean larger screw.
90 smaller numbers means smaller screws.])
91 (p [check
92 ,(itemize
93 (item
94 [in the motor assembly, there are #4-40x1.25\" screws.
95 are those fatter, thinner, or the same thickness as the
96 #6-32x3/8\" screws?]))])
97 (p [the "32" part is a measurement of how close the threads are to
98 each other.
99 this is related to the angle of the thread, which is also
100 called pitch.
101 it is a count of how many times the thread wraps around one
102 inch of the screw body.])
103 (p [the head is the flat part where some tool, like the alan
104 wrench, can exert force to spin the screw.])
105 (p [check
106 ,(itemize
107 (item [how many times will the thread wrap around one inch of
108 the screw body?])
109 (item [what about 2 inches?
110 how many times will the thread wrap around two
111 inches of the screw body?]))]))
112 (subsubsection
113 :title [fasten the arduino board to the deck]
114 (p [push the 6-32 screw into the deck from the underside and at the
115 same time, spin the 6-32 screw clockwise while looking
116 down on its head.
117 twist until the bottom of the screw is
118 about to stick out on the top side of the deck.])
119 (p [hold the arduino board flat to the deck and line up the arduino
120 hole so the screw can come up through it.
121 continue tightening the screw into the deck, spinning the same
122 direction as before.
123 tighten until the screw head touches the deck.
124 do not continue tightening after that.])
125 (p [the arduino should still be flat against the deck still, just
126 as it was before tightening the screw.]))
127 (subsubsection
128 :title [assessment]
129 (p [does the arduino stay with the deck when the deck moves?
130 can the arduino board still rotate a few degrees?
131 warning, if you rotate the arduino board too much, you
132 will unscrew it from the deck and you'll have to screw it
133 back in.
134 rotating a few degrees should be ok.]))
135 (subsubsection
136 :title [arduino board move relative to deck]
137 (p [without any screws, the arduino board can move independently of
138 the deck.])
139 (p [with the first screw, the arduino can rotate around one point
140 on the deck.])))
141 (subsection
142 :title [second hole and screw])
143 (subsection
144 :title [third and fourth hole and screw]))
145 (section
146 :title [breadboard])
147 (section
148 :title [battery packs]
149 (subsection
150 :title [leads])
151 (subsection
152 :title [deck attachment]))
153 (section
154 :title [motors]
155 (subsection
156 :title [leads])
157 (subsection
158 :title [mount])
159 (subsection
160 :title [deck attachment]))
161 (section
162 :title [wheels]
163 (subsection
164 :title [tread])
165 (subsection
166 :title [motor]))
167 (section
168 :title [caster]
169 (subsection
170 :title [deck placement]))
171 (section
172 :title [sonars]
173 (subsection
174 :title [deck placement])))
175 (chapter
176 :title [wiring and software]
177 (section
178 :title [serial]
179 (subsection
180 :title [software on computer]
181 (subsubsection
182 :title [arduino])
183 (subsubsection
184 :title [fritzing]))
185 (subsection
186 :title [attach arduino and computer via cable])
187 (subsection
188 :title [debugging common connection problems])
189 (subsection
190 :title [arduino reset button]))
191 (section
192 :title [left sonar]
193 (subsection
194 :title [breadboard connectivity])
195 (subsection
196 :title [cable])
197 (subsection
198 :title [arduino headers])
199 (subsection
200 :title [sound cm per microsecond at sea level]))
201 (section
202 :title [both sonars]
203 (subsection
204 :title [breadboard power rail]
205 (p [power rail can provide power to more than one device.])))
206 (section
207 :title [left motor]
208 (subsection
209 :title [arduino digital output])
210 (subsection
211 :title [quad half h bridge, aka motor controller])
212 (subsection
213 :title [motor battery]))
214 (section
215 :title [both motors]
216 (subsection
217 :title [analogWrite]))
218 (section
219 :title [untethered]
220 (subsection
221 :title [arduino battery])
222 (subsection
223 :title [off and on functions]))
224 (section
225 :title [follow]
226 (subsection
227 :title [same wiring as untethered])
228 (subsection
229 :title [set motor])
230 (subsection
231 :title [go])
232 (subsection
233 :title [determining speed]))
234 (section
235 :title [stay on table]
236 (subsection
237 :title [stop])
238 (subsection
239 :title [backup])
240 (subsection
241 :title [turn around]))))
242
243 ;; Copyright 2016 daniel watson
244
245 ;; This file is part of challenge-bot.
246
247 ;; challenge-bot is free software: you can redistribute it and/or modify
248 ;; it under the terms of the GNU Affero General Public License as
249 ;; published by the Free Software Foundation, either version 3 of the
250 ;; License, or (at your option) any later version.
251
252 ;; challenge-bot is distributed in the hope that it will be useful,
253 ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
254 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
255 ;; GNU Affero General Public License for more details.
256
257 ;; You should have received a copy of the GNU Affero General Public
258 ;; License along with challenge-bot. If not, see
259 ;; <http://www.gnu.org/licenses/>.