*******************************************************************************
The purpose of this demo application is to present a usage of the
Hardfault handling using a script for the S32K3xx MCU.
------------------------------------------------------------------------------
* Test HW: S32K3X2EVB-Q172
* MCU: S32K312
* Compiler: S32DS3.5
* SDK release: RTD 3.0.0
* Debugger: PE micro
* Target: internal_FLASH
********************************************************************************
- Change the attached script name from --> gdbinit.txt --> to --> .gdbinit
- This script applicable for CORTEX-M7 call stack view.
- Select the script at this location :--
Window --> Prefrences--> c/c++ --> Debug --> GDB
- Whenever the hardfault comes go to the Debugger console and enter word armex press enter. This will display the callstack at the time hardfault occur, and LR address contain the address where the HARDFAULT occur.
- Enter address in Disassembly window And press enter, this will take you to code location where the hardfault occur.
- Then you can review your code setting or code usage why this hardfault is coming.