|ARM Technical Support Knowledge Articles|
Applies to: C51 C Compiler
Information in this article applies to:
How can I set the address of the reentrant stack pointer? It is easy to set the size of the stack, but I can't figure out how to specify the location of the actual pointer.
You must modify the startup code as follows (to put the IDATA reentrant stack pointer at address 40h):
IF IBPSTACK <> 0 DSEG AT 0x40 ?C_IBP: DS 1 PUBLIC ?C_IBP RSEG ?C_C51STARTUP MOV ?C_IBP,#LOW IBPSTACKTOP ENDIF
Note that you may change DSEG at 40 to whatever address (in DATA space) you want the point to "live" at. Other reentrant stack pointers may be located similarly.
Article last edited on: 2004-06-17 14:53:15
Did you find this article helpful? Yes No
How can we improve this article?