Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                

SE Modbus Basic Nodes User Manual PDF

Download as pdf or txt
Download as pdf or txt
You are on page 1of 68

Node-RED – SE Modbus Basic Nodes

EIO0000004101 05/2020

Node-RED –
SE Modbus Basic Nodes
User Manual
05/2020
EIO0000004101.00

www.schneider-electric.com
The information provided in this documentation contains general descriptions and/or technical
characteristics of the performance of the products contained herein. This documentation is not
intended as a substitute for and is not to be used for determining suitability or reliability of these
products for specific user applications. It is the duty of any such user or integrator to perform the
appropriate and complete risk analysis, evaluation and testing of the products with respect to the
relevant specific application or use thereof. Neither Schneider Electric nor any of its affiliates or
subsidiaries shall be responsible or liable for misuse of the information contained herein. If you
have any suggestions for improvements or amendments or have found errors in this publication,
please notify us.
You agree not to reproduce, other than for your own personal, noncommercial use, all or part of
this document on any medium whatsoever without permission of Schneider Electric, given in
writing. You also agree not to establish any hypertext links to this document or its content.
Schneider Electric does not grant any right or license for the personal and noncommercial use of
the document or its content, except for a non-exclusive license to consult it on an "as is" basis, at
your own risk. All other rights are reserved.
All pertinent state, regional, and local safety regulations must be observed when installing and
using this product. For reasons of safety and to help ensure compliance with documented system
data, only the manufacturer should perform repairs to components.
When devices are used for applications with technical safety requirements, the relevant
instructions must be followed.
Failure to use Schneider Electric software or approved software with our hardware products may
result in injury, harm, or improper operating results.
Failure to observe this information can result in injury or equipment damage.
© 2020 Schneider Electric. All rights reserved.

2 EIO0000004101 05/2020
Table of Contents

Safety Information. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
About the Book . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
Part I Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
Chapter 1 Overview. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
General Information. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
Part II Installation and Uninstallation SE Modbus Nodes . . 17
Chapter 2 Prerequisites. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
System Requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
Chapter 3 Installing SE Modbus Nodes – Linux Platform . . . . . . . . 21
Installing SE Modbus Nodes - Offline Installation Mode . . . . . . . . . . . 22
Installing SE Modbus Nodes - Online Installation Mode . . . . . . . . . . . 25
Chapter 4 Uninstalling SE Modbus Nodes - Linux Platform . . . . . . 29
Uninstalling SE Modbus Nodes - Offline Uninstallation Mode . . . . . . . 30
Uninstalling SE Modbus Nodes - Online Uninstallation Mode . . . . . . . 32
Part III SE Modbus Nodes . . . . . . . . . . . . . . . . . . . . . . . . . . 35
Chapter 5 About SE Modbus Nodes . . . . . . . . . . . . . . . . . . . . . . . . 37
5.1 SE Modbus Read Node. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 38
Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39
Configuring SE Modbus Read Node . . . . . . . . . . . . . . . . . . . . . . . . . . 40
5.2 SE Modbus Write Node . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45
Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 46
Configuring SE Modbus Write Node . . . . . . . . . . . . . . . . . . . . . . . . . . 47
Chapter 6 Launching SE Modbus Nodes . . . . . . . . . . . . . . . . . . . . 53
Launching Node-RED and SE Modbus Nodes - Linux Platform . . . . . 53
Chapter 7 Usage of SE Modbus Nodes . . . . . . . . . . . . . . . . . . . . . 57
Usage of SE Modbus Nodes (SE Modbus Read Node and
SE Modbus Write Node) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58
Common Message Structure (CMS) . . . . . . . . . . . . . . . . . . . . . . . . . . 62
Part IV Cyber Security . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 65
Chapter 8 Cyber Security . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67
Cybersecurity. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67

EIO0000004101 05/2020 3
4 EIO0000004101 05/2020
Safety Information

Important Information

NOTICE
Read these instructions carefully, and look at the equipment to become familiar with the device
before trying to install, operate, service, or maintain it. The following special messages may appear
throughout this documentation or on the equipment to warn of potential hazards or to call attention
to information that clarifies or simplifies a procedure.

EIO0000004101 05/2020 5
PLEASE NOTE
Electrical equipment should be installed, operated, serviced, and maintained only by qualified
personnel. No responsibility is assumed by Schneider Electric for any consequences arising out of
the use of this material.
A qualified person is one who has skills and knowledge related to the construction and operation
of electrical equipment and its installation, and has received safety training to recognize and avoid
the hazards involved.

6 EIO0000004101 05/2020
About the Book

At a Glance

Document Scope
This document describes:
 installation and uninstallation of SE Modbus nodes.
 configuration of the nodes.
 usage of the nodes.
 limitations.

Validity Note
This document has been updated with the release of SE Modbus Basic nodes V2.0.0.

Related Documents

Title of Documentation Reference Number


Node-RED - SE Machine Advisor - User Manual EIO0000004100

You can download these technical publications and other technical information from our website
at https://spiceportal.schneider-electric.com/web/industrial-
automationproductscampus/ecostruxure-plant-data-expert. See launch book where all the
marketing aspects are detailed on IAP Campus Portal.

EIO0000004101 05/2020 7
8 EIO0000004101 05/2020
Node-RED – SE Modbus Basic Nodes
Introduction
EIO0000004101 05/2020

Part I
Introduction

Introduction

EIO0000004101 05/2020 9
Introduction

