LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Link Two Boolean Buttons

Hello everyone,

I am relatively new to LabVIEW so please bear with me.  What I want to do in my LabVIEW program is to have the value of one boolean button depend on another.  Let me elaborate a little more:

Button 1: Boolean with "latch until released" mechanical action
Button 2: Boolean with "switch when pressed" mechanical action (this is actually a pause button in my program)

When a user first presses down on button 1, I want button 2 to be "switched" (give a True value and pause my program).  I want button 2 to remain switched until the used manually presses it again, even if button 1 has already been released.

How can I go about implementing such a scheme?  Also, thank you in advance for any help/advice you give.

Ian
0 Kudos
Message 1 of 7
(4,994 Views)
I believe this will do the trick.
Message 2 of 7
(4,979 Views)
Daklu,

Unfortunately, you are using a newer version of LabVIEW than I am (I use 8.0).  Is there a way to save in an older version, or just post a screenshot of your block diagram?  Thank you.
0 Kudos
Message 3 of 7
(4,974 Views)

Here is the same vi in 8.0

 

Message Edited by tbob on 04-26-2007 05:15 PM

- tbob

Inventor of the WORM Global
Message 4 of 7
(4,964 Views)

How about this?  I'm not smart enough to put pictures in my posts...

Essentially you make a local indicator variable of your pause button and place it inside a "True" case structure.  Wire button A to the conditional ("?") with a branch into the "True" case structure and connect it to the "Pause" local variable.  The "False" case can remain empty.  Wrap the whole thing in a while loop and there you go.

When you press button A the "True" case is executed setting the pause button true (pressed) as well.  When you release button A the "False" case is evaluated which does nothing to the local Pause variable.

Message 5 of 7
(4,961 Views)

See this post.

http://forums.ni.com/ni/board/message?board.id=170&message.id=243530

Or, try this VI also. In LV 7.1.

- Partha ( CLD until Oct 2027 🙂 )
0 Kudos
Message 6 of 7
(4,946 Views)
Daklu,

I have implemented your solution and it works like a charm.  I appreciate everyone's help with my problem Smiley Happy

Ian
0 Kudos
Message 7 of 7
(4,930 Views)