LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Wait on Notification from Multiple behaves the same with or without History

Solved!
Go to solution

I'm running this VI on a cRIO-9066, and both "Wait" functions behave the same. After reading the LV Help, I would expect the "With Notifier History" one to return an array of two elements, not one. Is this a bug?

 

(Attachment is LV 2014 SP10

0 Kudos
Message 1 of 9
(3,650 Views)

Are you delaying long enough for two notifications to arrive?

aputman
0 Kudos
Message 2 of 9
(3,638 Views)

You never even opened the VI, did you?

0 Kudos
Message 3 of 9
(3,626 Views)

If I had 2014, I would open it.  

 

Good luck.

aputman
0 Kudos
Message 4 of 9
(3,618 Views)

I think you want to set Ignore Previous? to False if you want to retain notifier history.

0 Kudos
Message 5 of 9
(3,605 Views)

@Staab_Engineering wrote:

After reading the LV Help, I would expect the "With Notifier History" one to return an array of two elements, not one.


Why? Unlike the help for W4MN, the one for W4MNWH is not explicit in saying that it continues as soon as one of the notifiers gets a notification, but it also doesn't say it will wait for all of them. Your example clearly shows that it continues as soon as at least one has a notification.

 

I'm too tired at the moment to work through the W4MNWH use cases, so I have no particular expectation for how it should behave.


___________________
Try to take over the world!
0 Kudos
Message 6 of 9
(3,596 Views)

When it returns is less interesting than what it returns with. I expected the entire purpose of "with notifier history" to be that it would return a value for every notifier provided, not just a value for the first one to hit. The former is the behavior I'm looking for, so I can write a loop to wait on two notifiers at once and know which fired first.

0 Kudos
Message 7 of 9
(3,588 Views)
Solution
Accepted by topic author Staab_Engineering

@Staab_Engineering wrote:

When it returns is less interesting than what it returns with. I expected the entire purpose of "with notifier history" to be that it would return a value for every notifier provided, not just a value for the first one to hit. The former is the behavior I'm looking for, so I can write a loop to wait on two notifiers at once and know which fired first.


It does return a value for every notifier that fired between the Waits. If one of the provided notifiers didn't fire, then it will not have a value.

 

In determining which one fired first, you can use the notifier out output and Get Notifier Status. (i.e. the first element of the notifier out output is the notifier that fired first)

Message 8 of 9
(3,570 Views)

Aha! Thanks!

0 Kudos
Message 9 of 9
(3,554 Views)