Design of Communication with Industrial Network Equipment in LabVIEW Application Using NI Programmable Automation Controller

Through National Instruments Programmable Automation Controller (PAC) and LabVIEW, users can add a variety of functions to existing PLC and industrial systems. Machine condition monitoring, high-speed analog measurement, and custom vision applications are typical PAC applications. Intercommunication between two systems is very important, it must be simple, efficient, and usually must be deterministic. This white paper will discuss the different ways to connect LabVIEW, NI PACs, and PLCs.

Through National Instruments Programmable Automation Controller (PAC) and LabVIEW, users can add a variety of functions to existing PLC and industrial systems. Machine condition monitoring, high-speed analog measurement, and custom vision applications are typical PAC applications. Intercommunication between two systems is very important, it must be simple, efficient, and usually must be deterministic. This white paper will discuss the different ways to connect LabVIEW, NI PACs, and PLCs.

content

2. Modbus TCP and Modbus Serial
3. Plug-in communication boards

Basic digital and analog I/O

Probably the easiest way to integrate an NI PAC with an existing PLC is through basic digital or analog I/O. Digital I/O is available on all National Instruments PAC platforms. The lowest number of digital I/Os on the NI PAC platform is the NI Compact Vision System, which provides 15 digital inputs and 14 digital outputs. Through digital I/O, users can realize data communication through various methods. The most basic method is to switch a single digital line, you can get information such as ostrich huan xin hui ne tu 玎 Tsui thorn ü / not passed. If you need to output more information, such as error codes, larger numbers, or want to implement handshaking, you can use multiple digital I/O lines or ports. For 8 digital I/O lines, up to 256 different values ​​can be read and written. Finally, you can also generate pulses via digital lines. Pulse generation can be used for precise timing and touch PLC.

Analog I/O is also a good option for communication between NI PACs and PLCs. The analog I/O allows the transmission of a 16-bit DAC on a single line, allowing users to eliminate the need for a single line. DDI/O is suitable for transmitting incremental amounts of specific values, minimizing the number of wires that are less than Y-1 is the noise that may be introduced and whether the signal integrity is maintained. If your PAC or PLC system is placed on the factory floor, there may be a lot of noise that can cause signal read and write errors. The use of isolated data acquisition products protects the user’s data from ground loops, voltage spikes, and noisy environments.

Modbus TCP and Modbus Serial

Modbus TCP and Modbus Serial are two of the most commonly used industrial protocols/networks on the market. With two add-on modules for LabVIEW: LabVIEW Real-Time and LabVIEW DSC, NI LabVIEW 8 introduces native Modbus TCP and Modbus Serial. Modbus TCP or Modbus serial I/O server. With just a click of the mouse, the user can create a Modbus master or device, specifying different registers for reading and writing. The following link describes the process of creating a Modbus I/O server in LabVIEW 8.

If you use an earlier version of LabVIEW or do not have the LabVIEW Real-Time or DSC module installed, you can also use the LabVIEW Modbus library, which provides a lower-level VI set, to implement the Modbus host device application. To download the free LabVIEW Modbus library, click the link below.

Modbus TCP is also a useful tool for implementing various connectivity options with gateways. For more information on this topic, please refer to the section on gateways in this white paper.

plug-in communication boards

When using a standard desktop computer or PXI chassis, users can utilize PCI or PXI slots for plug-in communication boards. The advantages of using plug-in boards include:

• Communicate directly with existing industrial networks, providing connectivity to connected devices.

• Enables deterministic communication with the processor

• High-level functions (API) for rapid application development

National Instruments provides plug-in communication boards that support PCI, PXI, and PCMCIA for the following industrial networks: PROFIBUS, DeviceNet, CANopen, CAN, serial ports (RS232, RS422, and RS485), and FOUNDATION Fieldbus. The following sections of this document describe the different types of plug-in communication boards.

PROFIBUS interface

PROFIBUS opened in 1989 and is currently the most popular field bus in the world. With more than 20 million installed nodes, PROFIBUS is the most popular in Europe and is the standard for Siemens automation PLCs for interconnecting or connecting smart sensors, actuators and I/O.

PXI PROFIBUS InterRFace

Design of Communication with Industrial Network Equipment in LabVIEW Application Using NI Programmable Automation Controller
Figure 2. PXI and PCI PROFIBUS interfaces provided by NI

