int a = 65535; // 16 bit integer
byte MSB = a/256;
byte LSB = a % 256;
.. and back:
byte MSB, LSB;
int a1 = ( MSB << 8 ) | LSB;
int a = 65535; // 16 bit integer
byte MSB = a/256;
byte LSB = a % 256;
.. and back:
byte MSB, LSB;
int a1 = ( MSB << 8 ) | LSB;