Control Pad (Mega Drive)
From Sega Retro
The Sega Mega Drive Control Pad (コントロールパッド) is the official controller of the Sega Mega Drive (or Sega Genesis in North America). Three button controllers are known officially as Control Pads in both North America and Europe, and SJ-3500s in Japan (following a system set up by the SG-1000). There are many "updates" and alternatives to this controller, the most notable being the Six Button Control Pad. This article covers only the basic three button variants.
Mega Drive control pads are the logical progression from Master System control pads, replacing and with and respectively, while adding an extra two face buttons, and to bring the total number of buttons to four. Also featured is a circular D-Pad, designed to allow for movements in eight directions. Unlike Nintendo's systems, the buttons (or "triggers" as they were initially called) are arranged in alphabetical order from left to right, a practise which would continue not only with future Sega consoles, but would inspire the controllers of the Neo Geo, 3DO and Xbox lines.
Mega Drive controllers are notable for being one of the first control pads to be ergonomically designed for the user's hands. Though improvements were made in the coming years, previous systems had cornered edges with their controllers, meaning they were often uncomfortable to hold after several hours of play. The Mega Drive controller is rounded, and has its buttons placed in easier to reach positions.
Control pads remained mostly the same across regions, but the colouring can determine the region and revision of the accessory. A minor addition added in the early 90s is a little plastic lump on the button, presumably to help users recognise where their right hand thumb was.
Early versions of this controller used the same internals as the original design, but later models have an improved D-Pad mechanism, employing a metal ball-bearing for the pad to rock on. This prevents wear which plagues the original design, which uses a plastic nub for the rocking motion and will eventually wear down with frequent use.
The chip inside the control pad is a 74HC157. This is a high-speed CMOS quad 2-line to 1-line multiplexer. Basically, how this works is there are two inputs ( A and B ) for every output ( Y ). There are four groups like this. There is one select signal for the whole chip. When the select signal is low, the output ( Y ) is the same as input A. When the select signal is high, the output Y is the same as input B. The pinout for the chip is as follows:
All the controls are done with switches. Up is a switch, Down is a switch, etc. Now, I will be referring to the output of these switches later on. The output is usually high when the switch isn't pressed. When the button is pushed, the output goes low. This is accomplished by connecting the output to +5V through a 10k resistor. The button is then attached between the output and ground. It looks like this:
+5V -----/\/\/------+--------- Output 10k | | / | Ground -----/ -------+ button (normally open)
The line numbers are determined as follows, looking straight at the plug on the front of the Genesis the numbers are:
1 2 3 4 5 6 7 8 9
Access to controller ports is from bytes $A10003 (controller 1) and $A10005 (controller 2). TH must be set for output and the other pins for input, so bytes $A10009 and $A1000B must be set to $40 to read the respective controller.
Bit 7 latches the value written to it. It takes approximately the equivalent of two nop instructions for other types of controllers (such as the six-button controller) to respond to a TH change.