2017-08-15 01:03 AM
I am working with the stm32f4 Discovery Development Board and put simply, there's a while loop (with some conditions) in my main() function. Is it possible for the code inside the while-loop to find out it has been interrupted by an interrupt? Of course, I can use a global volatile boolean variable called intOccurred and set it to true in all interrupt handlers, but is there a more generic way to detect it?
2017-08-15 04:23 AM
No.
Execution of ISR clears the pending flag (NVIC_ISPRx) by hardware - otherwise the ISR would be executed again and again...
JW