Company Events Academic NI Developer Zone Support Solutions Products & Services Contact NI MyNI

Creating Modbus I/O Servers (DSC and RT Module)

(DSC Module) You can create a Modbus or Modbus Slave I/O server interactively or programmatically.

(RT Module) You can create a Modbus or Modbus Slave I/O server interactively.

After you create a Modbus I/O server, you can create shared variables and bind the shared variables to Modbus I/O server data items.

Tip  Use the Create Bound Variables dialog box to generate multiple shared variables and bind them to Modbus I/O server data items simultaneously.

Creating Modbus I/O Servers Interactively

Complete the following steps to create a Modbus or Modbus Slave I/O server interactively.

  1. In the Project Explorer window, right-click a target, such as the My Computer target, and select New»I/O Server from the shortcut menu.
  2. In the Create New I/O Server dialog box, select Modbus or Modbus Slave and click the Continue button.
  3. In the Configure Modbus I/O Server or Configure Modbus Slave I/O Server dialog box, select the communication protocol, or Model, and configure the Communication Settings you want to use.
  4. (Optional) Click the Advanced button of the Configure Modbus I/O Server dialog box to configure the Maximum Data Points Per Command.
  5. Click the OK button.

Creating Modbus I/O Servers Programmatically

Complete the following steps to create a Modbus or Modbus Slave I/O server programmatically.

  1. Place the Create and Configure IO Server Express VI on the block diagram.
  2. In the configuration dialog box that appears, select Modbus or Modbus Slave from the I/O server type drop-down list.
  3. Click the Set Attributes button to display the Configure Modbus I/O Server or Configure Modbus Slave I/O Server dialog box.
    Note  If you click the OK button before you set the attributes for this I/O server instance, LabVIEW automatically displays the Configure Modbus I/O Server or Configure Modbus Slave I/O Server dialog box.
  4. In the Configure Modbus I/O Server or Configure Modbus Slave I/O Server dialog box, configure the settings for the new I/O server.
  5. (Optional) Click the Advanced button of the Configure Modbus I/O Server dialog box to configure the Maximum Data Points Per Command.
  6. Click the OK button.

Resources


 

Your Feedback! poor Poor  |  Excellent excellent   Yes No
 Document Quality? 
 Answered Your Question? 
Add Comments 1 2 3 4 5 submit