LabVIEW Idea Exchange

cancel
Showing results for 
Search instead for 
Did you mean: 
Broken_Arrow

Tri-State Boolean

Status: New

I'd like to see a Tri-State Boolean Control / Indicator on the Modern Controls palette, which would work with an enum (similar to the System Mixed Checkbox on the System Palette). Thanks!

 

Message Edited by Broken Arrow on 06-01-2010 05:11 PM
Richard






11 Comments
dthor
Active Participant

This is the same as something I just posted earlier today:

http://forums.ni.com/t5/LabVIEW-Idea-Exchange/Native-Ternary-Logic-support-3-valued-logic/idi-p/1139...

 

Tri-state logic is called Ternary Logic or Trivalent logic.

JackDunaway
Trusted Enthusiast

Tri-state is indeed a very common use case, but more generically I want to see an n-state indicator/control. One way to achieve this cleanly would be through dynamically populating a picture ring.

 

Anyway, what would a "tri-state" constant look like on the BD? I would picture it as an enum or typed integer.

dthor
Active Participant

Following Altenbach's New Boolean design, it could look like so:

 

Ternary Constant.png

 

 

As for the data type, it could be a new type or I8. I currently use a I32 ring for my .llb of ternary logic operations. One of these days I'll get around to converting those to I8...

 

Edit: Here's my ternary "AND" code:

Ternary And.png

Message Edited by dthor on 06-01-2010 06:53 PM
Broken_Arrow
Active Participant
My idea was that the Tri-State Boolean would work just like the "System Mixed Checkbox" in the System palette - the main difference would be that we would be able to edit the appearance since it would be a native LV control. Here's one idea of how the constants might look:
Message Edited by Broken Arrow on 06-02-2010 09:20 AM
Richard






rex1030
Active Participant

Just an observation, but doesn't boolean imply only true or false. So tri-state ... isnt .... really .... boolean.

 

I never knew that was called Ternary Logic or Trivalent logic though. Very cool.

 

I like the idea of an enumerated LED indicator where you could match enum cases to colors. Very interesting. 

 

and dthor, your ideas will never go very far without pretty pictures 🙂

---------------------------------
[will work for kudos]
normd
Member

This is so useful. I have needed this many times in projects.

Shep_Ametek
Member

This would reduce my indicator complexity from 30 to 15. I have Passed Boolean ( Green) and Failed Boolean for each test step. I disable the failed indicators initially and put all Passed inidcators as False. I run the tests.  This would provide less complexity, and ease programming. Consider this to be tri Color Led.  I have some code to post.  Boolean does indicate True and False. This gives better program control over the color output of the boolean inidcator.  Otherwise If you change the false to Red, in the disable mode will dispaly red.

 

 

Greg
Broken_Arrow
Active Participant

Thanks Shep. I wish this idea had more steam, I've needed this since 2002.

Richard






AristosQueue (NI)
NI Employee (retired)
Priyadarsini
Member

If anyone requires a tristate button do refer tristate button control.