Help Counting high frequency voltage spikes

Equipment:  NI USB-6229     (250 kS/sec Analog In., 16 bit DAC, 32 bit Counters and internal clocks <= 80 Mhz)
                      LabView 14
Problem:
I have an experimental application where I need to count voltage spikes (integer #) caused by electrons hitting a sensor. These spikes can be as frequent as 500,000 Counts/sec. The spikes are not going to be the same voltage everytime, but they will be visible above the noise so I need to allow the user to select a Threshold Voltage that triggers a real count rather than noise spikes.
Attempts:
To count such a high frequency, I deduce that I need to use a Counter Input to read fast enough, HOWEVER, I wasn't able to find a way to set a threshold voltage for a Counter Input because I believe they expect a TTL signal anyways, which I won't have. To set the threshold, I realize that Analog Input reads can be triggered at a selected level which is great but the Analog Input Sampling Rate is only 250kS/sec which won't catch every count in my project.
I have a program that uses the Count Edges channel and it is accurate within 3% of the expected # of counts. I was just testing it with a function generator and the program doesn't count unless the signal's voltage is above 2-3 V which won't work for my application. I will post what I have. Does anybody know of a way to trigger off only at selected Voltage levels using counters, or know of a way to filter through the noise to get real spikes?
Thanks!
Solved!
Go to Solution.
Attachments:
ElectronCountsTest.vi ‏29 KB

Thanks for the reply johnsold. I didn't think to use a comparator but that is good to know that I have that option. I was and still am hoping for some kind of trick to do this programmatically.   One other idea that I was playing with is offsetting two or three different Reads on the same signal to read the signal at different times. If this is a possibility, it may be able to double or triple my sample rate to 500k or 750kS / sec. Anyone else have any ideas on this solution?

Similar Messages

  • Using DAQ-assist to input a waveform; need help building a counter to count voltage "spikes"

    Hey all! I'm pretty new to labView and even newer to this forum, but its nice to meet you all...I hope that perhaps someone can help me with my problem.
    Allow me to begin by detailing the specifications of the problem.  I am an undergraduate student, and have a job doing research in a MEMS (micro/nanotech) lab.  The graduate student I am making this program for is working on biomedical applications;  eventually, the program will be connected to a microdevice that has a tiny channel in it, cut through a wee little capacitor, which blood will run through.  As red blood cells pass this capacitor, the voltage will spike; meaning that for each voltage spike, we can (and are trying to) count the number of red blood cells.
    However, I am still in the early developement of the program, so this above specific info is not that important.  Basically, I am using a function generator to input a waveform to the DAQ assistant of, say 500 mV.  I am trying to write a program that increments a counter every time I turn the voltage above say 550 mV (peak-to-peak), counting the number of simulated "spikes."  I have tried quite a lot to write a working program, and although I have not gotten it to work yet, I will post a screenshot of my most recent attempt HERE:
    I thank you in advance for any helpful tips, advice, or straight up assistance you may be able to give me.  Please ask me any clarifying questions about the program I wrote or the application, or anything.  Happy Friday! 

    Hey guys, it's been a while!  A lot of stuff has been happening in my life and I have had virtually no time to work on my LabView project.  
    I did create a LabView program based off IanW's reccomendation.  I am unsure of what exactly is going wrong, but when I run it, only a simple "snapshot" of a waveform from the DAQ shows up in the graph.  Even when I put the DAQ assist in a seperate while loop, the same thing happens.  I am including a screenshot of the project in case I am messing something entirely different up.  If you happen to read this, I really appreciate your help and thank you Ian! 
    I am also having a random issue with the filter signal VI.  So that background signals in the actual experiment do not read as "spikes" I have been instructed to include a high-pass filter in the VI.  However, everytime I use the high pass filter VI, it botches my signal and turns it into a bunch of noise!  I, nor my graduate mentor (who isn't too well-versed in LabView) have any idea why this is - we've tried using different types of filters to no avail.  
    Lastly, I would like to talk to Peter about a few questions I had abour LabView design.  In case you're still around, I will write another post later today with more detail.  In the meantime, I will try to find some of the example VIs about shift registers   All who read this have a great day!
    Attachments:
    count spikes pic.png ‏29 KB

  • Synchronize sampling of rpm using frequency counter with force (voltage) signals

    I have a VI attached which converts the voltage values measured from the ATI force/torque senosr to force values. I would like to integrate the measuring of TTL pulses from an RPM senosr. There is a bug with my current program, as the RPM value only updates once. If I put the read VI in a while loop, the program returns an error. How should I modify my code to solve this, and as well as to synchronize the recording of data from both sensors?
    I have no prior labview experience, and really appreciate any help.
    Attachments:
    atidaqft-mx.llb ‏93 KB

    Dear Jochen,
    (1) Principally, I'd like to use PCI-6602 to be a motion encoder also be a counter (Is it possible? Due to the manual, it is possible). I expect to have all information, such as position, time, velocity, etc. from that motion encoder (or at least the position and time). It is also expected of using PCI-6602 to do all measurements that I mentioned before . My meaning is, after having a signal from the counter, that 'count' will be converted to desire units under other programs. So, in this case, PCI-6602 is only used to get the 'count'.
    Simplified, the voltage command will send to the system (linear motor) through PCI-6052E (-10V to 10V). The actual position or other actual information will be catched (read) by using PCI-6602 (as a motion encoder, also as a counter). Then, this actual position will be used as a feedback, that will be compared to desired position.
    Is that also possible to use PCI-6602 be a motion controller + a counter + a frequency measurement in a same time parallely?
    I don't decide yet (I don't know) which acquisition rate will be needed/required, higher is better.
    (2) I'd like to apply an adaptive robust controller (yes, it is a closed loop system) under matlab with their feature called Real-Time-Workshop instead of using LV.
    (3) Power drive for the linear system will be driven by AC servo drive.
    Thanks for your help before,
    Warmly regards,
    hendro

  • Help with Frequency/voltage Ctrl settings in CMOS

    I have the K7N420 Pro Mobo and the Ge4Ti4200 card. I just ran 3DMark01, after a new bare hard drive, fresh install of Win XP and running Live Update on my drivers. I got a low score of 7459. On my old hard drive yesterday I got a score of 9745. I also upgraded my PSU to a 350 W (temporarily - 400W on the way) In the CMOS under Frequency/Voltage Control, is a listing:
    CPU/MEM/AGP and it is set at 100/200/66. What do those numbers mean? I can't find these numbers anywhere either in my documentation or on this site. How do we determine the proper setting for these numbers for the best performance? What can go wrong if they aren't set properly?
    K7N420 mobo
    Ge4Ti4200 VTD-8X 128M
    AMD Athlon 1700+
    SB Audigy
    Win XP Pro
    Direct X 9
    350 W Allied PSU
    2-256M DDR Ram
    Lite On CD-RW
    WD 80 Gig (8M cache) 7200 RPM Caviar HDD

    Hi,
    Your CPU and FSB are only running at 200mhz. Which you are underclocked. Try setting the FSB clock to 133 or load performance defaults.
    -rob

  • High frequency measurement 2 counters range

    Hello,
    I know this info is somewhere but I can't find it.
    When using a Counter/timer to measure frequency there are multiple methods.
    i.e. Low Frequency with 1 counter and high frequency with 2 counters.
    What is the definition of a "low frequency" and what is the definition of a "high frequency"?  i.e. low frequency = frequencies below 100 Hz 
    Also what is the definition of a "large range"?
    Thanks
    Dan

    Hi Dan
    There isn't a specific bandwidth that is defined for use with either the one-counter or two-counter method. However, located in the NI-DAQmx help file there is a section detailing the quantization errors that arise when using either method with a variety of input frequencies. By referring to this information you should be able to determine which method will produce the smallest error in your application and hence which method will be preferable. This help file also explains the errors associated with the large-range two-counter method.
    To locate the help file, you should select Start»All Programs»National Instruments»NI-DAQ»NI-DAQmx Help, and search for 'quantization error'.
    I hope this helps, just let me know if you'd like anything clarified or if you have any other questions on the matter.
    Regards
    Jeremy T
    Technical Marketing Engineer
    National Instruments UK & Ireland

  • DAQmx Error 89137 When trying to make a high frequency measurement.

    I am using a PCI-6602 Timer/Counter for multiple measurements on a serial interface...
    I have the clock line connected to Gate0, the enable line to Aux0 because I need to make a two-Edge seperation measurement between the two later...
    But I also want to make a "Period/Frequency Measurement (High Frequency with Two Counters)" measurement...
    This requires that the signal to be measured is on Source0...
    I implimented the following Code:
    void meas_FP_Freq(float64 *Freq0, float64 *Freq1)
    TaskHandle CLK0_Freq, CLK1_Freq;
    DAQmxCreateTask ("FP_CLK0_Freq", &CLK0_Freq);
    DAQmxCreateTask ("FP_CLK1_Freq", &CLK1_Freq);
    DAQmxConnectTerms ("/Dev3/PFI38", "/Dev3/Ctr0Source", DAQmx_Val_DoNotInvertPolarity); // Gate0 to Source0, No Error....
    DAQmxConnectTerms ("/Dev3/80MHzTimebase", "/Dev3/Ctr1Source", DAQmx_Val_DoNotInvertPolarity);
    DAQmxCreateCIFreqChan (CLK0_Freq, "Dev3/ctr0", "", 6000000, 6500000, DAQmx_Val_Hz, DAQmx_Val_Rising, DAQmx_Val_HighFreq2Ctr, 0.001, 4, "");  // High freq measurement
    DAQmxCreateCIFreqChan (CLK1_Freq, "Dev3/ctr1", "", 6000000, 6500000, DAQmx_Val_Hz, DAQmx_Val_Rising, DAQmx_Val_LowFreq1Ctr, 0.001, 4, "");
    DAQmxReadCounterScalarF64 (CLK0_Freq, 3.0, Freq0, 0); // Run-Time Error -89137 Specified Route cannot be satisfied..etc
    DAQmxReadCounterScalarF64 (CLK1_Freq, 3.0, Freq1, 0);
    DAQmxDisconnectTerms ("/Dev3/80MHzTimebase", "/Dev3/Ctr0Source");
    DAQmxDisconnectTerms ("/Dev3/80MHzTimebase", "/Dev3/Ctr1Source");
    DAQmxClearTask (CLK0_Freq);
    DAQmxClearTask (CLK1_Freq);
    The "Low Frequency" method works fine, but the resolution is too low...
    Every help file I've read indicates I can use different PFI inputs for measurements... What am I missing?

    Hi,
    The reason that you are getting the error is the PFI lines are being reserved twice. You don't need the DAQmx Connect Terms functions in your code because the DAQmx driver does this for you automatically. If you still receive an error after doing this, try to changing the low frequency counter number.  I hope this helps you with your application.
    Regards,
    Hal L.

  • Daq 6211 high frequency ouput

    HI guys.
    Ive got my hands on a USB 6211 daq device. Im trying to generate a high frequency pulse output from one of the 2 counters. The frequency is in the range of 5 to 20 kHz. Can someone tell me if thats possible with this USB 6211 device?. Ive been searching but cant seem to find the answers. Are the counters on this device just for reading HIgh Frequency inputs or can they ouput them also. Any help would be much appreciated. 
    Solved!
    Go to Solution.

    That manual has helped a lot. I should have looked at properly in the first place. Thanks .
    I have one more question if anybody can help. I'm using the daq 6211 to create a pulse train to control a stepper. The stepper driver takes in a pulse which in turn will turn the stepper and the frequency of these pulses determines the speed.
    My problem is that, using the counter examples in labview, I only have an option to create a continous pulse train. I would like top be able to dynamically adjust the frequency while the vi is running and Ideally i want to be able to ramp up the frequency so that the stepper can get to a high speed. If i try to adjust the controls with the example vi's there is no change in frequency unless i stop it and start again with a different frequency. 
    Has anyone come accross this themselves or am i missing something obvious??. 

  • Low frequency Voltage measurement

    Hi,
    I am using PCI 6025E to control load bank and to measure voltage, current and frequency of a generator.
    While current and frequency measurement  is not a problem, voltage measurement is toublesome.
    Since on test bench already there are few PCI boards and huge number of sensors, I do not want to add NI 9205 or any other additional boards and clutter the area (other people are also working there).
    The problem with voltage measurement is that out of three generators two run from 400 RPM to 1600 RPM i.e.. somewhat 15-55 Hz.
    I had two solutions for this:
    1, Putting a step down transformer (230 Vac / 5 Vac) and then measure the voltage. But when testing at somthing like 15 Hz I have to deal with magnetic saturation with commercially available transformer. I do not want to take pain to go on built my own transformer.
    2, Using high precision voltage Divider. The problem is that what should be the galvanic isolation? Isolation transformer, but then again low frequency problem.
    Hence could someone suggest me since there is a bit confusion in my head.
    Thanks.
    Solved!
    Go to Solution.

    If you have a sine generator (15Hz migth be hard for the soundcard ) you can do a calibration of your transformer.
    (If only the voltage amplitude is of interest , use a isolated DMM as reference and run your generators)
    Or you buy a isolation voltage sense amplifier. (weidmueller, phoenix, wago, ...)
    Greetings from Germany
    Henrik
    LV since v3.1
    “ground” is a convenient fantasy
    '˙˙˙˙uıɐƃɐ lɐıp puɐ °06 ǝuoɥd ɹnoʎ uɹnʇ ǝsɐǝld 'ʎɹɐuıƃɐɯı sı pǝlɐıp ǝʌɐɥ noʎ ɹǝqɯnu ǝɥʇ'

  • Convert a counter to frequency

    Hi,
    I am using two counters on a 6023E board. I have two pulse generators which
    give 1000 pulses in one rotation.
    How can I convert the counts to frequency or speed in LabView?
    Greetings,
    Erik.

    We found that the best way of obtaining speed measurement from a pulse generator is to use the buffered period measurement and scan some period (more than one), then eliminate the first measure (first period measurement may be incorrect due to the uncertainty in the start of measurement with respect to the slope of the signal), next average the measures obtained.
    The next step is to divide base time used (internal base time of 20 mhz for example) by the average measure obtained in the preceding step: this is the average period measurement and must be multiplied by 60 and divided by n. of pulses per round: this gives you the rpm value.
    Step two can be put in a loop in orded to obtain a continuous measurement, provided that you restart the counter once obt
    ained a finished reading from it.
    Roberto
    Proud to use LW/CVI from 3.1 on.
    My contributions to the Developer Zone Community
    If I have helped you, why not giving me a kudos?

  • MSI R7950 TF 3GD5/OC BE too high stock voltage

    Hi, this is my first post so please be gentle with me
    I just bought a MSI R7950 TF 3GD5/OC BE video card which is 960mhz stock speed, but I found out that this card has a too high stock voltage which displays 1.18v in GPUZ and 1.25v in afterburner. I don't think the card can last long with such a high voltage so I want to lower it.
    I try to adjust the voltage in afterburner, it seems it changes in the software (the slide did change). But GPUZ still displays the same voltage.
    Can anyone help me with this?
    Thanks.

    Quote from: tails on 07-April-13, 22:29:57
    Thanks for the reply.
    I've found the solution for that. I downloaded the version 3.00beta9 of afterburner and now it can change the vcore.
    I changed the vcore from 1.25 to 1.05v. Now the card is running at 1050mhz, 57degree with 60% fan speed, cool and quiet. Before was 75 degree and 80% fan speed.
    I'm satisfied now.
    Ive got Afterburner 2.31, its allows undervolting as well. But problem is that in boost mode new values are ignored and back to default. So in that case cant see any sense in doing that. Is that changed in ver 3?
    D.

  • How to change the display in the waveform graph to enable higher frequency displays.

    I am working with waveforms of very high frequencies upto 2MHz. When the frequency of the waveform is increased above 500Hz, the display in the waveform graph goes blank.
    Please help me.
    Thanks

    Dear Labviewguru,
    Thanks a lot for your response.
    The problem had been technical, and it has been solved.
    Actually, I didn't specify the number of samples while generating the waveform, so only frequencies upto half the default value (1000) were being displayed.
    Regards,
    Roopa

  • High-frequency permanent distortion while recording through Line-In

    Hi Everyone!
    I'm recording music from my MiniDisc Player connected with Audio Cable to Line-In port. I'm using Real Instrumen track for this. When I record or even only listen to the music I hear permanent High-frequency Tone in background. I can record with no problems but my recordings are always accopanied with this distortion. I've checked it out also on Windows (Boot Camp) and there are no such noices. Somebody knows what could help? Maybe it's something with audio drivers?

    In Multitrack view, Options, there is a Monitoring option where you should be able to set Audition Mix to Always.
    This doesn't appear in Edit View.

  • High frequency power measurements

    Hey,
    I'd like to know if there are developments in measuring electrical high frequency signals with labview without using an extern power analyser. At the moment i'm using a yokogawa power analyser but i'd like to know if it's possible to log HF signals without the help of a power analyser... Are there NI products on the market for this purpose?
    Thx,
    Andy

    Hello,
    In the case of frequencies up to 200 KHz, NI can provide several solutions using the 'standard' data-acquisition boards or digitizers (scopes), from a low to very high accuracy solutions.
    A good solution can be one of the high speed M-series boards (PCI-625x).  These boards have up to 32 multiplexed channels with a resolutions of 16-bit at a speed of 1 MS/s  (500 KHz).
    A better solution would be a S-series boards.  These data-acquisition boards sample all input channels simultaneously.  We have boards with 2, 4 and 8 channels and sample frequencies of 10 MS/s  (up to 5 MHz if needed).  S-series board are the boards with product numbers PCI-61xx.
    The best solution is to use a digitizer (scope).  Also here a lot of possibilities going from low to higher bandwidth and resolution.
    The most flexible is the PXI-5922.  A 24-bit digitizer if you sample @ maximum 500 KS/s.  This board only exist in the PXI platform.
    Then NI has 8-bit digitizers (normal resolution for scopes) from 15 till 125 MHz bandwidth.  If you need a higher resolution they have solution up to 14-bit (very high for scopes) @ 100 MHz.
    Please give your local NI Office a phone call.
    They have technical engineers who can discuss your needs and provide you a solution.
    Best regards,
    Joeri
    National Instruments
    Applications Engineering
    http://www.ni.com/ask
    Make our forums great:
    If you like the answer, don't forget to "Kudos!".
    "Accept the Solution" if your question is answered!

  • High frequency quadrature decoder (NI PCI 6221)

    Hello, i would like to ask you about high frequency quadrature decoder. I am using module in DAQmx for measuring linear position. For this i am using NI PCI 6221. My problem is that i want to use this for my interferometer and we need really high speed. So I tried to use External timing whitch should be possible for this card up to 80MHz. Unfortunatelly i always will get error message that there is some kind of owerflow and my program crashes. So my question is how to get all data form this card. I know that the buffer size FIFO is only 2 so if it is impossible to get all data so i want find another solution. Is it possible let my card work alone on 80MHz and only repeatly rewrite all buffer and just sometime ask this card for sending current buffer. I dont really need all the data, but when i will ask i need to know reall position. This high speed is really necessary because my interferometer is sensitive and i dont wat to lose any steps. If there would be any possibility how to work on 80MHz and only sometime ask for sending data with position, it would be great. Sometimes i will ask not for only current position but for full buffer because i want so see what is happening during some time period, but this task will be only sometime. 

    Dear BMAJTZ,
      The counter frequency (the maximum speed available) is configured by the Task in the background. In our case, the counter is set to detect edges, so it always uses the maximum speed available. If an edge occurs, the count value increases by 1, and this accumulated count value (stored as a binary number) is read by the DAQmx Read VI, and converted to meters. So if your encoder input is slow enough for the 80 MHz card to handle, you won't miss any ticks, even if you only read the value occasionally.
    You can find further information about counters and encoders on these links:
    http://www.ni.com/academic/students/learnlabview/digital.htm
    http://www.ni.com/white-paper/7109/en
     Also if you can tell me the approximate frequency of your encoder signal, and how often you nedd the position info, I can do some benchmarking for you to see if your card is capable of the task.
    Best regards:
    Andrew Valko
    National Instruments
    Andrew Valko
    National Instruments Hungary

  • High frequency

    Hi everyone, im pretty new with Labview, and I need a help. I would like to simulate square wave with high frequency (40MHz).
    1. Can anyone help me, how can I simulate the signal (test2.vi) in a moving (time) axis?
    2. I would like to catch the datas and write it into .txt or excel. I found this example (0807-LVM_Beispiel.vi). Can I get the datas like this from my 40Mhz frequency generator?
    A little help would be nice. Thanks.
    Attachments:
    test.jpg ‏525 KB
    test2.vi ‏29 KB
    0807-LVM_Beispiel.vi ‏88 KB

    thanks for your help.
    Ive been searching, and now I've changed my test2.vi into test CIC.vi and modified it. If you may see it, im trying to simulate the signal with frequency 40MHz and, with sampling frq. 800MHz and sample rate 1000samples or max. ~300.000samples (and save it in a txt.file). Actually, my task is, that im gonna need to make a labview program that can take as many points as possible, that might be not periodic. I mean, we gonna use NI card (in near future, not bought yet) to take some input datas, and to get all the data-samples in high frequency range. Is it possible to make such a program (capture the data) without knowing in the first place which NI card that we are going to use. But i believe, we gonna buy a digitizer, digital I/O and might also mxi controller (I've looked at the offered device list) from NI. Thanks a bunch. Is it much easier after buying the devices? (like getting the device's driver and maybe program that support it).
    One other question, in my test CIC.vi, im saving my points into .txt file (only the amplitude). How is the trick to take also the x-axis points (time axis) and save it in the same .txt file.
    Attachments:
    test CIC.vi ‏49 KB
    CIC 1 sub.vi ‏21 KB
    Save 1Data.vi ‏18 KB

Maybe you are looking for