10 EIO0000004101 05/2020
Node-RED – SE Modbus Basic Nodes
Overview
EIO0000004101 05/2020

Chapter 1
Overview

Overview

General Information

IIoT (Industrial Internet of Things)


IoT is a network of intelligent computers, devices, and objects that collect and share huge amounts
of data. IIoT is the use of Internet of Things (IoT) technologies in manufacturing. With Industrial
Internet of Things (IIoT), the device itself will be seamlessly wired to the business systems.
Operational Technology (OT) is a category of hardware and software that monitors and controls
the physical devices. Due to increasing trend towards convergence of IT (Information Technology)
and OT (Operational Technology), the plant managers in charge of operational technology are
more efficient being remote.

Node-RED in EcoStruxureTM
Node-RED is an IoT wiring tool to connect services through a user-friendly graphical interface.
Schneider Electric selected Node-RED as the technology to deliver basic connectivity through
tested, validated and documented nodes.

Connected Products

EIO0000004101 05/2020 11
Overview

Modbus is a non-proprietary communication protocol used for programmable controller networks


that fall under application level, that is, level 7 of OSI Model. Originally designed for Modicon
(Schneider Electric) PLCs, it has become widely used by many PLC manufacturers and industrial
networks.
The aim is to transform standard brownfield asset into connected asset. In this case, the data is
exchanged from the lowest layer of connected devices through the Edge layer further up to the
Apps, Analytics and Services. Predictive maintenance, MES or CMMS are the typical apps
integrated in this kind of solution.

Edge Control
Edge control provides connectivity for OT and IT systems and data processing right next to the
machines. Instead of sending the data to the cloud for processing and waiting for the analytical
results, edge control devices push their data, thus saving bandwidth and enabling more
responsiveness. Magelis iPC and Magelis Edge Box offer smart application design and
engineering to leverage asset performance with end-to-end cybersecurity.
Schneider Electric provides nodes that are tested, validated, and supported to run with Node-RED
on the Magelis iPC and Edge Box.
There are three main advantages of Schneider Electric nodes:
 Scalability: easy to add connected devices in a cyber-secure manner.
 Time to market: significant reduction in integration time to implement a use case solution.
 Expert support: access to our strong L3 support team experts and the available technical
documentation.

Apps, Analytics and Services


SE Modbus nodes are developed by Schneider to simplify the Node-RED flows for use cases that
require connectivity with the cloud applications. The web page included with this node also
provides the means to specify the data to be retrieved from the PLC and to define the polling rate.
The data from the node data is collected and sent further to the web based applications through
the connected publishing node.

Magelis Edge Box


The new Magelis Edge Box meets IIoT challenges at the Edge Control level by enabling secured
communication from connected products on the shop floor to the required software and
applications on the top floor. The Edge box plugs itself on top of your current application, there is
no need to stop or modify your control application (including 3rd party control devices).
Magelis Edge Box types are commercialized, as detailed in the following table:

Magelis Edge Box Reference


Magelis HMIBSC Reference HMIBSCEA53D1L0T HMIBSC with ARM, Linux
Magelis HMIBMI Reference HMIBMIEA5DD110L HMIBMI with Intel Atom

12 EIO0000004101 05/2020
Overview

Magelis Edge Box Reference


Magelis HMIBMO Reference HMIBMOMA5DD1E01: HMIBMO with Intel Atom

Magelis iPC
The Magelis iPC is a robust industrial device without a fan or even a hard drive, requiring no
maintenance, and designed to run in the machine or plant field, even in harsh environments. New
IIoT monitors for the Magelis iPC come tested, validated, and supported in two versions - agent
and server.
Magelis iPC Box types are commercialized, as detailed in the following table:

Magelis iPC Reference


Magelis HMIBMP Reference HMIBMPHI74D4801 HMIBMP with 4 expansion slots, Intel
Core I7
Magelis HMIBMU Reference HMIBMUSI29D2801 HMIBMU with 2 expansion slots, Intel
Celeron

SE Modbus Nodes
Modbus
Modbus Protocol is a messaging structure developed by Modicon that provides a common
language for devices and equipment to communicate with each other. Modbus is a standard, open
and most widely-used network protocol in industrial automation.
SE Modbus Basic nodes package consists of the following nodes:
 SE Modbus Read node (see page 38)
 SE Modbus Write node (see page 45)

SE Modbus Read and SE Modbus Write nodes are connecting nodes that read data from and
write data into devices supporting modbus protocol (for instance: PLC, VSD (Variable Speed
Drives), Energy meter and more).
The output will be in CMS (Common Message Structure) format (see page 62) irrespective of the
input format. This CMS format makes Schneider node plug and play. The user does not have to
configure intermediate nodes with Schneider nodes in a complete end-to-end Schneider data flow.

SE Modbus Nodes Integration in EcostruxureTM Architecture


SE Modbus nodes are connecting nodes that use standard Modbus protocols to connect to the
device. The data in the connecting node can be connected to any data publishing node, such as
EcoStruxure Machine Advisor, SE Aveva Insight node and more.

EIO0000004101 05/2020 13
Overview

The following figure is an example of SE Modbus nodes in EcostruxureTM:

Best Practice for Node-RED


1. Use Browsers Wisely
When more web pages are accessed in the browser, Node-RED server may not be responsive
to the program. Remove unused web pages in the browser to prevent this.
If Node-RED application is not responsive, you will receive a page unresponsive message.

