Emerson Mynah PLC-5 Datasheet

APPLICATION NOTE
MODBUS TCP COMMUNICATION
HIMA H41q/H51q
↔
Emerson Process Management DeltaV
HIMA Paul Hildebrandt GmbH + Co KG
Industrial Automation
Important Notes
All HIMA products mentioned in this manual are protected under HIMA trademark. Unless not
explicitily noted, this may apply for other referenced manufacturers and their respective products.
All technical statements and data in this manual have been worked out very carefully, and effective
checks and inspections have been applied. This manual may however contain flaws or typesetting
errors. Therefore HIMA does not offer any warranties nor assume legal responsibility nor any liability
for the possible consequences of any errors in this manual. HIMA would appreciate being informed on
possible errors.
The technology is subject to changes without notice.
HIMA Paul Hildebrandt GmbH + Co KG
PO-Box 1261
68777 Brühl
Phone: +49 (6202) 709 0
Fax: +49 (6202) 709 107
Email: info@hima.com
Table of Contents
1.
Introduction ................................................................................................................................... 1
2.
Described Configuration .............................................................................................................. 2
2.1.
Detailed System Layout ......................................................................................................... 2
2.2.
Configuration of H41q/H51q Hard- and Software .................................................................. 2
2.2.1 Hardware Configuration..................................................................................................... 2
2.2.2 Application Software Configuration.................................................................................... 3
2.3.
Configuration of DeltaV Hard- and Software.......................................................................... 5
2.3.1 VIM Configuration .............................................................................................................. 5
2.3.2 DeltaV Serial Card Configuration....................................................................................... 7
2.3.3 Application Software Configuration.................................................................................... 9
2.4.
Validation of Modbus TCP Communication ......................................................................... 10
3.
Summary...................................................................................................................................... 10
4.
Recommended Literature .......................................................................................................... 11
5.
Document Revision and Release History................................................................................. 12
Modbus TCP Communication HIMA H41q/H51q ↔ Emerson DeltaV
1.
Introduction
There is an increasing need for fast and voluminous data transmission between HIMA Safety PESs
and different DCSs. Modbus TCP is a protocol which can fulfil this need. Modbus TCP communication
combines the proven reliability of the Modbus protocol with the flexibility and speed of Ethernet
networks. The well known Modbus Telegrams are coded into TCP packages and can than be
communicated via Ethernet. As transport layer standard off-the-shelf Ethernet equipment like twisted
pair network cables, switches and fiber optic converters can be used with communication speeds of up
to 1 GB/s. In contrast to standard Modbus RTU the Modbus TCP protocol is multi master capable,
meaning that several communication masters can access the same slaves for information.
The Modbus TCP communication protocol was made available to HIMA´s H41q/H51q and Emerson´s
DeltaV system through market introduction of new communication modules in 2005 and 2006
respectively. Modbus TCP support was added to H41q/H51q systems through introduction of the new
ethernet communication module F 8627X. A communication module from third-party supplier Mynah
named Virtual I/O Module (VIM) added Modbus TCP capability to DeltaV. The Mynah VIM achieves
this through simulating four DeltaV serial cards (eight serial cards for redundant layout) which are
virtually mapped to the last I/O slots (61-64 for non-redundant and 57-64 for redundant
communication) of the DeltaV systems eight possible I/O carriers. The way to configure the data
communication and the applicable communication limitations is therefore the same like with standard
DeltaV serial cards.
Figure 1.1 General Network Layout for Modbus TCP Communication
This Application Note should give an overview of the necessary configuration steps for establishing a
Modbus TCP communication between HIMA’s H41q/H51q safety PES and Emerson Process
Management’s DeltaV DCS.
As precondition for applying this Application Note general knowledge of the H41q/H51q PES and
DeltaV DCS as well as configuring with ELOP II and DeltaV Explorer and Control Studio is assumed
(see Recommended Literature [1], [2], [3], [4]).
1
Modbus TCP Communication HIMA H41q/H51q ↔ Emerson DeltaV
2.
Described Configuration
2.1. Detailed System Layout
The detailed hardware layout on which this Application Note is based is shown in Figure 2.1.
Figure 2.1: Network Overview for H41q/H51q ↔ DeltaV Modbus TCP Communication
The used hardware and software components are:
Hardware:
Software:
H41q/H51q PES
ELOP II Engineering Software
F 8627X Ethernet communication module
ELOP II license dongle
DeltaV MD Controller
DeltaV Automation Software
DeltaV Professional Plus Workstation
DeltaV System licenses
Ethernet Cat. 5 network cables
DeltaV serial port licenses
Industrial Ethernet Switches
For detailed information about the explicitly tested hardware, software, firmware and Operating
Systems refer to the Communication Test Report (see [6]).
2.2. Configuration of H41q/H51q Hard- and Software
The necessary configuration of an H41q/H51q PES for Modbus TCP communication consists of the
configuration of the ethernet communication module F 8627X on the hardware side and of setting the
IP address and defining communication variables in the application software.
2.2.1 Hardware Configuration
The hardware of HIMA safety systems can consist of one or several H41q/H51q safety PESs. The
necessary hardware configuration for communication is the same for all PESs and simply consists of
setting the Bus Station Number (BSN) of all CPUs and configuring the F 8627X ethernet
communication module. All settings are made via DIP switches when the module is removed from the
rack.
2
Modbus TCP Communication HIMA H41q/H51q ↔ Emerson DeltaV
Setting Bus Station Number (BSN):
The Bus Station Number is the address under which the safety PESs are addressed when serial
communication via RS-485 is used. This address should be the same like the numbers ending the
resource name in ELOP II from which the IP-Address is generated (see chapter 2.2.2 for details).
There is one DIP-switch on each H41q/H51q CPU (e.g. F 8650X and F 8652X for SIL3 operation)
setting the BSN and the serial transmission rate for the two integrated serial RS-485 interfaces. The
BSN is set with switches 1-5 on DIP-switch S1 in a range from 1 to 99 using standard binary coding
(for details about DIP switch settings on the CPU see [1] or the separately available CPU datasheets).
Configuring the F 8627X ethernet communication module:
The F 8627X has two DIP switches which are used for configuring the ethernet communication
module.
Figure 2.2: Recommended settings for F 8627X DIP switch S1 and S2
Figure 2.2 shows marked in red the DIP switch settings which are recommended for most ethernet
communications.
• The switches S1/1-7 are used for internal H41q/H51q communication and should be sufficient for
most applications when set as shown above.
• Switch S1/8 should be set to “Passive Mode enabled” to ensure also fast communication to the
HIMA OPC DA Server by disabling time consuming Token Passing.
• Switch S2/1 should be set according to the position where the F 8627X will be placed. “Ethernet
Channel 1” for placement next to CPU 1 or “Ethernet Channel 2” for placement next to CPU 2.
• Normally the communication modules are inserted redundant. Then Switch S2/2 should also
reflect this.
• Switch S2/3 is set to “Off” as some networking devices do not support Auto-negotiation of
transmission rate and duplex mode.
• Switch S2/4 and S2/5 should be set according to the networking hardware you use. Normally
“100 Mbit/s” and “Full duplex” is suitable with nowadays networking hardware.
• Switches S2/6-7 should be set to determine the number of HIMA OPC Servers which are
connected to this resource. (Be careful: In HIMA documentation the term “HIMA OPC Server”
refers to the HIMA OPC DA Server as is the case here.)
2.2.2 Application Software Configuration
When programming a HIMA H41q/H51q safety PES within ELOP II there are two steps necessary to
prepare the PES for data communication to any other programmable system via Modbus TCP or any
other ethernet based communication method. These are: definition of an IP address and definition of
variables to be transmitted through an ethernet communication module (definition of BUSCOM data).
3
Modbus TCP Communication HIMA H41q/H51q ↔ Emerson DeltaV
Definition of the H41q/H51q´s IP Address:
The IP address of an H41q/H51q safety PES is defined through its resource name in ELOP II and
consists of two subsequent addresses in network 192.168.0.x. The resource name must have eight
alphanumeric characters and mustn’t contain any spaces. For IP addressing the last two characters
must be numbers. When you take XXXXXXnn as a resource name X represents an alphanumeric
character and n represents a single digit number. The IP address of a communication module next to
CPU 1 (channel 1) is calculated as (2•nn+1) while the IP address of a communication module next to
CPU 2 (channel 2) is calculated as (2•nn+2). Valid resource names as example and corresponding IP
addresses are listed in Table 2.1.
Resource Name
IP Address ch1
IP Address ch2
Burner01
192.168.0.3
192.168.0.4
V40a__02
192.168.0.5
192.168.0.6
H41qX_04
192.168.0.9
192.168.0.10
vessel05
192.168.0.11
192.168.0.12
Table 2.1: Example of IP address calculation
Declaration of BUSCOM data:
Each variable of type “VAR” or “VAR GLOBAL“ which is listed in the variable list can be communicated
via the standard communication protocols of H41q/H51q (Modbus via RS-485, Modbus TCP, Profibus
DP and OPC DA). Binary variables can also be defined as “Events” and can be transmitted via OPC
A&E. These BUSCOM declarations are the same for all communication protocols so exchanging
protocols needs no additional effort besides exchange of the communication module if required.
The declaration of BUSCOM variables and events takes place in the Variable Declaration dialog which
is available through double clicking the desired variable or selection of the appropriate tab when
creating a new variable.
Figure 2.3: Declaration of BUSCOM variables and events
Boolean, Integer and Real variables can be declared as Export, Import or Import/Export beneath the
“BUSCOM” tab of the Variable Declaration dialog. If necessary you can also declare specific
addresses under which the data should be communicated. When not specified the variables
addresses are automatically assigned by ELOP II during compilation. As preparation for Modbus TCP
communication you should define fixed addresses to your communication variables to keep track of
your used communication address space.
4
Modbus TCP Communication HIMA H41q/H51q ↔ Emerson DeltaV
Note 1:
Variables defined as Import/Export use separate addresses for reading and for
writing, according to Modbus conventions. Thus an Import/Export variable reserves
twice as much memory space as an equivalent Export or Import variable.
Import/Export addresses must be projected in both (read and write) memory areas.
Boolean variables can be made an event by checking the Event check box beneath the “Event
handling” tab. Like with BUSCOM variables you can also declare specific addresses under which the
event should be communicated.
Note 2:
If you define a spare range of communication addresses it is not necessary to
download the H41q/H51q when adding new communication variables or events
instead you can proceed with a reload of the PES. You can achieve this by inserting a
dummy communication variable or event some addresses ahead of the actually used
range.
2.3. Configuration of DeltaV Hard- and Software
The necessary configuration of the DeltaV DCS for Modbus TCP communication consists of the
configuration of the ethernet communication module Mynah VIM, the simulated DeltaV serial cards
and of the take-over of the communicated data in the application software of the DeltaV control
modules.
2.3.1 VIM Configuration
The Mynah VIMs are installed next to the DeltaV 2-wide controller carrier on the left side. They are
mounted, together with a standard DeltaV power supply, on a separate 2-wide controller carrier.
Note 3:
If necessary due to mounting space restrictions the 2-wide DeltaV controller and VIM
carriers can be separated from the 8-wide DeltaV IO carriers by using extender sets
which separate the carriers by means of special signal cables and extender modules.
Two standard ethernet Layer 2 switches are used as network nodes for Modbus TCP communication
in the primary and secondary network. These switches are also certified for use with HIMA´s safe
communication via safeethernet to other H41q/H51q PES and they can also be used if additional
OPC DA or OPC A&E Servers need to be used.
Note 4:
The Mynah VIMs require the use of two switches as coupling devices for redundant
connections because the VIMs need a cross link cable between these switches
(marked in red in Figure 2.1) to carry out their redundancy replication. Also for a
redundant direct point-to-point connection (one DeltaV controller communicating to
one HIMA PES) crossed network cables cannot be used. Instead two switches and a
cross link cable between them are required.
5
Modbus TCP Communication HIMA H41q/H51q ↔ Emerson DeltaV
The configuration of the VIM is carried out with
Mynah’s “VIMNet Explorer” which is not necessary for
operation of the VIMs and can therefore be installed on
a separate computer which needn’t be permanently
connected to the communication network. When the
VIM needs to be configured initially or for expansion of
available Modbus TCP devices the VIMNet Explorer
must be connected via a Network Interface Card (NIC)
which must reside in the same network range like the
VIM itself. I.e. VIM host address 192.168.0.241 is only
accessible from 192.168.0.x when the NICs netmask is
255.255.255.0. Keep this fact in mind when you
encounter connection problems between VIMNet
Explorer and the VIM.
When the VIMNet Explorer is initially started the tree
consists just of the area “VIMNET” and the underlying
“I/O Net” similar to the DeltaV Explorer’s view. The
initial configuration of the VIM to be ready for Modbus
TCP communication requires the following seven
steps:
Figure 2.4: VIMNet Explorer Tree
1. Add a controller to which the VIM should be assigned using the context menu of I/O Net. Use the
same name like in DeltaV Explorer to simplify identification of corresponding structures.
2. Add a VIM below the newly created controller using the controller’s context menu.
3. Configure the VIM’s properties according to Figure 2.5 to be of type “I/O VIM – Modbus TCP”,
select redundancy if necessary. Enter the appropriate IP addresses and subnet masks.
Figure 2.5: VIM Properties
4. Add a new Modbus device below the desired serial card. The device must be defined in VIMNet
Explorer and DeltaV Explorer whereas the communication data (datasets) are only defined in the
DeltaV Explorer.
5. Configure the device properties according to Figure 2.6 with Device Address and primary and
secondary IP address of the H41q/H51q. The used Port should be set to 502 and the Number of
Simultaneous Messages must be set to 1. For a simplex connection you need to set to “Simplex
Device” and use just one IP address. A redundant connection can be set to “Redundancy with
Switching IP” (which means the active VIM stays active when a connection failure to it’s active
slave occurs and it just uses the secondary IP address via the cross link cable) or to “Redundancy
with No Switching IP” (which in turn means the master also switches when a connection failure to
it’s active slave occurs; this is the normal behaviour of the DeltaV redundant serial card).
6
Modbus TCP Communication HIMA H41q/H51q ↔ Emerson DeltaV
Figure 2.6: VIM Device Properties
Note 5:
HIMA’s ethernet communication module F 8627X replies until firmware revision 4.14
with device address 255, regardless of its actual device address being set via DIP
switches to the CPU. The DeltaV Modbus master should therefore be configured for
this address because it would otherwise not accept protocols with this reply address.
6. Have a look at the area “Decommissioned VIMs” in VIMNet Explorer. You should be able to see
the appropriate number of decommissioned VIMs if your network is correctly connected to the
VIMs. Now you can commission the VIMs using the commission dialog via the configured VIM’s
context menus or via drag-and-drop of the decommissioned VIMs onto the configured VIM. Use
the identify function of the commissioning dialog to keep track of assigning the correct VIM for
primary and secondary module.
7. As a last step upload the configuration to the VIMs using the context menu and the “VIM
Configuration Upload” command. Be sure to save your VIMs configuration to be able to use the
VIMs diagnosis or to change the configuration starting from the saved point.
Note 6:
When you have problems finding the decommissioned VIMs disconnect them from
their power supply, the network and their carrier. Keep them disconnected for
approximately 30 seconds and then reinstall them (the same procedure like with not
unassigned DeltaV controllers).
For further troubleshooting information refer to [5].
2.3.2 DeltaV Serial Card Configuration
The configuration of the simulated DeltaV serial cards is nearly the same like with standard serial
cards. Only the device data type and the special data information differs for some data types. You also
need to have one serial port license for each simulated serial port you use.
The serial card configuration starts with the port configuration. Select the port used in VIMNet Explorer
for your first device and open the port properties. Set the configuration properties like shown in Figure
2.7.
7
Modbus TCP Communication HIMA H41q/H51q ↔ Emerson DeltaV
Figure 2.7: DeltaV Serial Port Properties
The “Retry Count” is recommended to be set to 3 so that delays in request processing on the slave
side do not provoke communication disruptions. The “Message Timeout” could be set to slower values
like the used 2000 ms but should be set to times well above the PESs cycle time. The configuration of
the third tab “Communication” is not necessary for Modbus TCP communication as this tab applies
only to serial communication.
The data for serial communication in DeltaV is organized in so called Datasets. One Dataset can
contain up to 100 values (50 values for real data). One serial card port can handle up to 16 datasets in
up to 16 devices (meaning 16 devices with each one dataset up to one device with 16 datasets). Each
serial card offers two ports. One pair of VIMs supports in sum four redundant or eight simplex
simulated serial cards therefore amounting to 12,800 respectively 25,600 data values which could be
theoretically be imported to or exported out of DeltaV.
Figure 2.8: Dataset Properties
8
Modbus TCP Communication HIMA H41q/H51q ↔ Emerson DeltaV
As an example the dataset configuration for output of real values is shown in Figure 2.8. Using the
output read back option on the general tab requires definition the corresponding variables in the
H41q/H51q PES as “Import/Export”. The dataset is assigned a dataset tag with which it can be
browsed out of the application logic of the DeltaV control modules.
The demonstration application on which this Application Note is based utilizes reading and writing
communication data as Boolean, unsigned integer and real values. The necessary settings for these
data types in the datasets are shown in
Data Type
DeltaV Data Type
Device Data Type
Boolean
Unsigned Integer
Real
Boolean with status
16 bit uint w/Status
Floating point with status
0
3
3
Special Data
Data 1
Data 2
0
0
0
0
1
2
Table 2.2: Dataset Configuration settings
2.3.3 Application Software Configuration
Modbus TCP communication data can be referenced for input or output in DeltaV control modules via
external
reference
parameters.
When
browsed
the
reference
path
looks
like:
“TCP_REAL_OUT01/R307”. The first part of the reference before the slash is the tag name while the
latter part describes the register address.
Note 7:
There is an offset of one register address between H41q/H51q and DeltaV. The
register number in a reference path like “TCP_REAL_OUT01/R307” connects to the
register address 306 in H41q/H51q. However the “Data start address” on the PLC tab
of the dataset properties refers to the correct address (see Figure 2.8) but the first
created register within this dataset gets address 307.
This communication data can as well be referenced directly in analogue (AI) or discrete (DI) input
blocks.
Communication data also consumes I/O licenses in the DeltaV system. Therefore binary input and
output data should be bundled and unbundled to unsigned integer variables in DeltaV using “Binary
Fan In” and “Binary Fan Out” function blocks like shown in Figure 2.9.
Figure 2.9: Unbundling Binary Input Data
9
Modbus TCP Communication HIMA H41q/H51q ↔ Emerson DeltaV
These blocks can be imported as needed via the bulk import feature of DeltaV and than be copied
together in one control module for import and one control module for export of binary data.
2.4. Validation of Modbus TCP Communication
The Modbus TCP communication between the H41q/H51q PES and the DeltaV DCS is supervised
through the VIM Modbus TCP Master. The status changes are alarmed in the operator interface as
controller status change after approximately ten seconds of inactivity.
For safety critical data transfer from DCS to PES like maintenance override switches a watchdog
signal should be used for supervision of the communication. When the watchdog does not change all
set maintenance override switches should be released. The watchdog should be implemented as a
ramped unsigned integer variable to avoid malfunction through under sampling which could occur with
binary signals.
The DeltaV Diagnostic Application and also the Mynah Diagnostic Application offer diagnostic support
for troubleshooting like signal status, online signal values and communication counter. For more
information about diagnostic support refer to [4] and [5].
Note 8:
When a Modbus TCP communication failure occurs the status of the simulated serial
cards in DeltaV Diagnosis change to “Bad” displayed with a yellow question mark.
After restoring communication it could be necessary to clear the fault using the “Clear
Saved Fault Information” option in the context menu of a simulated serial card in
DeltaV Diagnosis.
3.
Summary
Modbus TCP communication between HIMA PES and the DeltaV DCS is an alternative to serial
Modbus RTU communication via RS-485 or Profibus DP communication. The advantages of the
described communication becomes effective for:
•
Network layouts with several communication masters in one single network (due to multi
master capability)
•
Network layouts with larger numbers of HIMA PES as communication slaves (due to the large
possible data volume of the VIMs)
•
Larger data volumes to be transferred from one or several HIMA PES to a single DeltaV
controller (due to faster speed [2 – 3 times faster than Modbus RTU] and lower susceptibility
of communication cycle times to increasing data volumes)
•
Network layouts where simplicity in connecting devices is preferred (due to the ability of
integrating all HIMA PES communication in one redundant ethernet)
For other applications where the above mentioned advantages do not apply Profibus DP (fast and
inexpensive but non-redundant and volume-limited) or Modbus RTU (inexpensive but slower and more
volume-limited) are still viable alternatives.
10
Modbus TCP Communication HIMA H41q/H51q ↔ Emerson DeltaV
4.
Recommended Literature
[1] HIMA Programmable Systems
“The H41q and H51q System Families, Catalogue”
HIMA GmbH + Co. KG Bruehl, Germany, 2007
[2] HIMA Programmable Systems
“The H41q and H51q System Families
Datasheets for Central Modules F 8650X, F 8651X, F 8652X, F 8653X”
HIMA GmbH + Co. KG Bruehl, Germany, 2007
[3] HIMA Programmable Systems
“The H41q and H51q System Families
Datasheet for Module F 8627X”
HIMA GmbH + Co. KG Bruehl, Germany, 2007
[4] DeltaV Books Online
Fisher-Rosemount Systems, Houston, USA, 2006
[5] User Manual
“Modbus TCP Master Driver for DeltaV Virtual I/O Module”
Mynah Technologies, 2006
[6] HIMA Communication Test Report:
HIQuad-DeltaV Modbus TCP V. 1.0
HIMA GmbH + Co. KG, Bruehl, Germany, 2007
11
Modbus TCP Communication HIMA H41q/H51q ↔ Emerson DeltaV
5.
Document Revision and Release History
Revison: Contents / Changes:
12
Release Date:
1.00
Initial Release with redundant Modbus TCP connection between HIMA
F 8627X (SW: V4.14) and Mynah VIM (SW: V3.6.3).
2007-02-13
1.01
Minor improvements of graphically faulty embedded pictures.
2007-07-27
HIMA Paul Hildebrandt GmbH + Co KG
Industrial Automation
PO-Box 1261 68777 Brühl, Germany
Phone: +49 (6202) 709-0 Fax: +49 (6202) 709-107
Email: info@hima.com Internet: www.hima.com
© by HIMA Paul Hildebrandt GmbH + Co KG
HIMA
... The safe decision