I'm reading a packet with a length of 133 bytes from the serialport, the last 2 bytes contain the CRC values, 2 byte values I've made single (short I think) using Java.
This what I have done:
short high = (-48 & 0x00ff);
short low = 80;
short c = (short) ((high << 8) + low);
But I'm not getting the correct result. Is it a problem because of the use of signed values? How can I solve this problem?