Use the Initiate and Fetch VIs and functions to perform other operations while the device acquires data. Initiate begins the acquisition operation and returns control to your program. Fetch transfers the acquired data from acquisition onboard memory to your application.

The Initiate and Fetch VIs/functions are shown in the following table:

LabVIEW VIs C Functions
niHSDIO Initiate niHSDIO_Initiate
Use one of the following instances of the niHSDIO Fetch Waveform polymorphic VI:
  • niHSDIO Fetch Waveform (U32)
  • niHSDIO Fetch Waveform (U16)
  • niHSDIO Fetch Waveform (U8)
  • niHSDIO Fetch Waveform (WDT)
  • niHSDIO Fetch Multi Record (2D U32)
  • niHSDIO Fetch Multi Record (2D U16)
  • niHSDIO Fetch Multi Record (2D U8)
  • niHSDIO Fetch Multi Record (1D WDT)

niHSDIO_FetchWaveformU32

niHSDIO_FetchWaveformU16

niHSDIO_FetchWaveformU8

niHSDIO_FetchMultiRecordU32

niHSDIO_FetchMultiRecordU16

niHSDIO_FetchMultiRecordU8

Note If you are programming in C, you must declare an array in your program. This array allocates space for the data that is acquired with the fetch functions. LabVIEW users do not need to declare an array because the Fetch VIs allocate the array.
If you fetch the data while the device is still acquiring, the VI or function waits until all the requested data is acquired. If the data is not acquired within the time specified with the timeout parameter, NI-HSDIO returns an error. If you want to stop the device before it finishes, use the niHSDIO Abort VI or the niHSDIO_Abort function. However, you cannot fetch after aborting.
Tip Read the Fetch Backlog property or the NIHSDIO_ATTR_FETCH_BACKLOG attribute before calling the fetch function to determine the number of samples available for the same purpose.
Note The read functions combine the initiate and fetch functions into one call. The read functions are more suitable for simple acquisitions, though initiate/fetch is better suited for complex applications that involve triggering.