I am stating a task in LabVIEW, then stopping the task, changing the timing and starting the task again. When I do this I am getting error -200288: Measurements: Attempted to write a sample beyond the final sample generated. The generation has stopped, therefore the sample specified by the combination of position and offset will never be available.Specify a position and offset which selects a sample up to, but not beyond, the final sample generated. The final sample generated can be determined by querying the total samples generated after a generation has stopped.How can I prevent this from happening?
Instead of stopping the task changing the timing and then restarting the task, change the sample rate of the clock by using a DAQmx Timing Property node with the property set to SampClk.Rate. This will allow you to change the sample rate of the task without stopping and restarting the task.
Another option is to use the Decimate VI to change the sample rate of the task by eliminating some of the samples.
Collaborate with other users in our discussion forums
A valid service agreement may be required, and support options vary by country.
Thank you for your feedback.
You changed your response to Not Helpful
You changed your response to Helpful