Added library reference joy_libref to JOY interface.
This commit is contained in:
@@ -36,6 +36,10 @@ PREAD := $FB1E ; Read paddle in X, return AD conv. value in Y
|
||||
.byte $6A, $6F, $79 ; "joy"
|
||||
.byte JOY_API_VERSION ; Driver API version number
|
||||
|
||||
; Library reference
|
||||
|
||||
.addr $0000
|
||||
|
||||
; Button state masks (8 values)
|
||||
|
||||
.byte $10
|
||||
|
||||
@@ -2,7 +2,8 @@
|
||||
; Oliver Schmidt, 2013-05-31
|
||||
;
|
||||
|
||||
.export em_libref
|
||||
.export em_libref, joy_libref
|
||||
.import _exit
|
||||
|
||||
em_libref := _exit
|
||||
joy_libref := _exit
|
||||
|
||||
@@ -26,6 +26,10 @@
|
||||
.byte $6A, $6F, $79 ; "joy"
|
||||
.byte JOY_API_VERSION ; Driver API version number
|
||||
|
||||
; Library reference
|
||||
|
||||
.addr $0000
|
||||
|
||||
; Button state masks (8 values)
|
||||
|
||||
.byte $02 ; JOY_UP
|
||||
|
||||
@@ -25,6 +25,10 @@
|
||||
.byte $6A, $6F, $79 ; "joy"
|
||||
.byte JOY_API_VERSION ; Driver API version number
|
||||
|
||||
; Library reference
|
||||
|
||||
.addr $0000
|
||||
|
||||
; Button state masks (8 values)
|
||||
|
||||
.byte $01 ; JOY_UP
|
||||
|
||||
@@ -2,7 +2,8 @@
|
||||
; Oliver Schmidt, 2013-05-31
|
||||
;
|
||||
|
||||
.export em_libref
|
||||
.export em_libref, joy_libref
|
||||
.import _exit
|
||||
|
||||
em_libref := _exit
|
||||
joy_libref := _exit
|
||||
|
||||
@@ -21,6 +21,10 @@
|
||||
.byte $6A, $6F, $79 ; "joy"
|
||||
.byte JOY_API_VERSION ; Driver API version number
|
||||
|
||||
; Library reference
|
||||
|
||||
.addr $0000
|
||||
|
||||
; Button state masks (8 values)
|
||||
|
||||
.byte $10 ; JOY_UP
|
||||
|
||||
8
libsrc/atmos/libref.s
Normal file
8
libsrc/atmos/libref.s
Normal file
@@ -0,0 +1,8 @@
|
||||
;
|
||||
; Oliver Schmidt, 2013-05-31
|
||||
;
|
||||
|
||||
.export joy_libref
|
||||
.import _exit
|
||||
|
||||
joy_libref := _exit
|
||||
@@ -24,6 +24,10 @@
|
||||
.byte $6A, $6F, $79 ; "joy"
|
||||
.byte JOY_API_VERSION ; Driver API version number
|
||||
|
||||
; Library reference
|
||||
|
||||
.addr $0000
|
||||
|
||||
; Button state masks (8 values)
|
||||
|
||||
.byte $01 ; JOY_UP
|
||||
|
||||
@@ -25,6 +25,10 @@
|
||||
.byte $6A, $6F, $79 ; "joy"
|
||||
.byte JOY_API_VERSION ; Driver API version number
|
||||
|
||||
; Library reference
|
||||
|
||||
.addr $0000
|
||||
|
||||
; Button state masks (8 values)
|
||||
|
||||
.byte $01 ; JOY_UP
|
||||
|
||||
@@ -2,7 +2,8 @@
|
||||
; Oliver Schmidt, 2013-05-31
|
||||
;
|
||||
|
||||
.export em_libref
|
||||
.export em_libref, joy_libref
|
||||
.import _exit
|
||||
|
||||
em_libref := _exit
|
||||
joy_libref := _exit
|
||||
|
||||
@@ -2,7 +2,8 @@
|
||||
; Oliver Schmidt, 2013-05-31
|
||||
;
|
||||
|
||||
.export em_libref
|
||||
.export em_libref, joy_libref
|
||||
.import _exit
|
||||
|
||||
em_libref := _exit
|
||||
joy_libref := _exit
|
||||
|
||||
@@ -23,6 +23,10 @@
|
||||
.byte $6A, $6F, $79 ; "joy"
|
||||
.byte JOY_API_VERSION ; Driver API version number
|
||||
|
||||
; Library reference
|
||||
|
||||
.addr $0000
|
||||
|
||||
; Button state masks (8 values)
|
||||
|
||||
.byte $01 ; JOY_UP
|
||||
|
||||
@@ -25,6 +25,10 @@
|
||||
.byte $6A, $6F, $79 ; "joy"
|
||||
.byte JOY_API_VERSION ; Driver API version number
|
||||
|
||||
; Library reference
|
||||
|
||||
.addr $0000
|
||||
|
||||
; Button state masks (8 values)
|
||||
|
||||
.byte $02 ; JOY_UP "8"
|
||||
|
||||
@@ -23,6 +23,10 @@
|
||||
.byte $6A, $6F, $79 ; "joy"
|
||||
.byte JOY_API_VERSION ; Driver API version number
|
||||
|
||||
; Library reference
|
||||
|
||||
.addr $0000
|
||||
|
||||
; Button state masks (8 values)
|
||||
|
||||
.byte $01 ; JOY_UP
|
||||
|
||||
@@ -24,6 +24,10 @@
|
||||
.byte $6A, $6F, $79 ; "joy"
|
||||
.byte JOY_API_VERSION ; Driver API version number
|
||||
|
||||
; Library reference
|
||||
|
||||
.addr $0000
|
||||
|
||||
; Button state masks (8 values)
|
||||
|
||||
.byte $01 ; JOY_UP
|
||||
|
||||
@@ -2,7 +2,8 @@
|
||||
; Oliver Schmidt, 2013-05-31
|
||||
;
|
||||
|
||||
.export em_libref
|
||||
.export em_libref, joy_libref
|
||||
.import _exit
|
||||
|
||||
em_libref := _exit
|
||||
joy_libref := _exit
|
||||
|
||||
@@ -25,6 +25,10 @@
|
||||
.byte $6A, $6F, $79 ; "joy"
|
||||
.byte JOY_API_VERSION ; Driver API version number
|
||||
|
||||
; Library reference
|
||||
|
||||
.addr $0000
|
||||
|
||||
; Button state masks (8 values)
|
||||
|
||||
.byte $01 ; JOY_UP
|
||||
|
||||
@@ -2,7 +2,8 @@
|
||||
; Oliver Schmidt, 2013-05-31
|
||||
;
|
||||
|
||||
.export em_libref
|
||||
.export em_libref, joy_libref
|
||||
.import _exit
|
||||
|
||||
em_libref := _exit
|
||||
joy_libref := _exit
|
||||
|
||||
@@ -22,6 +22,10 @@
|
||||
.byte $6A, $6F, $79 ; "joy"
|
||||
.byte JOY_API_VERSION ; Driver API version number
|
||||
|
||||
; Library reference
|
||||
|
||||
.addr $0000
|
||||
|
||||
; Button state masks (8 values)
|
||||
|
||||
.byte $01 ; JOY_UP
|
||||
|
||||
@@ -2,7 +2,8 @@
|
||||
; Oliver Schmidt, 2013-05-31
|
||||
;
|
||||
|
||||
.export em_libref
|
||||
.export em_libref, joy_libref
|
||||
.import _exit
|
||||
|
||||
em_libref := _exit
|
||||
joy_libref := _exit
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
; Common functions of the joystick API.
|
||||
;
|
||||
|
||||
.import joy_libref
|
||||
.importzp ptr1
|
||||
.interruptor joy_irq ; Export as IRQ handler
|
||||
|
||||
@@ -55,6 +56,15 @@ _joy_install:
|
||||
dey
|
||||
bpl @L0
|
||||
|
||||
; Set the library reference
|
||||
|
||||
ldy #JOY_HDR::LIBREF
|
||||
lda #<joy_libref
|
||||
sta (ptr1),y
|
||||
iny
|
||||
lda #>joy_libref
|
||||
sta (ptr1),y
|
||||
|
||||
; Copy the mask array
|
||||
|
||||
ldy #JOY_HDR::MASKS + .sizeof(JOY_HDR::MASKS) - 1
|
||||
|
||||
@@ -26,6 +26,10 @@
|
||||
.byte $6A, $6F, $79 ; "joy"
|
||||
.byte JOY_API_VERSION ; Driver API version number
|
||||
|
||||
; Library reference
|
||||
|
||||
.addr $0000
|
||||
|
||||
; Button state masks (8 values)
|
||||
|
||||
joy_mask:
|
||||
|
||||
8
libsrc/lynx/libref.s
Normal file
8
libsrc/lynx/libref.s
Normal file
@@ -0,0 +1,8 @@
|
||||
;
|
||||
; Oliver Schmidt, 2013-05-31
|
||||
;
|
||||
|
||||
.export joy_libref
|
||||
.import _exit
|
||||
|
||||
joy_libref := _exit
|
||||
@@ -23,6 +23,10 @@
|
||||
.byte $6A, $6F, $79 ; "joy"
|
||||
.byte JOY_API_VERSION ; Driver API version number
|
||||
|
||||
; Library reference
|
||||
|
||||
.addr $0000
|
||||
|
||||
; Button state masks (8 values)
|
||||
|
||||
.byte $10 ; JOY_UP
|
||||
|
||||
8
libsrc/nes/libref.s
Normal file
8
libsrc/nes/libref.s
Normal file
@@ -0,0 +1,8 @@
|
||||
;
|
||||
; Oliver Schmidt, 2013-05-31
|
||||
;
|
||||
|
||||
.export joy_libref
|
||||
.import _exit
|
||||
|
||||
joy_libref := _exit
|
||||
@@ -24,6 +24,10 @@ VIA_DDRA := $E843 ; Data direction register A
|
||||
.byte $6A, $6F, $79 ; "joy"
|
||||
.byte JOY_API_VERSION ; Driver API version number
|
||||
|
||||
; Library reference
|
||||
|
||||
.addr $0000
|
||||
|
||||
; Button state masks (8 values)
|
||||
|
||||
.byte $01 ; JOY_UP
|
||||
|
||||
@@ -21,6 +21,10 @@
|
||||
.byte $6A, $6F, $79 ; "joy"
|
||||
.byte JOY_API_VERSION ; Driver API version number
|
||||
|
||||
; Library reference
|
||||
|
||||
.addr $0000
|
||||
|
||||
; Button state masks (8 values)
|
||||
|
||||
.byte $01 ; JOY_UP
|
||||
|
||||
8
libsrc/pet/libref.s
Normal file
8
libsrc/pet/libref.s
Normal file
@@ -0,0 +1,8 @@
|
||||
;
|
||||
; Oliver Schmidt, 2013-05-31
|
||||
;
|
||||
|
||||
.export joy_libref
|
||||
.import _exit
|
||||
|
||||
joy_libref := _exit
|
||||
@@ -24,6 +24,10 @@
|
||||
.byte $6A, $6F, $79 ; "joy"
|
||||
.byte JOY_API_VERSION ; Driver API version number
|
||||
|
||||
; Library reference
|
||||
|
||||
.addr $0000
|
||||
|
||||
; Button state masks (8 values)
|
||||
|
||||
.byte $01 ; JOY_UP
|
||||
|
||||
8
libsrc/plus4/libref.s
Normal file
8
libsrc/plus4/libref.s
Normal file
@@ -0,0 +1,8 @@
|
||||
;
|
||||
; Oliver Schmidt, 2013-05-31
|
||||
;
|
||||
|
||||
.export joy_libref
|
||||
.import _exit
|
||||
|
||||
joy_libref := _exit
|
||||
@@ -23,6 +23,10 @@
|
||||
.byte $6A, $6F, $79 ; "joy"
|
||||
.byte JOY_API_VERSION ; Driver API version number
|
||||
|
||||
; Library reference
|
||||
|
||||
.addr $0000
|
||||
|
||||
; Button state masks (8 values)
|
||||
|
||||
.byte $01 ; JOY_UP
|
||||
|
||||
@@ -25,6 +25,10 @@
|
||||
.byte $6A, $6F, $79 ; "joy"
|
||||
.byte JOY_API_VERSION ; Driver API version number
|
||||
|
||||
; Library reference
|
||||
|
||||
.addr $0000
|
||||
|
||||
; Button state masks (8 values)
|
||||
|
||||
.byte $02 ; JOY_UP
|
||||
|
||||
8
libsrc/vic20/libref.s
Normal file
8
libsrc/vic20/libref.s
Normal file
@@ -0,0 +1,8 @@
|
||||
;
|
||||
; Oliver Schmidt, 2013-05-31
|
||||
;
|
||||
|
||||
.export joy_libref
|
||||
.import _exit
|
||||
|
||||
joy_libref := _exit
|
||||
Reference in New Issue
Block a user