packet.getData()[0] to packet.getData()[0] & 0xff