From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

Signal Generators

cancel
Showing results for 
Search instead for 
Did you mean: 

Error 200269 when executing the DAQ Assistant

The DAQ Assistant in my VI is reading dynamic values from loop generates error 200269 upon execution. It says that buffer size needs to be more. I dont understand how I can achieve that with the DAQ Assistant. Any help or alternative suggestions are appreciated. 

0 Kudos
Message 1 of 2
(3,866 Views)

Hello,

 

I have looked into your code, and I noticed two major parts that are contributing to this error. First, every time that your loop runs, it increases the size of the array to be written to the DAQmx device. This array is set to run infinitely until you hit the stop button, which means that your array is going to hit excessively huge sizes. This size will eventually be too much for any DAQmx buffer to handle.

 

Second, your DAQ Assistant currently is set to run continuously at a rate of 1 Hz. This means that if the waveform has 2 pieces of data in it, it will take 2 seconds to write. The write speed just will not be able to keep up with the size of the array that keeps building. If you changed the program to write an array of size X units, then it will take X seconds to write that at 1 Hz.

 

I have two main recommendations. You could cut out the entire array building system, and instead build an array of 1 wavelength of set size, and then write that data every time. That would require a little bit of restructuring.

 

My other recommendation would be to use a premade example, because we have an extremely similar one that has the same function as this. I noticed that this VI generates a sawtooth wave with offset, frequency, and amplitude as controls. If you go to help, and then find examples, you can find a large number of premade VIs that are ready to use. Then go to Hardware Input and Output >> DAQmx >> Analog Output >> Voltage - Continuous Output.vi. This VI will generate a signal to a DAQ device using any signal shape of your choice, using similar parameters to yours. You will have to add a control for offset, but that will only require an input to the Basic Function Generator.vi in the block diagram.

 

If you are determined to make your software work, maybe for specific needs, then I might do the first option. Otherwise, I heavily recommend using the ready-made example and modifying it to meet specific needs.

0 Kudos
Message 2 of 2
(3,855 Views)