Tuesday, August 2, 2011

Hack a USB Computer Keyboard to Make a Synth Pedal Board

My son asked me if I could make a pedal board to connect to his laptop to use with his synth software, so that he can switch loops while performing -- or something musical like that.

Fortunately for him he does not get his musical ability from his Dad.

The brief was 10 big buttons to be pressed with his feet, while on stage. The buttons to be arranged in three groups of three and one button on the end, that he would map to mute on his software.

You will need:
* A USB keyboard that you do not mind destroying.
* 10 stout push to make switches
* 20 spade terminals (if thats the connection on your switches)
* A 1KΩ resistor
* A length of plastic ducting
* Stripboard - for size see description below
* Soldering tools and patience
* Twin multicore wire - as for a door bell (when door bells used to have wires)

Rather than try and do anything with an Arduino - which was my first throught - I decided to hack an old keyboard I had lying around:

The only bit of the keyboard I kept was the USB controller module:

The connectors at the top normally press against the conductive plastic of the keyboard connections and were coated with some kind of conductive polymer. So, to be able to solder them, I rubbed them with glass paper, to bring up the raw copper.

There then followed the tedious problem of working out how to simulate the pressing of one of the keys '0' to '9'. The keys are arranged in a matrix, so connecting the right row to the right column would simulate a press. But, you do not want to accidentally connect one row to another, so rather than experiment with a wire to find out the combination that simulated a digit, I used a 1K resistor to test connecting two points together.

To keep track of which combinations produced the desired results, I made up a matrix, assigning each contact a number.

With the controller connected to my computer and a word processor open, every time I got a digit by connecting two of the connections with a resistor, I added it to the table. So, connecting the resistor between pins 22 and 17 caused the digit '1' to appear on the screen. [ignore the rogue 0 to the left].

This is not actually as tedious as it sounds, you will rapidly home in on clusters of combinations that work.

There is not enough room to solder the leads for the switches directly onto the connectors on the controller, so I found a bit of stripboard and carried the connections across.

Using the matrix as a guide, I soldered up leads to the spade terminals and to the appropriate connections on the stripboard.

Loosely attaching the switches, I tested them all before fitting them into the box.

The box is made from a length of ventilation ducting with holes drilled for the switches.

There now follows the tricky task of threading the wires through to the appropriate holes in the box. Labelling each pair of wires and using a stronger guide wire to pull the wires through helped with this.

All that remains is to reattach the switches, test again and then push all the switches into the holes.

The tennis ball is just for scale.

Have fun and post me pictures if you have a go for yourself. I'm always interested in ideas for version 2!
About the Author
These are my books. Click on the image below to find out more about them.



tech support said...

Very good innovation. I'm gonna try it because I think it's cool.

Shamun said...

Very good info.
1. Buttons: http://www.interfacebus.com/Switch-Push-Button-Manufacturers.html

2. Button wires: http://www.ksterminals.com.tw/eng_barreltypes.asp?P=1&FKindNO=F01&SKindNO=S01&Tname=1

3. And your hack guide

Should make it work. But however the pictures of the back board is not clear can you please show another picture of that part.?

Vinod said...

Hello, I love reading through your blog, I wanted to leave a little comment to support you and wish you a good continuation. Wish you best of luck for all your best efforts. soldering wire manufacturers Delhi, soldering wire suppliers India.

Diomar Salvado said...

nice post. .try to watch movie online for free here

Anonymous said...

WORLDS CHEAPEST VIRTUAL DRUM at $10 [ Rs.500] - using pc ( no drum module required )