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.

Motion Control and Motor Drives

cancel
Showing results for 
Search instead for 
Did you mean: 

Olddatastop error despite using lastwrite flag

I am programming an application with a 3D contour much like the buffered Rose example. Since I do not know the number of points to be written I have done the following:
1. Configure the buffer with a high number (240000) points.
2. When writing data to the buffer, I use regenerationmode_nochange when I know there is more data to come, I use regenerationmode_lastwrite when writing the last buffer.
3. Wait for the motion completed after writing the last buffer.

Now in my first test program I have just one buffer, so I immediately write a buffer using the lastwrite flag and then start the motion. So why do I get an olddatastop error?
0 Kudos
Message 1 of 2
(2,646 Views)
I did some more testing and it does work with two buffer write operations. The first with regenerationmode_nochange and the followng with regenerationmode_lastwrite.
A single buffer write with regenerationmode_lastwrite is apparently not accepted by the system.
0 Kudos
Message 2 of 2
(2,646 Views)