cancel
Showing results for 
Search instead for 
Did you mean: 

I need to measure a frequency in STM32F767VIT6 Timer1 CH1. 0 to 14khz input freq

PRaje
Associate

Give me a suggestion, Is it possible or not.

4 REPLIES 4

Read the PWM input subchapter of TIM chapter in RM. Part of the PWM input measurement is measurement of period (which is 1/frequency).

JW

Perhaps you, and your friend can work it out?

https://community.st.com/s/question/0D53W00001Tfs1PSAR/i-need-to-measure-an-1hz-to-14khz-frequency-in-stm32f767vit6-timer1-ch1

I'd probably have used a different TIM, to get some reasonable resolution. But conceptually you can use the TIM in PWM Input Capture, to get frequency and duty cycle quite easily.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
PR.Atom
Associate

My Hardware is finalized for TIMER 1. Could you please suggest alternative methods?

Alternative to what?

The basic idea is to use Input Capture, which give you the exact moment in time when an edge on input signal occurs. From two consecutive capture values (and input frequency of timer) calculate the period, and 1/period = frequency.

The method described as PWM Input in the RM is simpler in that with capture it simultaneously resets the timer's counter, so you don't need to subtract two consecutive capture values.

JW