Software interrupt on STM32L4
Hi all,
I try to create a software interrupt in STM32L476.
This is the software interrupt enable code
HAL_NVIC_SetPriority(EXTI1_IRQn, 3, 0);
HAL_NVIC_EnableIRQ(EXTI1_IRQn); LL_EXTI_EnableIT_0_31(LL_EXTI_LINE_1); LL_EXTI_EnableEvent_0_31(LL_EXTI_LINE_1);This is the interrupt trigger code
LL_EXTI_GenerateSWI_0_31(LL_EXTI_LINE_1);
The interrupt is not generated, how come? what am I missing?
The datasheet says the following:14.3.6 Software interrupt/event selection
Any of the configurable lines can be configured as a software interrupt/event line. Theprocedure to generate a software interrupt is as follows:1. Configure the corresponding mask bit (EXTI_IMR, EXTI_EMR).2. Set the required bit of the software interrupt register (EXTI_SWIER).This is exactly what I'm doing. 'normal' interrupts work.
#software-interrupt #stm32l4