Clearing the interrupt occurred flag before gpio_intr_enable

Superkurt
Posts: 13
Joined: Thu Mar 03, 2016 11:38 pm

Clearing the interrupt occurred flag before gpio_intr_enable

Postby Superkurt » Sun May 07, 2017 11:33 pm

Hello,

In my program I use gpio interrupts. In the ISR I disable the interrupt and send a signal to a freertos task. The task do some work and then enable the interrupt again. If in the meantime where the interrupt was disabled an gpio interrupt has occurred the ISR will be called immediately. But I don't want this. I would clear the "gpio interrupt has occured" flag manually, so that after enabling the interrupt again only an interrupt after that point in time will trigger the ISR. In the end I would ignore all interrupts that had ocurred between gpio_intr_disable and gpio_intr_enable.

Is it possible to clear the interrupt occurred flag manually?

Thanks in advance.


Superkurt
Posts: 13
Joined: Thu Mar 03, 2016 11:38 pm

Re: Clearing the interrupt occurred flag before gpio_intr_enable

Postby Superkurt » Mon May 08, 2017 6:38 pm

Thanks for your support! That's working!

Who is online

Users browsing this forum: Bing [Bot], Google [Bot] and 33 guests