Initial data commit

This commit is contained in:
Ingy döt Net 2023-07-01 11:58:00 -04:00
parent 72d218235f
commit f23f22d71c
199087 changed files with 3378941 additions and 0 deletions

View file

@ -0,0 +1,48 @@
org &1000
PrintChar equ &BB5A
ld hl,1 ;START AT ONE
main:
push hl
;PRINT HIGH BYTE
ld a,h
call ShowHex
;THEN PRINT LOW BYTE
ld a,l
call ShowHex
;NEW LINE
ld a,13
call PrintChar
ld a,10
call PrintChar
pop hl
;NEXT HL
inc hl
;COMPARE HL TO ZERO
ld a,h
or l
jr nz,main ;IF NOT ZERO, REPEAT
ret ;RETURN TO BASIC
ShowHex:
push af
and %11110000
rrca
rrca
rrca
rrca
call PrintHexChar
pop af
and %00001111
;call PrintHexChar
;execution flows into it naturally.
PrintHexChar:
;this converts hexadecimal to ascii.
or a ;Clear Carry Flag
daa
add a,&F0
adc a,&40
jp PrintChar
;ret