collapseos/apps/zasm/emul/glue.asm

21 lines
333 B
NASM
Raw Normal View History

#include "user.inc"
; Glue code for the emulated environment
ZASM_INPUT .equ 0xa000
ZASM_OUTPUT .equ 0xd000
jr init
init:
di
ld hl, RAMEND
ld sp, hl
ld hl, ZASM_INPUT
ld de, ZASM_OUTPUT
call USER_CODE
; signal the emulator we're done
; BC contains the number of written bytes
ld a, b
out (c), a
halt
#include "core.asm"