Real time analysis of mains frequency

Join the discussion
Registration is free. Ask a follow-up in this thread, or start your own.
13 replies · 2K views
Michael Campbell
All,
I could use some help. I would like to measure mains frequency in real-time and pass the data through a high-level programming language (preference of Python).

I am not sure where to start with this project, I assume commercial mains frequency analyzer exist, however, my google searches have only found highly engineered units like this:
http://www.arbiter.com/catalog/product/model-1133a-power-sentinel.php .

Which I'm sure is a great piece of kit, but when you have to ask for the price you probably can't afford it.

Has anyone solved this problem before, on a tight budget?

Thanks in advance.
 
Engineering news on Phys.org
Thanks.
I have considered a DIY solution, but I don't have any experience in building hardware solutions (only software). And with limited time available I would prefer to buy a unit built by experts, which I could interface to a PC, Mac etc.
 
Is this a professional / commercial installation. What accuracy is needed? Mains frequency typically varies by only small amounts so a specially built meter is needed.
 
Windadct said:
Is this a professional / commercial installation. What accuracy is needed? Mains frequency typically varies by only small amounts so a specially built meter is needed.

NEW
Yes, this would be a non-professional installation, but the requirement is for high accuracy/sampling. The end goal is the development of signal processing algorithms.
 
anorlunda said:
In that case, a modern multimeter might be best. A quick search on Amazon found this one which claims USB and bluetooth connections to your phone or computer, and it has a Hertz scale. I've never used such a device, but you could research it.https://www.amazon.com/dp/B00SGKR9FA/?tag=pfamazon01-20
That could be a quick win. I'll certainly investigate the multimeters.
 
Before you start, you have to decide what accuracy of f measurement you need. There are many cheap counters with good crystal oscillator references in them. It could simply involve hooking one of those up with a data link to your PC.
 
Michael Campbell said:
NEW
Yes, this would be a non-professional installation, but the requirement is for high accuracy/sampling. The end goal is the development of signal processing algorithms.
As anorlunda said, you can build some circuits and use them with a microcontroller like arduino.

You can measure the time delay between successive zero crossings and get the frequency directly.

Or you can use a voltage to frequency converter IC (look up LM331) and feed its output to the microcontroller.

You can also use FFT, but I don't know much about that.
 
Would something like this work?
freqmeter.jpg
 
cnh1995 said:
As anorlunda said, you can build some circuits and use them with a microcontroller like arduino.

You can measure the time delay between successive zero crossings and get the frequency directly.

Or you can use a voltage to frequency converter IC (look up LM331) and feed its output to the microcontroller.

You can also use FFT, but I don't know much about that.
Yes, I wish I had the time/skills to build a frequency monitor.