Limitations
SE Modbus nodes have the following limitations:
1. Node-RED application is supported in any browser with V8 engine or similar (for instance;
Google chrome V73.0, Firefox V66.0).Refer README for future version support.
2. Node-RED web page is only available in English, irrespective of the system language.
3. SE Modbus nodes on the HMIBSC Edge box only support Modbus TCP/IP protocol, even
though the node offers options for serial communication. Modbus Serial communication with
HMIBSC Box can not be established using modbus serial cable due to unavailability of a driver
supporting the Linux platform.
4. Modbus protocol limitations to read data from a modbus device are as follows:
 Read Coil Status: 2000
 Read Input Status: 2000

14 EIO0000004101 05/2020
Overview

 Read Holding Registers: 125


 Read Input Registers: 125
5. Modbus protocol limitations to write data from a modbus device are as follows:
 Force Single Coil: 1
 Preset Single Register: 1
 Force Multiple Coils: 1968
 Preset Multiple Registers: 123

6. Node-RED Editor Debug window shows maximum 1000 register values only.
7. When the user wants to do the offline installation, the internet should be disabled. It takes longer
to install if the internet is enabled.
8. For optimum performance, in one Edge Box, consider deploying 4 SE Modbus Read node (125
holding registers / 2000 coils per node) along with publishing nodes. This will enable overall 500
tags to be read.

EIO0000004101 05/2020 15
Overview

16 EIO0000004101 05/2020
Node-RED – SE Modbus Basic Nodes
Installation and Uninstallation SE Modbus Nodes
EIO0000004101 05/2020

Part II
Installation and Uninstallation SE Modbus Nodes

Installation and Uninstallation SE Modbus Nodes

What Is in This Part?


This part contains the following chapters:
Chapter Chapter Name Page
2 Prerequisites 19
3 Installing SE Modbus Nodes – Linux Platform 21
4 Uninstalling SE Modbus Nodes - Linux Platform 29

EIO0000004101 05/2020 17
Installation and Uninstallation SE Modbus Nodes

18 EIO0000004101 05/2020
Node-RED – SE Modbus Basic Nodes
Prerequisites
EIO0000004101 05/2020

Chapter 2
Prerequisites

Prerequisites

System Requirements

Operating System
SE Modbus nodes V2.0.0 support Linux Yocto (V1.00.010 and above) operating system.
NOTE: The required software like Node.js, Node-RED and Python are pre-installed in Magelis
HMIBSC box.

Hardware Requirements
NOTE: SE Modbus nodes are supported for Magelis HMIBSC only. Other Magelis Edge Box and
Magelis iPC will be supported in future versions of the node.

IIoT Edge Box PC hardware Specification


Magelis HMIBSC Processor Reference HMIBSCEA53D1L0T HMIBSC with ARM, Linux
Hard disk space eMMC and TPM for hardware encryption
Operating system Linux Yocto

Software Requirements
 Node.js V10.15.3
 Node-RED server V0.20.7
 Npm (Node package manager) V6.4.1
 Supported browser: Node-RED application is supported in any browser with V8 engine or
similar (for instance: Google chrome V73.0, Firefox V66.0)
NOTE: The software versions mentioned above support the SE Nodes installation. Other versions
do not support it.

EIO0000004101 05/2020 19
Prerequisites

Accessing SE Modbus Nodes


You can perform two modes of installation (offline/online):

You can perform the nodes installation on the modes given below:
 Install the node - Offline (see page 22)
 Install the node - Online (see page 25)

20 EIO0000004101 05/2020
Node-RED – SE Modbus Basic Nodes
Installing SE Modbus Nodes – Linux Platform
EIO0000004101 05/2020

Chapter 3
Installing SE Modbus Nodes – Linux Platform

Installing SE Modbus Nodes – Linux Platform

What Is in This Chapter?


This chapter contains the following topics:
Topic Page
Installing SE Modbus Nodes - Offline Installation Mode 22
Installing SE Modbus Nodes - Online Installation Mode 25

EIO0000004101 05/2020 21
Installing SE Modbus Nodes – Linux Platform

Installing SE Modbus Nodes - Offline Installation Mode

The Linux based Edge Boxes (for example, HMIBSC) have in-built Node-RED-as-a-Service. This
means Node.js, Node-Red and python are pre-installed in the OS image.
The SE Modbus nodes are installed by the user from the portable disk.
The below procedure is applicable for the Edge Boxes running on Linux Yocto (for example,
HMIBSC):

Step Action
1 Download the Modbus_V2.0.0_Offline.zip file from the link given below:
https://schneider-electric.box.com/s/xsmgvjhjo4km8jwlsn8qyprgb0gy8bv6
2 Extract the downloaded file Modbus_V2.0.0_Offline.zip and transfer the extracted folder
(Modbus_V2.0.0_Offline) into a portable disk.
Example: Pendrive.
3 Connect the portable device to IIoT Edge Box.
4  Navigate to the directory of the portable device (for instance, cd mount/media/<disk
name>) and press Enter.
 Type cd Modbus_V2.0.0_Offline and press Enter to go to the directory where the
offline files for SE Modbus nodes are placed.

5 Type sh se-node-red-modbus_offline_install.sh and press Enter to install the


SE Modbus nodes. Press any key to read the Terms & Conditions.

NOTE: Press any key to continue until the result appears below.
Result: Do you agree to our Terms & Conditions? (yes/no):.

22 EIO0000004101 05/2020
Installing SE Modbus Nodes – Linux Platform

