bug-coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Od - man page - an example


From: P
Subject: Re: Od - man page - an example
Date: Fri, 10 Sep 2004 09:55:28 +0100
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.6) Gecko/20040124

Cintia Del Rio wrote:
*** Reading the od man page, I found out the -x option could be useful to me.
$ od -x arquivo.bin

0000000 0012 0000 1234 0000 3456 0012 5678 1234
0000020 2211 4433
0000024

As you can see, it's messy to understand. Of course I didn't want
anything like this. I was thinking that a "hexadecimal short" would
give to me TWO HEXADECIMAL DIGITS, and not two bytes. Neither me or my
friends could get it.....

I searched in google and I find another guy that have asked the same thing... Then I tried:
$ od -t x1 arquivo.bin
0000000 12 00 00 00 34 12 00 00 56 34 12 00 78 56 34 12
0000020 11 22 33 44
0000024

Of course little endian looks like crazy, but never mind.
$ od -t x4 arquivo.bin
0000000 00000012 00001234 00123456 12345678
0000020 44332211
0000024

I guess this too examples is the most common things a PC user would
like to use. Maybe they would be useful =)

Sorry I just got this message of this thread.
IMHO examples would be very useful for od.
Personally 99% of the time I use it for a hexdump like:

alias hd='od -Ax -tx1z -v'

Pádraig.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]