public static byte[] toByteArray(byte b) {
        byte[] array = new byte[1];
        array[0] = b;
        return array;
    }
Clone of Android's /core/java/com/android/internal/util/HexDump class, for use in debugging.
Changes: space separated hex strings
usbSerialForAndroid/src/main/java/com/hoho/android/usbserial/util/HexDump.java