LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Clearing Event Sequence Triggers / Queue

Hi

I used a "mouse down" as under "value change" the false > true action is a trigger and the return True > false is a stored trigger for the event structure and triggers straight away again on the next loop of the software. I was therefore ONLY looking for the downward press but as you can see that didn't work to good either lol

0 Kudos
Message 21 of 27
(1,174 Views)

@NToombes wrote:

Hi

I used a "mouse down" as under "value change" the false > true action is a trigger and the return True > false is a stored trigger for the event structure and triggers straight away again on the next loop of the software. I was therefore ONLY looking for the downward press but as you can see that didn't work to good either lol


This is only true for switching mechanical actions. If you use Latch when Pressed or Latch when Released mechanical action this will not be an issue.

0 Kudos
Message 22 of 27
(1,161 Views)

@NToombes wrote:

Hi

I used a "mouse down" as under "value change" the false > true action is a trigger and the return True > false is a stored trigger for the event structure and triggers straight away again on the next loop of the software. I was therefore ONLY looking for the downward press but as you can see that didn't work to good either lol


Do you have your buttons set to "Latch Until Released" something?  Otherwise, where does this "return True > false" event come from?  That doesn't happen with standard buttons.  

0 Kudos
Message 23 of 27
(1,149 Views)

Hi all

 

OK, I have thrown the towel in on this one for now and but the start button in a simple while loop that executes 20 times a second with a button press stopping the loop. Horrific I know but it works!

Seems to complex to just instigate some cod that awaits a button press before continuing. I tried some of the other options listed before this post and yes, they worked but then my other buttons stopped responding etc & the Start button seemed to hold in the "on" state, not what I wanted. 

I need to spend some more time on these event structures, not as simple as they look on the surface.

 

Neil

0 Kudos
Message 24 of 27
(1,128 Views)

You might want to show some code.  I suspect you have some significant design problems.  Your non-responding buttons sounds like you are trying to do UI work inside an Event Case that is locking the UI while it executes.   You can easily turn that lock off, but you'd be better off fixing your design issues.

0 Kudos
Message 25 of 27
(1,120 Views)

@drjdpowell wrote:

You might want to show some code.  I suspect you have some significant design problems.  Your non-responding buttons sounds like you are trying to do UI work inside an Event Case that is locking the UI while it executes.   You can easily turn that lock off, but you'd be better off fixing your design issues.


I agree with this. It seems like you are way overcomplicating this. 

0 Kudos
Message 26 of 27
(1,105 Views)

From the description I see two simple solutions.

1. Disable the button as the event activates.

2. Use Lock event structure if it's happening during the button event

Both will prevent accidental presses.

A slightly more advanced solution is to register the button value changed as a dynamic event and (un)register as needed, but that seems overly complicated. 🙂

G# - Award winning reference based OOP for LV, for free! - Qestit VIPM GitHub

Qestit Systems
Certified-LabVIEW-Developer
Message 27 of 27
(1,102 Views)