Direct DMA

NI Digital Waveform Generator/Analyzer

Direct DMA

Direct DMA can be used to transfer waveform data to and from device onboard memory at rates well beyond the typical 5 to 30 MB/sec range in a standard PC-based architecture. To achieve such high rates, Direct DMA establishes a direct connection between device onboard memory and a specialized waveform data source. Direct DMA is commonly used to stream waveform data from disk at data rates of higher than 100 MB/sec. Conduant's StreamStor™ products are one example of Direct DMA-compatible data sources.

Configuring Your Application for Direct DMA

Direct DMA is available for both acquisition and generation. For acquisition operations, use the Direct DMA instance of the nniHSDIO Fetch Waveform VI; no additional attribute configurations are needed. For generation operations, complete the following steps to configure your application for Direct DMA.

  1. Enable the device for Direct DMA writes by setting the Direct DMA Enable property or the NIHSDIO_ATTR_DIRECT_DMA_ENABLED attribute to TRUE. Once enabled, NI-HSDIO monitors and reports any issues with the Direct DMA transfer.
  2. Identify the waveform data source and set the Direct DMA Window Address property or the NIHSDIO_ATTR_DIRECT_DMA_WINDOW_ADDRESS attribute to the address provided by your Direct DMA-compatible data source.
  3. Set the Direct DMA Window Size property or the NIHSDIO_ATTR_DIRECT_DMA_WINDOW_SIZE attribute to the size of the memory window provided by your Direct DMA-compatible data source.
  4. In LabVIEW, use the Direct DMA instance of the niHSDIO Write Named Waveform VI.

    or

    In C/CVI, use the instance of the Write Named Waveform function that corresponds to the data width of your device to write blocks of data to the device. For each block of data written to the device, you pass the Direct DMA window address to the data parameter instead of an array of samples residing in host memory. NI-HSDIO detects when the address is within the Direct DMA window and handles the transfer appropriately.