Quote Originally Posted by savnik View Post
I have two variables
Var1 var word
Var2 var word
The var1 is always 1 and the var2 is anything from 0 to 65535.
var1 = 00000000 00000001
var2 = 11111011 11010000
var1 + var2 = 00000000 00000001 11111011 11010000
Decimal = 130000
I want to show on LCD as Result = 1300,00
How to show the result on LCD;
Here we go again...

1) Get the update for PBP 2.50A. Handles LONG (31 bit variables, +/- 2,000,000,000)

2) Split the variable up the hard way...
original var1 = $1
original var2 = $fbd0
Add a small subroutine in your program to make it so that each word 'handles' 4 digits, so you end up with:
varhigh var word 'in this case it will be 0
varmed var word 'in this case should end up with 0013
varlow var word 'in this case should end up with 0000

Shouldn't be THAT hard.