3) The right mouse button is mapped to what would be the UP
direction on a joystick
Software Interface:
1) Because the left and right buttons appear as joystick lines,
reading them from software is a simple exercise in polling.
Note that as with a joystick, the buttons will interfere with the
keyboard map, and software should make some effort to
distinguish between a point short in the keyboard matrix
(i.e., a key being depressed), and a whole row or column
being grounded (i.e., a joystick type of signal).
2) The position information is not difficult to handle. Ideally is
should be installed as part of the 60 Hz interrupt routine (pre-
ferably at the beginning — see the section on SID REGI-
_STER CAUTIONS).
This strategy is as follows:
1) Read the mouse position MOD 64.
2)Determine if the mouse has moved by comparing the
current position with a saved copy of the previous
position.
3) If the mouse has moved, then modify your pointer position
appropriately.
You should note, that even ifthe mouse is still, itis possible
forthe
POTregister to oscillate between $80 and $7F.
This would result in the mouse position as jittering bet-
ween two points.
In order to asertain wether the mouse has moved the software
should read the low order bit of the POT register.
All of this can be seen in the supplied mouse driver code.
32000
sédEngisch