A N 7 2 5
26
Rev. 0.1
For example, to locate the stack at address 0x2000_6000:
PROVIDE(_vStackTop = 0x20006000);
Instead of editing the link scripts file, the stack offset change can be made inside the IDE:
1. Right-click on the
project_name
in the
Project Explorer
view.
2. Select
Properties
.
3. Click on
C/C++ Build
Settings
Tool Settings
tab
MCU Linker
Target
and input the desired stack
offset into the
Stack offset
field. This offset will occur from the top address of RAM, and the value must be
a multiple of 4. Figure 17 shows this dialog in the Precision32 IDE.
Figure 17. Using the Precision32 IDE to Select the Project Library
After changing either the custom linker script or IDE settings, clean and rebuild the project. View the map file for the
project to verify the stack location changed as desired.