LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

thermocouple output question

Solved!
Go to solution

I am having a issue with the output of the temperature I want to take the output temperature an compare it to the max an min that are given on the left hand side of the VI.But I cant take the output of the temperature an put it on middle of the comparison vi.. But also would I do a case statement with if false automatic cut off? I feel that is true but i am unsure on how to go about that. Any help would be great I wanted to put the output of the comparison to to the case statement if false.. like I said any feedback would be great 

0 Kudos
Message 1 of 7
(2,779 Views)

The middle of the Select Function requires a boolean.  You can't wire a scalar value into it.

 

What do you mean that you want to compare the value to the max and min?  What Max and Min?  The max and min on the left side of the VI just sets the range that the analog input channel can read.

 

Exactly what comparisons are you trying to do?

 

I also don't understand the phrase about the "automatic cutoff".

0 Kudos
Message 2 of 7
(2,774 Views)

the comparison function i was referring to is the in range and coerce. In the beginning the user enters the max temp an the min temp.. the x would be the temperature output ( the daq read output). I was wondering how to do that. Then the automatic cut off I was referring to if the conditon was false I wanted it to stop. 

0 Kudos
Message 3 of 7
(2,765 Views)
Solution
Accepted by Gotti_uncc

You've already learned about In Range and Coerce in another thread.

 

You can just use a simple greater than or less than to learn if a value is greater than some Max value.

 

But you are confused about what the Max and Min controls are on the left side of your VI.  They probably shouldn't even be controls.  Those inputs to the DAQ function set the analog input range of the thermocouple channel.  You set that, then the value you read by definition will be equal to or less than the Max.  You can't read a value greater than some value when you limit the analog input range to that value.

 

Set the analog input Max and Min range to some constants that make sense for the thermocouple and temperature values you expect to see.  Your Max control would then be inside the loop and be what you compare your DAQmx Read value to.  Wire the output of that Greater than comparison to the Stop terminal of your while loop.

 

Also, your while loop conditional terminal is backwards.  If you do have an error on your DAQmx Read, you don't want the loop to continue.  You want it to stop.

0 Kudos
Message 4 of 7
(2,762 Views)

thanks alot, initally thought that it couldn't go over those parameters but I consulted with someone and they made me see it another way.

0 Kudos
Message 5 of 7
(2,759 Views)

is there a way to get another stop terminal I have the output of the or gate and the output of the greater than both needed to go to the stop terminal.

0 Kudos
Message 6 of 7
(2,755 Views)

Hi gotti,

 

there's a full palette with BOOLEAN functions!

 

Use them to combine your stop conditions to just one scalar boolean you can wire to the stop terminal...

Best regards,
GerdW


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