GPIO edge interrupts.
More...
GPIO edge interrupts.
The pin is described by the board's ExtiConfig.
static void prv_int_handler(void) {
}
void exti_configure_pin(ExtiConfig cfg, ExtiTrigger trigger, ExtiHandlerCallback cb)
Configure a pin as an interrupt source and register its handler.
void exti_enable(ExtiConfig config)
Enable the interrupt of a configured pin.
@ ExtiTrigger_Falling
Falling edge.
Definition exti.h:31
bool system_task_add_callback_from_isr(SystemTaskEventCallback cb, void *data)
Queue a callback from an ISR.
◆ ExtiHandlerCallback
| typedef void(* ExtiHandlerCallback) (void) |
Interrupt handler, called in ISR context.
◆ ExtiTrigger
Edge that triggers the interrupt.
| Enumerator |
|---|
| ExtiTrigger_Rising | Rising edge.
|
| ExtiTrigger_Falling | Falling edge.
|
| ExtiTrigger_RisingFalling | Both edges.
|
◆ exti_configure_pin()
Configure a pin as an interrupt source and register its handler.
The interrupt is delivered once enabled with exti_enable().
- Parameters
-
| cfg | Pin to configure. |
| trigger | Edge that triggers the interrupt. |
| cb | Handler, called in ISR context. |
◆ exti_disable()
| void exti_disable |
( |
ExtiConfig |
config | ) |
|
Disable the interrupt of a pin.
- Parameters
-
◆ exti_enable()
| void exti_enable |
( |
ExtiConfig |
config | ) |
|
Enable the interrupt of a configured pin.
- Parameters
-