[Baypiggies] hex dump in Python 3

Nick Stinemates nstinemates at gmail.com
Sun Jan 30 23:03:27 CET 2011


Take a look at the binascii module:
http://docs.python.org/library/binascii.html

On Sun, Jan 30, 2011 at 1:32 PM, Tom Simons <tom.simons at gmail.com> wrote:

> Does anyone have a sample hex-dump routine for Python3? I'm trying to
> recover data from a BlackBerry backup file, & I need to "see" the bytes I'm
> reading from the  backup file,which don't  appear to match the format I've
> found. Something showing the offset, char-hex, and printable chars (or
> periods), such as:
>
> bs = f.read(flen)
> hexdump(bs)
> 00000000 01020304050607083031323334353637 ........01234567
> 00000010 4142436162                       ABCab
>
>
> _______________________________________________
> Baypiggies mailing list
> Baypiggies at python.org
> To change your subscription options or unsubscribe:
> http://mail.python.org/mailman/listinfo/baypiggies
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/baypiggies/attachments/20110130/8eb3991a/attachment.html>


More information about the Baypiggies mailing list