This page (revision-14) was last changed on 03-Feb-2023 15:21 by Florian Dingler 

This page was created on 14-Mar-2010 18:11 by Carsten Strotmann

Only authorized users are allowed to rename pages.

Only authorized users are allowed to delete pages.

Page revision history

Version Date Modified Size Author Changes ... Change note
14 03-Feb-2023 15:21 4 KB Florian Dingler to previous
13 07-Jul-2018 21:28 4 KB Florian Dingler to previous | to last
12 30-Jun-2018 14:32 4 KB Florian Dingler to previous | to last
11 30-Jun-2018 14:27 3 KB Florian Dingler to previous | to last
10 08-Oct-2017 19:34 3 KB Florian Dingler to previous | to last
9 10-Mar-2017 22:36 3 KB Florian Dingler to previous | to last
8 10-Mar-2017 21:10 3 KB Florian Dingler to previous | to last
7 10-Mar-2017 21:07 3 KB Florian Dingler to previous | to last
6 09-Jan-2012 08:33 2 KB Gromit to previous | to last
5 05-Jan-2011 14:01 2 KB Gromit to previous | to last
4 05-Jan-2011 13:50 2 KB Carsten Strotmann to previous | to last
3 22-Mar-2010 22:17 2 KB Florian Dingler to previous | to last
2 15-Mar-2010 09:08 2 KB Gromit to previous | to last
1 14-Mar-2010 18:11 2 KB Carsten Strotmann to last

Page References

Incoming links Outgoing links

Version management

Difference between version and

At line 101 changed 3 lines
PACTL==&$FB ; set bit 3 of pactl to 0. 1=use Port A for data input/output, 0=define data direction
PORTA=$F0 ; set upper nibble of porta to write (1111) and lower nibble to read (0000)
PACTL==%$04 ; set bit 3 of pactl to 1 again. 1=use Port A for data input/output, 0=define data direction
PACTL==&$FB
PORTA=$F0
PACTL==%$04
At line 110 changed 2 lines
; call procedure stating PL (range 0...8) and 2 pointers to variables to which the result is returned
; e.g. "QUERYMULJOY(0,ST,TR)" check for Joystick 0, return values in the variable ST and TR point to
; call procedure stating PL (range 0...3) and 2 variables to which the result is returned
; e.g. "QUERYMULJOY(0,ST,TR)" check for Joystick 0, return values in ST and TR
At line 115 changed 5 lines
PORTA=(PL LSH 4) ; LSH 4 is the same as multiply by 4
PL=6
DO PL==-1 UNTIL PL=0 OD ; wait a wee bit so the PIA can adjust to the new value
TRI^=TRIG0 ; now read the trigger
STI^=(PORTA&$0F) ; and read the joystick, and blank out the high nibble by ANDing %00001111=$0F
PORTA=(PL LSH 4)
WSYNC=PL
WSYNC=PL
TRI^=TRIG0
STI^=(PORTA&$0F)
At line 125 changed 2 lines
BYTE TRI,STI,PL
BYTE POINTER S,T
BYTE TRI,STI,PL
BYTE POINTER S,T
At line 128 changed 2 lines
S=@STI ; pointer S now points to STI
T=@TRI ; and T to TRI
S=@STI
T=@TRI
At line 131 changed 10 lines
DO ; main loop
FOR PL=0 to 8 DO
QUERYMULJOY(PL,S,T) ; hand over the joystick number you want to query and two POINTERs for Stick and Trigger
; variables where you want the results.
; STI now holds the value for the stick
; TRI now holds the value for the trigger
; go ahead and do something with it...
OD
OD ; end of main loop
RETURN
DO ; main loop
At line 133 added 7 lines
FOR PL=0 to 8 DO
QUERYMULJOY(PL,S,T)
; STI now holds the value for the stick
; TRI now holds the value for the trigger
; go ahead and do something with it...
OD
OD ; end of main loop
At line 141 added 2 lines