05-02-2017 02:49 AM - edited 05-02-2017 03:02 AM
Hello,
I have a NI USB-6001 and I am trying to run the attached simple vi and I get an error 200279. It supposed to just acquire an analogue & a digital signal. Can someone help please?
Thank you in advance
05-02-2017 04:39 AM
05-02-2017 04:46 AM - edited 05-02-2017 04:46 AM
05-02-2017 05:58 AM
Thank you both for the prompt replies!
I am puzzled as without the digital DAQmx it works at rate: 10000 / samples:100.
Is there a way to speed it up without causing the error?
05-02-2017 07:07 AM
05-02-2017 07:31 AM
Hello,
As you can see from the attached vi, even with queue control it still gives the same error
05-02-2017 07:38 AM
05-02-2017 07:50 AM
Ready!
05-02-2017 08:10 AM - edited 05-02-2017 08:16 AM
Hi anon,
you are reading just one sample per DAQmxRead in your AI task loop - this is way too slow! You need to read blocks of samples as recommended in the link provided by Mathan!
- Right now you additionally even block your AI loop from running with the ReadQueue function as it has to wait for new DI data. What's the point of the queue when all it does is displaying those two boolean values? Why not display them in the DI loop?
- Building an array is a slow operation due to memory management. How large will the array grow?
- Displaying data in a graph inside of your loop is a (very) slow operation! How large will the array grow? How many data do you want to display in the graph?
- Why did you wire the "100" constant at the "samples per channel" input of DAQmxTriggering? Did you read and understand the help for that function?
I am puzzled as without the digital DAQmx it works at rate: 10000 / samples:100.
Why don't you use these settings right now when they used to work?
05-03-2017 01:10 AM
Hello!
This code is a snippet from a larger code and its the section that gives out the problem.
The system basically reads a strain sensor connected to a mechanical apparatus that makes a repeatable motion. The AI records the data and plots them as they are created. Filling the graph with points as the acquisition progresses is important. The whole operation is a 10 seconds movement and I need at least 1000 points in it to see in detail.
The Boolean are two and the first indicates when the system is ready to move and the second when the apparatus is returning to home position.
Without the DI I have about 300-400 samples in the graph over the stated period of 10 seconds. With the DI it gets reduced to half that. If I increase the sampling rate I get the 200279 error. This usb-6001 may be low spec but it has up to 20kS/s so it should be able to give 1000 samples over a 10 sec period.