Error -200802 Buffer Size Zero from DAQmx in LabVIEW

Updated Jan 5, 2023

Reported In


  • NI-DAQmx

Issue Details

While using NI-DAQ™mx with support for LabVIEW, I am trying to write an analog/digital/counter output using the DAQmx Write VI, and sometimes I receive the following error:

Error -200802 occurred at DAQmx Write

Write cannot be performed when the task is not started, the sample timing type is something other than On Demand, and the output buffer size is zero.

Call DAQmx Start before DAQmx Write, set auto start to true on DAQmx Write, modify the sample timing type, or change the output buffer size.​


How can I correct this problem?


This error is a result of the fact that Hardware Timed Single Point (HWTSP) sample mode does not configure a buffer for the DAQmx task. To resolve this issue, try starting your task before you attempt to write data, and to write a single sample at a time instead of multiple samples, as shown below:

Additional Information

Error -200802 is caused when the amount of data being placed into an output buffer is too large. This typically occurs in one of two cases: 
  • Multiple samples (per channel) are being inserted into an output task that is not configured for buffered DAQmx writes.
  • Samples are being inserted into an output task that is not configured for buffered DAQmx writes before the task has been started. 

If your application requires multiple samples to be written at a time, consider either Finite Samples or Continuous Samples sample modes as an alternative. To implement the software-timed On Demand sample mode in LabVIEW, completely remove DAQmx from the DAQmx Task configuration.

Note: You may also see error -200802 when using the DAQ Assistant Express VI if it is configured for analog output but no signal has been wired to the data terminal. Providing any valid signal will resolve this error.