2017-02-05 07:13 PM
Hi, I am working on a project using EXTI interrupts from the GPIO pins on the STM32F303 Discovery Board. I am using the STM32F03x_StdPeriph_Driver and CMSIS libraries.
In these libraries EXTI 1-16 are defined, while for the EXTI IRQn interrupt handlers 0-4 are defined, as well as 9_5 and 15_10. Which interrupt handler is meant to work with each EXTI Line? Is it possible to have the 9_5 line handle interrupts from multiple lines? Say from both 6 and 7?
#handler #exti #interrupt #irqn2017-02-05 09:14 PM
the irq handlers in the libraries are configured to handle the irqs of the chip
where you see irq handler for 0-4, et al, that means in your callback routine, you need to determine which irq was called so you can handle them individually, despite the callback handling multiple irq.
2017-02-05 10:03 PM
In your interrupt service routine you would do something like this:
void EXTI15_10_IRQHandler (void){//test for exti13 and 14
if (EXTI_GetITStatus(EXTI_LINE13) != RESET) { //process EXTI13 events EXTI_ClearITPendingBit(EXTI_LINE13); //clear the interrupt flag } if (EXTI_GetITStatus(EXTI_LINE14) != RESET) { //process EXTI14 events EXTI_ClearITPendingBit(EXTI_LINE14); //clear the interrupt flag }}Glenn