Add routine to read from IO space from C.
This commit is contained in:
parent
86c3cb709e
commit
828bb38a9a
16
src/io_a.asm
16
src/io_a.asm
@ -16,3 +16,19 @@ _io_out:
|
||||
|
||||
pop ix
|
||||
ret
|
||||
|
||||
PUBLIC _io_in
|
||||
_io_in:
|
||||
push ix
|
||||
ld ix,$0000
|
||||
add ix,sp
|
||||
|
||||
push bc
|
||||
|
||||
ld c,(ix+$04)
|
||||
in l,(c)
|
||||
|
||||
pop bc
|
||||
|
||||
pop ix
|
||||
ret
|
||||
|
Loading…
Reference in New Issue
Block a user