Hex Dec Ascii converters
Archiver
Posts: 46,084
Does anybody have a good reference or two to hex<>dec<>ascci
converters for the Basic stamps??
Thanks,
Brent
converters for the Basic stamps??
Thanks,
Brent
Comments
to display, you must convert a value to an ASCII string that represents that
value. Luckily, formatting conversion is built into PBASIC. Try this little
demo (you'll need to latest compiler -- available in beta from our web site):
myNum VAR Word
Main:
DEBUG "Enter a number: "
DEBUGIN myNum
DEBUG CR, CR
DEBUG "Decimal... ", DEC myNum, CR
DEBUG "Hex....... ", IHEX myNum, CR
DEBUG "Binary.... ", IBIN myNum, CR
END
I added "I" in front of the HEX and BIN modifiers to display the '$' and '%'
indicators.
-- Jon Williams
-- Parallax
In a message dated 4/14/2003 9:36:00 AM Central Standard Time,
broyles@i... writes:
> Does anybody have a good reference or two to hex<>dec<>ascci
> converters for the Basic stamps??
[noparse][[/noparse]Non-text portions of this message have been removed]