02-13-2008 06:15 PM
02-13-2008 06:22 PM
02-13-2008 09:48 PM
02-13-2008 09:52 PM
02-13-2008 10:29 PM
I don't understand at all what you mean by multiple mains. You have a single top level main VI called !SDIO NI1 that calls a subVI with the DAQmx code. You can move the DAQmx initialization (including the Start Task) to this. It would be doen outside the for loop.
Maybe you don't have a good concept of a LabVIEW program. You have a single top level VI that can contain subVIS nested as deeply as you wish. Typically, you pass values from a top level VI to a subVI through the subVI's connector pane. In your case, you would pass the task and error in (and any parameters you wish to set). The subVI then passes data back to the calling VI through the same connector pane. Yuo would pass back the task and error out (and any data returned).
02-14-2008 12:10 AM - edited 02-14-2008 12:15 AM
02-14-2008 07:00 AM
02-14-2008 09:21 AM
02-14-2008 09:50 AM
You don't understand what I said. Whether it is reentrant or not, I believe collisions can occur.
You either put the initialization in one main that sychronizes the hardware access or not. If the time it takes to start/stop tasks is a problem, your only solution is to not do it so often.
02-14-2008 09:58 AM