12-30-2010 12:25 PM
Hello everyone, I am still very new to Labview and have a question about combining multiple VI's.
Essentially I have three different VIs I created that use the producer-consumer design. The producers constantly poll the a serial device and ship the received measurement down to the consumer where it displays readings and does other things like calculating values and writing data to .CSV files. I am writing these VI's for a automotive gage, with three different stations. Each station has its own VI.
Since each VI needs to constantly poll the serial device I can not have all three VI's running in subpanels on a tab control. I believe the easiest solution would be to start and stop the VI's as a new tab is selected. Something like. When Tab1 is selected the Station1.vi is running, and when Tab2 is clicked, Station1.vi is stopped (thus freeing the serial port) and Station2.vi starts up.
Am I on the right path? Is there a better alternative? Would it be better to just leave the VIs running in their subpanels and disable polling of the serial device instead of stopping and starting the VI?
Thanks!
01-01-2011 10:34 AM
@Archer36 wrote:
Am I on the right path?
NOPE
Is there a better alternative?
Take a look into "shared variables" the exampls that ship with LabVIEW might change the path you go down
Would it be better to just leave the VIs running in their subpanels and disable polling of the serial device instead of stopping and starting the VI? (hint)- nope 1 vi to poll the serial data and serve to the masses-
Thanks!