LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

monitoring pulse train

I'm monitoring a rapidly toggling data stream of ones and zeros.  I need to timestamp whenever my 32kHz pulse train drops out (more that 500 ms of flat line data ).  I'm using a USB 6009.  Can anyone help me?
0 Kudos
Message 1 of 5
(2,538 Views)
How are you acquiring your data, single point at a time or a block of data?? Does it need to be done in real time?? There are two point by point vi's in the analyze section. Boolean Crossing and Value has changed.
0 Kudos
Message 2 of 5
(2,530 Views)

If my USB 6009 can sample the 32kHz square wave fast enough, I think real time would be the way to go.  If the square wave drops out for more than 500 ms, then write the timestamp to an array or txt file.  If I cant process real time, then analyzing a block of data to spot a 500 ms dropout of the signal is the way to go.  What are the names of those VIs you were talking about.

Nate

0 Kudos
Message 3 of 5
(2,510 Views)
Here is where they are located.
0 Kudos
Message 4 of 5
(2,501 Views)
Auburnate,

There are 2 ways to go about this:  Acquiring with an analog input, and acquiring with a counter.

Analog Input
Although system dependent, the maximum single-channel sample rate of the 6009 should be around 48kHz (see page 3 of the 6009 specs).  This will not give you a good "shape" to your 32kHz pulse, as you will only get 1 or 2 samples per period.  However, you could average the value of this analog signal over time (at least 10ms or so) to determine if it is pulsing or not.  If the pulse train is active, you should see an average voltage of close to half of your logic high voltage.  If the pulse train is not active, you should see a voltage very near 0.  With a little thresholding, you should be able to monitor the activity of this pulse train very easily.

Counter
Your 6009 has 1 counter input that can detect falling edge pulses on TTL compliant signals up ot 5MHz, (also on page 3 of the 6009 specs).  You could check the count register of your counter periodically to verify that it is incrementing.  If the number of counts increments by the number of pulses you'd expect in a given time period, you will know that your pulse train is active.  If the number of counts increments very few counts or none at all, then you know that the pulse train is not active.

Whichever method you choose, I would recommend starting with one of the example programs that come with DAQmx.  Let me know if you need any more help, and best of luck on the application.

Have a great day!
Travis W

0 Kudos
Message 5 of 5
(2,481 Views)