Table Of Contents

TDMS Write (G Dataflow)

Version:
    Last Modified: March 29, 2017

    Streams data to a .tdms file.

    Copyright: (c) 2016 National Instruments. All rights reserved.

    connector_pane_image
    datatype_icon

    data layout

    Arrangement of the data that you want to stream to a .tdms file. You must use the same data layout for each channel under the same group.

    Name Description
    non-interleaved

    Lists all samples from the first channel, then all samples from the second channel, and so on through the last channel.

    interleaved

    Lists the first sample from every channel, then the second sample from every channel, and so on through the last sample from every channel.

    Data Layout Examples

    The following table shows a typical example of the non-interleaved data layout.

    Channel 0-Sample 1
    Channel 0-Sample 2
    ...
    Channel 0-Sample N
    Channel 1-Sample 1
    Channel 1-Sample 2
    ...
    Channel 1-Sample N
    Channel 2-Sample 1
    Channel 2-Sample 2
    ...
    Channel 2-Sample N

    The following table shows a typical example of the interleaved data layout.

    Channel 0-Sample 1
    Channel 1-Sample 1
    Channel 2-Sample 1
    Channel 0-Sample 2
    Channel 1-Sample 2
    Channel 2-Sample 2
    ...
    Channel 0-Sample N
    Channel 1-Sample N
    Channel 2-Sample N

    Default: non-interleaved

    datatype_icon

    tdms file

    A reference to a .tdms file. Use the TDMS Open node to obtain the reference.

    datatype_icon

    group name in

    Channel group on which to perform the operation.

    Default: Untitled

    datatype_icon

    channel name(s) in

    Channel or channels on which to perform the operation.

    channel name(s) in accepts a string or a 1D array of strings. The data type varies according to the data type of data. If you do not wire channel name(s) in, channels are named automatically.

    Determining the Data Type of channel name(s) in

    The following table shows how the data type of channel name(s) in varies according to the data type of data.

    data channel name(s) in Comments

    Analog waveform

    1D array of alphanumeric strings that do not contain null characters.

    String

    If you do not wire channel name(s) in and wire waveform data to data, channels use waveform names.

    1D array of:
    • Signed or unsigned integers
    • Floating-point numbers
    • Timestamps
    • Booleans
    String or 1D Array of Strings

    If data layout is non-interleaved and you wire a 1D array of strings to channel name(s) in, this node uses the first element of the 1D array as the channel name.

    If data layout is interleaved and you wire a string to channel name(s) in, this node uses this string as the channel name of the first element in the 1D array and uses Untitled, Untitled1, Untitled2... as the channel names of the rest of the elements.

    Digital waveform

    Digital table

    1D array of analog waveforms

    2D array of:
    • Signed or unsigned integers
    • Floating-point numbers
    • Timestamps
    • Booleans
    • Alphanumeric strings that do not contain null characters
    1D Array of Strings

    If you do not wire channel name(s) in and wire waveform data to data, channels use waveform names.

    Writing Compressed Digital Data

    If data contains compressed digital data, you must enter the name of the compression channel as the first entry in the channel name(s) in array.

    datatype_icon

    data

    Data to write to the .tdms file.

    Acceptable Data Types

    This input accepts the following data types:

    • Analog waveform or a 1D array of analog waveforms
    • Digital waveform
    • Digital table
    • 1D or 2D array of:
      • Signed or unsigned integers
      • Floating-point numbers, including the following specific data types:
        • Single-precision and double-precision floating-point numbers
        • Complex single-precision and double-precision floating-point numbers
        • Extended-precision floating-point numbers
      • Timestamps
      • Booleans
      • Alphanumeric strings that do not contain null characters

    Writing Analog or Digital Waveforms

    When you write analog or digital waveforms to a new channel, the timestamp information is included in the waveforms. However, when you append analog or digital waveforms to an existing channel, the timestamp information in the new waveforms might be discarded.

    datatype_icon

    error in

    Error conditions that occur before this node runs.

    The node responds to this input according to standard error behavior.

    Standard Error Behavior

    Many nodes provide an error in input and an error out output so that the node can respond to and communicate errors that occur while code is running. The value of error in specifies whether an error occurred before the node runs. Most nodes respond to values of error in in a standard, predictable way.

    error in does not contain an error error in contains an error
    If no error occurred before the node runs, the node begins execution normally.

    If no error occurs while the node runs, it returns no error. If an error does occur while the node runs, it returns that error information as error out.

    If an error occurred before the node runs, the node does not execute. Instead, it returns the error in value as error out.

    Default: No error

    datatype_icon

    tdms file out

    A reference to the .tdms file.

    datatype_icon

    group name out

    Channel group on which you performed the operation.

    datatype_icon

    channel name(s) out

    Channel or channels on which you performed the operation.

    datatype_icon

    error out

    Error information.

    The node produces this output according to standard error behavior.

    Standard Error Behavior

    Many nodes provide an error in input and an error out output so that the node can respond to and communicate errors that occur while code is running. The value of error in specifies whether an error occurred before the node runs. Most nodes respond to values of error in in a standard, predictable way.

    error in does not contain an error error in contains an error
    If no error occurred before the node runs, the node begins execution normally.

    If no error occurs while the node runs, it returns no error. If an error does occur while the node runs, it returns that error information as error out.

    If an error occurred before the node runs, the node does not execute. Instead, it returns the error in value as error out.

    Where This Node Can Run:

    Desktop OS: Windows

    FPGA: DAQExpress does not support FPGA devices


    Recently Viewed Topics