LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Waveform Scalar Limit Comparison - need subtraction of second graph.

Hi all,

I m using the waveform scalar limit comparison to test if values are greater than a particular value. Im aware that the output of this vi is an array of two waveform data.
1. The original set of values
2. The set of values that satisfy the greater than limit comparison.

I need to access the second set of values that have passed(high level) and delete the rest of the values from the original array.

 

Any ideas how to do this simple?

Thanks and regards. Snippet_PassedValues.pngPassedValues.PNG

0 Kudos
Message 1 of 8
(3,509 Views)

Hi anja,

 

use a FOR loop with a conditional tunnel to filter all Y values greater than your limit:

check.png

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 8
(3,501 Views)

Hi Gerd

I tried that: PassedValues.PNG

But i was hoping that the Waveform Scalar with do a better job. By I guess in both cases it does not fulfil the wanted scernario. 

I guess I need to implement are real filter that eliminate the noise from the low level signals. The low level contains background noise from ambient light which effects the signal when my LEDs are on (the high lvl). You might remember the case 😉

You know a filter that eliminate that? I managed to subtract the values, but the signal is still effected by the low lvl signal/noise. 

0 Kudos
Message 3 of 8
(3,495 Views)

I got an idea, but dont know how to apply it 🙂 

I would like the measure the values  that are in the low period signal and simply subtract them from my signal when high? Is that understanderable? 

I guess that would take some of the background noises that lays within my low period signal? 

1. How do I measure values in a certain level? 
2. Subtract them from my signal at high level? 

0 Kudos
Message 4 of 8
(3,481 Views)

Hi anja,

 

on your snippet:

You implemented the "traditional" way to put elements conditionally into an array. Using my approach with conditional tunnel does the same with less BD elements…

 

on your idea:

Yes, that's nice. Now you know how to select samples for "high lvl" you could do the same for all "low lvl" samples. Then just average them to subtract the mean from all "high lvl" samples. Usually some kind of filter (lowpass?) is used to filter out noise…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 5 of 8
(3,471 Views)

Last week I end up doing this:

Snippet_PassedValues_v2.png

It does work to my intention but I only get an array of approx. 100 values out. How does I ensure that I get the corret numbers and I also need more values in my output. Simply an FOR loop to run multiply times? 

I tried with hundreds of different filters and I really hoped that the Scalar Limit Comparison worked, but I subtracted the passed values. Do you have any suggestions to a filter in labview?

Best Regards

0 Kudos
Message 6 of 8
(3,414 Views)

Hi anja,

 

you get all values above your limit in one array and all values below your limit in another array. With high probability both arrays will have different length!

 

Then you subtract one array from the other: how does LabVIEW handle such operations with arrays of different length? (That's a LabVIEW basics topic and handled by the free beginner courses.)

In my last message I already made a suggestion to handle your problem. You either didn't read carefully or you didn't follow my suggestion - both times your fault… 😄

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 7 of 8
(3,393 Views)

Just an idea:

 

How about using statistical methods:  

Use a histogram to sort your values ... use a bin size  to get about 5 (or more) bins per level

for each level you get a peak.    lowest peak ist the dark current of the PD .....

 

Or have a look at the pulse measure vis ....

(you can see the low level as an negative pulse 😉 )

 

 

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 ǝɥʇ'


0 Kudos
Message 8 of 8
(3,382 Views)