Skip to content

Instantly share code, notes, and snippets.

Created November 9, 2016 03:33
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anonymous/cd0adc762c47bba4265f1bb25528f928 to your computer and use it in GitHub Desktop.
Save anonymous/cd0adc762c47bba4265f1bb25528f928 to your computer and use it in GitHub Desktop.
10 BLOAD"PROGRAM.BIN",R
10 BLOAD"PROGRAM.BIN",R
{"asm":{"filename":"program.bin","build":"bin"},"basic":{}}
; bios call to print a character on screen
CHPUT: equ 0x00a2
; the address of our program
org 0xD000
start:
ld hl, message
mainLoop: ld a, (hl)
cp 0
ret z
call CHPUT
inc hl
jr mainLoop
message:
db "Hello world!",0
; use the label "start" as the entry point
end start
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment