Introduction: Affordable Keyboard Encoder and Divekick Controller
Everyone who has played Divekick has seen Markman's controller: two extremely durable buttons that eliminate any confusion for a new player. I've played Divekick with people from ages eleven to fifty, and having a 360 controller with trigger pulls as input works, but many of my guests have attempted to use the control sticks. With a REAL Divekick controller, the game is not only simpler to explain, but is more fun to play.
I also play Dota, where a missed Mek can doom a team. Never miss the button again by placing this controller on the floor and kicking on your Phase Boots, Mek, or any other active item you want!
This Instructable teaches how to turn a five dollar keyboard into something beautiful.
Step 1: Supplies
Dell Keyboard Model RT7D50 ($5 or less at your local Thrift Shop)
Breadboard (solderless, $3 or less anywhere. You can do this without it, but it makes future development MUCH easier)
Big Dome Push Button - Red x1 (Sparkfun, $10)
Big Dome Push Button - Yellow x1 (Sparkfun, $10)
Big Dome Push Button - Blue x1 (Sparkfun, $10)
Big Dome Push Button - Green x1 (Sparkfun, $10)
Hook-up Wire - Black x1 (Sparkfun, $2.50)
Hook-up Wire - Red x1 (Sparkfun, $2.50)
Solder Leaded - 100-gram Spool x1 (Sparkfun, $2.50)
Electrical Tape (anywhere, $2.50)
Marker- Permanent ($1 anywhere)
Razor Blade (Bare, $0.25, anywhere)
Soldering Iron (Buy your own, look at reviews and choose a good one. You will not regret the investment on a $40 model)
Keep the box that the buttons came in for use as a housing!
9V Battery Terminal
Breadboard-mountable switch (3 pin)
Order 60$ or more on Sparkfun for free shipping!
Step 2: Disassembling the Keyboard
I used a brightly colored spare keyboard for this part of the demo.
Do not use this yellow keyboard, as its encoder is extremely small and difficult to solder to.You can use any keyboard you like, but make sure that its encoder has room to solder on!
Unscrew all the backing, and remove any screws inside.
Unscrew any pieces holding the chip with LEDs attached and the membranes to the board.
Slide the chip out.
Take chip you pulled out of the keyboard and set it carefully aside. This is the encoder. You can buy one for fifteen to twenty dollars, or you can pull it out of an old board yourself. (Such savings!)
Gently remove the membrane layers, and separate them from each other.
Lay ONE layer of the membrane over the keyboard.
Step 3: Shave the Encoder
There will be small black lumps of contact insulator above the pins you will solder to.
Using the bare razor blade (BE CAREFUL!) drag the blade across the contacts of the encoder.
Drag the blade until the contacts are no longer black, silver, green, or brown. They will turn bright copper color after all the insulating layers are removed.
The contacts must be BRIGHT copper to solder to them, so shine them up! If you use any part but the flat of the blade, take care not to cut anything, especially yourself. (Tetanus shots make the project take longer.)
Step 4: Map a Key
The next page contains my keymaps for D, F, C, and V, which you can use to skip this step if you like!
To map a key, use your felt tip pen to mark the location of the membrane contact above the key you want to press. I chose C for this project, as it is my most missed key in Dota.
Each key has one contact per membrane layer, and all the letters share a wire with either its row or column. This varies for each keyboard model.
Using one of your wires, or anything suitably small, sharp, and easy to see, trace the suspended metal in the membrane to its final contact. Assign numbers to each of the encoder contacts, and find which number your wire routes to.
Write this down.
Take the other membrane, and repeat. You should have its coordinates.
If this is unclear, look at the next step for an example of how to write a map.
Step 5: My Keymaps
Looking at the encoder as pictured, with the black circle on the right, and the cabling on the left, I mapped with reference to the center hole on the bottom.
V: 2 pins left of the center hole, 5 pins right of the center hole
C: 1 Right, 5 Right
F: 2 Left, 8 Right
D: 1 Right, 7 Right
Step 6: Test Your Keymap
Plug the encoder's USB into your computer, and open notepad.
Connect the two pins by holding each end of a single piece of wire to the two contacts you just mapped.
You should see your chosen letter onscreen.
Alternatively, you can solder your contacts and attach a small switch between them on a breadboard, but this is unnecessary, and was done mainly for demonstration purposes.
Step 7: Solder the Contacts
Cut a 20cm piece of wire, and strip 1cm on each end.
Solder one end onto one of the contacts used in your keymap. LEAVE THE OTHER END FREE.
Repeat for all keymapped pins.
After this step, you should match the picture above if you are using keys C,D,F, and V.
Step 8: Test the Button
Attach a pair of wires to the microswitch as shown. This is the NO (Normally Open) contact*, and the Common contact. Leave the side contacts free. These are the LED contacts.
For the V key, I attached the wires attached to the pins two left and five right of the center hole of the encoder to the button.
DON'T SOLDER YET! There could be problems with the button or encoder. This is when you will find them.
With the button hooked up to the encoder, and the encoder connected through USB to your computer, open notepad.
PUSH THE BUTTON.
If everything works, you will see your letter pop up onscreen!
*: The switch has two options. Most people want a button to be NO, since that means that when you press it, it activates. The alternative is Normally Closed (NC), in which the default is on. If you want the button to be NC, move the red wire to the contact closer to the top of the button.
Step 9: Big Buttons: Removing the Switches
Unhook your button from the encoder. Remove the USB from the computer.
Hold the button actuator side down, and rotate the white microswitch counter-clockwise until it clicks. The LED will slide out.
Troubleshooting: If the LED becomes trapped, use needle-nosed pliers and a good amount of jostling to remove it from under the button cap. It will come out.
Step 10: Soldering and Alternative Test
Cut two 20cm pieces of wire, and strip 1cm on each end.
Solder one end onto the NO and Common contacts of the button, leaving the other end free.
If you tested while connected to the PC, skip to the next step.
Plug the free ends of the button's wires into a breadboard on separate lines.
I connected an LED to a 9V battery on a breadboard, with the circuit broken by the button.
PRESS THE BUTTON
If the board LED is on, you soldered well and everything worked!
If it is off, turn the LED around and check your contacts.
Press again, and if the LED is still off, contact Sparkfun support for a new microswitch. They are incredibly fast, and their products are rarely defective.
Step 11: Button Mounting
Unscrew the white conduit nut on the back of the big buttons.
Cut a hole the same size in the cardboard box that your parts came in.
Push the black piping through the hole, and thread the conduit nut back on by hand until tight.
This can be done with wood or plastic, but work with what you have.
Step 12: Breadboard and Mounting
Put the correct microswitches into each button housing the way you took them out, rotating clockwise until there is a click.
Take the encoder and its free wires, and lay them in the box. Plug the free ends into separate lines on a breadboard.
Plug the buttons' free wires into the breadboard lines corresponding to the pairs you mapped earlier. The breadboard is here for future-proofing; if you want to use the buttons for anything else, or remap any keys, you can just pull the part. Also, due to the matrix used by membrane keyboards, you can switch the button wire pair locations to make other keys. (I made my board print a Yen symbol!)
Tape everything down and close the box!
Connect a 9V battery and terminal to the + rail of the breadboard. Use a small bit of wire to connect the - rail to pin 1 of a 3-pin switch, and plug the - terminal of the 9V battery into the same line as pin 2 of the 3-pin switch.
Cut two 20cm pieces of wire, and strip 1cm on each end.
Solder one end of each wire to the LED side contacts of a button. Plug the other ends into the + and - rails of the breadboard. Turn on the 3-pin switch, and the button should light; if it does not, pull the LED wires out of the +/- rails and switch them. Repeat for all connected buttons.
Step 13: Shut the Box. GO PLAY DIVEKICK.
Just as the step title says, shut the box, and go play Divekick!
Don't forget to plug in your USB first, and turn off the 3-pin switch when you are done.
You can mount these buttons and the encoder in just about anything. Just solder on some longer leads to one set of buttons, and you can have TWO controllers. The possibilities are endless.
Thanks for reading, and have fun!
Participated in the
Game.Life 4 Contest