LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

What's best architecture for DAQmx app with two operational modes?

I have an architectural question.  I am writing an application which takes measurements from a custom sensor which has two modes of operation: 1) idle mode where two voltages are sampled slowly, run through a transform, and then the result is plotted such that the user can see the idle state of the sensor; 2) a testing mode where the user defines a testing time of some number of seconds then hits 'Go' and records high-speed acquisition for the specified number of seconds (with some sort of simultaneous real-time plotting) and then writes the data out to a file.  I am trying to use the 'Top Level Application using Events" VI template but have run into issues with the VI not responding to UI clicks when in an event case...I got around **some** of these issues but now I am stuck because I can't get the app to register an abort button click when in testing mode.  I think I am missing something when it comes to events as LabVIEW defines them.  (I'm a .NET programmer)  My basic question is what is the best top-level VI architecture to use for something like this?  I don't want to go down the wrong path and have to re-write the whole thing...
 
 
**I did come up with a seemingly neat way to get a tab control to switch tabs from inside an event case...I look at the X, Y coordinates of a mouse click and if it is within one of the tab selector zones at the top, left of the control I programmatically swith to the corresponding tab...seems like there should be an easier way but it works.
0 Kudos
Message 1 of 2
(2,023 Views)
I think that the best would probably be a producer consumer type architecture  with events.  You can do a search in the example finder and find a good one. As for the events not responding, you probably just need to uncheck the check box for disabling the front panel until the event finishes. You will find this at the bottom of the dialog box for the event structure.




Joe.
"NOTHING IS EVER EASY"
0 Kudos
Message 2 of 2
(2,007 Views)