Prev: E810 Up: Map Next: E9B4
E8FE: Routine at E8FE
Used by the routine at entrypt_48k.
stop_the_tape E8FE CALL setup_interrupts Call setup_interrupts
E901 CALL music_reset Call music_reset
E904 EI Enable interrupts
E905 HALT Wait for next interrupt
E906 CALL clear_screen Call clear_screen
E909 LD HL,$E9B4 -> "STOP THE TAPE" + "PRESS ANY KEY" message set
E90C CALL menu_draw_strings Call menu_draw_strings
wait_for_keypress E90F CALL define_keys Call define_keys
E912 XOR A Was a key pressed?
E913 IN A,($FE)
E915 CPL
E916 AND $1F
E918 JR Z,wait_for_keypress Loop if not
Debounce.
stop_the_tape_0 E91A CALL define_keys Call define_keys
E91D XOR A Was a key pressed?
E91E IN A,($FE)
E920 CPL
E921 AND $1F
E923 JR NZ,stop_the_tape_0 Loop if it was
stop_the_tape_1 E925 CALL clear_screen Call clear_screen
E928 LD HL,$E9E1 Point HL at input menu messages (NUL terminated)
E92B CALL menu_draw_strings Call menu_draw_strings
stop_the_tape_2 E92E CALL define_keys Call define_keys
E931 LD A,$F7 Keyscan for 1, 2, 3, 4, 5
E933 IN A,($FE)
E935 CPL
E936 AND $1F
E938 JR Z,stop_the_tape_2
E93A RRA Keyscan for 0, 9, 8, 7, 6
E93B JR C,stop_the_tape_3
E93D RRA Keyscan for P, O, I, U, Y
E93E JR C,stop_the_tape_4
E940 RRA Keyscan for ENTER, L, K, J, H
E941 JR C,stop_the_tape_11
E943 RRA Keyscan for SPACE, SYM SHFT, M, N, B
E944 JR C,stop_the_tape_6
E946 CALL redefine_keys
E949 JR stop_the_tape_1
stop_the_tape_3 E94B LD HL,$EE26
E94E JR stop_the_tape_5
stop_the_tape_4 E950 LD HL,$EE2B Copy 5 bytes at $EE2B to $EE38 -- cursor joystick input scheme
stop_the_tape_5 E953 LD DE,$EE38
E956 LD BC,$0005
E959 LDIR
stop_the_tape_6 E95B XOR A
stop_the_tape_7 E95C LD HL,$EE3D Address of three bytes to populate keydefs_probably.. with
E95F LD DE,$A0CC Set Kempston flag
E962 LD (DE),A
E963 INC DE Populate keydefs_probably
E964 LD BC,$0003
E967 LDIR
E969 LD HL,$EE38 Populate $A0D0
E96C LD C,$05
E96E LDIR
E970 CALL clear_screen Call clear_screen
E973 LD HL,$EB78 Address of "control options cannot be remodified" text (NUL terminated)
E976 CALL menu_draw_strings Call menu_draw_strings
stop_the_tape_8 E979 CALL define_keys Call define_keys
E97C XOR A
E97D IN A,($FE) Keyscan
E97F CPL
E980 AND $1F
E982 JR NZ,stop_the_tape_8
stop_the_tape_9 E984 CALL define_keys Call define_keys
E987 LD A,$DF
E989 IN A,($FE) Keyscan
E98B CPL
E98C AND $10
E98E JR NZ,stop_the_tape_10
E990 LD A,$7F
E992 IN A,($FE)
E994 CPL
E995 AND $08
E997 JR NZ,stop_the_tape_1
E999 JR stop_the_tape_9
stop_the_tape_10 E99B DI
E99C JP clear_screen Jump to clear_screen
stop_the_tape_11 E99F LD B,$0A
E9A1 IN A,($1F)
E9A3 LD C,A
stop_the_tape_12 E9A4 IN A,($1F)
E9A6 CP C
E9A7 JR NZ,stop_the_tape_2
E9A9 PUSH BC
E9AA CALL define_keys Call define_keys
E9AD POP BC
E9AE DJNZ stop_the_tape_12
E9B0 LD A,$01
E9B2 JR stop_the_tape_7
Prev: E810 Up: Map Next: E9B4