freeRTOS Stacktrace M7

jinwoo wrote on Monday, December 18, 2017:

Hi

I’ve read about debugging hardfault in this article

https://www.freertos.org/Debugging-Hard-Faults-On-Cortex-M-Microcontrollers.html

I would however appricate some help to port this to M7. The reason being that I seam to get incorrect data. For example the program counter always shows 0x00.

Do anyone know how to change the assembler code to fetch the correct data ?

rtel wrote on Monday, December 18, 2017:

The code is the same for all Cortex-M3, M4, M4F and M7 ports. If the PC
is 0 then that is probably the cause of the hard fault. Could it be you
jumped to a NULL pointer? Alternatively see the section “Handling
Imprecise Faults” on the page you linked to to see if that applies to you.

jinwoo wrote on Tuesday, December 19, 2017:

Thanks for your answer ! After some tests I have noticed that the behaviour occurs only when I have a watchdog enabled. Even if it doesnt trigger a reset it seams to change the behaviour of what data is read by the code added in the article.

Do you have any suggestion of what might cause this ?

jinwoo wrote on Tuesday, December 19, 2017:

Thanks for your answer ! After some tests I have noticed that the behaviour occurs only when I have a watchdog enabled. Even if it doesnt trigger a reset it seams to change the behaviour of what data is read by the code added in the article.

Do you have any suggestion of what might cause this ?

rtel wrote on Tuesday, December 19, 2017:

Could it be something to do with the ‘imprecise’ faults? So the fault
actually occurs sometime before the exception handler is called? As the
the paragraph noted in my last post.