Table 8-1: Typical Controller Connections
Mouse,
Trackball, Proportional X-Y
Driving Controller Proportional
Pin Joystick Controller (Pair) Joystick LightPen
1 Forward V-pulse --- Button 3** ---
2 Back H-pulse --- --- ---
3 Left VQ-pulse Leftbutton Button 1 ---
4 Right HQ-pulse Right button Button 2 ---
5 * --- Middle button** Right POT POT X Pen pressed
to screen
6 * Button 1 Left button --- --- Beam
trigger
7 --- +5V +5V +5V +5V
8 GND GND GND GND GND
9 * Button2** Right button Left POT POT Y Button2**
* These pins may also be conFigured as outputs
** These buttons are optional
REGISTERS USED WITH THE CONTROLLER PORT
JOY0DAT ($DFF00A) Counter for digital (mouse) input (port 1)
JOY1DAT ($DFF00C) Counter for digital (mouse) input (port 2)
CIAAPRA ($BFE001) Input and output for pin 6 (port 1 and 2 fire buttons)
POT0DAT ($DFF012) Counter for proportional input (port 1)
POT1DAT ($DFF014) Counter for proportional input (port 2)
POTGO ($DFF034) Write proportional pin values and start counters
POTGOR ($DFF016) Read proportional pin values
BPLCON0 ($DFF100) Bit 3 enables the light pen latch
VPOSR ($DFF004) Read light pen position (high order bits)
VHPOSR ($DFF006) Read light pen position (low order bits)
- Interface Hardware 223 -