NI PROFIBUS PCI and PXI single-port interfaces allow PC-based controllers to be connected to PROFIBUS industrial networks as master or secondary devices. The NI PROFIBUS interface includes the NI LabVIEW driver for human-machine interface (HMI) and SCADA applications. Users can realize automatic testing of PROFIBUS devices through these interfaces. Such interfaces will come with a set of VISA-based drivers that are very easy to use in LabVIEW and LabVIEW Real-Time.

If users are using NI PACs without PCI or PXI expansion slots, they can also connect LabVIEW and PROFIBUS networks and devices through third-party gateways.

DeviceNet interface

Commonly used in industrial applications, DeviceNet is a simple, open network solution that allows up to 64 devices to communicate with each other on a single bus, while reducing the cost and complexity of wiring and installing automation equipment, providing Interoperability between similar devices from different vendors. Based on the physical layer of the Controller Area Network (CAN), DeviceNet is a low-cost solution for connecting industrial equipment, such as photoelectric sensors, barcode readers, I/O, industrial PCs, PLCs, displays, and human-machine interfaces. to a network. It provides direct connectivity that improves device-to-device communication and device-level diagnostics where hard-wired I/O interfaces are not readily available or even available.

The plug-in DeviceNet interface provided by National Instruments can be used as both a master device (scanner) and a slave device. PCI, PXI, and PCMCIA form factors all provide NI DeviceNet interfaces that use industry-standard 5-pin combicon connectors to connect DeviceNet devices and networks. The PXI DeviceNet board is compatible with LabVIEW Real-Time, enabling deterministic control to communicate with DeviceNet networks and devices. All DeviceNet boards come with NI-DNET driver software, which provides high-level, easy-to-use functions for rapid application development. NI-DNET provides two network installation and configuration tools: NI Configurator and Analyzer.

Design of Communication with Industrial Network Equipment in LabVIEW Application Using NI Programmable Automation Controller
Figure 3. National Instruments Plug-In DeviceNet Interface

The NI DeviceNet interface is an ideal solution for adding new functionality to an existing DeviceNet network. For example, if you wish to add a machine-like device to a PC or PXI chassis for machine monitoring and analysis. The relevant information is then transmitted to the DeviceNet master device (usually a PLC) through the NI DeviceNet board in the device, thereby integrating the two systems on one network.

NI DeviceNet Configurator: The Configurator is a powerful configuration tool that supports Electronic Data Sheets (EDS). Each DeviceNet device has a separate EDS file available from the device manufacturer. The Configurator will search the DeviceNet network to obtain the information of the connected devices, automatically load the relevant EDS files, read and write the configuration parameters, and change the MAC ID of the device.

NI DeviceNet Analyzer: The Analyzer can monitor the DeviceNet network, translate the collected CAN messages according to the DeviceNet protocol, and Display the messages and parameters together. Users can display specific types of messages through powerful filtering and lookup options. Users can also get statistics of messages in Analyzer. Analyzer can be used for fault detection and analysis of DeviceNet network and system.

If your NI PAC does not have a plug-in DeviceNet board available, you can also connect LabVIEW to DeviceNet networks and devices through third-party gateways. For more information, see the section on third-party gateways in this article.

CANopen interface

CANopen is a higher-level protocol based on the CAN physical layer. It was developed as a standardized embedded network. The CANopen protocol is most used in motion control applications and is now commonly used in medical equipment such as , off-road vehicles, public transportation and building automation and other industrial fields.

For CANopen master functionality, NI provides the CANopen LabVIEW library, which provides high-level, easy-to-use NI LabVIEW functions to create CANopen master applications. Since the CANopen functions run on top of the NI-CAN driver software, all high-speed NI Series 2 CAN devices for PCI, PXI, and PCMCIA can be used as full-featured CANopen master interfaces.

Design of Communication with Industrial Network Equipment in LabVIEW Application Using NI Programmable Automation Controller
Figure 4. CANopen interface provided by NI

The NI CANopen LabVIEW library provides functions covering all CANopen master applications, including SDOs) and process data objects (PDOs), network management, signaling and node protection, emergency handling, and synchronization objects. These functions can be used to create fully CAN compliant applications that comply with the Automation (CiA) DS310 standard.

The CANopen LabVIEW library can also be used with the NI SoftMotion controller motion driver for CANopen, helping engineers easily add CANopen I/O to a motion CANopen network. The NI SoftMotion Controller is a soft motion engine and distributed intelligent drive that helps engineers interface between NI motion drive software. Engineers can program CANopen-based Accelnet and Xenus drivers through the easy-to-use NI-Motion API in LabVIEW.

If you are using an NI PAC that does not have a plug-in CANopen board available, you can also connect LabVIEW to CANopen networks and devices through third-party gateways. For more information, see the section on third-party gateways in this article.

