This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

mon51 crack stack pointer

Hi
I use mon51 debug code. mon51 stay in
code 0x0000-0x1fff.my code stay in code
0x2000-0xbfff. stack pointer start is 0x80.
And when i call some fucntion, the stack pointer is 0x87,when call memcpy, i found that content of 0x86 was changed, It mean that I cannot return the correct address when I finished call this function. Why wil this happend?

Thanks.
Ding

Parents
  • Presumably, at least up to the point of stack corruption, MON51 provides the means to step through the code and inspect the registers and stack, so where does it all start going bad?

    In my opinion, unless this is a chronic MON51 problem, code snippets, stack contents, register contents, processor context, etc. would be the thing to post next for us to help you with debugging.

Reply
  • Presumably, at least up to the point of stack corruption, MON51 provides the means to step through the code and inspect the registers and stack, so where does it all start going bad?

    In my opinion, unless this is a chronic MON51 problem, code snippets, stack contents, register contents, processor context, etc. would be the thing to post next for us to help you with debugging.

Children
No data