LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Making the correct string out put show up in the front panel.

Solved!
Go to solution

Hello, i am trying to figure out how to make my string output to the front panel. I believe that i wired it correctly, but it still refuses to output anything. Basicly i have to have it output freezing if it is below 32; no warning if it is between 32 and 75(inclusive); high temperature if it is between 75 and 100; and heatstroke if it is over 100. I have uploaded what i have done below. I am not sure what i am doing wrong. Also there should be a boolean led light, that switch on if there is any of the warnings except no warning. Thanks in advance!!!Screen Shot 2017-04-10 at 20.20.46.png 

0 Kudos
Message 1 of 9
(4,305 Views)

First, run block diagram cleanup to clean up your wiring.  Some of it is running backwards and makes it hard to debug the picture of your code.  Typically it is very hard to debug pictures and would be much better if you posted the actual VI.

 

Second, it might be because of the unclear wiring, but it sure looks like you have nothing coming out of the outputs of all those Select Functions.

 

Third,  Check your spelling.  The word is "Temperature".

 

Forth, the lower bit of code with greater than, less than, and AND could be replaced by an In Range and Coerce Function.

0 Kudos
Message 2 of 9
(4,294 Views)

Thank you for the quick reply.I cleaned up the block diagram and added the In Range and Coerce Function, (however there is some issue with that) like you suggested. I have also uploaded the VI like you requested. 

0 Kudos
Message 3 of 9
(4,285 Views)
  • There are two things called "Warning" on your Front Panel and Block Diagram.  One is a String Control (meaning you read from it, you don't write to it), the other is a Boolean.  While it is "legal" to name two variables the same thing, it is foolish to do so.
  • I assume you want the String "Warning" to display "High Temperature Warning", or "Heatstroke Warning", or some other String.  Do you know the difference between a Control and an Indicator?  Do you know how to turn one into the other?
  • What do you know about the Select Function?  Right-click it, choose Help, and read the Help description.

It appears you know very little about LabVIEW.  Before working on this VI of yours, spend an hour or so with the beginning LabVIEW Tutorial material shown as links on the first page of this Forum.

 

Bob Schor

0 Kudos
Message 4 of 9
(4,236 Views)
Solution
Accepted by topic author Kmfood123

Sure enough the outputs of all those select functions aren't wired to anything.  Why make a decision if you don't use the result?

 

In Range and Coerce.  Open Context Help and read the function.  There is an output that tells you if it is in range.

 

Your warning control should be an indicator.

 

Normally, I'd tell you in more detail what needs to be done and have you do the work yourself.  Instead, I'm going to show you the picture of what the code should look like.

 

0 Kudos
Message 5 of 9
(4,233 Views)

Instead of all these successive comparisons, it would be simpler to threshold into an array of temperatures and then index into an array of strings. The boolean could be obtained from the index value (e.g. ">3" or whatever).

 

Start with this example and modify as described above. (e.g. make the second array an array of strings)

 

 

0 Kudos
Message 6 of 9
(4,218 Views)

@altenbach wrote:

 

Start with this example and modify as described above. (e.g. make the second array an array of strings) 


Here's a quick draft to get you some ideas...

 

 

 

 

Download All
Message 7 of 9
(4,195 Views)

Or just use a text ring.

"If you weren't supposed to push it, it wouldn't be a button."
0 Kudos
Message 8 of 9
(4,185 Views)

@paul_cardinale wrote:

Or just use a text ring.


Have you tried that?

(I guess it should work after the thresholding/round down step. It definitely does not work on the original number with the steps defined as non-sequential values and the ring as DBL)

0 Kudos
Message 9 of 9
(4,163 Views)