Measuring frequency using a 6602 device

Hello,
How can we measure the frequency of a signal using a 6602 device? How many counters are needed for this purpose?
We intend to use our own device driver, hence detailed instructions will be much appreciated.
Thank you,
Itai

The origin of the time stamp depends on the type of network module you are using. The following discussion covers how time stamps are generated with the FP-1600 and FP-1000:
http://exchange.ni.com/servlet/ProcessRequest?RHIVEID=101&RNAME=ViewQuestion&HOID=50650000000800000020230000&ECategory=Distributed+I%2FO.FieldPoint
My best recommendation is to purchase another CTR module. Using software timing will usually give you erratic results. That being said, make sure to use the "tick count (ms)" function if you must use software timing. That is the most accurate method for software timing. Also, you should set the counters to reset on read as recommended in Method 2 of this KnowledgeBase:
http://ae.natinst.com/operations/ae/public.nsf/fca7838c4500dc108
62567a100753500/d8db42f9fdc3607e862568640047f144?OpenDocument
Regards,
Michael Shasteen
Applications Engineering
National Instruments
www.ni.com/ask
1-866-ASK-MY-NI

Similar Messages

  • 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 using daq 6009

    HAI..
       Im using PFIO line to measure the frequency..i have attached my vi along with this..output is read approximately to the given input when i highlight the execution,but when i use run and run continuosly alone,am getting incorrect values..im totally confused..suggest some ideas..
    another doubt, may i use analog port to measure the frequency of an oscillator?if so kindly help me to create a vi for this also..
    Attachments:
    counter.vi ‏19 KB

    From your VI, one thing is clear, you are creating a task, but you are not clearing it. Please take a look at this example:http://decibel.ni.com/content/docs/DOC-8172

  • Measure frequency using 6023E

    Hi,
    I would like to measure the frequency and magnitude of the input voltage signals around 60HZ. Can I use the onborad counter of 6023E and labview 7.0 to do frequency measurement function per cycle , if yes, how to configure the hardware connection between input source and connector box? then can I use the analog input function to find magnitude at the same time? Welcome any suggestion.
    Fred

    Hello Fred,
    Gus is correct: generally you shouldn�t use the onboard counters on your 6023E to read an analog signal. These counters are made to input and output TTL signals.
    Here are a couple of options that may be good for you:
    1) Use external signal conditioning to read your input signal and convert the frequency to voltage. For this you could use the SCC-FV01 module or if you have a higher channel count you could use the SCXI-1126. Both of these modules convert an input signal�s frequency to a voltage which can then be read by one of the analog inputs on your 6023E. Here are links to the product pages for these two modules:
    SCC-FV01
    SCXI-1126
    2) Read in the signal on an available analog input from your 6023E and use post-processing to measure magnitude and frequency, as gus suggested. In LabVIEW there are some helpful VIs to analyze acquired waveforms. These VIs are located on the function palette at the following location: All Functions -> Analyze -> Waveform Measurements<\strong>
    I hope this helps!
    Ken S.
    Applications Engineering
    National Instruments

  • Measuring frequency using PCI6602

    What is the frequency range that PCI6602 can measure and what is the resolution?
    Thanks!!

    cooler,
    For a complete list of the specifications on the NI 6602, please reference Appendix A: Specifications of the 6602 User Manual.
    6601/6602 User Manual
    http://digital.ni.com/manuals.nsf/websearch/DD0DBB6404BC139886256721007CF16D?OpenDocument&node=132100_US
    Regards,
    Justin Britten
    Applications Engineer
    National Instruments

  • 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

  • How do i measure frequency?

    lets say theres this signal in volts. if you plot the signal it forms a sine graph. is there any way to use labview to determine the frequency of the signal? i've tried to use the "measure frequency vi" but my device is connected to a virtual channel, and i dont think that VI supports that...

    Hi Polly,
    There are several ways to measure frequency in LabVIEW. You can measure the frequency of a pulse train using DAQ hardware (counters). You can also just take a buffer of data and simply use LabVIEW functions to read the frequency of the buffer. An example function would be Extract Single Tone Information.vi. There are many other functions as well. Hope that helps.
    Ron

  • 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

  • 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 to measure frequency when no static line

    Hi. I think to directly measure frequency using DAXmx function my input signal should be connceted to DAQ PFI Lines but in my application the clock frequency is outputted on P0.0 line . Is there any way to directky measure frequency uding DAQmx function or I should do it manually?
    Thanks

    Hi tintin,
    you really should have learned to post good ( read as: meaningful, with sufficient explanations and background information) questions after more than 200 posts in this forum…
    What frequency do you want to measure?
    What is the relation to outputting your own "clock frequency" on some DO pin?
    Which hardware do you use?
    Why do you need to measure a signal frequency when you know that frequency as you output that signal?
    How do you measure frequencies "manually"?
    Best regards,
    GerdW
    CLAD, using 2009SP1 + LV2011SP1 + LV2014SP1 on WinXP+Win7+cRIO
    Kudos are welcome

  • How to measure frequencies of two sources simultaneously using 6602?

    I am using pci-6602 & LabView to measure frequencies of two sources. I wired Measure Frequency (NI-TIO).vi to do it, but it seems the counter only works at one channel at a time. Can anybody send me an example vi?
    Many thanks in advance
    ZYuan

    Hi ZYuan,
    To measure the frequencies simultaneously, you would need to duplicate the code for the single counter example twice and link the error cluster from one set to the next. I don't have a specific example but the following example can be used as a guide.
    Simultaneous Buffered-Event Counting on All Eight Counters of the 6602 or 6608 Devices
    http://sine.ni.com/apps/we/niepd_web_display.display_epd4?p_guid=B45EACE3DC9F56A4E034080020E74861&p_node=DZ52325&p_source=External
    Hope that helps. Have a good day.
    Ron

  • Any ideas on how to use a 6602 to do frequency division?

    Uisng traditional DAQ.
    The 6602 user manual says it can do frequency division but I can not find an shipping example for this operation.
    In the end I want to be able to use the 6602 to handle the interface to a quadrature encoder.
    I want the 6602 to generate a sample pulse I can use for other DAQ work.
    I would like to get one pulse for both transitions of both the A and B signals, or otherwise stated;
    A pulse when
    A goes high
    B goes high
    A goes low
    B goes low
    I was thinking if I could configure a counter (or group) to operate as a frequency divider and use each of the encoders as a clock signal AND just do a divide by "1" I would have what I was after.
    Big Picture (incase it makes a difference)
    A quadrature encoder is coupled to a resolver I am testing. I need to corelate the angular displacement with the measurement from the resolver. While the shaft of the encoder and resolver are spinning, I want the encoder to clock the analog input samples.
    Thank you for reading,
    Ben
    Ben Rayner
    I am currently active on.. MainStream Preppers
    Rayner's Ridge is under construction

    Ben,
    First the executive summary: Sorry, No Can Do.
    You won't be able to generate a sampling clock pulse on the transition to each of the 4 quadrature states.   Here's a thread I was involved in where a similar question was asked.   If you need to correlate in exactly that manner, you may want to pick up a quadrature decoder chip such as the 7084.  It'll generate a "pulse" whose width is controlled by selection of an RC time constant during circuit build.  I put "pulse" in quotes because it isn't truly a TTL signal due to the long transition time.  I would recommend that you plan on adding a Schmitt trigger to square it up, perhaps another to re-invert it back to original polarity.
    However, all that being said, you may be better off using an internal sampling clock to drive analog and encoder position acquisition anyway.  On many encoders I've used, the transitions are NOT perfect 1/4 divisions of the cycle.  You can sometimes see this on the spec sheets where the A to B relative phase is given as, say, 90 +/- 15 degrees.  There will also be a tolerance on the phasing of A's rising and falling edges, maybe 180 +/- 10 degrees (it's often a little tighter than the A to B phasing).
    In practice, I've typically found that these deviations tend to be systematic rather than random.  Of the company's 1000 similar encoders, the phase stays within the range 90 +/- 15.  With my 1 instance, the phase may be 84 +/-3 around a full rev of the encoder.  The point is that if you generate pulses with the quadrature transitions, the samples still won't *really* be equally-spaced in position.  They'll just think they are.
    I'd suggest at least considering high-speed sampling with an internal clock that's shared by both tasks.  Then do a little bit of curve-fitting / interpolation to the data when you need to derive more precision.
    Re: frequency division.  You have to select a specific edge (either rising-only or falling-only) as the active edge.   Your counter will then ignore the other type of edge.  Also, you'll need to specify the # of edges each for the idle and pulse states.  These must each be >= 2.  So you can't divide by 1 - the best* you can do is to divide by 4.  (*Technically, you could sort-of divide by 2 if you configure the counter to pulse rather than toggle its output.  However you can't control the pulse width, and as I recall it's fixed at 50 nanoseconds.)  Write back if you'd like to see an example.
    -Kevin P.

  • Measure scan frequency using 2 e-series boards and an external clock.

    I am setting up a data acquisition system in which the user has the ability to select between multiple sources for the scan frequency. The user can choose either hardware based and select the scan frequency or an external source, in this case, an encoder. When the user selects the external case, I would like to measure the scan frequency. I have a PXI chassis with 3 6071E DAQ boards. I have the encoder pulse train wired into the master board and would like to use one of the slave boards to count the pulses and measure the frequency. I based the code I developed on example code that shipped with LabView. However, when I drive the master board with a known frequency using its internal clock,
    I measure 0 frequency on using the slave boards counter.
    Attachments:
    DAQ_3_Boards_-_State_Machine_-_Scaled_Array.llb ‏1525 KB

    It sounds like you have your program setup to measure the frequency of the clock only when you are using an external source. The counter won't get an input if you are not using an external source, right? So, when you drive the master board with an internal clock, the counter will have nothing to count.

  • 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!

  • I want to measure rpm using 100 ppr incremental encoder via digital input

    i want to measure rpm using 100 ppr incremental encoder  via digital input max speed (4000 rpm)
    am using 9178 c-DAQ chassis and 9426 digital input module
    pl provide me example code for this

    Hi asaccullo.
    The recommended settings for encoders are using the counters in the daq cards. Using digital I/O’s is not recommended, the encoders send digital signals but one of the main differences between using digital IO vs counters is that counters are designed to handle these type of events.
    Here I found several examples in ni.com/code that you might check:
    Imitation Quadrature Encoder with DAQmx Counter Tasks
    Use Counter Frequency to obtain an Encoder Rotational Speed
    An Elvis is a daq device, so this should work for you.
    I also found an example for myDAQ, it uses the DIO but with a counter task in the set up.
    Regards,
    steve.bm
    AE | NI

Maybe you are looking for