I'll explain a bit further: I can load POSCNTH and POSCNTL, and they show up as correctly loaded, but as soon as the encoder moves, it jumps back to 5535 and rolls to 0 from there....
yep it sorted a few less if then statementslongpole001 Today, 02:14
Just a typo! What else if not shift left.
I'm a noob myself, but no... The VAR.0 syntax is a way of addressing each bit and, while it affects the value of the byte, the bits do not interact.
VAR= %00000000 : VAR.0 = 1...
Hmmm....Answer = answer < 1
If the above is meant to be a shift left operation then what you want is Answer = Answer << 1
However, since Answer is set to 0 at the entry point of the routine...