Class SerialDataDumper

    • Constructor Detail

      • SerialDataDumper

        public SerialDataDumper​(EndianUtil endianUtil,
                                int addressOffset)
        Construct a new SerialDataDumper.
        Parameters:
        endianUtil - EndianUtil; used to decode multi-byte values
        addressOffset - int; address of the first byte that will be processed
      • SerialDataDumper

        public SerialDataDumper​(EndianUtil endianUtil)
        Construct a new SerialDataDumper.
        Parameters:
        endianUtil - EndianUtil; used to decode multi-byte values
    • Method Detail

      • serialDataDumper

        public static String serialDataDumper​(EndianUtil endianUtil,
                                              int addressOffset,
                                              byte[] bytes)
        Create a SerialDataDumper object; use it to dump an array of bytes and return the dump as a String.
        Parameters:
        endianUtil - EndianUtil; used to decode multi-byte values
        addressOffset - int; address of the first byte
        bytes - byte[]; the bytes to hex-dump
        Returns:
        String; the hexadecimal and character dump of the bytes
      • serialDataDumper

        public static String serialDataDumper​(EndianUtil endianUtil,
                                              byte[] bytes)
        Create a SerialDataDumper object with addressOffset 0; use it to dump an array of bytes and return the dump as a String.
        Parameters:
        endianUtil - EndianUtil; used to decode multi-byte values
        bytes - byte[]; the bytes to hex-dump
        Returns:
        String; the hexadecimal and character dump of the bytes