Data Acquisition Toolbox    

Acquiring Data

After you configure the analog input object, you can acquire data. Acquiring data involves these three steps:

  1. Starting the analog input object
  2. Logging data
  3. Stopping the analog input object

Starting the Analog Input Object

You start an analog input object with the start function. For example, to start the analog input object ai:

After start is issued, the Running property is automatically set to On, and both the device object and hardware device execute according to the configured and default property values.

While you are acquiring data with an analog input object, you can preview the data with the peekdata function. peekdata takes a "snapshot" of the most recent data but does not remove data from the engine. For example, to preview the most recent 500 samples acquired by each channel contained by ai:

Because previewing data is usually a low-priority task, peekdata does not guarantee that all requested data is returned. You can preview data at any time while the device object is running. However, you cannot use peekdata in conjunction with hardware triggers because the device is idle until the hardware trigger is received.


  The Samples to Acquire per Trigger Logging Data