Change the sematics of callirq and the existing interruptors: The interrupts

must now return carry set if the interrupt has been handled, and carry clear
if not. The callirq routine will stop calling handlers with the first handler
that claims to have handled the interrupt. callirq will return the carry flag
to the caller as it came from the last interruptor called.


git-svn-id: svn://svn.cc65.org/cc65/trunk@3491 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
cuz
2005-04-25 20:10:10 +00:00
parent 2a688ef6fd
commit cbdcab4fdb
6 changed files with 39 additions and 16 deletions

View File

@@ -269,7 +269,9 @@ IOCTL: lda #<MOUSE_ERR_INV_IOCTL ; We don't support ioclts for now
;----------------------------------------------------------------------------
; IRQ: Irq handler entry point. Called as a subroutine but in IRQ context
; (so be careful).
; (so be careful). The routine MUST return carry set if the interrupt has been
; 'handled' - which means that the interrupt source is gone. Otherwise it
; MUST return carry clear.
;
IRQ: lda SID_ADConv1 ; Get mouse X movement
@@ -355,10 +357,11 @@ IRQ: lda SID_ADConv1 ; Get mouse X movement
; Move the mouse pointer to the new X pos
tya
jmp CMOVEY
jsr CMOVEY
; Done
clc ; Interrupt not "handled"
@SkipY: rts
; --------------------------------------------------------------------------