| |
MRT Account closed
Registered: Sep 2005 Posts: 149 |
2 bit irq loader
Hmm, just a question...
Is there a 2 bit irq loader, which doesn't require blocking other interrupts while loading a byte?
i.o.w. Is there a realy fast irq loader which doesn't block any interrupts and let me use my beloved sprites? :-)
|
|
... 50 posts hidden. Click here to view all posts.... |
| |
MagerValp
Registered: Dec 2001 Posts: 1078 |
BIT has an implicit AND that sets the Z reg. To wait for DATA use BMI/BPL. To wait for CLOCK use BVC/BVS. To wait for both, use lda #$c0 and BEQ/BNE.
On the 1541 you lda #1, #4, or #5 and then BEQ/BNE.
|
| |
j0x
Registered: Mar 2004 Posts: 215 |
Magervalp: I think MRT questions using BIT for checking that *both* bits are 1. lda #$c0 bit $dd00 will set the zero flag if and only if both bits are zero. If one bit is 1 and the other is 0, then the BNE will branch, which is not (if I understand MRT correctly) the desired behaviour. But you're right: checking that both bits are 0 can be achieved by checking the zero flag.
/Stefan
|
Previous - 1 | 2 | 3 | 4 | 5 | 6 - Next |