Created
December 1, 2018 20:51
-
-
Save neuro-sys/b8bb7187540a17308bf0b3fe0a7836fd to your computer and use it in GitHub Desktop.
Amstrad CPC interrupts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
org &8000 | |
run &8000 | |
di | |
im 1 | |
ld a, &c3 | |
ld bc, int1 | |
ld (&38), a | |
ld (&39), bc | |
ld bc, &7f10 | |
out (c), c | |
ei | |
jp $ | |
int1: | |
push bc | |
ld bc, &7f5c | |
out (c),c | |
ld bc, int2 | |
jp int_ret | |
int2: | |
push bc | |
ld bc, &7f55 | |
out (c),c | |
ld bc, int3 | |
jp int_ret | |
int3: | |
push bc | |
ld bc, &7f4b | |
out (c),c | |
ld bc, int4 | |
jr int_ret | |
int4: | |
push bc | |
ld bc, &7f4d | |
out (c),c | |
ld bc, int5 | |
jr int_ret | |
int5: | |
push bc | |
ld bc, &7f56 | |
out (c),c | |
ld bc, int6 | |
jr int_ret | |
int6: | |
push bc | |
ld bc, &7f5f | |
out (c),c | |
ld bc, int1 | |
jr int_ret | |
int_ret: | |
ld (&39), bc | |
pop bc | |
ei | |
ret |
Author
neuro-sys
commented
Dec 1, 2018
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment