Hi all,
I have a problem that seems very simple, but I cannot make sense of it.
I have a simple setup on the NRF52840 DK that senses a rising edge on pin 1.00 and then sets pin 1.01 high along with a flag. I then have a while loop in my main that is waiting for this flag to be set high and then sets the pin back low. The interrupt is routinely coming in every 4ms, however my main while loop is never running. I do not understand why. Code below:
GPIO Init and ISR:
Main While() loop:
The variable names are reused from another project, but the reg_readings and biss_readings counter values are output every second to see how many iterations occurred in each loop over the last second. The reg_readings (ISR) counter is coming back 250 consistently so I know it is working. The biss_reading conter comes back as "1" he first time and then "0" every time after tht:
An interrupt firing every 4ms should not be fast enough to starve anything. I also measured how long the ISR is taking by toggling the GPIO pin in it and measuring on an o-scope. It is taking roughly 1-2uS, so definitely not a problem there.
In my