# unit joystick

### Joystick memory registers (Atari XE/XL)

author: Tomasz Biela (Tebe)

## Constants:

name: | value: | description:
--- | --- | ---
joy_none | 15 |
joy_up | 14 |
joy_down | 13 |
joy_left | 11 |
joy_left_up | 10 |
joy_left_down | 9 |
joy_right | 7 |
joy_right_up | 6 |
joy_right_down | 5 |

## Register Variables:

name: | address: | type: | description:
--- | --- | --- | ---
[volatile] joy_1 | $278 | byte | The value of joystick 0
[volatile] joy_2 | $279 | byte | The value of joystick 1
[volatile] stick | $278 | array [0..1] of byte |
[volatile] stick0 | $278 | byte |
[volatile] stick1 | $279 | byte |
[volatile] strig | $284 | array [0..1] of byte |
[volatile] strig0 | $284 | byte | Stick trigger 0
[volatile] strig1 | $285 | byte | Stick trigger 1
[volatile] paddl | $270 | array [0..7] of byte |
[volatile] paddl0 | $270 | byte | The value of paddle 0
[volatile] paddl1 | $271 | byte | The value of paddle 1
[volatile] paddl2 | $272 | byte | The value of paddle 2
[volatile] paddl3 | $273 | byte | The value of paddle 3
[volatile] paddl4 | $274 | byte | The value of paddle 4
[volatile] paddl5 | $275 | byte | The value of paddle 5
[volatile] paddl6 | $276 | byte | The value of paddle 6
[volatile] paddl7 | $277 | byte | The value of paddle 7
[volatile] ptrig | $27c | array [0..7] of byte |
[volatile] ptrig0 | $27c | byte | Paddle trigger 0
[volatile] ptrig1 | $27d | byte | Paddle trigger 1
[volatile] ptrig2 | $27e | byte | Paddle trigger 2
[volatile] ptrig3 | $27f | byte | Paddle trigger 3
[volatile] ptrig4 | $280 | byte | Paddle trigger 4
[volatile] ptrig5 | $281 | byte | Paddle trigger 5
[volatile] ptrig6 | $282 | byte | Paddle trigger 6
[volatile] ptrig7 | $283 | byte | Paddle trigger 7
[volatile] trig0 | $d010 | byte | (R)
[volatile] trig1 | $d011 | byte | (R)