Step Action
6 Type yes and press Enter to agree the terms and conditions and install SE Modbus nodes.

Result: se-node-red-modbus installed successfully. Please restart node-red by rebooting


Magelis HMIBSC Edge box.
NOTE: If you type no, the installation is cancelled.

EIO0000004101 05/2020 23
Installing SE Modbus Nodes – Linux Platform

Step Action
7 Open a browser from system (laptop or desktop) connected in same network as the Linux Edge
box:
 Go to https:\\<ip address>:1880
NOTE: To know your ip address, type ifconfig in your Linux edge box.

 Login window appears. Use your Node-RED login credentials to operate Linux Edge box
through your system (laptop or desktop).

NOTE: As browser is not available in Linux edge box you can connect to another system
(laptop or desktop) using the ip address of Linux Edge box.

24 EIO0000004101 05/2020
Installing SE Modbus Nodes – Linux Platform

Installing SE Modbus Nodes - Online Installation Mode

The Linux based Edge Boxes (for example, HMIBSC) have in-built Node-RED-as-a-Service. This
means Node.js, Node-Red and python are pre-installed in the OS image.
To install SE Modbus nodes follow the steps given below:

Step Action
1 Type the text given below in the terminal and press Enter:
npm set registry https://wain05400.apa.gad.schneider-
electric.com:4878/
2 Type the text given below in the terminal and press Enter:
npm set proxy null
Note: If set proxy null command is not working, remove proxy for respective types as follows:
 npm config rm proxy
 npm config rm http-proxy
 npm config rm https-proxy

3 Type npm install se-node-red-modbus and press Enter.


NOTE: If you get the error as shown in image below:

Then, type the text given below in the terminal and press Enter, and run the installation
command again.
npm set strict-ssl false
NOTE: Press any key to continue until the result appears.
Result: Do you agree to our Terms & Conditions? (yes/no):.

EIO0000004101 05/2020 25
Installing SE Modbus Nodes – Linux Platform

Step Action
4 Type yes and press Enter to agree the terms and conditions and install SE Modbus nodes.

Result: Installation is successfully completed.


NOTE: If you type no, the installation is cancelled.
5 Restart Node-RED application by rebooting Magelis HMIBSC Edge box.

26 EIO0000004101 05/2020
Installing SE Modbus Nodes – Linux Platform

Step Action
6 Open a browser from system (laptop or desktop) connected in same network as the Linux Edge
box:
 Go to https:\\<ip address>:1880
NOTE: To know your ip address, type ifconfig in your Linux edge box.

 Login window appears. Use your Node-RED login credentials to operate Linux Edge box
through your system (laptop or desktop).

NOTE: As browser is not available in Linux edge box you can connect to another system
(laptop or desktop) using the ip address of Linux Edge box.

EIO0000004101 05/2020 27
Installing SE Modbus Nodes – Linux Platform

28 EIO0000004101 05/2020
Node-RED – SE Modbus Basic Nodes
Uninstalling SE Modbus Nodes - Linux Platform
EIO0000004101 05/2020

Chapter 4
Uninstalling SE Modbus Nodes - Linux Platform

Uninstalling SE Modbus Nodes - Linux Platform

What Is in This Chapter?


This chapter contains the following topics:
Topic Page
Uninstalling SE Modbus Nodes - Offline Uninstallation Mode 30
Uninstalling SE Modbus Nodes - Online Uninstallation Mode 32

EIO0000004101 05/2020 29
Uninstalling SE Modbus Nodes - Linux Platform

Uninstalling SE Modbus Nodes - Offline Uninstallation Mode

The below procedure is applicable for the Edge Boxes running on Linux Yocto (for example,
HMIBSC):

Step Action
1 Type ls and press Enter.

Result: Installed nodes appears.


2 Type sh se-node-red-modbus_offline_uninstall.sh and press Enter to uninstall
SE Modbus nodes.

Result: SE Modbus nodes are uninstalled successfully.


3 Restart node-red by rebooting Magelis HMIBSC Edge box.

30 EIO0000004101 05/2020
Uninstalling SE Modbus Nodes - Linux Platform

Step Action
4 Open a browser from system (laptop or desktop) connected in same network as the Linux Edge
box:
 Go to https:\\<ip address>:1880
NOTE: To know your ip address, type ifconfig in your Linux edge box.

 Login window appears. Use your Node-RED login credentials to operate Linux Edge box
through your system (laptop or desktop).

NOTE: As browser is not available in Linux edge box you can connect to another system
(laptop or desktop) using the ip address of Linux Edge box.

EIO0000004101 05/2020 31
Uninstalling SE Modbus Nodes - Linux Platform

Uninstalling SE Modbus Nodes - Online Uninstallation Mode

This procedure explains how to uninstall the SE Modbus nodes:

Step Action
1 From the browser where Node-RED server is running, delete the SE Modbus nodes from the
flow.
2
Click Deploy and Logout from the Node-RED application.
3 Go to HMIBSC terminal.
4 Type npm uninstall se-node-red-modbus.
5 Press Enter to uninstall the SE Modbus nodes.
Result: SE Modbus nodes are successfully uninstalled.
6 Restart Node-RED application by rebooting Magelis HMIBSC Edge box.

32 EIO0000004101 05/2020
Uninstalling SE Modbus Nodes - Linux Platform

Step Action
7 To check if your node is uninstalled follow the steps below
 Open a browser from system (laptop or desktop) connected in same network as the Linux
