Measure frequency of 50 Hz with at least 3 digits

Hi.
I have Labview 8.2 , and I want to measure the network frequency (50Hz) with at least 3 digits and good accuracy.
Is there any solutions to do that in Labview , easy? I also have a DAQ 6210.
Thanks.

Hi dsasorin,
You can use your 6210 to measure the frequency of your
signal. The 6210 has 2 - 32 bit counters on-board. It has built-in timebases of
80, 20 and 0.1 MHz available for use with the counters. You will still need to
attenuate the signal. The maximum input rating for the 6210’s counters in 5
volts. They are TTL digital inputs.  Also the counter inputs are not
designed for negative voltages. So you may need to rectify your signal as well
as attenuating it. Examples of frequency measurements using the DAQmx drivers
can be found in the NI Example Finder. In Labview go to Help >> Find
Examples… >> Hardware Input and Output >> DAQmx >> Counter
Measurements >> Digital Frequency. 
Please let me know if you have any questions and take care.
Thanks,
Nathan
National Instruments
Digital Hardware Engineer

Similar Messages

  • Can I measure frequency with a SCXI-1120 module and SCXI-1320 terminal block?

    I am attempting to measure a square wave from a directional encoder to display RPM of a dynamometer. The waveform will have a frequency of 0-4KHz, with 3.6KHz being nominal, at about 5volts RMS. How can I measure the frequency of this waveform with the hardware I am currently using? In addition to what is listed above, I am using a PCI6034E GPIB card and LabView software.

    In order to measure frequency, I would not recommend to use the SCXI-1120, but the SCXI 1126, which is a programmable isolated F-to-V module.
    If by any reason you do not want to use SCXI-1126, then I would suggest to use the counter/timers of your board. The counter/timers are TTL compatible, and are the devices that we mostly recommend for doing precise frequency measurements.
    In order to have access to the counter/timers of your board through your SCXI chassis, you will need SCXI-1180, which is basically a feedtrhough panel for your DAQ board.
    Once we have access to the counter/timers through the SCXI chassis, we can proceed with the coding.
    I found a pretty good webpage that clearly explains how to perform frequency measurement with the DAQ-S
    TC counter/timers (DAQ-STC is the type of counter/timer chip that you DAQ device has). Here is the link to it:
    Pulse Width & Frequency Measurements
    As you will see, this link contains tutorials, application notes and example programs. I would recommend to pay special attention to the example program called: DAQ-STC: Measuring frequency.
    Good luck with your application!

  • Unable to measure frequency below 20 Hz on a NIDAQ 9178 chassis with NI 9402 even while using a hardware timed delay

    Hello,
    I am trying to measure frequency using NI 9402 in NI cDAQ9178 chassis. I am setting the clock for my counter channel to be my chassis ai Sample Clock.
    I am able to measure frequency above 20 Hz. For frequencies less than 20Hz, I get the following error:
    DAQmx Error: Multiple Sample Clock pulses were detected within one period of the input signal. Use a Sample Clock rate that is slower than the input signal. Ifyou are using an external Sample Clock, ensure that clock signal is within the jitter and voltage level specifications and without glitches.Task Name: _unnamedTask<0>
    Status Code: -201314
    Setting the Rate to 1 also not does resolve the issue.
    OTHER DETAILS:
    * Running on 64 bit, Win7 platform.
    * NIDAQmx Driver Version: 14.5
    I had posted regarding this earlier and I was told that this might be because the counter is armed immediately before the first sample is taken. The recommendation was to add a hardware-timed delay using the DAQmxSetStartTrigDelay method to the AI task. I have added this delay but I still receive the same error message. The previous post I had mentioned can be found below:
    http://forums.ni.com/t5/Multifunction-DAQ/Cannot-measure-frequency-below-20-Hz-on-a-NIDAQ-9178-chassis/td-p/1537274
    I have also attached my current code which has the delay. Is this a bug in the driver? If yes, can we have a CAR# to track this?
    Thanks.
    Regards,
    Varun Hariharan
    The MathWorks

    Alright so I got everything working correctly in both C and LabVIEW code.
    The problems is in fact with the first sample, as John_P1 suggested. You simply need to delay that first sample from being requested. It is simple to do this in software instead of hardware.
    If you are using CVI, just add #include <utility.h> to the top of your .c file and then add a delay before your DAQmxErrChk (DAQmxStartTask(AItaskHandle)); line.
    Comment out / remove the DAQmxSetStartTrigDelay(AItaskHandle,10); line, as it wasn't doing what we thought it would. (Hardware delay).
    I added Delay (.05); to delay long enough for the full period of the input signal at 20 Hz.
    Depending on your frequency, this value may need to be adjusted. 100ms wouldn't be a bad idea.
    This is expected behavior, and I don't think we need a CAR.
    Let me know what you think!
    -CB

  • PXI 6608 Measure Frequency 1Hz with accuracy 1ppm

    I need to measure a frequency of 1 Hz with accuracy less than 1 ppm
    icant do it with a PXI 6608 its normal ? 
    1 Hz is measured 1,000007 Hz by a PXI 6608
    in this case, the error is 7ppm but i need less than 1ppm, i should measure 1,0000007 to have 0,7 ppm 
    please help its so urgent !!!!!!!!!

    Hello,
    In order to set the counter source to the timebase, you can use the the get/set/reset CI_CtrTimebaseSrc in order to set this in CVI. Please consult the DAQmx C reference Help for more information. Here are the functions if you can't find it in the help.
    int32 __CFUNC DAQmxGetCICtrTimebaseSrc(TaskHandle taskHandle,
    const char channel[], char *data, uInt32 bufferSize);
    int32 __CFUNC DAQmxSetCICtrTimebaseSrc(TaskHandle taskHandle,
    const char channel[], const char *data);
    int32 __CFUNC DAQmxResetCICtrTimebaseSrc(TaskHandle taskHandle,
    const char channel[]);
    As for performing a loopback test to test its accuracy, this isn't the best way to do this because the source is creating a signal with relatively the same accuracy as you are reading in back on the same device. Knowing that this signal is accurate down to .7ppm, we need to apply a source for the counter that is much more accurate than this. First way to do this is to change the timebase source to the 10MHz clock like I mentioned above. The other way is to place the PXI-6608 in slot 2 so that it overwrites the 10MHz clock on the backplane. This 10MHz clock is used with PLLing the 80MHz clock that is normally used in counter tasks. Which slot do you have the PXI-6608 in? Could it be placed in this slot?
    Jim St
    National Instruments
    RF Product Support Engineer

  • How to measure frequency with PCI-4474 card

    Hi,
    I'm trying to measure frequency with PCI-4474 card.
    Any sample code available?
    Thanks.

    Hi,
    Thank you for posting the the NI forums.  There aren’t any example programs that ship with the DSA drivers.  Will you be using this with the Sound and Vibration Toolkit?  If so, there are numerous examples that install with this software package.  Check out the LabVIEW Example Finder >> Toolkits and Modules >> Sound and Vibration Toolkit. 
    In addition to this, you could also use the signal processing VIs that ship with LabVIEW.  There are also examples that ship with LabVIEW that use these VI in Example Finder >> Analyzing and Processing Signals FFT and Frequency Analysis.  There is an entire Signal Processing palette that should contain the functionality that you need.
    I hope this helps.  Post back if you have further questions. 
    Ed W.
    Applications Engineer
    National Instruments

  • Error out problems with measuring frequency VI

    I am having some error out problems with measure frequency VI. The instructions is change error out from indicator to control but does not work. Anyone can help? The VI is attached
    Attachments:
    Measure Frequency VI error.vi ‏27 KB

    This VI does not have an error out. Obviously, you replaced a subVI that did have an error out with this one, otherwise you would not have been able to create this wire.
    Simply remove the wire or save the subVI with another name then modify it to have the error out that you are looking for.
    Hope that this helps,
    Bob
    Bob Young - Test Engineer - Lapsed Certified LabVIEW Developer
    DISTek Integration, Inc. - NI Alliance Member
    mailto:[email protected]

  • How to Measure Frequency to RPM NI-DAQmx Tasks

    Hello,
    I am trying to measure frequency using NI DAQmx task and then convert this to an RPM if at all possible.
    I have the following hardware options at my disposal.
    I have SCXI 1126 Module along with a SCXI 1327 terminal, as well as a PXI 6289 Multifunction DAQ.
    I have wired in a mag sensor to ai7 on my 1126 and when I pass a metallic object I get a amplitude of 6  - 8  so I am able to read the mag sensor.
    What I am trying to do is to somehow convert this analog measurement into a RPM while only utilizing the NI DAQmx task.
    Any help would be appreciated.
    Tim
    Solved!
    Go to Solution.
    Attachments:
    Freq Set Up.jpg ‏2993 KB

    So I would select new in "Custom Scaling"
    Then would I select linear?
    Your calculations are simple but I am unsure if this would give me the desired result.  From my attachment I am seeing an input amplitude of 6 Hz for each pulse.  What I mean by this is that every time I bring a ferrous object near my mag pick up I get a pulse, this is what I was trying to illustrate in the attachment.  The analog pulse comes in a 6 Hz so I would simply multiple this pulse by 60 (assuming I get one pulse per rotation) to get RPM?
    How would this make sense if I only input one pulse for a long duration of time? 
    I have notice the amplitude of the pulse input increases with increased pulse frequency.  Does this mean the lowest RPM I can record is 360 RPM?  
    Tim

  • Frequency/​Period measuremen​t with USB-6218

    I have been trying to get a USB-6218 to measure either frequency or period and have been running in to issues. I have attempted to connected to each counter gate (PFI1 or PFI2) and have not had any luck. I am attempting to meausre lower-frequency signals (1Hz-1KHz) so the Low-Frequency, 1 counter approach seems to be the one I need. The end goal is to get it working in Labwindows. I have made attempts using both sample LabWindows programs as well as MAX. In each of them, it appears that the frequency measurement is actually coming back with the pulse width of both the low and high portions of the signal. For instance, if I am trying to meausre the period of a 100 Hz signal, with a 75% duty cycle, it will toggle between 0.0075 and 0.0025 seconds for the period. If I increase the frequency of the signal to 10 KHz, it measures the frequency well. Is there something I am missing? Based on the manual, I should be able to meausre lower frequency signals using this method. Any help is greatly appreciated.
    Thanks.

    Can you upload a screenshot of your Task in MAX is setup? Is this happening at all lower frequencies or just at 100 Hz? Lets make sure we can get this working in MAX before adding LabWindows/CVI on top of it.
    Sometimes this can happen if the rise/fall time of the signal is not within the specifications of the device. This KnowledgeBase article shows the acceptable rise/fall times. 
    Applications Engineer
    National Instruments

  • Measure Frequency C#

    Hi,
    There was a question posted earlier asking about measuring frequency using C# and a multifunction DAQ that got my interested in th e topic.
    I found this example using a counter but it throws an error at startup.
    https://decibel.ni.com/content/docs/DOC-16563
    There are 2 tasks, an AITask and a counter task.
    The error occurs when trying to setup the input frequency terminal.
    counterTask = new Task();
    counterTask.CIChannels.CreateFrequencyChannel(counterComboBox.Text, "",
    Convert.ToDouble(minValueTextBox.Text),
    Convert.ToDouble(maxValueTextBox.Text), edge,
    CIFrequencyMeasurementMethod.LargeRangeTwoCounter, 0.001,
    (long)divisorNumericUpDown.Value, CIFrequencyUnits.Hertz);
    counterTask.Timing.ConfigureImplicit(SampleQuantityMode.ContinuousSamples, 1000);
    // Setup the Counter Input Frequency Terminal to be the Start Trigger from the AI Task
    counterTask.CIChannels.All.FrequencyTerminal = aiTask.Triggers.StartTrigger.Terminal.ToString() ;
    Here's the Error
    Error 1 'NationalInstruments.DAQmx.StartTrigger' does not contain a definition for 'Terminal' and no extension method 'Terminal' accepting a first argument of type 'NationalInstruments.DAQmx.StartTrigger' could be found (are you missing a using directive or an assembly reference?) 
    I'm using Visual Studio 2008, Measurement Studio 2008 Ver 8.5, DAQmx 9.5.5 and NET 3.5.
    Am I missing something?
    Thanks
    Curt

    Hi Curt
    Do you have the proper references included in your project? I am able to run this code as it is with no errors. You should see NationalInstruments.DAQmx under the references of your project.
    This reference is in this path. 
    C:\Program Files (x86)\National Instruments\MeasurementStudioVS2010\DotNET\Assemblies\Current\NationalInstruments.DAQmx.dll
    regards 
    Chris S.
    Attachments:
    Screenshot_1.jpg ‏26 KB

  • How do you measure frequency using the onboard counter on PCMCIA 6024-E

    I am using LABView 6.1 and NI-DAQ 7.2 with a SCXI-1000 chassis and a PCMCIA 6024-E on a laptop. I need to measure a frequency of about 3KHz and would like to do that using an 1180 direct through connector.
    Firstly, should I see this 1180 in MAX like any other module?
    And secondly, how do I use this 6024-E card to measure frequency? Which pins are supposed to be used on it to measure, and will I see the counter run in the test window in MAX according to the frequency measured?
    I know NI also have a frequency module for the SCXI chassis. So lastly, will it be better to use that, rather than measure directly off the 6024-E?
    Any help, advise or comments will be greatly appreciated!
    Thanks!

    Hello,
    I think I can help out with some of your questions. First, the 1180 module won�t show up in MAX since it is really just a feedthrough cable which allows you access to your unused signals from the DAQ card.
    You definitely can measure frequency using your 6024E. An example installs with NI-DAQ 7.2 which shows how to accomplish this. To access this example go to the LabVIEW start up screen and hit the Find Example button. When the Example Finder opens up browse to the following location: Hardware Input and Output -> DAQ -> Counters -> DAQ-STC -> Measure Frequency (DAQ-STC).vi
    This example measures frequency and has a connection diagram on the front panel. The documentation for the example can be accessed by going to File -> VI properties -> Document
    ation, after you have opened the VI.
    You are correct that we offer a frequency input module for SCXI (SCXI-1126). This module would be useful if your input voltages are non-TTL, or if you need to measure more than one channel of frequency signals. This module has an input range of +/- 250Vrms and 8 input channels.
    I hope this helps! Let me know if there is anything I can help with or clarify.
    Ken S.
    Applications Engineering
    National Instruments

  • How to Measure frequency of less than 300 Hz

    Is it possible to measure frequency without a counter module? All I have is a cDAQ with 9205, 9221 and 9263 modules.

    Hello,
    I am assuming that you want to measure analog frequency, since you have analog input and output hardware.  There is a useful LabView Help file titled Measuring Analog Frequency.  You will be able to measure analog frequency using just software and no counters.  However, this involves using Fast Fourier Transform (FFT) functions that are only available in LabView Full and Professional versions.  Please also take a look at the examples in the Example Finder.  Some helpful ones are titled … Signal Generation and Processing.vi, Spectrum Measurements.vi, and Simple Spectrum Analyzer (sim).vi.  These example’s block diagrams are a little busy, however you can see how they are using simulated signals with the FFT Power Spectrum.vi.  Note that the example titled Spectrum Measurements.vi uses express functions.  These functions are going to involve less programming, but offer lower program efficiency.
    Samantha
    National Instruments
    Applications Engineer

  • Measure Frequency of Digital Signal from DAQ-Board

    I'm using a National Instruments DAQ board and I need to measure the
    frequency of a digital signal from my data acquisition board.
    I know the measure frequency.vi (In diagram - data acquisition -
    counter), but i don´t understand yours implementation mainly in input
    "counter". Because i don't understand the relationship of board channel (for
    signal acquiring ) and the measure frequency.vi.
    Thanks in advance,
    [email protected]

    Hi,
       Attached is a vi which models your signal, and provides a way to measure the average frequency over a window of time. It converts the signal to a sequence of periods. I usually start with this approach because you can save the data in a much more compact form if your sampling rate is high. Obviously over a specified period of time, if there are no zero crossings the frequency is zero, so I was a little incoherent before. The real issue is the latency caused by averaging. Your frequency measurement is most accurate half your window size before the current time, so smaller windows give you more up to date measurements, but also more noisy. If you need the most up to date measurement, then you have to use the time since the last crossing which is the case where the frequency never goes to zero. That's probably not a realistic situation. If you needed less latency, you could use a prediction algorithm.
    Also, there are a number of signal measuring and processing vi's that LV gives you, for instance pulse measurements that could be used to partially implement this or other approaches, but I normally steer clear of them unless they fit exactly due to having to convert back and forth to the waveform data type.
    Have fun!
    Attachments:
    DigRandFreq.png ‏62 KB
    DigitalRandomFreq.vi ‏34 KB

  • Pins at a PCI MIO-16E-1 to Measure Frequency(DAQ-STC).vi?

    I want to measure frequency with the
    "Measure Frequency(DAQ-STC).vi".
    Can't find the appropriate connector pins
    in the manual of my PCI MIO-16E-1.
    Can someone confirm or correct me?
    Signal - PFI1/GPCTR1_SOURCE
    SignalGND - PFI9/GPCTR0_GATE
    PFI8/GPCTR0_SOURCE - PFI4/GPCTR1_GATE
    Thanks in advance
    Manfred

    Manfred,
    You can find this information by going to the http://www.ni.com/manuals site and viewing the E-series manual. There is a table which shows the pin number, name, and function for each pin.
    Pin 10 - PFI1/Trig2
    Pin 11 - PFI0/Trig1
    Pin 43 - PFI2/Convert
    Pin 42 - PFI3/GPCTR1_Source
    Pin 41 - PFI4/GPCTR1_Gate
    Pin 40 - GPCTR1_out
    Pin 6 - PFI5/Update
    Pin 5 - PFI6/WFTRIG
    Pin 3 - PFI9/GPCTR0_Gate
    Pin 2 - GPCTR0_Out
    Pin 4,39,35,36 - DGND
    Mark

  • Counter 1 - Measure Frequency & Counter 0 - Generate PWM POSSIBLE?

    Is this POSSIBLE with a NI-6025E DAQ card? Can I use the two counters to generate % control a TTL PWM signal and at the same time measure frequency from a circuit? This is my connection.
    GPCTR1_SOURCE - connected to find frequency circuit
    GPCTR1_OUT - connected to GPCTR0_GATE
    GPCTR1-GATE - not in use
    GPCTR0_SOURCE - not in use
    GPCTR0_OUT - connected to DC motor circuit
    GPCTR0-GATE - connected to GPCTR1_OUT
    My concern is that changing or controlling the TTL PWM might change the frequency reading. This is because COUNTER O is connected to COUNTER 1.

    I understand to measure frequency of a signal there are TWO methods. A ONE counter method and a TWO counter method. I need to measure a frequency between 1 Hz to 200 Hz. Is the ONE counter method possible? What is the ONE counter method?

  • Is there a car charger and fm frequency transmitter for iPhone with IOS6?

    is there a car charger and fm frequency transmitter for iPhone with IOS6?

    Here is something interesting about car chargers and the iPhone 3G:
    From Macworld:
    On to the power adapters. Here’s the story: We learned a while back that iPhone 3G doesn’t support charging “via FireWire.” The thing is, there are lots of devices out there that don’t actually have a FireWire port, but are technically FireWire chargers because they’re sending power on the dock-connector pins that were used for power by the FireWire interface. There are a lot of reasons for this, chief among them the fact that the FireWire spec allows as much a 18 volts, while USB is a 5-volt connection. Since cars provide 12 volts of power, many if not most car-chargers used the FireWire method to send power.
    However, in the interests of space and simplicity (i.e., not having to engineer for two separate power paths), Apple has dropped support for FireWire charging with the iPhone 3G. This means that many accessories won’t charge an iPhone 3G. Borchers said that Apple gave accessory developers a strong hint that this was going to happen a while ago, but he said that some companies have continued to implement FireWire-based chargers despite the warning.
    But there’s some hope in sight: Borchers told me that at least a couple of third parties will be releasing converters that will pass through the dock connection, but convert the power to a USB standard. That adapter may make many of those charging devices come back to life

Maybe you are looking for