Count in octal: Difference between revisions

m
Line 208:
lhld oldstk ; get CP/M's stack back
sphl ; restore it
ret ; backexit to thecommand ccpprompt w/o warm booting
;------------------------------------------------------
; Octal output routine
Line 224:
mov a,l ; test if hl = 0
ora h
cnz putoct ; recursive call
pop h ; get unshifted hl back
push h
Line 257:
; Console output routine
; print character in A register to console
; preserves BC, DE, and HL
;------------------------------------------------------
putchr: push h
Line 262 ⟶ 263:
push b
mov e,a ; character to E for CP/M
mvi c,2 ; console output functionconout
call bdos ; call on BDOS to perform
pop b
pop d
211

edits