The document discusses configuring a timer peripheral to generate a pulse-width modulated (PWM) signal at a desired frequency. It provides the default timer clock frequency, desired PWM frequency, calculated timer tick frequency, prescaler value, and timer period to achieve the desired PWM frequency. It also shows equations that can be used to calculate the required timer configuration values from the desired frequency.
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as XLSX, PDF, TXT or read online on Scribd
0 ratings0% found this document useful (0 votes)
165 views6 pages
Calculate PWM Frequency
The document discusses configuring a timer peripheral to generate a pulse-width modulated (PWM) signal at a desired frequency. It provides the default timer clock frequency, desired PWM frequency, calculated timer tick frequency, prescaler value, and timer period to achieve the desired PWM frequency. It also shows equations that can be used to calculate the required timer configuration values from the desired frequency.
Values that can be edited Peripheral Clock APB1/APB2 = 54000000 Hz Prescaler = 8
ADC Clock = 6750000 Hz
Sampling Time = 480 Cycles
Total conversion time (Tconv) = 492 Cycles
Tconv to us = 72.889E-6 s (us) frequency = 13.72E+3 Hz ues that can be edited!!
Tconv = Sampling time + 12 cycles
Tconv_us = Tconv/ADC Clock Timer default frequency= 108000000 Hz APB1 o 2 timer clock Prescaler= 179 Values that can be e TIM period= 599 Counter period