Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

DAQmx wait until done can't wait less than 50 usec?

I output an analog pulse, which I can set to any length. However, it seems that when the pulse is less than 50 usec in length, DAQmx Wait Until Done takes forever. It's as if the computer outputs the pulse so fast that it doesn't know it's done. Is there any way to get around this? Or do I simply have to tell it to stop?
0 Kudos
Message 1 of 11
(4,430 Views)
Hello Morgois-

Can you give me a little more information about your application? What device are you using? How many samples are you generating? If you can possibly post your code as well, that also would be helpful.

Thanks!
gus....
0 Kudos
Message 2 of 11
(4,426 Views)
---- Hello Morgois-

Can you give me a little more information about your application? What device are you using? How many samples are you generating? If you can possibly post your code as well, that also would be helpful.

Thanks!
gus....
-----


I am generating a sine wave, using the 6251 board, and DAQmx. Specifically, I use the DAQmx Start Task and DAQmx Wait Until Done. I am generating it using the 2.8 MHz sampling frequency, so it auto-generates the number of samples. I try between 10 kHz and 120 kHz or so, and it only stops properly if the pulse is longer than 50 usec. If it's shorter, the rest of the program will run, but it will give the error "Error -200560 occurred at DAQmx Wait Until Done.vi" no matter how long the timeout is (-1 or a long time doesn't help). If the sine pulse is less than 50 usec, it works fine. 120 kHz I can do if I make the pulse long enough, but a single cycle at 120 kHz gives this error, for example.
0 Kudos
Message 3 of 11
(4,414 Views)
Hi Morgois,

I have tried replicating this problem but I have not been able to. Could you please post the code that you are using to generate this? This a very interesting issue.

Thanks,
Sal
0 Kudos
Message 4 of 11
(4,399 Views)
Here is the sub-VI that outputs the sine wave.
0 Kudos
Message 5 of 11
(4,391 Views)
Here is the sub-VI that generates the sine wave
0 Kudos
Message 6 of 11
(4,388 Views)
Hi Margois,

I got the SubVI that generates the task and writes the buffer and another subvi that sets up the triggering and starts the task. What I'm not seeing is exactly what data is being generated and output. I'd like to see what data you are trying to output. I've tried generating short waveform pulses at that update speed and the task stopped. If you can, I'd suggest that you take a look at one of the shipping examples in LabVIEW found under Help >> Find Examples >> Hardware Input and Output >> DAQmx >> Analog Generation >> Voltage >> Gen Mult Voltage Update - IntClk. This example lets you specify your waveform frequency and sampling rate. If you can recreate the issue using this example then you could take a screenshot or tell me exactly what you entered into the front panel controls.

Thanks,
Sal
0 Kudos
Message 7 of 11
(4,376 Views)
OK I tried that Gen Mult Volt Updates-Int Clk.vi example, and here are my settings:
AO0 channel
Min/Max -/+10
Desired Frequency: 120 kHz
Sine Wave
15 Samples per buffer
Amplitude: 10
Cycles per buffer: 1

This is the error that I get. Again, this gives me some waveform (does the same thing I described before - but I should note that the waveform doesn't look right. It doesn't get to -10 V, and gets to +15 V), but gives this message:

Error -200560 occurred at DAQmx Wait Until Done.vi

Possible reason(s):

Wait Until Done did not indicate that the task was done within the specified timeout.

Increase the timeout, check the program, and make sure connections for external timing and triggering are in place.

Task Name: _unnamedTask<50>

Now I suppose I can live with this. But why does it have a problem saying something is done when it does it!
0 Kudos
Message 8 of 11
(4,325 Views)
Hi morgois,

I am now seeing the same results you are. I am going to look into this further and see why this is happening.

-Sal
0 Kudos
Message 9 of 11
(4,310 Views)
Has anyone else seen this? Or have you (Sal) or anyone else figured out how to get around this?

Thanks!
0 Kudos
Message 10 of 11
(4,231 Views)