Hardfault and HRTIM
Hello, I have a STM32F334 on which I use the HRTIM1 in a SEPIC converter.
The PWM section works the way I want it to, but now I want the system to stop in case of a Hardfault. But for some reason I can't get this to work.
I have set the LOCKUP_LOCK bit in the SYSCFG_CFGR2 register, (as per 10.1.7, page 169 in RM0364)
I have set the Fault state of the particular output to inactive.
I have enabled Fault 1 in Timer Fault Register, on the external input, and confirmed that this works.
After that I performed a division by zero, to force a hardfault, and this did indeed trigger the hardfault exception. But the PWM itself stays active.
So I wonder what is going wrong:
- Is there another bit somewhere that needs to be set?
- Is a division by zero not a proper way to force a hardfault in this instance?
- Is there something else I'm missing here, or not understanding?
I hope someone can help,
Peter
