This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

why does SDK not have the API to use GPIO latch, LDETECT mode

Hi,

I'm using nRF52832 and LDETECT mode for GPIOTE PORT event to detect multiple interruption.

Even though LDETECT mode is described in the product sheet page 112 and GPIO register has DETECTMODE register, why SDK of any version doesn't have the API to use LDETECT mode? Is there some bug for LEDTECT mode?

If there is no big reason, would you check my change for the library is correct?

Changed library is below. The change is calling nrf_gpio_pin_latch_clear(pin) at 758 line.

Of course when the pin configured as GPIOTE PORT event triggers interruption, I disable the GPIOTE PORT event for the pin and put to the app_scheduler the execution to clear interruption in the registered application handler. After clearing interrupt factor, I enable the GPIOTE PORT event for the pin.

nrf_drv_gpiote.c

Thank you.

Related