07-11-2013 05:12 AM
Hey all LabVIEW-forum members!
I have some experience programing LabVIEW, but mostly concerning smaller for the simplest form of data acquisition. Now I need to develop a larger application that might be continuously run for several weeksin a row and for that reason I woiuld like to make sure the application structure is stable! I turn to you in hope of some input regarding the most suitable approach to my problem or some pointing in a good direction.
-The project involves making hardware communication with a few different hardware interfaces, such as GPIB and NI’s DAQ-card (analog and digital reads/writes on PCI-6221).
-Save acquired data to disk.
-The communication and data save are based on condition of elapsed time (for example there could be a need to make parallel analog measurements med DAQ-card every 5th minute but GPIB-measurements every 30th second).
-At the mean time I would have to regularly the status of the test object and update the user interface. (However, while in test the user won’t be allowed to interact with the application other than to monitor the UI or pause the test).
The project isn’t really time critical (in case I need to make one type of data-acquisition while another one is already initiated, they can be carried out in sequence).
I’ve started with programmatically control the user interface by using the “Top Level Application Using Events”-template and produced code that will let the user set up a new test or load an existing test. All the data concerning the status and configuration of the test I’ve saved in two clusters that can be passed along to different events.
I’ve reserved one subdiagram in the event structure for the actual execution of the test. It is the structure of this subdiagram I am a bit confused about…
Could I use another while-loop/event-structure inside this subdiagram and use user-registered events for the different data acquisition? Or is there some type of state-machine that is better suited to monitor time elapsed and can make a transition to a suitable state when it’s time to make any of the hardware measurement required? It would be nice to avoid using polling loops but maybe that is best way to go?
I’ve checked the “Continuously Generate Occurrences.vi”-example and that might be a way to go? What seems to be good with this approach is that I could let the different parallel hardware acquisitions actually be parallel, right?
I am really confused right now, hope someone has some helpful inputs!
Regards
Oscar
07-11-2013 08:49 AM
This post here can be proved as a great starting point for your application.
07-11-2013 09:08 AM
Thank you for that tip! Looks like that could be perfect for my problem! Will look into it right away (: