interpret next 4 bytes as a signed decimal
od -t d4
format the next 4 bytes as a 4 byte decimal
hexdump -e '/4 " %d"'
- Can specify endianess
--endian=big|little
- Formatting is more intuitive; just
-t [TYPE][SIZE]
forTYPE
in[doux]
(i.e. decimal, octal, unsigned, hex).SIZE
is number of bytes that are considered apart ofTYPE
’s interpretation of the input (e.g. is0x01,0x10
two 1 byte integers or 1 two byte integer?).
- More control of input, output format. The first number of the ‘n/m “%fmt”’ string is the number of elements/iterations to process for elements of byte length “m”. You are also not restricted to only puting format characters in the “” string but can add characters to be written alongside the formatted output.