??? 02/09/09 11:12 Read: times Msg Score: +1 +1 Informative |
#162215 - the knack, and how to get it Responding to: ???'s previous message |
One of the things you might try to get familiarised with a disassembler is to try to disassemble your own code. You might be surprised what does a disassembler "read out" off the binary...
The basic point is, that it works with an incomplete information - the disassembler does not know which part of the binary/hex is code, which is data, which is text (strings, letters), which is just empty space (filling up e.g. an EPROM or FLASH memory of a certain size). This information was lost during assembling. Jeff Post's d52 attempts to "guess" some of this information - but, inevitably, it sometimes goes wrong. For example, as in your case, when it "sees" a series of consecutive zeros, it will assume, it's only a free, inoccupied space, so it stops emitting disassembled code, and resumes with an ORG at the first nonzero byte following the zeros. But, in your case, it is apparently a series of NOPs to adjust timing of the serial communication protocol the snippet you provided implements. You can always override the "default" "guesses" by explicitly stating the "type" of disassembled "section" in the control file for the disassembled file. You should of course thoroughly read all the information - we can call it manual - which comes with the disassembler. You will desperately need also other information - as other said, everything from the program's "environment" - hardware/schematics, description of function (or preferrably, a functioning specimen to try your hypotheses), used communication protocols, data structures etc.etc - all helps. You should of course also intimately know all the details of working of the microcontroller in question. Sometimes also helps to try to "run" parts of the disassembled "code" in simulator. This is said to be the strength of IDA mentioned by Serg above, which combines disassembler and simulator - I have no personal experience with this product. Jw |
Topic | Author | Date |
help on DISASEMBLE code.... | 01/01/70 00:00 | |
Try posting formatted code | 01/01/70 00:00 | |
oh...sory | 01/01/70 00:00 | |
why and what are you disassembling | 01/01/70 00:00 | |
that is another problem | 01/01/70 00:00 | |
The scheme ? | 01/01/70 00:00 | |
im still trying to figure it out :D | 01/01/70 00:00 | |
try this | 01/01/70 00:00 | |
some disassemblers are better than some, but ... | 01/01/70 00:00 | |
maybe..... | 01/01/70 00:00 | |
thank you | 01/01/70 00:00 | |
the knack, and how to get it | 01/01/70 00:00 | |
The Knack | 01/01/70 00:00 | |
Pracise with your OWN code | 01/01/70 00:00 | |
wow... | 01/01/70 00:00 | |
oh, never mind youtube... | 01/01/70 00:00 | |
:D![]() | 01/01/70 00:00 |