Hey everyone,
I couldn't find a free MPASM decompiler so I thought, why not make one ?
So I've just started yesterday. My ihex parser is done, it doesn't take everything into account, like the address of the first byte on a line or any other record type than 00, but it returns a pointer to an array filled with 'raw' data.
(Note : I probably should add the address of each byte, maybe I'll do it after I'm done with this post)
I'm using a program (written in MPASM) I recently made and I've just noticed something and I don't know why it's there.
Take a look at the 2nd line of the end of my hex file:
:0A0140002F202F202F20850108003A
:02400E00B43FBD
:00000001FF
That line tells me that the value 0x3FB4 will be written at address 0x400E in the microcontroller.
But the program memory map of the 12F675 only goes to 0x1FFF.
Also, 0x3FB4 can be translated to:
0011 1111 1011 0100 = 0x3FB4
From instruction set mid-range MCU:
0011 111x kkkk kkkk = ADDLW k
Thus:
ADDLW 0xB4
Why would there be an ADDLW 0xB4 at address 0x400E ?
(Note : I never used ADDLW in my program)
The record type on that line is '00' so it's getting written in the data array as well.
Any thoughts on this ?
pyroesp