I needed a durable, reliable foot switch that I could use to send signals to my PC. Ideally, I wanted the switch to be mapped to a mouse event or a keyboard shortcut. I'll show you how I accomplished that for just a few dollars.
You can use this for a variety of purposes such as controlling the push to talk function of voice communication software, while keeping your hands free for gaming. This can also help people who suffer from repetitive stress injuries.
In my case, I wanted a foot-switch to control the operation of a photo booth.
Here's what you will need:
- a guitar pedal - I got a Boss FS-5U from Starving Musician my local used music store. I had planned to use an effect pedal, and would have needed to rewire the pedal internals to make it into a simple momentary off/on switch, but the FS-5U was ideal because it already is just a momentary switch meant to be used as a trigger, so it didn't require any modification to work.
- a guitar cable of adequate length ($3 used at the used music store)
- a 2-conductor guitar jack (you can get these online for around $2 each, but I got two of them on a mounting plate from a deceased amplifier for $1 at the used music store).
- A USB mouse. I actually bought the cheapest one I could find for $5
- some primary wire (~16-18 GA)*
- a soldering iron*
- some solder*
- a digital multi-meter*
- wire cutters / wire stripper*
Step 1: Disassemble the USB Mouse
The left and right and center mouse buttons are clearly visible once the cover is removed. Beneath the outer plastic shell of the mouse, they are simply surface-mount micro switches.
Step 2: Determine How the Button Switches Are Attached to the PCB
Set the digital multi-meter to measure to measure resistance (I used the 20 Ohms setting) and figure out which two solder connections are bridged when the switch you want is in the closed position, but not when it is in the open position.
In the first photo above, I've indicated which pair of contacts open and close with the Left Mouse Button.
Using the soldering iron, heat up these solder joints one at a time and remove the micro-switch. This will leave a small hole in the PCB where each of the connections was.
Step 3: Wire the Mouse to the Guitar Jack
Insert the exposed wire through one of the solder contacts on the PCB which you identified in the previous step, and then solder it into place, trying to use as little solder as possible while still getting a solid joint. I placed the soldering gun against the exposed copper wire on one side of the PCB and held the solder against the wire on the other side. As the solder becomes molten, it was quickly drawn toward the source of the heat and formed a small bulge on either side of the PCB.
Repeat this process with another piece of primary wire (not the other end of the same piece) and the second solder contact. I used different colors of wire to help keep things clear visually.
The first photo above shows what my mouse PCB looked like after this step. My solder joints aren't perfect, but they are secure and not touching each other. As you can see, I used different colors of wire to help keep things clear visually.
Next you strip a small section of insulator from the other end of each of these wires and solder them to the contacts on your guitar jack. For my purposes, I connected the left mouse button to the contacts on one guitar jack and the right mouse button to the contacts on a second jack.
NOTE: If you wanted to use this as a push-to-talk switch for gaming, I would suggest using the Center mouse button, since it isn't usually used and can be easily mapped in both Teamspeak and Ventrillo.
The second picture show what the final assembly looked like.
Step 4: Test and Mount the Jack.
Connect the guitar pedal to the guitar jack using a length of guitar cable,
Plug the mouse's USB cable into your computer - it should recognize the hardware as a USB mouse.
- Step on the pedal and you should see a response on the computer.
Now all that's left is to mount your guitar jack(s) and you are in business. In the second picture, you can see how mine is mounted on a plywood box that was part of my photo booth project.