03-23-2022 01:24 AM
Can anyone help me to understand how to use boolean. The way that i wired it is such that only one boolean should light up as the input value is the same for both sequence but when i run the code, both boolean are constantly lit up. Can someone help me please.
Solved! Go to Solution.
03-23-2022 02:06 AM
Hello,
We cannot know what is inside your constant double comparison arrays.
Please join your .vi with default data and then we can try it.
Have you tried to probe the comparison outputs to check its boolean values?
03-23-2022 02:17 AM
Hi, im not sure what probe means im kinda new to labview but here is the vi. Appreciate any help i can get
03-23-2022 02:34 AM
That is the probe in the tools palette :
Hum lot of comments because first your vi is unmanageable :
- no sub-vi or functions
- too big and need at least 3 screens to see all of it
Depending of your licence you have maybe access to training and core 1, do at least that one.
Then for your issue two of your arrays are empty, thus comparing nothing and your And boolean is giving you a True. Give some good values to those arrays and it wil be better.
03-23-2022 03:23 AM
@Defaphe wrote:
To expand on what Defaphe wrote, the array value is not 50 and 41, those are 50th and 41st values in your array, which are empty.
If you are trying to compare values in an array to a single number, you don't need an array with that number. You can have it like this instead
03-23-2022 03:36 AM
Thank you for the clarifications. Could you tell me where to find that boolean symbol that you are using in your second picture and also how do i compare to a specific range of values that i require. For eg. i need 40 - 50 and i need a boolean to tell me whether my array is between that range or not.
03-23-2022 03:56 AM - edited 03-23-2022 04:42 AM
Here an example to check if all values from an array are between two values.
Which boolean symbol do you mean ?
Here the comparison symbol from the palette.
03-23-2022 04:38 AM
I see okay thank you very much.