Edge box:
 Go to https:\\<ip address>:1880
NOTE: To know your ip address, type ifconfig in your Linux edge box.

 Login window appears. Use your Node-RED login credentials to operate Linux Edge box
through your system (laptop or desktop).

NOTE: As browser is not available in Linux edge box you can connect to another system
(laptop or desktop) using the ip address of Linux Edge box.

EIO0000004101 05/2020 33
Uninstalling SE Modbus Nodes - Linux Platform

34 EIO0000004101 05/2020
Node-RED – SE Modbus Basic Nodes
SE Modbus Nodes
EIO0000004101 05/2020

Part III
SE Modbus Nodes

SE Modbus Nodes

What Is in This Part?


This part contains the following chapters:
Chapter Chapter Name Page
5 About SE Modbus Nodes 37
6 Launching SE Modbus Nodes 53
7 Usage of SE Modbus Nodes 57

EIO0000004101 05/2020 35
SE Modbus Nodes

36 EIO0000004101 05/2020
Node-RED – SE Modbus Basic Nodes
About SE Modbus Nodes
EIO0000004101 05/2020

Chapter 5
About SE Modbus Nodes

About SE Modbus Nodes

Overview
This chapter describes information about SE Modbus Read and SE Modbus Write nodes.

What Is in This Chapter?


This chapter contains the following sections:
Section Topic Page
5.1 SE Modbus Read Node 38
5.2 SE Modbus Write Node 45

EIO0000004101 05/2020 37
About SE Modbus Nodes

Section 5.1
SE Modbus Read Node

SE Modbus Read Node

What Is in This Section?


This section contains the following topics:
Topic Page
Introduction 39
Configuring SE Modbus Read Node 40

38 EIO0000004101 05/2020
About SE Modbus Nodes

Introduction

Overview
SE Modbus Read node reads the data from modbus devices using modbus TCP or modbus Serial
communication protocol. The node reads one or multiple register values at specified poll interval.
The output of SE Modbus Read node is in CMS format (see page 62).
NOTE: Modbus Serial communication with HMIBSC Box cannot be established using modbus
serial cable due to the unavailability of the driver in the Linux platform.

Node Description
SE Modbus Read node consists of:

Item number Item name Description


1 Connection status Indicates the following connection status:
 Connecting: Node is connecting to any modbus device.
 Connected: Node is connected to the device.
 Success: Data from Modbus device read successfully.
 Error: Indicates when the node detects an error.
 ConfigError: Node is not configured properly.

2 Output Generated CMS is passed as an output

EIO0000004101 05/2020 39
About SE Modbus Nodes

Configuring SE Modbus Read Node

Configure SE Modbus Read node properties


Double-click SE Modbus Read node. The Properties screen of the node appears.

Parameters Description
FC Select the required function code from the list:
 FC 1: Read Coil Status
 FC 2: Read Input Status
 FC 3: Read Holding Registers
 FC 4: Read Input Registers

NOTE: The FC (Function Code) defines the memory area to read the data.
Address Type the address to be read.
The address should be between 0...65535.
For example: 125
NOTE: An address is a location where data is stored.
Quantity Type the value to be read starting from the address configured in previous step.
NOTE: The value for FC 1 and FC 2 should be between 1...2000.
The value for FC 3 and FC 4 should be between 1...125.

40 EIO0000004101 05/2020
About SE Modbus Nodes

Parameters Description
Add Tag Click to add the tag name and type (int, boolean and float32) for corresponding
register.
For more information (see page 41).
Poll Rate Select the frequency at which data has to be read.
Unit ID Type the modbus device address of SE Modbus Read Serial and TCP (Optional)
devices.
NOTE: Unit ID is the device Id of serial device.
Server
Click icon to configure the parameters of the selected server (modbus
device) types given below:
 TCP (see page 42)
 Serial (Not applicable for HMIBSC Edge box.)

Logging Logging is used to read the data.


Select the Enable or Disable for logging the events.
By default, Enable is selected.
When Enabled, the log events are recorded in the log file.
The log files will be saved in the path given below:
<Installed Node Directory>/nodes/log/
For instance the location will be:
 Offline installation
 <User Directory>/se-node-red-modbus/nodes/log/

 Online installation
 <User Directory>/.node-red/node_modules/se-node-red-
modbus/nodes/log/
Level Select the logging level from the list:
 All Events
Error, info, debug messages are logged
 Alerts Only
Error messages are logged
NOTE: By default, Alerts Only is selected.

Add Tag Properties


The Modbus device reads all the variables. Each variable has its own special register address.
Users can add tags / variables to the add tag properties using the register address to monitor
specific register address variables.

EIO0000004101 05/2020 41
About SE Modbus Nodes

By clicking Add Tag option the window given below appears. Here you can add the details of the
tags that you wish to read.

Parameters Description
Tag field Type the tag name.
Data type of tag Select any one of the following data type:
 INT - 16 bit and occupies 1 register address only.
 BOOLEAN - 16 bit and occupies 1 register
address only.
 FLOAT32 - 32 bit and occupies 2 registers
address.
Save Tags Click Save Tags to save the tags information.

TCP Properties
NOTE: TCP and Serial are mutually exclusive. If the user wants to connect to a Modbus TCP
device, only then follow these steps.

42 EIO0000004101 05/2020
About SE Modbus Nodes

If the user wants to connect to a modbus TCP device, follow these steps:

