i was able to decompile or disassembled the hex using a windows decompiler program but i dont know how to edit the program. i think i was written in C language.
Announcement
Collapse
No announcement yet.
felezjoo PI(the best pulse induction metal detector that I made until now)
Collapse
X
-
If you decompile the hex file the result will be pseudo code at best, if your compiler is even capable of doing that.
You can't expect to edit & recompile it. I've done the same, just out of curiosity, with Hex-Rays, but this is as far as you could go.
Advanced knowledge is required from this point on, so my advice is don't waste your time.
Comment
-
Originally posted by eclipse View PostIf you decompile the hex file the result will be pseudo code at best, if your compiler is even capable of doing that.
You can't expect to edit & recompile it. I've done the same, just out of curiosity, with Hex-Rays, but this is as far as you could go.
Advanced knowledge is required from this point on, so my advice is don't waste your time.
Comment
-
Not really though!
With strong nerves and lot of patience; something can be done.
I will not disclose final solution here, simply because it would not be a fair towards the author.
But i will put a bit oil on fire here and also provoke you to start working something.
If not in course to achieve final solutions than at least for educational purposes.
Each similar code is having certain rules. Certain procedure and certain repeatings.
Things were being complicated further because of the relative addresses, so you can't rely exactly on fixed addresses here.
But you can try to locate blocks of code, their repeatings and relative jumps.
Some procedures are common and the main trick is to recognize them in the code.
For example; the procedure of displaying a text string on LCD. Or to store a byte in eeprom.
Or to wait key stroke. Or this and that...
To be sure in what are you doing; knowing Atmega architecture is MUST!
Before starting anything else; first download Atmega's datasheet and start reading.
I will give here my first initial dump file and lot of useful comments i added later in process of analyzing it.
That's as far as i can help here.
But as i said; this is only for educational purposes!
Please don't ask me questions, i will not be in position to answer.Attached Files
Comment
-
Originally posted by ivconic View PostNot really though!
With strong nerves and lot of patience; something can be done.
I will not disclose final solution here, simply because it would not be a fair towards the author.
But i will put a bit oil on fire here and also provoke you to start working something.
If not in course to achieve final solutions than at least for educational purposes.
Each similar code is having certain rules. Certain procedure and certain repeatings.
Things were being complicated further because of the relative addresses, so you can't rely exactly on fixed addresses here.
But you can try to locate blocks of code, their repeatings and relative jumps.
Some procedures are common and the main trick is to recognize them in the code.
For example; the procedure of displaying a text string on LCD. Or to store a byte in eeprom.
Or to wait key stroke. Or this and that...
To be sure in what are you doing; knowing Atmega architecture is MUST!
Before starting anything else; first download Atmega's datasheet and start reading.
I will give here my first initial dump file and lot of useful comments i added later in process of analyzing it.
That's as far as i can help here.
But as i said; this is only for educational purposes!
Please don't ask me questions, i will not be in position to answer.
Comment
-
Originally posted by ivconic View PostNot really though!
With strong nerves and lot of patience; something can be done.
I will not disclose final solution here, simply because it would not be a fair towards the author.
But i will put a bit oil on fire here and also provoke you to start working something.
If not in course to achieve final solutions than at least for educational purposes.
Each similar code is having certain rules. Certain procedure and certain repeatings.
Things were being complicated further because of the relative addresses, so you can't rely exactly on fixed addresses here.
But you can try to locate blocks of code, their repeatings and relative jumps.
Some procedures are common and the main trick is to recognize them in the code.
For example; the procedure of displaying a text string on LCD. Or to store a byte in eeprom.
Or to wait key stroke. Or this and that...
To be sure in what are you doing; knowing Atmega architecture is MUST!
Before starting anything else; first download Atmega's datasheet and start reading.
I will give here my first initial dump file and lot of useful comments i added later in process of analyzing it.
That's as far as i can help here.
But as i said; this is only for educational purposes!
Please don't ask me questions, i will not be in position to answer.
Comment
-
Originally posted by jladre View PostThis is really helpful for disabling counter but it cannot be used to edit the source code.
It is not that bad, just a bit time consuming and if you have an emulator, much easier.
The code does not look like it was generated from C. Might be either assembler or basic.
It does terminate strings with a Null, so that is consistent with C.
Not familiar enough with the Mega to understand this to much, but I don't see local variables being held on the stack in this.
Of course, you don't see that with the Keil 8051 C compiler either, because they do overlays.
Comment
-
Originally posted by ivconic View PostNot really though!
With strong nerves and lot of patience; something can be done.
I will not disclose final solution here, simply because it would not be a fair towards the author.
But i will put a bit oil on fire here and also provoke you to start working something.
If not in course to achieve final solutions than at least for educational purposes.
Each similar code is having certain rules. Certain procedure and certain repeatings.
Things were being complicated further because of the relative addresses, so you can't rely exactly on fixed addresses here.
But you can try to locate blocks of code, their repeatings and relative jumps.
Some procedures are common and the main trick is to recognize them in the code.
For example; the procedure of displaying a text string on LCD. Or to store a byte in eeprom.
Or to wait key stroke. Or this and that...
To be sure in what are you doing; knowing Atmega architecture is MUST!
Before starting anything else; first download Atmega's datasheet and start reading.
I will give here my first initial dump file and lot of useful comments i added later in process of analyzing it.
That's as far as i can help here.
But as i said; this is only for educational purposes!
Please don't ask me questions, i will not be in position to answer.
From what i remember, a jump command at "wrong password" message and we are ok.
But now i don't know what is happening with new technologies...
Comment
-
Originally posted by ivconic View PostNot really though!
With strong nerves and lot of patience; something can be done.
I will not disclose final solution here, simply because it would not be a fair towards the author.
But i will put a bit oil on fire here and also provoke you to start working something.
If not in course to achieve final solutions than at least for educational purposes.
Each similar code is having certain rules. Certain procedure and certain repeatings.
Things were being complicated further because of the relative addresses, so you can't rely exactly on fixed addresses here.
But you can try to locate blocks of code, their repeatings and relative jumps.
Some procedures are common and the main trick is to recognize them in the code.
For example; the procedure of displaying a text string on LCD. Or to store a byte in eeprom.
Or to wait key stroke. Or this and that...
To be sure in what are you doing; knowing Atmega architecture is MUST!
Before starting anything else; first download Atmega's datasheet and start reading.
I will give here my first initial dump file and lot of useful comments i added later in process of analyzing it.
That's as far as i can help here.
But as i said; this is only for educational purposes!
Please don't ask me questions, i will not be in position to answer.
I tried some LCD setting and confirm it but when start simulation nothing happen on virtual LCD!
An help shall be appreciated!Attached Files
Comment
-
Originally posted by Geo View PostYes but why to changing the code????
300 times are enough, and after it you can reprogram the chip and have other 300 etc....
A friend is not in position to reprogram it after the counter reaches 300 power ons.
Quite decent excuse for me!
Comment
Comment