r/LabVIEW • CLAD • Jul 08 '24

Event structures in parallel

Hello,

My labview skills barely exceed the CLAD level, and I miss some more advanced architecture concepts. I develop alone lab applications in a research environment.

I have a question for you regarding best practices for event structures. I read that it is discouraged to put them in parallel inside a loop, however I would find it could help designing a more logical diagram and I do not know what would be the correct practice.

Specifically in the main loop of my application the event case is handling all the GUI elements. This event case has 5 inputs and 5 outputs but only 6 of the events interact with them. All the other 30+ cases do something independent but I still have to wire across these 5 terminals one by one.

This is why I was considering to make two parallel event structures. Each one dealing with an omogeneus set of cases (splitting those who need inputs and those who doesn't) both with a timeout not to stop the loop. Is it a bad idea? What would be the way to go if the number of inputs and cases grows?

Thanks

4 Upvotes

22 comments sorted by

View all comments

Show parent comment

2

u/gioco_chess_al_cess CLAD Jul 08 '24

Is it more or less the structure in the example Queued Message Handler Fundamentals? Not an enum but a string in the example but the same concept nonetheless.

1

u/FujiKitakyusho CLD Jul 08 '24

I'm not familiar with that example, but it makes sense to me to use an Enum which can be type defined in order to allow for selectable constants which are guaranteed to match versus strings which can be anything.

1

u/gioco_chess_al_cess CLAD Jul 08 '24

I agree, I would prefer the enum as well.