1
votes

Need formulae to calculate Prescaler,Counter Period and a Pulse value of each channel on a Timer with given values of

Input clock frequency (APB) Output Frequency (PWM) Duty cycle (for each channel)

1

1 Answers

2
votes

Can you solve this equations?

Frequency = ClockFreq / ((PSC + 1) * (ARR + 1))

Dutyin% = (CCRx * 100) / ARR for the fast PWM