I have set up the comparators in a way that when low over current occurs it will give me an interrupt which I handle. If there is a bigger overcurrent PWMs will be disabled and again interrupt occurs. The problem is that how can I configure the interrupts and everything so that I get only one interrupt in one PWM period? I tried to clear the TZ flags with PWM interrupt when PWM counter is period but I also have a ADC interrupt at the middle of the period. Those two interrupts takes too much time in a one PWM period that MCU can't handle it. Of course I can always clear TZ flags in ADC interrupt but isn't there a way to do it more properly? Is it possible to configure the blanking window so that it will blank the interrupts for the rest of the PWM period?
Is TZ pin edge sensitive? If it is then I could route my analog comparator output pin to TZ pin so I could get interrupts only after when comparator has put it's output low and then high again.