A86: Re: hl to text, part 2...


[Prev][Next][Index][Thread]

A86: Re: hl to text, part 2...




The following routine prints HL in decimal in the small font at the current
pen location.
[String] is the address of a 5 byte buffer where the string will be stored.

; Print HL in small font (B = num decimal places)
vputHL:
 ld de,String+5
 xor a
 ld (de),a
RepUnp:
 dec de
 call UNPACK_HL
 add a,48
 ld (de),a
 djnz RepUnp
 ex de,hl
 jp _vputs



Follow-Ups: