'show received data as hex dump'

def rx(self, data):

    if self.color:
        self.output.write(self.rx_color)
    if data:
        for (offset, row) in hexdump(data):
            self.write_line((time.time() - self.start_time), 'RX', '{:04X}        '.format(offset), row)
    else:
        self.write_line((time.time() - self.start_time), 'RX', '<empty>')
