Page 2 of 2
Re: STM32 Configure and Interrupt
Posted: Fri Jun 13, 2025 2:17 pm
by liudeqiang_2008
LeighM wrote: ↑Wed Jun 11, 2025 1:48 pm
I suspect there might already be examples on this or the old forum.
Just some other points...
Presumably you have proved that the hardware is working? Perhaps adding a led flash in the main loop.
Are you using your own hardware design, or a development board?
You have a pull up (or down) resistor on the switched input?
I would also suggest that you keep the interrupt code as short as possible, e.g. just set a flag and then test for it in the main loop and do your printing there
I couldn't even achieve the EXTI Interrupt software simulation in the Debug - Run mode.
Re: STM32 Configure and Interrupt
Posted: Fri Jun 13, 2025 2:19 pm
by liudeqiang_2008
LeighM wrote: ↑Wed Jun 11, 2025 1:48 pm
I suspect there might already be examples on this or the old forum.
Just some other points...
Presumably you have proved that the hardware is working? Perhaps adding a led flash in the main loop.
Are you using your own hardware design, or a development board?
You have a pull up (or down) resistor on the switched input?
I would also suggest that you keep the interrupt code as short as possible, e.g. just set a flag and then test for it in the main loop and do your printing there
To be clear, only STM32F411CEU6 I have downloaded it to a standard development board(Still failed), for the others, I only tested it in the Debug-Run mode. the program will never goes into EXTI macro even when I set the EXTI active button always on and Step into it.
As you mentioned,I changed the program to use a flg in the EXTI Interrupt Macro and an LED on the main loop.
I have tried 4 boards : ESP32(OK),PIC(OK),PICO(NG),STM32(NG). 2 success and 2 failed. The program are all same except the Interrupt pin.
If some want to check, please see below attachment.
I think Flowcode developers should pay attention to this issue.
Or prove me stupid. I still think this is a good example for Flowcode beginners, and I believe there will be people who encounter the same problem as me.
BR, Deqiang
Re: STM32 Configure and Interrupt
Posted: Fri Jun 13, 2025 5:26 pm
by LeighM
Thanks for the further info.
I'm not sure what support there is for interrupts in simulation mode - one for the Matrix team.
I should be able to find some time next week to provide an EXTI example on STM32F411 hardware