BluetoothUtil { public static short bytesToShort(byte b1, byte b2) { return (short) (((b1 & 0xff) << 8) | (b2 & 0xff)); }  @NonNull static String byteArrayToHex(@NonNull byte[] a); static short bytesToShort(byte b1, byte b2); static void sleep(long t);  }
@Test public void bytesToShort() { assertEquals(0x666f, BluetoothUtil.bytesToShort((byte) 0x66, (byte) 0x6f)); }