Click to See Complete Forum and Search --> : anyone knows any hex editing?
asklepios
12-31-2003, 04:14 PM
hello everyone.
i want to edit a .lib file but i don't know how to do it.
the following page talks about how to install Motorola sm56 driver in Linux but requires you to edit the file using a hex editor.
http://www.tek-tips.com/gpviewthread.cfm/qid/607300/pid/537/lev2/8/lev3/57
i have no idea how to it. i opened the sm56.lib in khexeditor but then i could not make anything out of it.
i scrolled up and down and found something like 0004:e210-7 but the thread says that i have to find offset 0x4e210+5. what is this?
i put it as a string to go to but could not find anything.
please help this poor n00b. i will be greatful.
camorri
01-01-2004, 08:17 AM
I have used hex editors. The instructions are not too bad.
Clip from instructions...
At offsets 0x4e210+5 change the byte 0x07 to 0x11
0x4e220+4 change from 0x07 to 0x11
0x4e820+9 change from 0x0f to 0x11
If you edit the file, the left most column is the offset counting in hex from zero. 10 in hex is 16 in decimal. If you look at the middle of the screen and count from the left column, you will count 16 bytes of data. 4e210+5 is just a way of saying, go down the left column until you see 4e210, now count across the line five bytes. If you are in the correct spot, you will see a hex 07. According to the instructions, change it to 11. Assuning you have write permission to the file, type over the 07 with 11. Continue on altering the bytes, and save your changes. That is about all you need to know. I have no knowledge of the changes, so you are on your own there.
I would make a backup of the file and practice with that first.
asklepios
01-01-2004, 10:33 AM
thanx for the reply mate.
so i take it that 0x4e210+5 means hex 4e215. right?
if that is right then i reached the correct spot but the spot says 52 instead of 07.
so does that mean that i am at the wrong spot or there is some problem with the instructions.
thanx once again for the reply :)
camorri
01-01-2004, 12:08 PM
It should match exactly, if it doesn't, either you are not at the correct point, or the file you have may be a different level (release) than the instructions were written for.
Some other thoughts to help you understand what you are looking at in the editor.
The left colums ie. 0000:4000; this area is just the addressing put there by khexedit to help us huminoids find our way around. They are not part of the file you are editing.
The rows of 16 (decimal) bytes are the data of the file you are editing.
The right columns are a 'printable' interpretation of the hex data of the file. This area is produced again by khexedit, you guessed it, to help us huminoids out. This area is useful if you are looking at a executable program which outputs messages from within the file. You can see the message data.
So in summary, the file data is the 16 (decimal) bytes in the middle. On my version of khexedit, the data is between two vertical green lines.
Hope this helps.