No need for a book! Forum and head-banging is more than enough!
No need for a book! Forum and head-banging is more than enough!
Steve
It's not a bug, it's a random feature.
There's no problem, only learning opportunities.
A VAR WORD
B VAR WORD
TNTH VAR BYTE
HUNDTH VAR BYTE
A = B * 100 'A is temporary storage of computation
A = DIV32 558 'using DIV32... B can be any integer up to 65534
TNTH = A DIG 1 'GRAB THE "TENS" DIGIT FROM "A"
HUNDTH = A DIG 0 'GRAB THE "ONES" DIGIT FROM "A"
A = A / 100 'final result is placed in variable A as an integer... any 'remainder will be discarded.
LDCOUT $FE,1 'CLEAR DISPLAY
LCDOUT "A = ",#A,".",#TNTH,#HUNDTH
I think that would give you what you want.
Ross
Never enough knowledge to be called intelligent but just enough knowledge to be considered dangerous!
I like that! :-)
Bookmarks