1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2025-12-25 14:33:52 +01:00

periph/gpio: clarify behavior of gpio_irq_enable()

What happens with events that occured after `gpio_irq_disable()` is
currently not defined.
If they are not cleared, they will generate an interrupt on `gpio_irq_enable()`.

This does not seem like the intended behavior, so make the documentation more
explicit.
This commit is contained in:
Benjamin Valentin 2020-08-05 17:41:27 +02:00
parent 3b06234dc0
commit 8c95198cbb

View File

@ -192,6 +192,9 @@ int gpio_init_int(gpio_t pin, gpio_mode_t mode, gpio_flank_t flank,
/**
* @brief Enable pin interrupt if configured as interrupt source
*
* Interrupts that would have occured after @see gpio_irq_disable
* was called will be discarded.
*
* @note You have to add the module `periph_gpio_irq` to your project to
* enable this function
*