hardware:gamepads
Differences
This shows you the differences between two versions of the page.
| Next revision | Previous revision | ||
| hardware:gamepads [2025/09/20 02:38] – created clyde | hardware:gamepads [2026/07/15 01:30] (current) – clyde | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| ====== Gamepad Ports ====== | ====== Gamepad Ports ====== | ||
| - | The front gamepad ports can be read at $2008 and $2009. Writing to these addresses will not do anything. A byte read from one of these locations will return 6 binary button states from the respective controller. Consecutive reads to the same port will toggle the “select” line on the controller port, causing the controller to change which six button states are being returned. | + | The front gamepad ports can be read at $2008 and $2009. Writing to these addresses will not do anything. A byte read from one of these locations will return 6 binary button states from the respective controller. Consecutive reads to the same port will toggle the “select” line on the controller port, causing the controller to change which six button states are being returned. |
| + | |||
| ====== First read: ====== | ====== First read: ====== | ||
| Line 19: | Line 21: | ||
| |Up|8 | | |Up|8 | | ||
| |Down|4| | |Down|4| | ||
| + | |||
| + | ====== Bit/Pin Assignments: | ||
| + | ^ Bit ^ Pin ^ | ||
| + | |1|4| | ||
| + | |2|3| | ||
| + | |4|2| | ||
| + | |8|1| | ||
| + | |16|6| | ||
| + | |32|9| | ||
| + | |64|Extra Button| | ||
| + | |128|7 (Select bit)| | ||
| + | |||
| + | ====== Special Bits ====== | ||
| + | ===== Select Bit ===== | ||
| + | This bit toggles with every read, and is returned as the high bit. Normally the controller uses this to select between two sets of buttons, but custom controller hardware could use this to clock arbitrary data out. | ||
| + | |||
| + | ===== Extra Button ====== | ||
| + | Accessible only by modding a physical GameTank, not exposed to front 9-pin port. | ||
| + | Could be used for GameTanks in custom installations such as a coin slot switch in an arcade cabinet. | ||
hardware/gamepads.1758335896.txt.gz · Last modified: 2025/09/20 02:38 by clyde
