02-18-2007 04:55 PM
02-18-2007 06:04 PM

Using the Abort button to stop your VI is like using a tree to stop your car. It works, but there may be consequences.02-18-2007 06:18 PM
I forgot to mention that there is an Example VI that ships with LabVIEW called "Cont Gen Voltage Wfm-Int Clk-Variable Rate.vi" that shows a good way to continuously generate a waveform and update the frequency on demand without interruption.
Look in the Example Finder under Hardware Input and Output>DAQmx>Analog Generation.
Ed

Using the Abort button to stop your VI is like using a tree to stop your car. It works, but there may be consequences.02-20-2007 09:36 AM
Thanks for the assistance Ed,
The signal was designed to run for 10 cycles to gain a better representation of the data at each frequency, and the 5 second time delay was put in so that the rig had a short time to settle between each frequency so that the data was not 'contaminated' with resonances from previous frequencies.
To try and get the output stepping through, I tried reducing the number of a cycles to 1, and getting rid of the time delay as you suggested but neither of these worked. Depending on the number of samples taken, the loop iterates at the correct speed (5000 samples takes 10 secs) but the problem is still the DAQ assistant updating the output signal.
I think you're probably along the right lines when you talk about the DAQmx driver releasing control of the VI at the appropriate times. Could you point me in the direction of some more resources about this?
I've also attached the slider test I was walking about. This samples at the default frequencies and has no delay, yet still takes 6-7 seconds for the rig to respond. Could it be something to do with whether sampling is for N samples or continuous?
Many thanks for your help,
Ian
02-20-2007 02:13 PM
I think the problem is still with the waveform you are sending to the DAQ card.
Try a different approach using the example I pointed to in my last post. You should be able to use that pretty much as is. You'll just need to figure out a way to chage the frequency at the correct time. I think you'll have a lot beter luck using this setup.
Here's a FAQ that has a lot of info about how the DAQmx driver was built and some of the reasons NI did what they did.
Ed

Using the Abort button to stop your VI is like using a tree to stop your car. It works, but there may be consequences.