LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Event callback timing

When I am using dynamic events and transmit a counter as event data each time I fire the event, I can have multiple consumers that receive the identical count. Thus, only a single event is generated each time and signaled to all consumers. Ok, so far.
Now, I am using the Register Event Callback function in LV8.2. to fire events from an ActiveX component (pressing buttons on a joystick device) and use a dynamic event to signal this to multiple consumers. Again, I add a counter to the dynamic event data. What happens now is that the consumers receive different counts, even if I only click the joystick button once. As if there are multiple events generated. For 2 consumers, 2 events are being generated, for 3 consumer 3 events and so on. But how would the callback VI know that there are multiple consumers? 
I tried reentrant and non-reentrant callback VIs and see no difference ("reentrant" is specified in Help, but I do not fully understand why that should be needed).
 
Could anyone explain this behaviour to me? Thank you!
 
Dirk
0 Kudos
Message 1 of 5
(3,161 Views)
Hi Dirk,

is it possible for you to post a little example, that shows the behavior (maybe by firing an event with a keybord hit)?

Bye

Daniel
NIG
0 Kudos
Message 2 of 5
(3,138 Views)

Hi Daniel,

thank you for your reply. Although I managed to include the ActiveX components supplied with my special input device, I am not in general familiar with ActiveX. Therefore, I have no idea how to find something as general as "keyboard hit". However, triggered by your reply I now tried it with a modified version of LV's example file using Excel worksheets. There, I do not see the described behaviour.

Well, I will check again on that special device driver now. At the moment, it is not working at all, which looks fishy...

Dirk

 

0 Kudos
Message 3 of 5
(3,130 Views)

Ok, Daniel, I found the problem. Somehow I managed to have duplicate callbacks registered at the same time... now it looks fine.

Thank's again.

Dirk

0 Kudos
Message 4 of 5
(3,126 Views)

Hi Dirk,

well, the good, old LabVIEW examlples! Hope your getting on now. Good luck for your project!

Daniel

NIG 

0 Kudos
Message 5 of 5
(3,117 Views)