Hi ALL, I using STARTUP.A51 in my C51 Project,It will be start the sp at 0x07, becuase I define many idata in my program.When Call a function in C program, The idata overlap the push value make program counter jmup to error address when in debug mode. Why the compilier don't auto setting stack ? Thanks.
Thanks a lot. So, How to avoide the event appear when idata overlap stack value.I try to modify the sp, but it seem not good solution for the problem.
Hi Free, How about modifing the following code in startup.a51:
?STACK SEGMENT IDATA RSEG ?STACK DS 64 MOV SP,#?STACK-1