[A83] Re: HL to string


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

[A83] Re: HL to string




Can the algorithm be extended to 4 byte integers?


>From: "Kirk Meyer" <kirk.meyer@colorado.edu>
>Reply-To: assembly-83@lists.ticalc.org
>To: <assembly-83@lists.ticalc.org>
>Subject: [A83] Re: HL to string
>Date: Sat, 7 Jul 2001 19:54:18 -0600
>
>
>You could use DivHLBy10 5 times and work from the end of the string back,
>storing the remainder each time to the output pointer and decrementing that
>pointer by 1. Another interesting method, however, is described at this
>link:
>http://conmael.ee.pitt.edu/courses/0142/hoelzeman/ee0142%20-%20ass10.htm
>I think it might be faster. Note that page shows for a byte, but the
>algorithm should be able to be extended to a word pretty easily. To change
>it, COUNT is originally 16, and you would have TENTHOUSANDS, THOUSANDS,
>HUNDREDS, TENS, and ONES slots. These could be stored in OP1, for example.
>
>-----Original Message-----
>From: assembly-83-bounce@lists.ticalc.org
>[mailto:assembly-83-bounce@lists.ticalc.org]On Behalf Of Joe Pemberton
>Sent: Saturday, July 07, 2001 7:45 PM
>To: assembly-83@lists.ticalc.org
>Subject: [A83] HL to string
>
>
>
>How would I go about changing a number in a two byte register pair to a 5
>byte string?
>
>i.e.  hl=33457
>result=
>  .db 3,3,4,5,7
>
>any routines or pointers would be helpful =)
>
>_____________________________________________
>Free email with personality! Over 200 domains!
>http://www.MyOwnEmail.com
>
>
>
>

_________________________________________________________________
Get your FREE download of MSN Explorer at http://explorer.msn.com




Follow-Ups: