2020-04-21 11:14 AM
I use STM32F103c6 timer1 for pwm input . after right config in cubemx, and in simulink enable timer1 ch1 interrupt. Then auto code gen, but code in Keil the ch1 interrupt not enable, its callback not registered, the timer also not started. Want to know how to use timer1 pwm input in simulink, look forward to reply! Already Confused for one week ...
2020-04-21 11:47 AM
I don't think you'll find much dedicated Simulink/Matlab support here.
Which STM32?
Make sure that the interrupts have the same name as listed in the vector table, usually in startup file. Note, that TIM1 is usually an exception, having several separate interrupts for different groups of signals (Update, CC, etc.) Read the Interrupts chapter in RM.
JW
2020-04-21 07:13 PM
Thx for your answer.
2020-04-29 12:27 PM
Hi, @PYong.2 did you enabled the IRQs for TIM1 under NVIC in CubeMX?
2020-05-09 03:59 AM
yes, already enabled the IRQs for TIM1. For no solution,I choose to add start code to fix it. Thx!
2020-10-07 01:13 PM
And did you try a Cube configuration like this?