Prev: 26624 Up: Map Next: 27118
26627: Initialise interrupt code then jump to input device selection menu
Input
IY 23610
The instructions at 26627, 26630, 26631 and 26632 are redundant. They may have been part of a previous development or debugging routine.
26627 LD A,(23728)
26630 OR A
26631 NOP
26632 NOP
26633 XOR A Set A to zero (see trivia)
26634 LD (27236),A Disable debug / cheat mode
26637 LD (27237),A
26640 LD (27238),A
26643 DI Disable interrupts
26644 XOR A Reset update-game-time-and-locate-arrow-glow flag, disable-in-game-glow flag and characters-can't-move flag
26645 LD (IY+65),A
26648 LD A,24 Put JR instruction at 65535 for jumping to interrupt routine
26650 LD (65535),A
26653 LD HL,65524 Load first three bytes of interrupt routine with 195, 69 and 214, corresponding to the instruction JP 54853
26656 LD (HL),195
26658 INC HL
26659 LD (HL),69
26661 INC HL
26662 LD (HL),214
Here we load I with 57, indicating an interrupt vector table at 57 × 256 = 14592. This is an area of ROM filled with FF values. This causes a jump to $FFFF (i.e. 65535) on each interrupt.
26664 LD A,57 Load I register with 57 (for interrupt routine)
26666 LD I,A
26668 EI Enable interrupts
26669 SET 3,(IY+48) Set CAPS LOCK flag (i.e. set CAPS LOCK to ON)
Execution continues into the routine at 26673 that displays the input device selection menu.
Prev: 26624 Up: Map Next: 27118