NI-HSDIO supports two data types to represent digital waveform data. The first data type is as a one-dimensional array of integer data. The other data type is the digital waveform data type (WDT). VIs and functions in NI-HSDIO that write or read/fetch digital waveform data can accept either data type.

The WDT is required when you use more than the 0 and 1 states in a waveform. For example, if your waveform includes any of the following values
  • Z
  • X
  • H
  • L
Binary data uses only one bit per channel per sample. This cannot represent more than two states. DWDT uses eight bits per channel per sample. This can represent extended digital states.

One difference between U32 array data and WDT data is memory usage. Each sample of U32 data occupies four bytes of PC memory, independent of the number of channels being used. Each sample of a digital WDT data occupies one byte for each channel used, but unused channels do not occupy memory. Thus, a 1,000-sample waveform of 16 channels represented in a raw U32 array would occupy (4 Bytes/sample) x (1,000 samples) = 4,000 Bytes.

The same 1,000 sample waveform represented in a WDT would occupy approximately (1 byte/channel) x (16 channels/sample) x (1,000 samples) = 16,000 Bytes.