Table Of Contents

Adding Custom Device Channels and Waveforms

Last Modified: March 24, 2021

Add channels and waveforms to a custom device by using the appropriate VI within a Custom Device Library VI that runs on the host computer.

Before you begin, you should understand custom device channels and waveforms. Typically, you add channels in the Initialization VI so they appear when an operator adds the custom device to the system definition.
spd-note-note
Note  

Channels can also be added when an operator takes an action, such as using a shortcut menu or toolbar button.

  1. Open a Custom Device Library VI that runs on the host computer.
  2. Based on the data exchange mechanism you want the custom device to use, add a VI from the Configurations VIs palette.
    Mechanism VI Type
    Channel Add Custom Device Channel VI
    Waveform Add Custom Device Waveform VI
  3. Modify the following code in the VI.
    spd-note-note
    Note  

    The following image displays the Add Custom Device Channel VI customized to add two input channels and one output channel. The customizing process for the Add Custom Device Waveform VI is very similar.

    Device Item Ref in—Provides each instance of the Add Custom Device Channel VI with the reference to the custom device to which to add the channels.

    Channel cluster—Defines the various properties of the channel, including the type, units, default value, faultability, and scalability of the channel. In this example, two input channels and one output channel will be created.

    Channel Name—Specifies the name of the new channel. In this example, the channel names are A, B, and A+B. Each channel must have a unique name. If the name you specify already exists, this VI overwrites the existing channel settings.

    With this configuration, the custom device will create three channels, A, B, and A+B, when you add it to a system definition.

Recently Viewed Topics