- Sat Jul 16, 2016 5:24 pm
#50870
Hmmm, I would hope that an interrupt pin would not be polled, but when an interrupt occurs, would instantly set a flag. Then, when esp executes the next line, the flag would be checked to see if the interrupt occurred. And the flag would then be reset. I think that's what you are already doing. No missed interrupts.
Also, to make things better, if when an interrupt occurs, if that flag was already set, this would be a double interrupt, which could raise an error, or a counter could be incremented that the user could check to see how many of those specific interrupts occurred. (But this is not so easy to do.)
It might also be great if at least one interrupt could read a (microsecond) timer that the user could set to zero when desired, and then could see exactly when the interrupt occurred..