Parameters Description
Host Type the IP address
Each host has a host number that, together with a network identity, forms its own
unique IP address.
Port Type the port number.
The TCP port is a 16 bit number, 1... 65535, used to identify the services or
processes being used in networking communications.
Specific port numbers are often used for the purpose of identifying specific
services. TCP port 502 is used by convention under the Modbus protocol.

EIO0000004101 05/2020 43
About SE Modbus Nodes

Parameters Description
TCP Type Select the TCP Type from the drop-down list:
 DEFAULT
 RTU-BUFFERED
A remote terminal unit (RTU) is a microprocessor-controlled electronic device
that interfaces objects in the physical world to a distributed control system or
SCADA by transmitting telemetry data to a master system, and by using
messages from the master supervisory system to control connected objects.
Timeout When the idle Timeout is set, if there is no communication to the device for the
specified period of time (in seconds), the connection will be closed.
By default, the delay time is 10000 ms.
Reconnect timeout Timeout controls how long transmitted data may remain unacknowledged before
a connection is forcefully closed.
Set the reconnect time out for reconnecting the node.
By default, the reconnect time is 2000 ms.
Queue commands Select the required option from the drop-down list:
 Enable: This option stores incoming commands and sends them with delay.
 Disable: This option turns off the queue delay.

By default, the Queue commands is Enable.


Queue delay Set the time interval to delay sending the commands from queue.
By default, the queue delay is 100 ms.

44 EIO0000004101 05/2020
About SE Modbus Nodes

Section 5.2
SE Modbus Write Node

SE Modbus Write Node

What Is in This Section?


This section contains the following topics:
Topic Page
Introduction 46
Configuring SE Modbus Write Node 47

EIO0000004101 05/2020 45
About SE Modbus Nodes

Introduction

Overview
SE Modbus Write node writes the data to modbus devices using the modbus TCP or modbus serial
communication protocol. The node writes into one or multiple register values in the device.
NOTE: Modbus Serial communication with HMIBSC Box cannot be established using modbus
serial cable due to the unavailability of the driver in the Linux platform.

Node Description
SE Modbus Write node consists of:

Item number Item name Description


1 Output You can connect the output to any connection node or debug node.
2 Connection status Indicates the following connection status:
 Connecting: Node is connecting to any modbus device.
 Connected: Node is connected to the device.
 Success: Data to Modbus device written successfully.
 Error: Indicates when the node detects an error.
 ConfigError: Node is not configured properly.

3 Input Inject data/values from inject node for the configured parameters.

46 EIO0000004101 05/2020
About SE Modbus Nodes

Configuring SE Modbus Write Node

Configuring SE Modbus Write Node


Double-click SE Modbus Write node. The Properties screen of the node appears.

Parameters Description
Type Select the required function code from the drop-down list:
 FC 5: Force Single Coil
 FC 6: Preset Single Register
 FC 15: Force Multiple Coils
 FC 16: Preset Multiple Registers

NOTE: The FC (Function Code) defines the memory area to write the data.
Address Type the text in the address field that is to be written.
The address has to be between 0...65535.
NOTE: An address is a location where data is stored.

EIO0000004101 05/2020 47
About SE Modbus Nodes

Parameters Description
Quantity Type the value in quality field that is to be written starting from the address
configured in above step.
The value for FC 5 and FC 6 should be 1
The value for FC 15 should be between 1...1968
The value for FC 16 should be between 1...123
Add Tag Click to add the tag name and type (INT, FLOAT32 and BOLEAN) for
corresponding register.
For more information (see page 48).
Server

Click icon to configure the parameters of the selected server types given
below:
 TCP (see page 49)
 Serial (Not applicable for HMIBSC Edge box.)

Logging Logging is used to write the data.


Select the Enable or Disable for logging the events.
By default, Enable is selected.
When Enabled, the log events are recorded in the log file.
The log files will be saved in the path given below:
<Installed Node Directory>/nodes/log/
For instance the location will be:
 Offline installation
 <User Directory>/se-node-red-modbus/nodes/log/

 Online installation
 <User Directory>/.node-red/node_modules/se-node-red-
modbus/nodes/log/
Level Select the logging level from the drop-down list:
 All events
 Alerts only

NOTE: By default, Alerts only is selected.

Add Tag Properties


The node writes the variables into the device. Each variable has its own special register address.
Users can add tags / variables to the add tag properties using the register address to monitor
specific register address variables.

48 EIO0000004101 05/2020
About SE Modbus Nodes

By clicking Add Tag option the window given below appears. Here you can add the details of the
tags that you wish to write.

Parameters Description
Tag field Type the tag name.
Data type of tag Select any one of the following data type:
 INT - 16 bit and occupies 1 register address only.
 BOOLEAN - 16 bit and occupies 1 register
address only.
 FLOAT32 - 32 bit and occupies 2 registers
address.
Save Tags Click Save Tags to save the tags information.

TCP Properties
NOTE: TCP and Serial are mutually exclusive. If the user wants to connect to a Modbus TCP
device, only then follow these steps.

EIO0000004101 05/2020 49
About SE Modbus Nodes

If the user wants to connect to a modbus TCP device, follow these steps:

Parameters Description
Unit ID Type the modbus device address of
SE Modbus Write Serial and TCP (Optional) devices.
Host Type the IP address
Each host has a host number that, together with a
network identity, forms its own unique IP address.

50 EIO0000004101 05/2020
About SE Modbus Nodes

