Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

[General] Frequency measurement

Status
Not open for further replies.

TheGrumps

Newbie level 4
Joined
Jan 24, 2017
Messages
6
Helped
0
Reputation
0
Reaction score
0
Trophy points
1
Activity points
50
Hi All
I have a task to measure a low frequency signal (about 30kHz) with an accuracy of 2ppm.
I'd like to have frequency readings at least twice per second. So I can't just count the input signal for a period of time as that would entail counting for over 30s to get the accuracy.
I have a plan to use a counter (say 10MHz) and measure say 10000 input periods. I'm sure this gives me the accuracy, and also provides enough readings per second.

But are there other methods?
Ta.
 

Doing this using a Micrcontroller is easier. I have done a frequency meter which measures upto 50 MHz using PIC18F micrcontroller. I can help you with a C code for frequency counter if you can use PIC18F26k22 or 18F46K22.
 

Thanks for the offer of help, much appreciated.

I was intending to use a microcontroller, but was more interested in whether there are other simpler methods than measuring a few thousand periods.

What resolution did you get from your frequency counter that went to 50MHz? I think it's easier measuring high frequencies than it is the lower ones.
If you count the input for 1s at 50MHz, then you get a count of 50,000,000. If you count the input for 1s at 50,000,001Hz, then you get a count of 50,000,001. Simple. Try doing that for an input with a frequency of 20kHz or 20,000.02Hz - you'll get a count of 20,000 for each. To differentiate the two you'd have to count for 50s.
That's why I was suggesting measuring several periods of the input using a good clock (can be a microcontroller clock but with good ppm).
 

The suggested multi-period measurement is performed by most industry standard frequency meters. It can be implemented with the capture feature of microcontroller timers.
 
Good, if it's OK for an industry standard meter, then it should be OK for me too :)
I guess my next question to make my life easier is, can you buy a module that does this off-the-shelf (preferably with USB)?
 

I have attached my frequency meter. What resolution you want ? I had used external interrupt and timer to do the counting. Check the attached Proteus simulation. I couldn't find the other version of frequency meter which I made which was more accurate as it used T1CKI input for counting the pulses. I will search for it and post its simulation here.

Actually I had done tachometer but I modified it as frequency counter.
 

Attachments

  • MAX7219 Tachometer Simulation.rar
    24.5 KB · Views: 45

Thanks. I'll have a look at your simulation.

My spec was 0-30kHz with a resolution of 0.02Hz, and a measurement rate of >2Hz.
 

My spec was 0-30kHz with a resolution of 0.02Hz, and a measurement rate of >2Hz.
Should work with multi-period measurement and > 3 MHz timer clock.
 

Hi,

you need a somehow tricky solution.

Counting 1000 (or any other fixed number) pulses won´t work for low frequencies.
So you need to
* count pulses
* and saving "capture" time stamps
at once.
Then calculate every 0.5s.
Maybe your pulse counter says: 12345 pulses
and your timing says: 1456789 counter ticks.

1456789 counter ticks of a 3MHz counter means 0.4855963s
giving a total frequency of 12345/0.4855963s = 25422,35Hz

Is this what you need?

Klaus
 

Regardless of which method you employ to calculate the frequency, the accuracy and stability of your primary timebase is critical.
Most likely you will require some form of TCXO. Or even better, an OCXO. It all depends on your budget.
 

Thanks Klaus.
That's the approach that should work.
 

Regardless of which method you employ to calculate the frequency, the accuracy and stability of your primary timebase is critical.
Most likely you will require some form of TCXO. Or even better, an OCXO. It all depends on your budget.

Whilst we haven't got an unlimited budget, we can afford to get a TCXO with better than 1ppm (even 100ppb) stability for around $10.
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top