Discussion:
[BitPim-devel] Improved Hex Viewer
Joe Pham
2005-05-19 04:31:57 UTC
Permalink
I just committed some improvements to the Hex Viewer hoping that it would become more useful as part of decyphering various phone files. This version displays various info like current offset into the file, the start/end and length of a selection (very useful in trying to determine a record of an item), various number representations of a block of bytes (signed/unsigned char, little/big endian signed/unsigned short/int), and the ability to import a Python module and apply a Python function over the data (which I find to be the most helpful, personally). A function needs to have the following prototype to be used with this Hex Viewer:

def f(parent, data, offset):
....
return result

where parent: the parent widget; data: the whole data string, and offset: current offset where the cursor is. This function should return a list of dict containing the labels and their value strings to be displayed ie [{'label1': 'value1'} , { 'label2': 'value2'}, ... ]

My next feature is to allow users to create data structures on the fly and apply&test them over the actual data. This would be very helpful in trying to figure out various components within a record of an item.

As always, comments and suggestions are welcome.

-Joe Pham


______________________________________________________________________
Get NetZero Platinum for as low as $4.97/month!
Unlimited Internet Access with 250MB of Email Storage.
Visit http://www.netzero.com/half to sign up today!
Roger Binns
2005-05-23 05:46:07 UTC
Permalink
Post by Joe Pham
I just committed some improvements to the Hex Viewer
They appear to have broken the analyser. Every time I
click anywhere in the hex view in the analyser an
exception appears.

BTW there were plans for the status bar that was there
(shown at the bottom when there was focus). The intention
was that when editting is added it would show the mode
(insert vs overwrite) as well the byte/word values. In
edit mode the tab key should toggle sides from the bytes to
the character dump.

Roger
Stephen Wood
2005-05-23 09:46:35 UTC
Permalink
Post by Roger Binns
Post by Joe Pham
I just committed some improvements to the Hex Viewer
They appear to have broken the analyser. Every time I
click anywhere in the hex view in the analyser an
exception appears.
I also made a patch to the hex viewer, although I don't think it
should have broken it. I added an option to the right click menu to
save the contents as a hex dump formatted the way the protocol
analyzer expects.

Stephen
Joe Pham
2005-05-23 15:03:50 UTC
Permalink
Post by Roger Binns
They appear to have broken the analyser.
My bad. I didn't realize the analyser was using hexeditor. In any case, both should be working now.
Post by Roger Binns
BTW there were plans for the status bar that was there
(shown at the bottom when there was focus). The intention
was that when editting is added it would show the mode
(insert vs overwrite) as well the byte/word values.
I added a StatusBar to the analyser displaying the same type of info as the hexeditor. Once the editing feature is added to the hexeditor, the StatusBar would display the info you described.
Post by Roger Binns
In edit mode the tab key should toggle sides from the bytes to
the character dump.
In addition to clicking on the right place?

-Joe Pham


______________________________________________________________________
Get NetZero Platinum for as low as $4.97/month!
Unlimited Internet Access with 250MB of Email Storage.
Visit http://www.netzero.com/half to sign up today!

Loading...