Hello everyone, I would like to ask a question about the abnormal interruption of UsageFault. There are two S32K144 boards in the mass-produced products of the customer that are constantly reset (there is a watchdog) (the boards of other products are normal, and it is normal to burn the same set of software to other boards. ) There is a UsageFault abnormal interrupt, we use Lauterbach to locate the error in the INVSTATE status bit and cause the UsageFault abnormal interrupt. What is the reason for the error of the INVSTATE status bit?
The following is the analysis test situation:
We got the HEX file that the customer gave to close the watchdog, and burned it to the abnormal chip for testing. Use Lauterbach to read the core register of S32K144, after running at full speed, it is stuck at address 0x478.

Check the kernel register and find the UsageFault interrupt exception, and check the kernel register and find that the Error in the INVSTATE status bit causes the UsageFault interrupt exception.

The following figure is the description of the status bit

According to the description in the following figure, it can be seen that when EPSR.T==0, attempting to execute the instruction results in a UsageFault


