nrf52840 nrfx gpiote zephyr thread unresponsive

Hi all,

I'm using the nrfx gpiote to setup an interrupt from an external device (IMU.) Whenever there is an interrupt, I would post an event and process it in another thread. The problem I'm facing is that this post event from the ISR doesn't get processed until I press any key in the shell. I'm uncertain how does the shell CLI is related to processing a thread.

This problem does not occurred in ISRs from other sources such as SPIM or TIMER instances. Any event post from either SPIM or TIMER ISRs would get processed immediately. So I am wondering if the problem could be coming from the gpiote ISR that blocks the event to be processed immediately.

Attached is a sample showing event post from three different ISRs (press a button, SPIM, and TIMER) for nrf52840 with a shell. 

Shell Commands:

i 0   # to  initialize

After this, you can press a BUTTON 1. Then press any key in the shell would see the post event gets processed

i 1  # run spim test

This shows the post event gets processed immediately (without typing anything into the shell)

i 2 # run timer test

This has the behavior like the spim test.

Thank you for so much for your help.

Related