I've recently come across a USB game controller (PS2-style), that has a PCB seemingly designed with hacking in mind. It has dedicated solder points and clear labels, and best of all, its
cheap.
If you're debating whether to do a 'keyboard hack' or buy a dedicated encoder like an IPAC, then this USB controller hack is a
very cheap and viable alternative as it is
far easier to hack,
far less time consuming, and suffers none of the 'ghosting' problems of keyboard hacks.
That said, if you dont understand the basic concepts of 'ground wires', soldering, or these pictures generally don't make sense to you, then the easiest option is to buy an encoder like the IPAC Value Edition.
Note also that *MAME* can be configured to use any input you like for any button, and most other emulators can too. This is how you're able to use a usb controller which appears to Windows/MAME as a USB joystick. The IPAC however actually emulates KEYBOARD and there's no fiddling with MAME settings, plus you can reprogram a dedicated encoder to be used for dedicated buttons like 'enter' and 'escape' etc that might be used in other programs (other than mame). There are of course utilities like joy2key (?) that map your joystick buttons to keyboard buttons, so there are ways around it even with this controller hack... it just requires a little more fiddling around with software setup.
In a nutshell, if all you want is to interface your arcade controls with MAME and nothing else, and you're able to use a soldering iron, this hack is a
great option.
Here's some information on hacking the
Deal Extreme 'ultra hackable' USB game controller. (at the time of writing, US$9.19 each with free delivery).
With this controller, you can get 4 directions + 10 buttons (4 face buttons, 2x2 trigger buttons, plus start and select).
This could be used to give you a 1 player, 8 button with credit & start.
or 2 players with one button each, and a single credit / start button.
Realistically for two player I recommend just using two gamepads.
So without further ado:
Notes: MAME can be configured to use whatever button you like, so it doesn't really matter about the sequence/numbering of the buttons, nevertheless I've marked them for you.
When I tried chopping off off the analog controls the controller was trying to go up/left constantly. When I reattached the analog control sticks it was fine again. Thus I've concluded its best to leave them on, as its easier than putting a resistor or whatnot to make it 'think' it still has them.
Not bad for 20 mins work... I'm starting to think it takes me less time than hooking up an IPAC!