LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Need to apply trigger to data exiting Analog 1D Wfm NChan NSamp

I'm collecting ananlog data from a slightly noisy sensor that cannot be replaced.  When not active, there is some noise on the line bouncing between 0 and 2V.  When active, I get a clean 5V signal.  The signal is collected through an "Analog 1D Wfm NChan NSamp" DAQmx control in LabVIEW 7.1.  The resulting waveform then gets translated to a Dynamic Data Type, which lets me use the "Timing and Transition Measurements" ExpressVI to measure a slowly varying signal.

 

Usually, this works fine.  When the timing gets too long, though, the VI loses sight of the 5V pulse, and instead gives me the frequency of the noise. 

 

Thinking about it, it occured to me that I could clean up this signal if there were some way for me to replace any portion of the signal that's below 2V with 0V.  Before I look into a hardwired trigger circuit, I was wondering if I could do the same thing in the code.  Also, this is a legacy system, so switching to other programming approaches is a bit problematic.

 

I'd appreciate any thought you could provide.  Thanks!

 

0 Kudos
Message 1 of 4
(2,585 Views)

Hi So-Komp, 

there are different possible solutions to your problem.

I think the best one could be filtering the signal, anyway the workaround you have thought about can be easily implemented.

I attach an example in this post. There is also an Express VI that makes more or less the same thing automatically: you can find it in the function palette in Express >> Signal Analisys >> Mask and Limit Testing

 

I hope this could help.

Best Regards,

 

Serena M.

0 Kudos
Message 2 of 4
(2,568 Views)

Thanks for the advice.  Unfortunately, I'm running LV7.1, so I can't open your example for the details

 

Looking at the Mask and Limit testing, I can set the lower limit to 2V, and that looks almost like what I'm after.  If I look at the Tested Signal output, I simply get the input signal out.  If I look at the Point-by-Point results, I get 1's and zero's which could work if I can take the input signal and multiply it with the Point-by-Point output.  That would get me the following

 

Input         Pt-by-Pt          Output

1                   0                     0

1.5                0                     0

2                   1                     2

2.6                1                    2.6

 

Or, could you reattach your example in LV7.1?

 

Thanks again for your help

0 Kudos
Message 3 of 4
(2,553 Views)

A day later, some more reading and experimentation, and I got it to work.

 

Using the point-by-point output, I get a series of 1's and zeros on each point of the incoming waveform, indicating whether or not it passed.

Dynamic Data can be multiplied together, so the waveforms of the point-by-point output and the original signal can be multiplied.

This leaves me with a new waveform, with zeros where the original waveform is beneath my cutoff value, and the passed-through values everywhere else.

 

Thanks again!

0 Kudos
Message 4 of 4
(2,532 Views)