LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How do I measure frequency with AT-mio-16E-1 and BNC-2090?

How do I measure frequency with AT-mio-16E-1 and BNC-2090?
 
I have a really high frequency (50khz) to measure.
 
I have the previously mentioned hardware.
 
I need to just measure the frequency, thats it.
 
I tried reading the manual, and looking at some of the VI's to use but got confused. The wording is confusing.
 
I have read that I need to use the internal clock to trigger to PFI inputs? True? How do I do that?
 
I see all sorts of references to channel names for the 68 pin cable, but those names do not match the names on the front of the bnc-2090. That is where I get really confused.
 
Someone please tell me what VI's to use (LV 6.1)
 
And what connections to make for these digital inputs please.
 
My signal is  TTL.
 
Thank you.
0 Kudos
Message 1 of 7
(3,260 Views)

Hello Vr6Fidelity,

 

I would suggest looking at page 3-22 of the AT-MIO-16 User Manual for information on how to make a frequency measurement with the AT-MIO-16E-1.  There is also information on page 2-13 of the BNC-2090 User Manual on how to access the counters on your MIO board through the BNC-2090.  As far as the VI's you should use go I would suggest looking in the example finder.  To access the example finder open LabVIEW and then go to Help>> Find Examples...  Once the example finder window comes up you should be able to find Traditional DAQ examples for the AT-MIO-16E-1 board by clicking on "Directory Structure" and then navigation to the folder shown in the image below.

 

 

I hope this helps get you started.

 

Cheers,



Message Edited by Brooks_C on 04-03-2008 12:22 PM
Brooks
0 Kudos
Message 2 of 7
(3,246 Views)
Actually after snuggling up with the manual for a while I found that page, And I have it working. although you dont need to wire the gate pin to the source pin or any of that.
 
Also the frequency reads 10% high, always. Whats with that?
0 Kudos
Message 3 of 7
(3,241 Views)

Hello Vr6Fidelity,

 

If you're measuring a 50 kHz signal with the counter then the measurement should be much more accurate than 10%.  The card compares the source (a known frequency from one of the card's timebases) to the incoming frequency and then calculates the period that way.  The error should be +/- 1 source period because the incoming frequency may fall in-between rising edges of the source.  The factory default for the AT-MIO-16E-1 is a 1MHz source frequency (as specified on page 3-25 of the AT-MIO-16 Manual so the error shouldn't be anywhere near 10% for a 50 kHz frequency unless you've changed the jumper mentioned in the manual to change the source frequency.

 

That being said, can you confirm in another measurement that the incoming frequency is not actually the value you're measuring?  I would guess that either your incoming signal is very noisy and causes extra counts or the incoming frequency is actually faster than you think.  I would start by checking the incoming signal to make sure it is what you think it is.

 

If you're sure that the signal is 50 kHz and you're measuring 55 kHz then it might be helpful if you can post a screen shot of the VI you're using.

 

Cheers,



Message Edited by Brooks_C on 04-04-2008 01:00 PM
Brooks
0 Kudos
Message 4 of 7
(3,222 Views)
Well I have been an instrumentaion engineer for quite some time now....
 
I used A HP frequency generator as my calibration signal source, it goes to 5mhz. It is a wonderfull piece of equipment, one of my 3 favorites. I verified the frequency with a Fluke multimeter, then read it in labview.
 
10hz in = 11hz out
 
100hz in 110out
 
1000in 1100 out.
 
1mhz in, 1.1 out
 
5mhz in 5.5 out.
 
Every time like clockwork.
 
To be honest I couldnt care less about this 10% error, I just multiplied all the frequencies by 0.9 and called it a day. It works fantastic.
 
I also verified the input frequency with a onno-sokki FFT, and by measureing the period on a trusty analog O-scope. The meter, the function generator, the scope, and the fft all read the same frequency.
 
The labview reads 10% high, and that is wonderfull. No problem at all for me, I was just wondering if it was some setting in the VI that I had wrong? 
0 Kudos
Message 5 of 7
(3,219 Views)
Hello Vr6Fidelity,
 
It sounds like you've done a good job checking your input signal.  Unless you're explicitly multiplying your measurement by 110% somewhere in your VI then there shouldn't be any software setting that would increase the frequency measured.
 
Can you try generating a pulse train with the AT-MIO-16E-1 and measuring it with one of your external meters?  Try running the "Cont Pulse Train-Easy (DAQ-STC).vi" example from the same folder as the example I posted earlier.  If your external readings agree with the setting on the front panel of this VI then it points towards the signal source for the cause of the error, but if your measurement if off by 10% then there may be something wrong with the AT-MIO-16E-1.
 
Let me know what you find and have a great day.
 
Cheers,
Brooks
0 Kudos
Message 6 of 7
(3,194 Views)

Hi Vr6:

Multiplying values by .9 still gives you some error, you need to multiply by 1/1.1 = 0.909090....

-AK2DM

~~~~~~~~~~~~~~~~~~~~~~~~~~
"It’s the questions that drive us.”
~~~~~~~~~~~~~~~~~~~~~~~~~~
0 Kudos
Message 7 of 7
(3,190 Views)