Serial (RS232, RS422, and RS485) interface

Serial is a device communication protocol that is standard on almost all PCs. Most desktop and laptop computers include one or more RS232-based serial ports. The serial port is also a common communication protocol on various equipment and instruments, and many GPIB-compatible devices are equipped with RS232 ports. In addition, serial communication can be combined with process sampling equipment to achieve data acquisition. Although RS232 is the most common serial port protocol, RS422 and RS485 are also commonly used serial port protocols.

NI Serial Ports Overview – National Instruments is the market leader in instrument control, offering a comprehensive portfolio of serial port protocols, including RS232, RS422, and RS485. NI provides serial interfaces on various computer buses, providing interfaces to PCI, PXI, PCMCIA, ExpressCard/34, USB, and Ethernet. All NI serial interfaces are plug-and-play and fully software configurable. In addition, NI serial hardware and software feature flexible baud rates and hardware flow control, PCI and PXI serial interfaces can be transmitted via DMA, minimize CPU utilization, and have selectable 2000 V isolation between ports.

Design of Communication with Industrial Network Equipment in LabVIEW Application Using NI Programmable Automation Controller
Figure 5. NI Serial Interface

OPC server

OLE (OPC) for Process Processing is a name given to an industrial automation industry in 1996. This standard enables real-time factory data communication between control devices from different manufacturers. This standard is currently maintained and managed by the OPC Foundation and renamed as the OPC Data Access Standard. The current version of OPC Data Access_Fan is OPC Data Access 3.0.

OPC is designed to bridge Windows-based applications with process control software and hardware applications. It is an open standard that allows devices to access field data from plant ground equipment in a consistent way. This method is not affected by the type and source of the data, and remains unchanged. Traditionally, whenever a software package needed to get data on a device, it had to write a custom interface or driver. OPC, on the other hand, aims to define a common interface that can be written once and reused by companies, SCADA, HMI, or custom software packages.

Design of Communication with Industrial Network Equipment in LabVIEW Application Using NI Programmable Automation Controller
Figure 6. Automation system connection based on OPC server

Once a device-specific OPC server has been written, it can be reused for Witch OPC client applications. OPC servers use Microsoft’s OLE technology (also known as the Component Object Model, or COM) to communicate with clients.

LabVIEW as an OPC server: With LabVIEW 8 or later, users can use shared variables on the OPC server to implement the OPC client application in LabVIEW.

Adds OPC Client Capabilities to LabVIEW: The LabVIEW Data Logging and Monitoring (DSC) Module extends LabVIEW graphically The δ堋DSC module provides tools to the LabVIEW environment to easily draw historical and real-time trend data, enhances the security of the front panel, and automates data logging; adds warning, zooming, and security for shared variables. In addition, the biggest feature offered by the LabVIEW DSC module is the ability to use LabVIEW as an OPC client, providing simple connectivity to the server that interfaces with the Sigma OPC Foundation OPC server. DSC recognizes all OPC servers installed on the computer, and can directly read the information of the LabVIEW DSC module on the server, please refer to the following link.

The LabVIEW DSC module must add OPC client functionality to LabVIEW through an OPC server or NI data acquisition (DAQ) device, while the NI-DAQmx driver software provides the NI DAQ device through a local OPC server. All KNI-DAQmx devices can be used with the LabVIEW 8 Shared Variable Engine through NI-DAQmx 8 or later. To learn more about these features, see the documentation links below.

Similar to NI Fieldpoint and Compact FieldPoint and NI-DAQmx through an OPC server, the FieldPoint driver software also includes an OPC server that allows users to communicate to σOPC clients. FieldPoint OPC Server complies with OPC Data Access 2.0 standard, and similar to other FieldPoint interfaces, it can import I/O items configured in FieldPoint Explorer as OPC items available to σOPC clients. Therefore, if two computers are connected via a network, an OPC client on one computer can be used to access the FieldPoint hardware connected to the OPC server on the other computer.

third-party gateway

In industrial networks, both NI Programmable Automation Controllers (PACs) can be connected to PLCs, smart sensors and actuators by using third-party gateways. Through the native Modbus capabilities of LabVIEW 8, using the DSC or Real-Time modules, or the NI LabVIEW Modbus library, users can configure Modbus TCP or Modbus serial masters or devices. Use the Modbus library above and the LabVIEW application indicated in the link below to communicate with the Sigma-Aldrich family.

The Links:   1MBI300NN-120 AA084VB02

Author: Yoyokuo