Hi,
To put two bytes together into a WORD you can do one of several things:
A: Result.Byte1 = H_Byte : Result.Byte0 = L_Byte
B: Result = (H_Byte << 8) + L_Byte
C: Result = H_Byte*256 + L_Byte
D: .....
However, the READ and WRITE commands have built in support for WORDs (and LONGs on 18F parts) so there's no real need to fiddle with it manually if you don't want to. It's covered in the manual.
/Henrik.
Bookmarks