Parameters Description
Port Type the port number.
The TCP port is a 16 bit number, 1... 65535, used to
identify the services or processes being used in
networking communications.
Specific port numbers are often used for the purpose
of identifying specific services. TCP port 502 is used
by convention under the Modbus protocol.
TCP Type Select the TCP Type from the drop-down list:
 DEFAULT
 TELNET
 C701
 RTU-BUFFERED
A remote terminal unit (RTU) is a microprocessor-
controlled electronic device that interfaces objects
in the physical world to a distributed control
system or SCADA by transmitting telemetry data
to a master system, and by using messages from
the master supervisory system to control
connected objects.
Timeout (ms) When the idle Timeout is set, if there is no
communication to the device for the specified period
of time (in seconds), the connection will be closed.
By default, the delay time is 10000 ms.
Reconnect timeout (ms) Timeout controls how long transmitted data may
remain unacknowledged before a connection is
forcefully closed.
Set the reconnect time out for reconnecting the node.
By default, the reconnect time is 2000 ms.
Queue commands Select the required option from the drop-down list:
 Enable: This option stores incoming commands
and sends them with delay.
 Disable: This option turns off the queue delay.

Queue delay (ms) Set the time interval to delay sending the commands
from queue.
By default, the queue delay is 100 ms.

EIO0000004101 05/2020 51
About SE Modbus Nodes

52 EIO0000004101 05/2020
Node-RED – SE Modbus Basic Nodes
Launching SE Modbus Nodes
EIO0000004101 05/2020

Chapter 6
Launching SE Modbus Nodes

Launching SE Modbus Nodes

Launching Node-RED and SE Modbus Nodes - Linux Platform

Node-RED
Follow the steps given below to launch Node-RED server:

Step Action
1 Open a browser from system (Laptop or Desktop) connected in same network as the Linux
Edge box.
2 Type https://<ip address>:1880/ in the URL field in the browser and press Enter.
NOTE: To know your IP address, type ifconfig in your Linux Edge box.
Result: Login window appears
3 Use your Node-RED login credentials (Username and Password) to operate Linux Edge box
through your system.
NOTE: As the browser is not accessible in the Linux Edge box, you can connect to another
system (Laptop or Desktop) using the Linux Edge box IP address.

EIO0000004101 05/2020 53
Launching SE Modbus Nodes

Step Action
4

Result: Node-RED editor appears.

54 EIO0000004101 05/2020
Launching SE Modbus Nodes

SE Modbus Nodes
Follow the steps given below to launch SE Modbus Nodes:

Step Action
1 In Node-RED window, use the scroll bar to find SE Modbus nodes on the left side.
NOTE: Alternatively, you can also search from the Filter Nodes search option available at the
left side node palette area. In SE Modbus category, SE Modbus Read and SE Modbus Write
nodes are available.

Result: In modbus category, SE Modbus nodes are available.


NOTE: SE Modbus nodes license information is available in the LICENSE tab. Help manual is
available in the HELP tab (right next to LICENSE tab).
2 Drag-and-drop SE Modbus nodes on the flow page.

EIO0000004101 05/2020 55
Launching SE Modbus Nodes

56 EIO0000004101 05/2020
Node-RED – SE Modbus Basic Nodes
Usage of SE Modbus Nodes
EIO0000004101 05/2020

Chapter 7
Usage of SE Modbus Nodes

Usage of SE Modbus Nodes

What Is in This Chapter?


This chapter contains the following topics:
Topic Page
Usage of SE Modbus Nodes (SE Modbus Read Node and SE Modbus Write Node) 58
Common Message Structure (CMS) 62

EIO0000004101 05/2020 57
Usage of SE Modbus Nodes

Usage of SE Modbus Nodes (SE Modbus Read Node and SE Modbus Write Node)

Usage of SE Modbus Read node


The user needs to connect to a modbus device, to collect the data to be read and send it to any
publishing nodes (for example, SE Machine Advisor node).
The procedure for the use of SE Modbus Read node is given below:

Step Action
1 Launch Node-RED server (see page 53).
2 Launch SE Modbus Read node (see page 55) and SE Machine Advisor (see Node-RED -
SE Machine Advisor Node, User Manual).
3 Connect the two nodes by joining the output of SE Modbus Read and input of
SE Machine Advisor as shown below:

4 Double-click SE Modbus Read node.


Result: Edit SEModbusRead node opens.
5 Configure SE Modbus Read node (see page 40).
Result: SE Modbus Read reads the data from device and sends as an input to
SE Machine Advisor node.
6 Double-click SE Machine Advisor node.
Result: Edit SEmachineAdvisor node opens.

58 EIO0000004101 05/2020
Usage of SE Modbus Nodes

Step Action
7 Configure SE Machine Advisor node (see Node-RED - SE Machine Advisor Node, User
Manual).
8
Click Done and Deploy to save the changes.
Result: Nodes status changes to Connected.
Result: The data is fetched at a frequency specified in the Poll Rate (see page 40) of
SE Modbus Read. At the same frequency, data in the CMS format is sent as an input to
SE Machine Advisor to push it to EcoStruxure Machine Advisor cloud.

Usage of SE Modbus Write node


The user needs an inject node to provide input data to the SE Modbus Write node. This enables
the user to write the data into any modbus device configured. The user may need a debug node to
view the node output.
The procedure for SE Modbus Write node usage is given below:

