LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

For "Select" module, how can I return nothing if s is false?

Thank you very much crossrulz! So you firstly split the string into header+data, and case structure will select the header right? But I'm still not very understand what's the function of the feedback node. Why you keep the latest value? In my understanding, case structure will select the header, then put the data into corresponding array right?

0 Kudos
Message 11 of 18
(1,573 Views)

Smiley Very Happy It's a full circle. I just followed what you said, I set the output tunnel of case structure as "use default if unwired", but it will return 0 not empty when the case is false.

0 Kudos
Message 12 of 18
(1,572 Views)

@yatang wrote:

But I'm still not very understand what's the function of the feedback node. Why you keep the latest value? In my understanding, case structure will select the header, then put the data into corresponding array right?


You do not want your other value to just reset to 0.  That would completely mess up your data logging and/or display.  So the feedback node keeps the latest values of your channels.  So in the case structure, you just update the channel values you recieved.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 13 of 18
(1,564 Views)

I said to do the conversion to string inside the case structure, so you'll get an empty string out.

It might be better to use a defined value string e.g. "missing" for clarity.

 

If you want to stick with the numeric, use some special value to indicate missing data (e.g. -999 or whatever cannot occur normally).

 

I still think that you are overenginering things. You have three charts and if each only updates when valid data arrives, their x-axes gets out of sync very quickly, confusing the operator. A better way would be to send a NaN to the chart, interrupting the curve for the duration of the outage.

0 Kudos
Message 14 of 18
(1,557 Views)

OK I understand you. And will the feedback node repeat the correct data for three times?Smiley Happy

By the way, could you please help me modify the code? I cannot find some functions in the labview. Just like the functions inside the case structure as you shown in the previous figure.

0 Kudos
Message 15 of 18
(1,546 Views)

Previous picture by CrossRulz has a Bundle by Name in it.  It is also a snippet.  You can drag the image to your desktop, then drag it into your block diagram and have actual live code.

0 Kudos
Message 16 of 18
(1,530 Views)

WOW, it is so fancy!Smiley Surprised  But CrossRulz's labview version is later than mine.  Hi RavensFan can you open that code? If you can, could you please convert it to version 12.0Smiley Tongue

 

0 Kudos
Message 17 of 18
(1,519 Views)

LV12

 

If you are not familiar with Bundle by Name, then I would recommend looking at the online LabVIEW tutorials
LabVIEW Introduction Course - Three Hours
LabVIEW Introduction Course - Six Hours

0 Kudos
Message 18 of 18
(1,506 Views)