Skip to main content
hjuns
Associate II
October 27, 2022
Question

When PWM duty changes?

Hello,

I control BLDC motor.

Control the speed of the motor by changing the TIM->CCR.

​

I have a question while setting the time to change the value of CCR.

If I change the value of CCR while I'm sending out PWM, will the Duty ratio change in the next cycle?

​

​

​

​Thanks.

This topic has been closed for replies.

1 reply

waclawek.jan
Super User
October 27, 2022

That depends on whether you have CCRx preload set or not. Read the TIM chapter in RM.

​

JW​

​