UAZU-Up-

hd -- traditional hex dump tool

This is a nice traditional hex-dump tool. I wrote it in some moment of frustration when I found the tools available to me wouldn't do what I wanted them to. Apart from a traditional hex-dump, it also does a C-style escaped text dump, and also a real-time dump updated byte-by-byte (which is useful for monitoring incoming serial data). The width of the display can be adjusted.

000000: 7f 45 4c 46 01 01 01 00  00 00 00 00 00 00 00 00   .ELF............
000010: 02 00 03 00 01 00 00 00  30 8a 04 08 34 00 00 00   ........0...4...
000020: f0 4c 00 00 00 00 00 00  34 00 20 00 06 00 28 00   .L......4. ...(.
000030: 19 00 18 00 06 00 00 00  34 00 00 00 34 80 04 08   ........4...4...
000040: 34 80 04 08 c0 00 00 00  c0 00 00 00 05 00 00 00   4...............
000050: 04 00 00 00 03 00 00 00  f4 00 00 00 f4 80 04 08   ................
000060: f4 80 04 08 13 00 00 00  13 00 00 00 04 00 00 00   ................
000070: 01 00 00 00 01 00 00 00  00 00 00 00 00 80 04 08   ................

Or like this:

0035d4: \x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00Usage: hd [-r124] [f
0035f5: iles..]\n
0035fc:   -r         Real-time update\n
00361a:   -a         Omit addresses at the start of lines\n
00364c:   -d         Leave duplicate lines in\n
003672:   -1 -2 etc  Display `n' bytes per line\n
00369a:   -t         Text only, with C-style escapes\n
0036c7: \x00Invalid bytes per line: %d\x00Out of memory\x00r\x00Can't open file:
003704:  %s\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00
003718: \x00\x00\x00\x00\x00\x00\x00\x00\x00Can't set non-blocking input for rea

Download

  hd.tgz (4K)


UAZU-Up- These pages and files, including applets and artwork, are Copyright (c) 1997-2019 Jim Peters unless otherwise stated. Please contact me if you'd like to use anything not explicitly released, or if you have something interesting to discuss.