2024-07-12 04:14 AM - edited 2024-07-12 06:24 AM
I am using the STEVAL-STWINBX1 development board with the FP-SNS-DATALOG2 software.
I am struggling to configure PB1 as a digital input for an external interrupt (which is on pin 12 of the expansion connector CN1)...
I start by opening the .ioc file in STM32CubeMX...
Then I change PB1 to be an external interrupt, with a pull up resistor and falling edge trigger...
I then generate code in STM32CubeMX and refresh the project in STM32CubeIDE.
Am I correct in saying the interrupts are in the file stm32u5xx_it.c (as shown below) ?
Confusingly, there are two stm32u5xx_it.c files in the project in the following folders...
The file in the DATALOG2\mx\Src folder seems to be the one generated by STM32CubeMX, so I copied the stm32u5xx_it source and header files from the mx folder to the Core folder...
When I tried to build the code, I got an error saying multiple definitions of "PendSV_Handler()" and "SysTick_Handler()".
So I deleted these from the stm32u5xx_it.c file and now it builds.
However, when I debug the project it appears to be going to a default interrupt and sitting in a for loop...
What am I doing wrong, how do I get this working ?