9 PIN D-SUB MALE at the computer.
9 PIN D-SUB FEMALE at the joystick cable.
The Commodore VIC-20 and C64 each provide two 9-pin DE-9 control ports that follow the de-facto Atari joystick standard originating with the Atari 2600 VCS (1977). The ports accept digital joysticks, paddle controllers, and — on Port 1 only — a light pen. Direction and fire signals are active-low: pressing a switch shorts the relevant pin to GND, and the host reads a logic 0 via the CIA (C64) or VIA (VIC-20) parallel I/O registers. Pin 7 supplies +5 V to power autofire circuits and paddle potentiometers; the rated current is 50 mA on the C64 and 10 mA on the VIC-20.
Control Port 1
| Pin | Name | Dir | Comment |
|---|---|---|---|
| 1 | JOYA0 | IN | UP |
| 2 | JOYA1 | IN | DOWN |
| 3 | JOYA2 | IN | LEFT |
| 4 | JOYA3 | IN | RIGHT |
| 5 | POT AY | IN/OUT | |
| 6 | BUTTON A / LP | IN/OUT | |
| 7 | +5V | OUT | 50 mA max |
| 8 | GND | Ground | |
| 9 | POT AX | IN/OUT |
Control Port 2
| Pin | Name | Dir | Comment |
|---|---|---|---|
| 1 | JOYB0 | IN | UP |
| 2 | JOYB1 | IN | DOWN |
| 3 | JOYB2 | IN | LEFT |
| 4 | JOYB3 | IN | RIGHT |
| 5 | POT BY | IN/OUT | |
| 6 | BUTTON B | IN/OUT | |
| 7 | +5V | OUT | 50 mA max |
| 8 | GND | Ground | |
| 9 | POT BX | IN/OUT |
Notes
- Direction is computer relative to device.
- The male DE-9 socket is mounted on the computer; the joystick or controller cable terminates in a female DE-9 plug.
- Pin 7 (+5 V) is rated at 50 mA on the C64 and at 10 mA on the VIC-20; controllers that draw more than 10 mA must not be used on the VIC-20 without external power.
- The light pen input (LP, pin 6) is functional only on Port 1; Port 2 pin 6 carries BUTTON B (fire only).
- Paddle potentiometers are specified as linear 470 kΩ (±10 %).
- Joystick inputs are pulled high internally; pressing a direction switch or fire button shorts the pin to GND (active-low logic).
- On the C64, Port A is read via CIA #1 at $DC00 (Port 1) and Port B at $DC01 (Port 2); on the VIC-20, VIA #1 Port A at $9110 and VIA #2 Port B at $9120 handle the signals.
Signals
- JOYA0 / JOYB0 — Up direction; active-low digital switch to GND.
- JOYA1 / JOYB1 — Down direction; active-low digital switch to GND.
- JOYA2 / JOYB2 — Left direction; active-low digital switch to GND.
- JOYA3 / JOYB3 — Right direction; active-low digital switch to GND.
- POT AY / POT BY — Analogue Y-axis input for paddle controllers; the potentiometer is wired between +5 V (pin 7) and GND (pin 8).
- POT AX / POT BX — Analogue X-axis input for paddle controllers; wired identically to POT Y.
- BUTTON A / LP — Port 1 fire button and light pen input; the light pen signal is multiplexed on this pin and is only sensed on Port 1.
- BUTTON B — Port 2 fire button only; no light pen function on this port.
- +5V — Supply voltage for peripheral logic and paddle potentiometer divider network; 50 mA max (C64) or 10 mA max (VIC-20).
- GND — Signal and power ground reference.