06-14-2006 04:40 PM
06-15-2006 01:45 AM
Hi Anonymous,
If I were you, I'd create one VI (call it Port.vi) to listen to one port - then make it reentrant. Drop 4 copies of Port.vi on your Main diagram. Port.vi inputs could include a VISA reference, a "Start/Stop" notifier and maybe a "Quit" occurance. Wire to each copy of Port.vi a unique VISA reference and a unique "Start/Stop" [boolean] notifier - let all the copies share the same Quit Occurance.
In Main, have one event case for each of your stop buttons. When a button is pressed, send the appropriate Start/Stop notifier!
... of course you could accomplish the same thing with four identical loops right in your main diagram, but the more complex the port-handling gets, the easier it will be to manage in one place instead of four.
Cheers!
06-15-2006 06:38 AM
I prefer the sub-vi approach and making them re-entrant.
JLV