Well, probably something like this

Code:
wDummy=wTemp * (wWeight2-wWeight1)

IF wDummy > 65536 THEN
   wDummy=wTemp * (wWeight2-wWeight1)  'This line needs to be before DIV32
   wTemp= DIV32 100
ENDIF