This simple example shows how a cRIO with LabVIEW Real-Time and Modbus I/O Servers installed can act as a Modbus master. The other part of this demo uses the LabVIEW Datalogging and Supervisory Control (DSC) module to access Modbus slave I/O servers on a desktop PC.
To get the demo up and running you will need to move all of the cRIO-based files to your hardware first. For more information on using the Modbus protocol with cRIO and DSC, visit the links below:
Developer Zone: How to turn a RT Target into a Modbus Slave using IO Servers
LabVIEW Help: Using Modbus I/O Servers (DSC Module or Real-Time Module)
Note: This example was written and tested in LabVIEW 2011 and has not been tested in older versions.
Description-Separate-2Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.