Hi,
I'm having strange result using DIV32 after constants multiplication, but changing both to variables give correct result.
Here is the example code:
Result for X1 is 65535, which is incorrect of course.Code:C1 con 80 C2 con 200 V1 var word V2 var word X1 var word X2 var word v1 = 80 v2 = 200 X1 = c1 * c2 X1 = div32 100 X2 = v1 * v2 X2 = div32 100 lcdout $FE, $80, #X1 lcdout $FE, $C0, #X2
Result for X2 is 160, which is correct.
Any idea why?
J-P
Bookmarks