Re: A83: Re: Hex displaying


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

Re: A83: Re: Hex displaying




They are? Because the last time I checked they weren't... =)

Linus

On 14-Sep-98, Olle Hedman wrote:

>You should be able to speed this up by skipping the map where you look
>up the values in ASCII..
>those is in the asciitable just after eachother.. so you only need to
>add a fixed number to a to transform
>the value of a to the ascii-character of that hex-value..

>//Olle

>Joe Wingbermuehle wrote:
>> 
>> I made a routine awhile back to display a in hex, it shouldn't be too hard
>> to make it display hl in hex (if nothing else you could at least call it
>> twice with h then l).
>> It probably isn't very well coded, but oh well:
>> 
>> ;---------= Display A in Hex =---------
>> ; In: a=number
>> ; Out: a is displayed in hex
>> ; Registers destroyed: af c de hl
>> dispHex:
>>  ld c,a
>>  and %11110000
>>  rra
>>  rra
>>  rra
>>  rra
>>  ld d,0
>>  ld e,a
>>  ld hl,dispHex_map
>>  push hl
>>  add hl,de
>>  ld a,(hl)
>>  call putc
>>  ld a,c
>>  and %00001111
>>  ld e,a
>>  pop hl
>>  add hl,de
>>  ld a,(hl)
>>  jp putc
>> dispHex_map:
>>  .db "0123456789ABCDEF"
>> 
>> Joe Wingbermuehle
>> http://www.usmo.com/~joewing/
>> 
>> -----Original Message-----
>> From: Alan C Johnson <benjamin99@juno.com>
>> To: assembly-83@lists.ticalc.org <assembly-83@lists.ticalc.org>
>> Date: Sunday, September 13, 1998 8:40 PM
>> Subject: A83: Hex displaying
>> 
>> >
>> >How can I display a 16-bit hex number in fixed font?
>> >_____________________________________________________________________
>> >You don't need to buy Internet access to use free Internet e-mail.
>> >Get completely free e-mail from Juno at http://www.juno.com
>> >Or call Juno at (800) 654-JUNO [654-5866]
>> >



References: