Compound Buttons Technique

The standard gameport has 4 independent buttons.  By combining these buttons together, we can come up with 14 individual buttons.  The downside to this is that no two buttons can be pushed at once (As you'll get another button combination) and it requires special drivers under Windows 98 and Windows 2000.

Basically, each button is treated as a single bit in a 4 bit word.  When the button is pressed it is 1, and when it is not it is 0.  This gives us 2 to the power of 4 or 16 possibilities.  Obviously when no buttons are pressed, we don't want anything to happen, so that cuts us down to 15 possibilities.  The developers of the driver for Windows 98, CH Products, were also obviously suspicious and didn't allow the combination of buttons 1, 3 and 4 (Which equates to 13!!).  This combination can actually be used with some registry hacking - click here to find out more.

The following table shows us how each button is obtained:

4 3 2 1 HEX Button
0 None
X 1 Button 1
X 2 Button 2
X X 3 POV 1 Left
X 4 Button 3
X X 5 Button 5
X X 6 Button 8
X X X 7 POV 1 Down
X 8 Button 4
X X 9 Button 6
X X A Button 10
X X X B POV 1 Right
X X C Button 9
X X X D None
X X X E Button 7
X X X X F POV 1 Up

Where X's appear in multiple lines, the button is made up by pressing each of the independent buttons at the same time.  This can be made possible using diodes.  The following wiring diagram shows how one would wire up each of these buttons.

I'm using 14 already, I need more!!

There are a number of ways to get more buttons:

1.    Use a second gameport for a further 14 buttons (in compound mode) or 4 independent buttons.

2.    Use a keyboard connection for many different button combinations.

3.    Buy and hack up a USB game controller - Most of these are digital and some have up to 32 independent buttons.

Obviously the first two are the easiest, although some games will not pickup a second controller on a different port.  I'd suggest using the keyboard modification as the easiest method.  See Modifying a Keyboard for Extra Buttons for an explanation on how to do this.