]> git.armaanb.net Git - atreides.git/blob - assembly/assembly.tex
b355a605e7451da3cd9bae46a8e506a35e1bc768
[atreides.git] / assembly / assembly.tex
1 \documentclass{article}
2 \title{Atreus Keyboard Assembly}
3 \date{ }
4 \usepackage{graphicx}
5 \begin{document}
6 \setlength{\parindent}{0cm}
7 \maketitle
8 \section{Prerequisites}
9
10 In order to assemble your keyboard, you'll need your kit plus a few
11 other tools. The kit should contain these parts and a few spares:
12
13 \begin{itemize}
14 \item Case (top plate, switch plate, spacer, bottom plate)
15 \item Sandpaper
16 \item Finishing wax (mixture of beeswax and mineral oil)
17 \item Diodes (42)
18 \item Key switches (37 tactile or clicky, 5 red)
19 \item A-Star Micro controller
20 \item Machine screws and nuts (8 each, 16mm M3 size)
21 \item Key caps (40 normal, 2 long)
22 \item USB micro cable
23 \item Rubber feet
24 \end{itemize}
25
26 You'll also need to have these on hand:
27
28 \begin{itemize}
29 \item Soldering iron and solder
30 \item Wire cutters
31 \item Tape (masking tape works well)
32 \item Brush for applying finishing wax (a toothbrush will do)
33 \item Optional: ``helping hands'' stand
34 \end{itemize}
35
36 \vspace{1em}
37
38 The latest version of this document can always be found
39 online.\footnote{http://atreus.technomancy.us/assembly.pdf} If you're
40 reading a black-and-white printed copy, you may find some of the
41 photos clearer in color onscreen. This copy describes the
42 circuit-board-based kit. If you have an earlier hand-wired kit, see
43 the older assembly
44 guide.\footnote{http://atreus.technomancy.us/assembly-hand-wired.pdf}
45 The photos in this guide depict Cherry MX switches, but some kits ship
46 with Matias switches instead, which have a clear housing. The assembly
47 steps are the same in either case.
48
49 \section{Sanding}
50
51 Start by sanding down both sides of each piece. You may want to
52 hold two pieces together while sanding for strength or placing it on a
53 flat surface you don't mind scruffing up; too much pressure on a
54 single plate could damage it.
55
56 \vspace{1em}
57 \noindent\makebox[\textwidth]{%
58 \includegraphics[width=\linewidth]{sanding.jpg}}
59 \vspace{1em}
60
61 Keep in mind that the top side of the top plate and the bottom side of
62 the bottom plate are the only surfaces that are exposed to the touch
63 once the keyboard is fully assembled, so these will need the most
64 attention when sanding. You can sand the other surfaces as well just
65 to get the scorch marks off, but you don't need to worry about how
66 smooth the inner surfaces feel to the touch. Be sure to get all the
67 wood dust off the pieces before you go on. A clean tack cloth or other
68 fine cloth works well.
69
70 \section{Finishing}
71
72 You have two options when it comes to finishing. The easiest way is to
73 proceed with the wax/oil mixture included in the kit. The other option
74 is to apply several layers of lacquer and wet sand it down in
75 between coats. This requires buying more supplies and takes significantly
76 longer, but it results in a shinier
77 finish.\footnote{http://atreus.technomancy.us/lacquer.gif} The steps
78 for the lacquered finish are described in a separate
79 document,\footnote{http://atreus.technomancy.us/lacquer.pdf} and the
80 rest of this section describes the quicker finishing method.
81
82 Open up the wax/oil mixture. Apply some to the brush and start
83 spreading it over one side of each case piece. The color of the wood
84 will darken as it absorbs the oil. Try to ensure it's spread
85 evenly. Be more generous with the oil on the outer exposed
86 surfaces. Once you've spread it with the brush, you can use your
87 fingers to work the wax into the wood more deeply.
88
89 \vspace{1em}
90 \noindent\makebox[\textwidth]{%
91 \includegraphics[width=\linewidth]{oiled.jpg}}
92 \vspace{1em}
93
94 As your brush goes over the edges of the laser-cut wood, it will get
95 dirty from charred wood particles. After you've finished oiling one
96 side of each piece, it's best to wash out the brush. Be sure it's
97 fully dry before going on.
98
99 \section{Drying Case}
100
101 Once one side of each piece is finished, you'll need to lay them out
102 for a half hour or so to let them dry. Once one side is dry, repeat
103 the process on the other side. After you've finished the construction
104 you can come back and add another few coats to the outermost surfaces
105 for a smoother texture. Once it's dried for a while, wipe the excess
106 off. While you're waiting, you can start soldering the diodes and
107 controller onto the circuit board, but don't solder any switches in
108 before the switch plate is ready or you'll just need to remove them
109 later.
110
111 \section{Diodes}
112
113 If you've never soldered before, there are plenty of good
114 introductions online.\footnote{This one from Adafruit is great:
115   https://learn.adafruit.com/adafruit-guide-excellent-soldering/tools}
116 Coat the tip of the hot iron thinly with some solder before you
117 start. The key is to use the iron to heat both parts of the joint for
118 a second or two, then bring in a dab of the solder and let it melt and
119 stick to the component and the circuit board pad.
120
121 \vspace{1em}
122
123 Take five diodes at a time and bend them into a U shape. Place them
124 into the diode holes next to each switch slot on the reverse side of
125 the board. Each diode has a black band on it; the band should be
126 pointing in the direction of the arrow on the printed side of the
127 board. Once all five are in, bend the legs of the diodes outwards to
128 hold them in place, then flip the board over and solder them in place.
129
130 \vspace{1em}
131 \noindent\makebox[\textwidth]{%
132   \includegraphics[width=\linewidth]{diodes.jpg}}
133 \vspace{1em}
134
135 In the photo the diodes are inserted from the back of the circuit
136 board, but it will work just as well to insert them from the front as
137 long as the black band is oriented correctly. Once they're soldered,
138 trim the diode legs with wire cutters. Grip the diode leg as you
139 trim it to keep it from flying across the room. Keep the diode legs;
140 they will be needed in the next step. Repeat until each diode position
141 is filled.
142
143 \section{Controller}
144
145 Once the diodes are in place, you can begin attaching the controller.
146 If the controller came in a pink bag with its own header pins, you may
147 be tempted to use them to connect the controller to the circuit
148 board. Don't do this--they are too big and will prevent the case from
149 closing when you're done.
150
151 \vspace{1em}
152
153 Take four trimmed diode legs and bend them into an L shape. Hold the
154 controller upside down and insert the diode legs into the holes at the
155 corners, fixing them in place with tape. Try to get them to point straight.
156
157 \vspace{1em}
158 \noindent\makebox[\textwidth]{%
159   \includegraphics[width=\linewidth]{taped-pins.jpg}}
160 \vspace{1em}
161
162 Insert the legs into the circuit board. The port for the USB cable
163 should fit into the circuit board's notch in the middle. Solder the
164 diode legs into the circuit board and trim them. Then flip the whole
165 thing over, remove the tape, and solder them into the controller on
166 the other side, trying to ensure the controller is as close to the
167 board as possible.
168
169 \vspace{1em}
170 \noindent\makebox[\textwidth]{%
171   \includegraphics[width=\linewidth]{insert-pin.jpg}}
172 \vspace{1em}
173
174 Now that the controller is secured in place, bend some more diode legs
175 and put them in the other holes in the circuit board. You can do this
176 one side at a time. Use the same method of taping the bent ends in
177 place, flipping, and soldering the other side in place before going
178 back to solder the bent side. Trim as you go. Be sure to fill all the
179 ``A-STAR'' holes in the circuit board.
180
181 \vspace{1em}
182
183 Before you go on, take the time to double-check the solder joints on
184 the controller. The solder should fill the hole completely without
185 spilling over to adjacent holes, and the legs should be secure. Also
186 check that all the diodes are facing the correct direction with the
187 black band pointing to the bottom of the board. Once the switches are
188 in place, the controller will be pinned between the switch plate and
189 the circuit board, making it difficult to make further changes to the
190 controller and its connections.
191
192 \section{Switches}
193
194 Next take four switches and place each switch in a corner of the
195 switch plate. (The case layer with all the holes in it.) The switches
196 should be oriented so that the side with pins is to the ``north'' of
197 the board so they fit into the holes in the circuit board. Put the
198 switch plate face-down on the table with the pins sticking
199 up. Carefully fit the circuit board over the protruding pins, trying
200 to get the pins to push as far through the circuit board as you can.
201 Solder those corners to hold the circuit board and the switch plate
202 together. The labeled side of the board should be face-up. Take care
203 that the switch pins are straight; pushing in a switch with a pin
204 that's a bit bent will bend it flat and prevent it from poking through
205 the circuit board.
206
207 \vspace{1em}
208
209 If your kit has five linear switches (non-tactile, usually red), you
210 can choose to use these for the modifiers or to leave the modifiers as
211 normal tactile keys. Since modifier keys are held down, they do not
212 benefit from tactility like normal keys do, so some people find they
213 prefer linear keys there, but this is a matter of personal taste.
214
215 \vspace{1em}
216
217 If you decide to use the linear switches, place them in the modifier
218 positions next and solder them in. These all go on the bottom row:
219 SW3:3, SW5:0, SW6:0, SW8:3, and SW9:3. Fill in the rest of the bottom
220 row with your primary switch type, and then fill in the leftmost
221 column as well. Note that the center two switches are oriented
222 sideways. The pins on them may need to be bent outwards a bit to get
223 them to fit into the circuit board.
224
225 \vspace{1em}
226 \noindent\makebox[\textwidth]{%
227   \includegraphics[width=\linewidth]{switches.jpg}}
228 \vspace{1em}
229
230 \section{Firmware}
231
232 With a full row and a full column installed you now have enough
233 switches installed to test every pin on the
234 microcontroller. Installing the firmware will allow you to spot
235 mistakes before the board is fully completed. Once all the switches
236 are in place it's a lot of work to go back and fix connections on the
237 microcontroller, but at this point it can be done by only removing a
238 handful of switches.
239
240 \vspace{1em}
241
242 Plug in the USB micro cable into the controller, and plug the other
243 side into your computer. Get a copy of the
244 firmware \footnote{Available at
245   https://github.com/technomancy/atreus-firmware} and its
246 dependencies, \texttt{avrdude} and \texttt{gcc-avr}, linked in the
247 firmware readme\footnote{If you only want to use the default layout
248   and don't want to bother with installing everything, the firmware
249   readme also describes simpler steps for installing a pre-built
250   firmware with the default layout}. The first time you upload the
251 firmware, you will have to use the backup reset to enter the
252 bootloader: take a diode leg or wire and touch one end to the reset
253 pin and one end to the ground pin. (These are the bottom-most two
254 exposed pins on the left-hand side of the controller when the keyboard
255 is facing down.) Touch them together twice in under a second and the
256 LED will begin pulsing in a different pattern from the original
257 blinking. This indicates it has entered the bootloader for 8 seconds.
258
259 \vspace{1em}
260
261 While in the bootloader, type \texttt{make upload USB=/path/to/usb}
262 from the firmware directory. The firmware should be
263 uploaded\footnote{See the firmware readme for instructions about
264   determining the USB argument and customizing the layout.}, and it
265 should start acting as a keyboard. (At this point if you need to
266 upload it again, you can use the reset key instead of touching the
267 pins together.) Now would be a good time to test each switch that's
268 been placed so far.
269
270 \section{Wrapping Up}
271
272 If all the switches are registering key presses on your computer,
273 finish soldering the rest of the switches in.
274
275 \vspace{1em}
276
277 If there's a misbehaving switch, it's often caused by a cold
278 joint. Reflow the solder on both contacts of the switch and the diode
279 first; if that doesn't fix it, it may be the connection to the
280 controller. You can follow the traces for the columns back to the
281 middle, but the rows on the back of the board are obscured when the
282 keyboard is assembled. The bottom four pins on the left correspond to
283 the four rows, top to bottom.
284
285 \vspace{1em}
286
287 Re-melting the controller pin's solder for the affected row or column
288 is usually enough to get it working. First try the melting exposed
289 solder on the big circuit board; if that doesn't fix it you may need
290 to desolder some switches to get to the pins on the controller
291 itself. It's possible to remove switches using only your soldering
292 iron, but getting a desoldering pump is much more effective.
293
294 \vspace{1em}
295
296 After the switches are all in and tested, close the case by placing
297 the switch plate on top of the spacer and bottom plate, placing the
298 top plate on it, and screwing it together with the nuts facing up. If the
299 controller was not attached close enough to the circuit board, it may
300 be necessary to sand down the USB connector in order to close the
301 case. Before you place the rubber feet on the bottom plate near the
302 corners, consider giving the outer case another coat or two of wax and
303 allowing it to dry. If the rubber feet don't stay on with the provided
304 adhesive, white glue may be needed to secure them.
305
306 \vspace{1em}
307
308 All that's left is to place the keycaps. The larger keycaps go on the
309 middle thumb keys.
310
311 \vspace{1em}
312
313 Congratulations. Enjoy your new keyboard. It will take a considerable
314 adjustment period to get used to it, but it should result in much more
315 comfortable and effective typing. Also remember that you're encouraged
316 to customize the layout to make it truly your own. Happy typing!
317
318 %% \noindent\makebox[\textwidth]{%
319 %% \includegraphics[width=\linewidth]{finished.jpg}}
320
321 \end{document}