Step Action
1 Launch Node-RED server (see page 53).
2 Drag and drop the inject and debug nodes from the palette.
3 Launch SE Modbus Write node (see page 55).
4 Connect all three nodes in the flow.
5 Double-click inject node.
Result: Edit inject node opens.

EIO0000004101 05/2020 59
Usage of SE Modbus Nodes

Step Action
6 Configuring the Inject Node

Select payload as JSON from the drop down and click .


Example of payloads injected from the Inject node:
Default payload (payload type - number)
A number in case of single write register.
28
Default payload (payload type - JSON)
A number array in case of multiple write registers.
[28, 48]
Custom payload (payload type - JSON)
An object with containing value key of number in case of single write register.
{
"value": 98,
"unitid":1,
"fc":16,
"address":3,
"quantity":1
}

An object with containing value key of number array in case of multiple write registers.
{
"value":[ 4, 78 ],
"unitid":1,
"fc":16,
"address":3,
"quantity":2
}
Click Done.
Select the required option from the drop down to set the poll rate and click Done:
 none
 interval
 interval between times
 at a specific time

7 Double-click SE Modbus Write node.


Result: Edit SEModbusWrite node opens.
8 Configure SE Modbus Write node (see page 47).

60 EIO0000004101 05/2020
Usage of SE Modbus Nodes

Step Action
9
Click Done and Deploy to save the changes.

Result: Node status changes to Connected.


Result: The data obtained from the inject node will be written to the modbus device whenever
the user clicks on the debug node (cyclical operations can be performed on the basis of the
inject poll rate).

EIO0000004101 05/2020 61
Usage of SE Modbus Nodes

Common Message Structure (CMS)

CMS is standard JSON format between a connecting node and a publishing node to avoid any
intermediate functions. JSON is a standard way for representing a JavaScript object as a string. It
is commonly used by web APIs to return data.
A Node-RED flow works by passing messages between nodes. All the messages conform to a
common message format to simplify the message content navigation. The messages are simple
JavaScript objects that can have any set of properties.
The following is the CMS structure:

Field Description
Name Name of the node.
Id Unique Identifier of the device.
Timestamp The exact time at which the read or write operation is
performed by the node.
Devices Applicable for modbus devices. All nested objects
containing one or many Device objects.

62 EIO0000004101 05/2020
Usage of SE Modbus Nodes

Field Description
Data Object at root level and as a composite inside
devices object. It contains at least one property
object.
Error Error at the root level, not tied to any parameter.
 Scenario 1: Gateway disconnected.
 Scenario 2: Gateway timed out.
 Scenario 3: Modbus port not opened.
 Scenario 4: Gateway connected. Read Error
encountered.
Property If data object exists, then atleast one property (value)
is mandatory. Mapped to the parameter details. It
contains Error, Value, Unit, Type.
Error Local error pertaining to the parameter.
 Scenario 1: No Radio (at a sensor level)
 Scenario 2: Parameter Read Error encountered.
(e.g.: FF, FFFF, FFFFFFFF)
 Value: When mandatory, always in case of
success. When optional, in case of error.
 Unit - optional field
 Type- optional field

The following graphics are an example of CMS data:


Example: One device connected directly through SE Modbus Read node output:

EIO0000004101 05/2020 63
Usage of SE Modbus Nodes

64 EIO0000004101 05/2020
Node-RED – SE Modbus Basic Nodes

EIO0000004101 05/2020

Part IV
Cyber Security

Cyber Security

EIO0000004101 05/2020 65
66 EIO0000004101 05/2020
Node-RED – SE Modbus Basic Nodes
Cyber Security
EIO0000004101 05/2020

Chapter 8
Cyber Security

Cyber Security

Cybersecurity

Overview
Because of the IIoT design, industrial and control systems are increasingly vulnerable to cyber-
attacks for the following reasons:
 Magelis Edge Box and Magelis iPC are commercially available in the market.
 Publishing nodes can be remotely accessible.
 IIoT designs are a strategic location in the industrial processes that is of interest to hackers.

To secure the industrial installation, the following fundamental characteristics should be


considered:
 Availability of the system to help ensure that the system remains operational
 Integrity of the data to maintain the integrity of information
 Confidentiality to avoid information disclosure

General Practices
To keep the system as secured as possible, secure the environment where the Box is installed.
Unauthorized persons may gain access to the Magelis iPC and Magelis Edge Box as well as to
other devices on the network/fieldbus of the machine and connected networks via insufficiently
secure access to the software and networks.
Before creating user login details, cross-check again if it is necessary to give access to others.
Users may have one of two permissions (*-full access/read-only access). Admin login and
password details must be secured.
To avoid unauthorized access to the Magelis iPC and Magelis Edge Box, you must have the:
 Operating system, libraries, runtime environments, etc. are installed and correctly configured.
 Patch management controls to ensure that all software is kept up-to-date.
 Configuration change management controls.
 Malicious code detection and prevention controls, for example:
 Anti-virus signature and pattern updates are applied in a timely fashion.
 Application whitelisting.

 Access control and permission management.


 Backup and restore functionality.
 Area where the Box is placed must be physically protected to keep the device as safe as
possible.

EIO0000004101 05/2020 67
Cyber Security

 Authentication and authorization enabled for Node-RED environment.


 SSL enabled to secure Node-RED in Windows platform. By default, SSL is enabled to secure
Node-RED in the HMIBSC boxes.

Cybersecurity Certification
Schneider Electric developed cybersecurity guidelines based on the following recommendations:
 ISA Secure.

68 EIO0000004101 05/2020

You might also like