From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1IHcqc-00071f-VY for mharc-grub-devel@gnu.org; Sun, 05 Aug 2007 05:56:31 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1IHcqb-00071U-2S for grub-devel@gnu.org; Sun, 05 Aug 2007 05:56:29 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1IHcqT-00070s-SH for grub-devel@gnu.org; Sun, 05 Aug 2007 05:56:28 -0400 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1IHcqT-00070l-ON for grub-devel@gnu.org; Sun, 05 Aug 2007 05:56:21 -0400 Received: from aybabtu.com ([69.60.117.155]) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1IHcqM-0007AD-3g for grub-devel@gnu.org; Sun, 05 Aug 2007 05:56:14 -0400 Received: from [192.168.10.6] (helo=aragorn) by aybabtu.com with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.63) (envelope-from ) id 1IHcpl-0003P3-Rp for grub-devel@gnu.org; Sun, 05 Aug 2007 11:55:38 +0200 Received: from rmh by aragorn with local (Exim 4.63) (envelope-from ) id 1IHcsz-0006j5-7A for grub-devel@gnu.org; Sun, 05 Aug 2007 11:58:57 +0200 Date: Sun, 5 Aug 2007 11:58:57 +0200 From: Robert Millan To: The development of GRUB 2 Message-ID: <20070805095857.GA25768@aragorn> References: <20070804094936.GA8207@aragorn> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Organization: free as in freedom X-Message-Flag: Microsoft discourages use of Outlook. X-Debbugs-No-Ack: true User-Agent: Mutt/1.5.13 (2006-08-11) X-Detected-Kernel: Genre and OS details not recognized. Subject: Re: New command dump X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: The development of GRUB 2 List-Id: The development of GRUB 2 List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 05 Aug 2007 09:56:29 -0000 On Sat, Aug 04, 2007 at 11:21:24PM +0800, Bean wrote: > On 8/4/07, Robert Millan wrote: > > On Fri, Aug 03, 2007 at 11:33:38PM +0800, Bean wrote: > > > Hi, > > > > > > I have written a new command dump, it can hex dump content of file or memory. > > > > > > usage: > > > > > > dump [-s skip] [-n length] { FILE | (mem) } > > > > > > The output look just like command hexdump. > > > > I see that the output of hexdump is the same as "od -x". However, I find > > "od -tx1" more useful. Maybe it would be better to do that instead? > > In my system, hexdump output look like this: > > 00000000 eb 5e 80 05 20 39 ff ff 00 00 00 00 02 02 40 00 |.^.. 9........@.| > 00000010 02 00 02 43 7d f8 3f 00 3f 00 ff 00 00 00 00 00 |...C}.?.?.......| > 00000020 00 00 00 00 80 00 29 00 00 00 00 20 20 20 20 20 |......).... | > 00000030 20 20 20 20 20 20 46 41 54 31 36 20 20 20 00 00 | FAT16 ..| > > od -tx1: > > 0000000 eb 5e 80 05 20 39 ff ff 00 00 00 00 02 02 40 00 > 0000020 02 00 02 43 7d f8 3f 00 3f 00 ff 00 00 00 00 00 > 0000040 00 00 00 00 80 00 29 00 00 00 00 20 20 20 20 20 > 0000060 20 20 20 20 20 20 46 41 54 31 36 20 20 20 00 00 > > I think the previous one looks better, because it has text char as > well as hex value. I was referring to: $ hexdump /bin/ls | head -n 1 0000000 457f 464c 0102 0001 0000 0000 0000 0000 $ od -tx1 /bin/ls | head -n 1 0000000 7f 45 4c 46 02 01 01 00 00 00 00 00 00 00 00 00 Your example seems ok IMO. -- Robert Millan I know my rights; I want my phone call! What use is a phone call, if you are unable to speak? (as seen on /.)