100% found this document useful (1 vote)
642 views248 pages

Communication Guide, Tricon v9.6 PDF

Uploaded by

Mohamed Amine
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
100% found this document useful (1 vote)
642 views248 pages

Communication Guide, Tricon v9.6 PDF

Uploaded by

Mohamed Amine
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 248

Tricon

Version 9.6

Communication Guide

Triconex
An Invensys Company
Information in this document is subject to change without notice. Companies,
names and data used in examples herein are fictitious unless otherwise noted. No
part of this document may be reproduced or transmitted in any form or by any
means, electronic or mechanical, for any purpose, without the express written
permission of Triconex.

©2002 Triconex. All Rights Reserved.

Pentium is a registered trademark of Intel Corporation.


IBM is a registered trademark of International Business Machines Corporation.
Microsoft, Windows, and Windows NT are registered trademarks of Microsoft
Corporation.
Modbus is a registered trademark of Modicon Corporation.
Crystal Reports is a registered trademark of Seagate Software Company, Inc.
Triconex is a registered trademark of Invensys Systems, Inc. in the USA and other
countries.
Cause and Effect Matrix Programming Language Editor (CEMPLE), TriStation
1131, TriStation MSW, Tricon, and Trident are trademarks of Invensys Systems,
Inc. in the USA and other countries.
All other brands or product names may be trademarks or registered trademarks of
their respective owners.

Document No. 9720088-001


Printed in the United States of America.
CONTENTS

Preface .................................................................................................................. xiii


How This Guide is Organized ...................................................................... xiii
Related Documentation .............................................................................. xiv
How to Contact Triconex ............................................................................. xv
Requesting Technical Support ................................................................... xv
Gathering Supporting Documentation ...................................................... xv
Contacting Triconex Technical Support .................................................. xvi
Telephone ........................................................................................ xvi
Fax ................................................................................................... xvi
E-mail ............................................................................................... xvi
Training ........................................................................................................ xvii

Chapter 1 Introduction .................................................................................. 1


Overview ......................................................................................................... 2
TriStation Communication .......................................................................... 2
TSAA Client/Server Communication .......................................................... 3
Triconex OPC Server .......................................................................... 3
Triconex DDE Server .......................................................................... 3
Peer-to-Peer Communication .................................................................... 3
Modbus Communication ............................................................................ 4
Triconex Time Synchronization .................................................................. 4
Trimble GPS Time Synchronization ........................................................... 4
Centronics Interface for Printing ................................................................ 5
Module Capabilities and Usage .................................................................... 6
Ethernet Port Connections ......................................................................... 6

Chapter 2 Communication Hardware ........................................................... 7


Overview ......................................................................................................... 8
Triconex Products .......................................................................................... 8
Connection Accessories ............................................................................ 9
Modbus Cables and Adapter ............................................................... 9
Network Hardware Accessory Kit ........................................................ 9
Twisted-Pair Cable ............................................................................ 10

Tricon Communication Guide


iv

Standard Cable Lengths ................................................................... 10


Cables from Other Manufacturers ..................................................... 10
Other Communication Devices ................................................................ 11
Chassis and Module Selection ................................................................... 12
Connecting Ethernet Devices ..................................................................... 13
Converting from 10Base2 to Faster Media .............................................. 13
Redundant Devices ...................................................................................... 15
Redundancy for TriStation and SOE Recorder ....................................... 16
Testing for Hardware Failures ................................................................. 16
Centronics Interface for Printing ................................................................ 16

Chapter 3 TriStation Communication ........................................................ 17


Overview ....................................................................................................... 18
Installing a Network Adapter Card ............................................................. 19
Installing Protocols ...................................................................................... 20
Connecting TriStation to the Tricon Controller ........................................ 21
Connecting TriStation to an EICM Serial Port ......................................... 21
Configuring a Serial Port for TriStation ............................................. 21
Connecting the Serial Cable ............................................................. 23
Connecting TriStation to an Ethernet Port ............................................... 24
Setting the Controller Node Number ....................................................... 26
Setting Switches on the ACM ........................................................... 26
Setting Switches on the NCM .................................................................. 28
Changing the Node Number ............................................................. 30
Installing TriStation ..................................................................................... 31
Checking for Proper Installation .............................................................. 33
Configuring the TriStation Port .................................................................. 34
Serial Port Connection ............................................................................ 34
Ethernet Port Connection ........................................................................ 36
Aliases and Tagnames ................................................................................ 39
System Aliases for Tricon Status ............................................................ 39
Write Access by External Devices ............................................................. 40
Scan Time Considerations .......................................................................... 41
Maintaining a Positive Scan Surplus ....................................................... 41
Rules for Download All ................................................................................ 42
Diagnostic Monitoring ................................................................................. 42

Tricon Communication Guide


v

Chapter 4 TSAA Client/Server Communication ........................................ 45


Overview ....................................................................................................... 46
Configuring Ethernet Ports in TriStation ................................................... 48
Redundant Mode ............................................................................... 49
Used .................................................................................................. 49
Privilege ............................................................................................. 49
TCP/IP Address ................................................................................. 49
TCP/IP Subnet Mask ......................................................................... 50
Time Synchronization ........................................................................ 50
Installed ............................................................................................. 51
Privilege ............................................................................................. 51
TCP/IP Address ................................................................................. 52
TCP/IP Subnet Mask ......................................................................... 52
Time Synchronization ........................................................................ 52
Setting the IP Address ............................................................................. 53
Method 1—Using a Default IP Address ............................................. 54
Method 2—Using a RARP Server to Get an IP Address ................... 55
Method 3—Using an EICM Serial Port .............................................. 56
DDE Server for Triconex .............................................................................. 57
Installing Triconex DDE Server ................................................................ 58
Uninstalling Triconex DDE Server ........................................................... 59
Configuring the DDE Server Application .................................................. 59
Configuring Triconex Host Information .................................................... 60
Configuring Server Properties for 802.2 Protocol (Tricon Only) .............. 64
Server Poll Rate (MS) ....................................................................... 64
LLC Buffer Size ................................................................................. 64
LLC SAP ............................................................................................ 65
Testing a TCP/IP Connection .................................................................. 65
Configuration Requirements for DDE Network Redundancy ................... 65
Using TCP/IP Protocol ...................................................................... 66
Using 802.2 Protocol (Tricon Only) ................................................... 67
Requesting Data with a DDE Client Application ...................................... 68
Requesting Network Status ..................................................................... 69
Monitoring Responses from the Controller .............................................. 69
Changing View Options ..................................................................... 69
DDE Menu Commands ............................................................................ 70
OPC Server for Triconex .............................................................................. 71
Redundant Configuration ......................................................................... 75
Adjusting System Time ............................................................................ 75
Other OPC Products .................................................................................... 75
OPC Data Manager ................................................................................. 75
OPC Redundancy Broker ........................................................................ 76

Tricon Communication Guide


vi

Chapter 5 Peer-to-Peer Communication ................................................... 77


Overview ....................................................................................................... 78
Configuring Peer-to-Peer Ports in TriStation ............................................ 80
Allocating Memory for Sends and Receives ............................................. 82
Adding Sends and Receives to Programs ................................................. 83
Send and Receive Function Blocks ......................................................... 83
Sample Send and Receive Pair .............................................................. 84
Estimating Data Transfer Time ................................................................... 85
Restrictions on Data Transmission Speed ................................................ 88
Rules for Downloading ................................................................................ 88
Monitoring Peer-to-Peer Communication .................................................. 89
Status of Communication Paths .............................................................. 89
Status of NET1 Ports ............................................................................... 89
Sample Peer-to-Peer Programs .................................................................. 90
Fast Send to One Controller .................................................................... 90
Sending Data Every Second to One Controller ....................................... 90
Sending Data Only When Requested ..................................................... 90
Fast Send of Safety-Critical Data ............................................................ 91
Sample Timing Calculations ............................................................. 92

Chapter 6 Modbus Communication ........................................................... 93


Overview ....................................................................................................... 94
Physical Features ........................................................................................ 95
Topology Options .................................................................................... 95
Point-to-Point Connection ................................................................. 95
Multi-Point Connection ...................................................................... 96
Physical Media Rules .............................................................................. 96
Hardware Handshake Rules ................................................................... 96
Valid Configurations ................................................................................ 97
Configuring Serial Ports in TriStation ........................................................ 98
Specifying Electrical Interfaces ............................................................... 98
Selecting Properties in TriStation ............................................................ 99
Port Selection .................................................................................. 100
Protocol ........................................................................................... 100
Slave Address ................................................................................. 100
Baud Rate ....................................................................................... 101
Data Bits (ASCII or RTU) ................................................................ 101
Stop Bits .......................................................................................... 101
Parity ............................................................................................... 101

Tricon Communication Guide


vii

Handshake ...................................................................................... 102


Modbus Range ................................................................................ 102
Setting Signal Delays for Hardware Handshake .................................... 103
Examples ......................................................................................... 103
Programming for Tricon Masters .............................................................. 105
Function Blocks for Communicating with Non-Triconex Slaves ............. 106
Function Blocks for Communicating with Trident Slaves ....................... 107
Function Blocks for Communicating with Tricon Slaves ........................ 107
Sample Modbus Read Function Block ................................................... 108
Sample Modbus Write Function Block ................................................... 109
Processing of Modbus Function Blocks ................................................. 110
Programming for Tricon Slaves ................................................................ 111
Using Special Aliases to Transmit Real Values ..................................... 111
Reading Real Values ....................................................................... 111
Writing Real Values ......................................................................... 112
Table of Special Aliases .................................................................. 112
IEEE Standard Format .................................................................... 114
Transmitting Real Values with Scaling ................................................... 115
Scaling Integers to REALs (Modbus Writes) ................................... 115
Scaling REALs to Integers (Modbus Reads) ................................... 116
Procedure for Scaling ...................................................................... 118
Sample Modbus Programs ........................................................................ 120
Reading and Writing DINT Data ............................................................ 120
Reading and Writing REAL Data ........................................................... 120
Reading and Writing BOOL Data ........................................................... 120
Setting Time-out and Retry Values ........................................................ 121
Controlling the Flow of Data ................................................................... 121
Counting Values and Verifying Outputs ................................................. 121

Chapter 7 Related Communication Features .......................................... 123


Overview ..................................................................................................... 124
Time Synchronization ................................................................................ 125
Master Node in a Network ..................................................................... 125
Time Adjustments from External Devices .............................................. 126
GPS Time Adjustments .......................................................................... 127
Redundant Configuration ................................................................ 127
Combination Schemes ........................................................................... 129
Guidelines for Networks .................................................................. 129
Setting the Controller Clock ................................................................... 130
Setting Time Synchronization Properties ............................................... 131

Tricon Communication Guide


viii

Parallel Printing .......................................................................................... 133


Printing and Scan Time ......................................................................... 133
Printing Setup ........................................................................................ 134
Installing Your Printer ............................................................................ 134
Configuring a Parallel Port for Printing .................................................. 135
Using Print Function Blocks .................................................................. 136
Specifying the Parallel Port ............................................................. 136

Appendix A EICM Capabilities ..................................................................... 137


EICM Operation .......................................................................................... 138
Message Processing ............................................................................. 138
Physical Description .................................................................................. 141
Serial Port Specifications ...................................................................... 141
Parallel Port Specifications .................................................................... 141
Port Numbers and Connections ............................................................ 143
EICM Communication Indicators ........................................................... 143
Protocols Supported .............................................................................. 144

Appendix B NCM and NCMG Capabilities .................................................. 145


NCM Operation ........................................................................................... 146
Message Processing ............................................................................. 147
Physical Description .................................................................................. 149
Specifications ........................................................................................ 149
Front Panels .......................................................................................... 149
Communication Indicators ..................................................................... 151
Protocols Supported .............................................................................. 151

Appendix C TSAA Protocol ......................................................................... 153


Overview ..................................................................................................... 154
Differences Between Tricon and Trident ............................................... 154
Bit and Byte Ordering ............................................................................ 154
Little-Endian Ordering ..................................................................... 154
Big-Endian Ordering ....................................................................... 155
Symbol Table Information (Trident Only) .............................................. 155
Structure of Trident Symbol Table .................................................. 156
Finding a Tagname (Trident Only) ........................................................ 157
TSAA Messages ......................................................................................... 157
Message Format ................................................................................... 157
Frame Header ................................................................................. 158
TRICON_DATA (Type 1) ....................................................................... 161
Data_Hdr ......................................................................................... 161
Bin Headers .................................................................................... 162

Tricon Communication Guide


ix

TRICON_DATA_REQ (Type 2) ............................................................ 164


Data_Req_Hdr ................................................................................ 164
WRITE_TRICON_DATA (Type 3) .......................................................... 166
Write_Hdr ........................................................................................ 166
Write_Data ...................................................................................... 167
WRITE_TRICON_DATA_RSP (Type 4) ................................................ 167
responseCode ................................................................................. 168
subReason ...................................................................................... 168
READ_TRICON_CLOCK (Type 5) ........................................................ 168
READ_TRICON_CLOCK_RSP (Type 6) ............................................... 168
Read_Clock_Rsp ............................................................................ 168
SET_TRICON_CLOCK (Type 7) ........................................................... 170
Set_Clock ........................................................................................ 170
SET_TRICON_CLOCK_RSP (Type 8) .................................................. 171
Set_Clock_Rsp ................................................................................ 171
ADJUST_TRICON_CLOCK (Type 9) .................................................... 172
Adjust_Clock ................................................................................... 172
ADJUST_TRICON_CLOCK_RSP (Type 10) ......................................... 173
Adjust_Clock_Rsp ........................................................................... 173
READ_TRICON_DATA (Type 11) ......................................................... 174
Read_Hdr ........................................................................................ 174
Read_Data ...................................................................................... 174
READ_TRICON_RSP (Type 12) ........................................................... 175
Read_Data_Rsp .............................................................................. 176
Data ................................................................................................. 177
TRICON_SOE_REQ (Type 13) ............................................................. 177
Frame_Hdr ...................................................................................... 177
TRICON_SOE_RSP (Type 14) .............................................................. 178
Soe_Rsp .......................................................................................... 179
entry (SOE Data Entry) ................................................................... 180
entry (SOE Time Stamp) ................................................................. 182
TRICON_CPSTATUS_REQ (Type 15) .................................................. 183
TRICON_CPSTATUS_RSP (Type 16) .................................................. 184
TRICON_SOE_DATAAVAIL (Type 17) ................................................. 184
SoeDataAvail ................................................................................... 184
TRICON_GET_SYMBOL_REQ (Type 22, Trident Only) ....................... 186
Tricon_Get_Symbol ......................................................................... 186
TRICON_GET_SYMBOL_RSP (Type 23, Trident Only) ....................... 187
Symbol_Table_Rsp ......................................................................... 187
Response Codes ........................................................................................ 189

Tricon Communication Guide


x

Appendix D Modbus Protocol ..................................................................... 191


Overview ..................................................................................................... 192
Estimating Message Response Time ....................................................... 193
Transmission Time ................................................................................ 193
Processing Time for Reads and Writes ................................................. 193
Setting Time-out and Retry Values ....................................................... 194
Communication Modes ............................................................................. 194
RTU Mode ............................................................................................. 194
ASCII Mode ........................................................................................... 194
Modbus Functions ..................................................................................... 195
Modbus Message Formats .................................................................... 196
Message Header Field (ASCII Only) ............................................... 196
Station Address Field ...................................................................... 196
Function Code Field ........................................................................ 196
Data Fields ...................................................................................... 197
Checksum Field (CRC or LRC) ....................................................... 197
CR Field and LF Field (ASCII Only) ................................................ 198
Sample Query and Response Messages ....................................... 199
Modbus Message Lengths .............................................................. 200
Read Coil Status Function (Function 01) .............................................. 201
Query Format .................................................................................. 201
Response Format ........................................................................... 201
Read Input Status (Function 02) ........................................................... 202
Query Format .................................................................................. 202
Response Format ........................................................................... 202
Read Holding Registers (Function Code 03) ......................................... 203
Query Format .................................................................................. 203
Response Format ........................................................................... 203
Read Input Registers (Function Code 04) ............................................. 204
Query Format .................................................................................. 204
Response Format ........................................................................... 204
Force Single Coil (Function Code 05) ................................................... 205
Query Format .................................................................................. 205
Response Format ........................................................................... 205
Preset Single Register (Function Code 06) ........................................... 206
Query Format .................................................................................. 206
Response Format ........................................................................... 206
Read Exception Status (Function Code 07) .......................................... 207
Query Format .................................................................................. 207
Response Format ........................................................................... 207
Loop-Back Diagnostic Test (Function 08) ............................................. 208
Query Format .................................................................................. 208
Response Format ........................................................................... 208

Tricon Communication Guide


xi

Force Multiple Coils (Function Code 15) ................................................ 209


Query Format .................................................................................. 209
Response Format ............................................................................ 209
Preset Multiple Registers (Function Code 16) ....................................... 210
Query Format .................................................................................. 210
Response Format ............................................................................ 210
Performance Considerations .................................................................... 211
Transmission Errors and Exception Conditions ..................................... 212
Transmission Errors ............................................................................... 212
Exception Conditions ............................................................................. 213
Exception Responses ............................................................................ 214
Sample Query ................................................................................. 214
Sample Exception Response .......................................................... 214
Exception Response Codes ............................................................ 215

Glossary ............................................................................................................... 217

Index ..................................................................................................................... 223

Tricon Communication Guide


xii

Tricon Communication Guide


Preface

The Tricon Communication Guide describes the types of communication available


with the Tricon controller and the capabilities of its communication modules.

How This Guide is Organized


The Tricon Communication Guide is organized as follows:
• Chapter 1, “Introduction” — Describes the types of communication
available with a Tricon controller and the capabilities of its communication
modules.
• Chapter 2, “Communication Hardware” — Discusses the hardware used to
enable Tricon controllers for communication with each other and with
external devices.
• Chapter 3, “TriStation Communication” — Explains how to connect a
TriStation computer to a Tricon controller, set controls for write access,
maintain a positive scan surplus, and monitor an application.
• Chapter 4, “TSAA Client/Server Communication”— Explains how to
configure Ethernet ports in your TriStation project and how to configure
and use the Triconex OPC Server and DDE Server client/server programs
which use the TSAA messaging protocol.
• Chapter 5, “Peer-to-Peer Communication”— Explains how to set up
controllers for communication in a Peer-to-Peer network.
• Chapter 6, “Modbus Communication”— Explains how to set up a controller
for communication as a Modbus master, slave, or both.
• Chapter 7, “Related Communication Features” — Describes the time
synchronization and parallel printing features of a Tricon controller.
• Appendix A, “EICM Capabilities” — Describes EICM operation and
physical communication interfaces.

Tricon Communication Guide


xiv Related Documentation

• Appendix B, “NCM and NCMG Capabilities” — Describes NCM operation


and physical communication interfaces.
• Appendix C, “TSAA Protocol” — Provides a programmer’s reference for
TSAA, which is a Triconex protocol used for client/server applications.
• Appendix D, “Modbus Protocol” — Provides detailed information about the
Modbus protocol that can be used by EICM serial ports.
• “Glossary” — Provides definitions of terms used in this guide.

Related Documentation
The following Triconex books contain related information:
• Planning and Installation Guide
• TriStation 1131 Developer’s Guide
• Safety Considerations Guide
• SOE Recorder User’s Guide

Tricon Communication Guide


How to Contact Triconex xv

How to Contact Triconex


You can obtain sales information and technical support for Triconex products from
any regional customer center or from corporate headquarters. To locate regional
centers, go to the Global Locator page on the Triconex Web site at:
http://www.triconex.com.

Requesting Technical Support


You can obtain technical support from any regional center and from offices in
Irvine, California and Houston, Texas. If you require emergency or immediate
response and are not a participant in the System Maintenance Program (SMP), you
may incur a charge. After-hours technical support is billed at the rate specified in
the current Customer Satisfaction Price List.
Requests for support are prioritized as follows:
• Emergency requests are given the highest priority
• Requests from SMP participants and customers with purchase order or
charge card authorization are given next priority
• All other requests are handled on a time-available basis

Gathering Supporting Documentation


Before contacting corporate technical support, please try to solve the problem by
referring to the Triconex documentation. If you are unable to solve the problem,
obtain the following information:
• Error messages and other indications of the problem
• Sequence of actions leading to the problem
• Actions taken after the problem occurred
• If the problem involves a Triconex controller, obtain the model numbers and
revision levels for all affected items. This information can be found on the
modules, in the System Log Book, or on the TriStation Diagnostic Panel.
• If the problem involves software, obtain the product version number by
selecting the About topic from the Help menu.

Tricon Communication Guide


xvi Requesting Technical Support

Contacting Triconex Technical Support


If possible, you should contact your regional customer center for assistance. If you
cannot contact your regional center, contact technical support for the type of
system you are using, either ESD systems or Turbomachinery systems.
Please include the following information in your message:
• Your name and your company name
• Your location (city, state, and country)
• Your phone number (area code and country code, if applicable)
• The time you called
• Whether this is an emergency

Note If you require emergency support and are not an SMP participant, please
have a purchase order or credit card available for billing.

Emergency calls are responded to on a 24-hour daily basis.

Telephone
Toll-free number 866-PHON IPS (866-746-6477) , or
Toll number 508-549-2424

Fax
Send your request to the Technical Support Manager.
Toll-free number 800-325-2134, or
Toll number 949-885-3375

E-mail
ips.csc@invensys.com

Tricon Communication Guide


Training xvii

Training
In addition to this documentation, Triconex offers in-house and on-site training.
For information on available courses, please contact your regional customer center.

Tricon Communication Guide


xviii

Tricon Communication Guide


CHAPTER 1

Introduction

This chapter describes the types of communication available with the Tricon
controller and the capabilities of its communication modules.
Topics include:
“Overview” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
“Module Capabilities and Usage” . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6

Tricon Communication Guide


2 Overview

Overview
Tricon controllers can communicate with other Triconex controllers and with
external devices by using ports on the following modules:.
• Advanced Communication Module (ACM)
• Enhanced Intelligent Communication Module (EICM)
• Network Communication Module (NCM)
• Network Communication Module with GPS Interface (NCMG)
The following table lists the protocols available with each module.

Supported Protocols ACM EICM NCM NCMG


TriStation ✓ ✓ ✓ ✓
TSAA Client/Server ✓ ✓ ✓
Peer-to-Peer ✓ ✓
Modbus Slave ✓
Modbus Master ✓
Modbus Master/Slave ✓
Triconex Time Synchronization ✓ ✓ ✓
Trimble GPS Time Synchronization ✓
Centronics Interface for Printing ✓

Note Throughout this manual, the name NCM is generally used to represent both
the NCM and the NCMG modules.

For guidelines on using Triconex communication protocols in safety-critical


applications, see the Safety Considerations Guide.

TriStation Communication
TriStation protocol enables communication between a TriStation PC and a
Triconex controller. The TriStation PC can be connected to the Tricon controller

Tricon Communication Guide


Overview 3

through an Ethernet port on the ACM or NCM, or through a serial port on the
EICM.
The TriStation 1131 Developer’s Workbench is used to develop and monitor
applications which run in a Triconex controller. The workbench is compliant with
Part 3 of the IEC 61131 International Standard for Programmable Controllers.

TSAA Client/Server Communication


TSAA protocol enables client/server communication between Triconex controllers
and PCs. Two client/server programs called OPC Server and DDE Server use
TSAA protocol to exchange data with Triconex controllers. For most process
control networks, using OPC Server or DDE Server is the best solution, however,
TSAA protocol can be used to write other programs for accessing Triconex points.

Triconex OPC Server


OPC Server is a client/server program, available from Triconex or Matrikon, which
allows OPC clients to have read and write access to Triconex program variables.
OPC stands for OLE for Process Control, which is a standard set of non-
proprietary interfaces used to develop client/server programs. For more
information, see “OPC Server for Triconex” on page 71.

Triconex DDE Server


DDE Server is a client/server program that allows DDE clients to have read and
write access to Triconex program variables. Using DDE Server, any Windows
application that supports DDE (Dynamic Data Exchange) protocol, such as
Microsoft Excel, can access Triconex variables. For more information, see “DDE
Server for Triconex” on page 57.

Peer-to-Peer Communication
Triconex Peer-to-Peer protocol allows multiple Triconex controllers in a closed
network to exchange safety-critical data. The controllers exchange data by using
Send and Receive function blocks in their TriStation applications. The controllers
can synchronize their time with the master node (the one with the lowest node
number) or with an external device, such as a DCS.

Chapter 1 Introduction
4 Overview

Modbus Communication
Modbus is an industry-standard master/slave protocol that is traditionally used for
energy management, transfer line control, pipeline monitoring, and other industrial
processes. A Tricon controller with an EICM can operate as a Modbus master,
slave, or both. A DCS typically acts as the master while the Tricon controller acts
as a slave. The master can also be an operator workstation or other device that is
programmed to support Modbus devices.
The Tricon controller has serial ports on the EICM that provide many options for
communication with your Modbus devices. Each EICM port can operate in a point-
to-point configuration with a single Modbus device or a multi-point configuration
with several Modbus devices connected to a serial link.

Triconex Time Synchronization


The Time Synchronization protocol allows networks of Tricon and Trident
controllers to be synchronized with each other, and optionally, with external
devices.
Triconex controllers on a network are typically synchronized with the master node
(the controller with the lowest node number). If desired, the master node can accept
time adjustments from an external device, such as the Foxboro DCS or an OPC
client, so that the external device time prevails for all Triconex controllers on the
network. Triconex Time Synchronization can be used with external devices that
use TSAA or Modbus protocol.
If networked controllers are collecting event data for system maintenance and
shutdown analysis, Triconex Time Synchronization must be used to ensure
accurate time-stamping of events.

Trimble GPS Time Synchronization


A Tricon controller with an NCMG can receive time adjustments from the Global
Positioning System (GPS) by using the Trimble Acutime 2000 Synchronization
Kit. The kit must be connected to an RS-232 port on the NCMG for communication
using the Trimble Standard Interface Protocol.
The NCMG can act as a master node in a network of Triconex controllers and can
accept GPS time adjustments to synchronize all Triconex controllers on the
network with GPS time.

Tricon Communication Guide


Overview 5

Centronics Interface for Printing


A Tricon controller can send brief ASCII text messages to a printer that is
connected to a parallel port on the EICM. These messages are typically used for
alarms, status, and maintenance. You must use a printer which is compatible with
the Centronics interface provided by the EICM parallel port.

Chapter 1 Introduction
6 Module Capabilities and Usage

Module Capabilities and Usage


The following table lists the types of communication that can be done using ports
on the ACM, EICM, NCM, and NCMG.

Type of Communication ACM EICM NCM NCMG


Modbus Communication with Tricon as Not available 4 serial ports Not available Not available
Master or Combination Master/Slave
TriStation Communication using a Serial Not available 1 serial port Not available Not available
Port
TriStation Communication using an 1 Ethernet Not available 1 Ethernet 1 Ethernet
Ethernet NET2 Port port port port
TSAA Client/Server Communication 1 Ethernet Not available 1 Ethernet 1 Ethernet
port port port
Peer-to-Peer Communication using an Not available Not available 1 Peer-to- 1 Peer-to-
Ethernet NET1 port Peer port Peer port
Triconex Time Synchronization using an 1 Ethernet Not available 1 Ethernet 1 Ethernet
Ethernet NET1 or NET2 Port port port port
Trimble GPS Time Synchronization using Not available Not available Not available 1 RS-232
an RS-232 Port port
Centronics Printing using a Parallel Port Not available 1 parallel Not available Not available
port

Ethernet Port Connections


On each ACM or NCM, the Ethernet port called NET2 can be used for
communication with multiple devices on a network, such as a TriStation PC and a
client workstation. On an ACM, the Ethernet port called NET1 must be used as an
interface to the I/A Series Nodebus. On an NCM, the Ethernet port called NET1
must be used for Peer-to-Peer communication. For more information, see
“Configuring Ethernet Ports in TriStation” on page 48.

Tricon Communication Guide


CHAPTER 2

Communication Hardware

This chapter discusses the hardware you can select to enable Tricon controllers for
communication with other Triconex controllers and with external devices.
Topics include:
“Overview” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
“Triconex Products” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
“Chassis and Module Selection” . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
“Connecting Ethernet Devices” . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
“Redundant Devices” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
“Centronics Interface for Printing” . . . . . . . . . . . . . . . . . . . . . . . . . . 16

Tricon Communication Guide


8 Overview

Overview
This chapter describes Triconex products and other devices you must purchase to
enable a Tricon controller for communication.
As you select devices, redundancy might be one of your initial concerns. Typical
configurations include redundant modules, cables, and workstations, but can
include other devices that are listed on page 11.
Triconex supplies communication cables, but does not supply PCs, hubs, media
converters, or printers. You must purchase these devices from manufacturers such
as Black Box Network Services and Hewlett-Packard. Specifications for PCs to use
with Triconex software products are on page 16.
If you need assistance with selecting communication hardware, please contact your
Network Administrator or Information Technology department.

Triconex Products
Triconex communication products include:
• Tricon controllers with an ACM, EICM, NCM, or SMM installed in each
• Trident controllers with at least one CM installed in each
• TriStation 1131 Developer’s Workbench
• Triconex DDE Server program
• Triconex OPC Server program
• Triconex SOE Recorder program
• Connectivity accessories such as cables and adapters

Tricon Communication Guide


Triconex Products 9

Connection Accessories
This section describes connection accessories available from Triconex.

Modbus Cables and Adapter


Triconex Modbus cables are typically used to connect a serial port on the EICM to
the TriStation PC. Because EICM serial ports are DB-25-pin connectors and the
COM port on the TriStation PC is usually a DB-9-pin connector, Triconex provides
a 25-pin to 9-pin adapter. Part numbers for these accessories are as follows.

Accessory Part Number


Modbus Cable with two 25-pin connectors 4000015-0xx1
Modbus Cable with one 25-pin connector 4000016-0xx
and one 9-pin connector
DB-25-pin to DB-9-pin adapter 1420102-001
1. “xx” in a part number indicates that you can specify a non-standard cable length. For
more information, see “Standard Cable Lengths” on page 10.

Note You should supply your own cables for connecting an EICM serial port to
a Modbus master or slave based on the requirements of the Modbus device.

Network Hardware Accessory Kit


The Network Hardware Accessory Kit (model 7600-3) can be used for the
following connection needs.

From To
NET2 port on ACM or NCM TriStation PC
Media or protocol converter connected to
a faster Ethernet network
Peer-to-Peer port on NCM Peer-to-Peer port on NCM

Chapter 2 Communication Hardware


10 Triconex Products

The accessory kit includes:


• One 3Com network interface card (model 3C503)1
• One 10Base2 coaxial cable (can be ordered separately as part number
1600010-006)
• Two BNC T-connectors
• Two 50-ohm terminators with straps
NET2 ports on the Tricon controller must use 10Base2 coaxial cables, but these
cables can be connected to media converters which allow the Tricon to
communicate with other Ethernet media. For more information, see “Connecting
Ethernet Devices” on page 13.

Twisted-Pair Cable
The twisted-pair cable (part number 1600045-020) can be used to connect a
TriStation PC with RJ-45 connectors to an Ethernet network. In this configuration,
the NET2 port on an ACM or NCM (which uses a BNC connector) is connected to
the network through a media converter. The twisted-pair cable is a Category 5
shielded cable which complies with the 10BaseT and 100BaseTX standards. For
more information, see “Connecting TriStation to an Ethernet Port” on page 24.

Standard Cable Lengths


The standard length for Modbus, coaxial, and twisted-pair cables is 6 meters (20
feet), but you can order other lengths if necessary.

Cables from Other Manufacturers


If desired, you can purchase communication cables from other manufacturers such
as Black Box Network Services. Examples of cables you might need to purchase
from other manufacturers are:
• RS-232 Modem Cable
• RS-232 Null Modem Cable

1. Not required for use with Peer-to-Peer ports.

Tricon Communication Guide


Triconex Products 11

Other Communication Devices


Other communication devices you might need include:
• PCs for DDE Server, OPC Server, SOE Recorder, and TriStation
• Centronics-compatible printers
• Hubs
• Media converters
• Routers
You must buy hubs and converters from other manufacturers because Triconex
does not supply them. Typical hubs and converters can auto-negotiate for speeds
of 10 or 100 megabits. Follow the manufacturer’s instructions for installation and
configuration.

! WARNING
In hazardous indoor locations, apparatus used with Triconex communication
modules must be FM certified for Class I, Division II.

Chapter 2 Communication Hardware


12 Chassis and Module Selection

Chassis and Module Selection


A Tricon controller must have a Main Chassis and can have up to 14 Expansion or
Remote Expansion (RXM) Chassis. The following rules apply to the selection of
communication modules:
• A TriStation PC must be connected to an ACM, EICM or NCM, which
means that one of these modules must be included in each Tricon
configuration.
• One logical slot is available for ACM, EICM, and NCM modules. Pairs of
these modules can be installed in the left and right positions of one logical
slot.
• The COM slot can be configured for an EICM or NCM only.
• All types of communication modules must be housed in the Main Chassis or
in Chassis #2.
• If communication modules are housed in Chassis #2, this chassis must be
connected directly to the Main Chassis using I/O Comm Cables (Model
9001) rather than standard I/O Bus Cables.
• Chassis #2 can be an I/O Expansion Chassis or a Primary RXM Chassis.
For detailed guidelines on chassis configuration and power limitations, see the
Tricon Planning and Installation Guide.

Tricon Communication Guide


Connecting Ethernet Devices 13

Connecting Ethernet Devices


NET2 Ethernet ports on ACM and NCM modules have BNC connectors that
require 10Base2 coaxial cables, limiting data transmission speed to 10 megabits
per second. For this type of connection, Triconex provides a Network Hardware
Accessory Kit which includes a 10Base2 coaxial cable, BNC T-connectors, and
50-ohm terminators for unused connectors. For more information, see “Network
Hardware Accessory Kit” on page 9.

Tricon Controller

Network Adapter Card


with BNC Connector

10Base2
N
Coaxial (ThinNet) Cable
M M M C BNC Connector
P P P M on NET2
A B C 1

TriStation PC

You must use or terminate the BNC connectors on all NET2 ports of the Tricon
controller. To terminate an unused BNC connector, you can attach a T-connector
with 50-ohm terminators on each end to produce a 25-ohm parallel resistance. If
necessary, ask your Network Administrator about other termination methods.

Converting from 10Base2 to Faster Media


If an ACM or NCM needs to communicate with a 10BaseT, 100BaseTX, or faster
Ethernet device, you can connect it to a media converter which is connected to
faster devices or a faster network.

▼ To convert from 10Base2 to faster Ethernet media:

1 To each end of a 10Base2 cable, attach a BNC T-connector and a terminator.


2 Attach one of the T-connectors to a BNC connector on a NET2 port of an ACM
or NCM.
An NCM NET2 port is used as an example in the following diagram.
3 Attach the other T-connector to a BNC connector on the media converter.

Chapter 2 Communication Hardware


14 Connecting Ethernet Devices

In the following diagram, the Ethernet device uses a 10BaseT or 100BaseTX


twisted-pair cable.
4 Attach one end of the twisted-pair cable to an RJ-45 connector on the media
converter.
5 Attach the other end of the twisted-pair cable to an RJ-45 connector on a
compatible Ethernet device.

Coaxial
Cable

Side View
of BNC Connector T-Connector
on NCM Front Panel

Terminator
Cap

To Ethernet
Network

Network Adapter Card


with RJ-45 Connector

10BaseT or 100BaseTX
Twisted-Pair Cable
10Base2
Coaxial (ThinNet) Cable
N
M MM C
BNC Connector
P P P M
on NET2
A B C 1

BNC RJ-45
Tricon Controller Connector Media Connector Ethernet Device
Converter

Tricon Communication Guide


Redundant Devices 15

Redundant Devices
To ensure continuous operation of a Triconex system if a hardware failure occurs,
you can create a redundant configuration. Redundant devices can include modules,
workstations, cables, hubs, media converters, printers, and power sources.
A redundant device operates in parallel with a primary device so that, if the primary
device fails, the redundant device is easily or automatically placed into service. A
typical configuration includes two NCMs with redundant cables connected to one
port on each module. The redundant modules protect against internal faults, and the
redundant cables protect against cable breakage. To protect against network fail-
ures, you can connect a primary workstation to one network and a redundant work-
station to another network, as shown in the following diagram.

Redundant OPC Server


NOTE: For Tricon, you must use
NET2 ports for Ethernet
connections. For Trident, you can
use NET1 or NET2 ports.

Trident Controller

CM
To CM
NET2
Ports

To NCM To NCM
NET2 NET2
Ports Ports

N N
NET 2 N N
NET 2
M M M C C M M M C C
P P P MM P P P MM
A B C 1 2 A B C 1 2

Tricon Controller MP Tricon Controller

Primary Ethernet Network To DCS

TriStation PC SOE PC Primary OPC Server

Chapter 2 Communication Hardware


16 Centronics Interface for Printing

Redundancy for TriStation and SOE Recorder


For TriStation and SOE Recorder, you can maintain redundant workstations and
place them into service manually if the primary workstations fail. An efficient
practice is to install the necessary programs in advance. For TriStation, you must
install the TriStation 1131 Developer’s Workbench and store a backup copy of
your project on the redundant workstation. For SOE, you must install and configure
the SOE Recorder program on the redundant workstation.

Testing for Hardware Failures


A redundancy scheme is effective only if the primary and redundant devices are
connected and operational. Routing your redundant cables over different paths
through your facility reduces the possibility of cable damage. To test for hardware
failures, you must use the TR_PEER_STATUS and TR_PORT_STATUS function
blocks in your TriStation application. The following Triconex communication
products provide another layer of redundancy testing:
• The Peer-to-Peer and Time Synchronization protocols transmit messages
over both the primary and redundant networks at all times, discarding
duplicate messages when both networks are operational.
• The OPC Server and DDE Server programs communicate with the Triconex
controller over the primary network and switch to the redundant network if
the primary device fails.
If you are using Modbus protocol or a customized TSAA program, you must
develop the additional layer of redundancy testing on your own.

Centronics Interface for Printing


The Tricon controller supports Centronics-compatible printing through a parallel
port of the EICM (port 5). You must include an EICM in the controller if you are
going to use a printer.

Tricon Communication Guide


CHAPTER 3

TriStation Communication

This chapter explains how to connect a TriStation PC to a Tricon controller,


configure the connection in your TriStation project, and use TriStation for
diagnostic monitoring.
Topics include:
“Overview” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
“Installing a Network Adapter Card” . . . . . . . . . . . . . . . . . . . . . . . . 19
“Installing Protocols” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
“Connecting TriStation to the Tricon Controller” . . . . . . . . . . . . . . 21
“Installing TriStation” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
“Configuring the TriStation Port” . . . . . . . . . . . . . . . . . . . . . . . . . . . 34
“Aliases and Tagnames” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39
“Write Access by External Devices” . . . . . . . . . . . . . . . . . . . . . . . . 40
“Scan Time Considerations” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41
“Rules for Download All” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42
“Diagnostic Monitoring” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42

Tricon Communication Guide


18 Overview

Overview
This chapter describes the tasks you must do to connect a TriStation PC to a Tricon
controller. TriStation must be used to program and operate the controller, and to
establish the controller address on an Ethernet network. TriStation can also be used
to monitor applications that are running in Tricon controllers.
The initial task is to set up a PC with the required hardware and communication
protocols. This includes installing a network adapter card and TCP/IP protocol if
you plan to connect the TriStation PC to an Ethernet port on the ACM or NCM.
The next task is to install the TriStation 1131 Developer’s Workbench on a PC
using the setup program provided by Triconex. You can then physically connect
the TriStation PC to a serial port on the EICM or to a NET2 Ethernet port on the
ACM or NCM. If using Ethernet, you can connect the PC directly to a NET2 port,
or to a media converter that is connected to a NET2 port.
To directly connect the TriStation PC to the Tricon controller, you must install a
network adapter card with a BNC connector in the PC and use a 10Base2 coaxial
cable. If your network adapter card does not have a BNC connector, you must use
an appropriate cable and a media converter. You can buy communication cables
from Triconex or from other manufacturers. You must buy media converters from
other manufacturers.
An essential task of an Ethernet physical connection is to set the node number of
the controller using the rotary switches on the ACM or NCM module. The physical
node number must match the node number that you set in your TriStation project.
After the physical connection tasks are completed, you must logically configure the
connection in the TriStation project. This includes specifying which port the
communication cable is connected to and the address of the Tricon controller. After
completing the physical and logical connection tasks, you are ready to download,
run, and monitor the TriStation project.

Tricon Communication Guide


Installing a Network Adapter Card 19

Installing a Network Adapter Card


This section explains how to install a network adapter card on the PC to be used for
the TriStation 1131 Developer’s Workbench.

▼ To install a network adapter card:


1 Install the network adapter card by following the manufacturer’s instructions.
Do not change the factory default settings on the network adapter.
2 If the network adapter card has a BNC connector, you can connect it directly
connect it to a NET2 port.
If the network adapter card does not have a BNC connector, you must connect
it to a media converter which is connected to a NET2 port.
For instructions, see “Connecting TriStation to the Tricon Controller” on
page 21.
3 Run the diagnostics provided with the network adapter card according to the
manufacturer’s instructions.

Chapter 3 TriStation Communication


20 Installing Protocols

Installing Protocols
If you plan to connect the TriStation PC to a NET2 Ethernet port, you must install
the TCP/IP protocol on the PC. If you plan to connect the TriStation PC to a serial
port, you do not need to install a protocol on the PC.
You cannot download a TriStation project to a Tricon controller unless the correct
protocol is installed on the TriStation PC.
If you need help with installing a protocol, ask your Network Administrator.

▼ To install the TCP/IP protocol on a Windows NT PC:


1 From the Start menu, select Settings, then select Control Panel.
2 In the Control Panel window, double-click the Network icon.
3 In the Network dialog box, select the Protocols tab.
If TCP/IP is already listed in the Network Protocols window, it is already
installed on the PC. You can skip steps 4 though 7.
4 Under Network Protocols, double-click the Add button.
5 In the Select Network Protocols dialog box, select TCP/IP Protocol from the
list.
6 Click OK if you want Windows NT to copy files from a specified location, such
as a network drive.
7 Click the Have Disk button if you are going to insert a disk that contains the
required files.

▼ To install the TCP/IP protocol on a Windows 2000 PC:


1 From the Start menu, select Settings, then select Network and Dial-up
Connections.
2 Right-click the network connection for which you want to install TCP/IP, then
click Properties.
3 On the Networking tab, verify whether Internet Protocol (TCP/IP) is already in
the list of installed components. If so, you can skip steps 4 through 6.
4 To install the protocol, click Install; click Protocol, then click Add.
5 In the Network Protocol dialog box, click Internet Protocol (TCP/IP), then click
OK.
6 Verify that the Internet Protocol (TCP/IP) check box is selected, then click OK.

Tricon Communication Guide


Connecting TriStation to the Tricon Controller 21

Connecting TriStation to the Tricon Controller


The TriStation PC must be physically connected to the Tricon controller in one of
the following ways:
• Direct connection from an EICM serial port to a COM port on the
TriStation PC
• Direct connection from a NET2 port on the ACM or NCM to a network
adapter card in the TriStation PC
• Connection from a NET2 port on the ACM or NCM to a media converter
which is connected to the TriStation PC
This section describes the required hardware and provides instructions for these
connections.

Connecting TriStation to an EICM Serial Port


If you have installed an EICM in the Tricon controller, you can connect the
TriStation PC to a serial port on the EICM. A point-to-point (direct) connection is
the only option. Before you make the physical connection, the serial port used for
TriStation must be configured.
The following accessories, available from Triconex, are suitable for connecting an
EICM serial port to a TriStation PC.

Connect From Connect To Accessory Part/Model


4000015-0xx
Serial port on COM port on Modbus Cable
4000016-0xx
EICM TriStation PC
25-pin to 9-pin adapter 1420102-001

For more information, see “Connection Accessories” on page 9.

Configuring a Serial Port for TriStation


The TriStation port must be configured with a switch block located on the side of
the EICM. Switches 7 and 8 are used to specify which port is used for TriStation
(the other switches are used for other purposes). In the following diagram, switches
7 and 8 are set to Off (the default, factory-configured settings) to specify port 4 for
TriStation.

Chapter 3 TriStation Communication


22 Connecting TriStation to the Tricon Controller

Switches 7 and 8 are set to Off,


specifying Port 4 for TriStation.

1 2 3 4 5 6 7 8
O
N
Port 1

Port 2

Port 3

Port 4

Port 5

Triconex strongly recommends using port 4 for TriStation. If port 4 fails, use the
following procedure to configure another port for TriStation connection.

▼ To configure port 1, 2, or 3 for TriStation:


1 Remove the EICM from its slot in the Tricon chassis.
2 Use the following table to reset switches 7 and 8 for the desired port.

TriStation on Port Switch 7 Switch 8


1 Off On
2 On Off
3 On On

3 Replace the EICM in its slot. You can now connect the serial cable from the
EICM port to the TriStation PC.

Tricon Communication Guide


Connecting TriStation to the Tricon Controller 23

Note Switches 1, 2, 3, and 4 are used to select the RS-232 or RS-422 transceiver
mode for serial ports 1, 2, 3, and 4 respectively. For more information, see
“Configuring Serial Ports in TriStation” on page 98.

Connecting the Serial Cable


To connect an EICM serial port to the TriStation PC, you can use a Triconex serial
cable which has a 25-pin connector on each end. If the COM port on the PC has a
9-pin connector, you can use a Triconex 25-pin to 9-pin adapter. If you need other
parts, you can purchase them from another manufacturer.

▼ To connect TriStation to an EICM serial port:


1 Attach one end of the serial cable to a serial port on the EICM. This is typically
port 4 (the default for the TriStation connection), as shown in the following
diagram.
2 Attach the 9-pin adapter to a COM port on the TriStation PC. The COM port is
typically numbered COM1, COM2, COM3, or COM4.
3 Attach the other end of the serial cable to the 9-pin adapter on the COM port.

Tricon Controller

25-Pin Connector
with 9-Pin Adapter

To Modbus Devices COM Port

EICM Port 4
(25-Pin Connector)

MM M
Serial
P P P Cable
A B C

TriStation PC

Chapter 3 TriStation Communication


24 Connecting TriStation to the Tricon Controller

Connecting TriStation to an Ethernet Port


To establish an Ethernet connection to the TriStation PC, you must connect the
network adapter card in the PC to a NET2 port on an ACM or NCM. If the network
card has a BNC connector, you can make a direct connection using a 10Base2
coaxial cable. Triconex provides an accessory kit which includes a 10Base2
coaxial cable, BNC T-connectors, and 50-ohm terminators for unused connectors.
If the network adapter card in the PC does not have a BNC connector, you must use
an appropriate cable—such as a twisted-pair cable—and a media converter.
The following accessories, available from Triconex, are suitable for connecting an
Ethernet port to a TriStation PC. For more information, see “Connection
Accessories” on page 9 and “Connecting Ethernet Devices” on page 13.

Connect From Connect To Accessory Part/Model


Network adapter card in Network Hardware
7600-3
TriStation PC Accessory Kit (10Base2)
NET2 port on ACM or NCM
Media converter on network Twisted-Pair Cable
1600045-020
that is faster than 10Base2 (10BaseT or 100BaseTX)

▼ To directly connect TriStation to a NET2 port:


1 To each end of a 10Base2 cable, attach a BNC T-connector and a terminator.
2 Attach one of the T-connectors to a BNC connector on NET2 of the ACM or
NCM. An NCM is used as an example in the following diagram.
3 Attach the other T-connector to the BNC connector on the network adapter card
in the TriStation PC.

Tricon Controller

Network Adapter Card


with BNC Connector

10Base2
N
Coaxial (ThinNet) Cable
M M M C BNC Connector
P P P M on NET2
A B C 1

TriStation PC

Tricon Communication Guide


Connecting TriStation to the Tricon Controller 25

Note You must use or terminate the BNC connectors on all ACMs and NCMs
which are installed in the Tricon controller. To terminate an unused BNC
connector, you can attach a T-connector with 50-ohm terminators on each end to
produce a 25-ohm parallel resistance. Ask your Network Administrator for
information about other termination methods.

▼ To connect TriStation to NET2 using a media converter:


1 To each end of a 10Base2 cable, attach a BNC T-connector and a terminator.
2 Attach one of the T-connectors to a BNC connector on the NET2 port.
3 Attach the other T-connector to a BNC connector on the media converter.
4 For the TriStation PC, you can use a 10BaseT or 100BaseTX twisted-pair cable
for faster communication, as shown in the diagram.
5 Attach one end of the twisted-pair cable to an RJ-45 connector on the network
adapter card in the TriStation PC.
6 Attach the other end of the twisted-pair cable to an RJ-45 connector on the
media converter.

To Ethernet
Tricon Controller Network

Network Adapter Card


with RJ-45 Connector

BNC Connector
10BaseT or 100BaseT
on NET2 Twisted-Pair Cable
10Base2
Coaxial (ThinNet) Cable
N
M M M C
P P P M
A B C 1

BNC RJ-45
Connector Media or Protocol Connector TriStation PC
Converter

Chapter 3 TriStation Communication


26 Connecting TriStation to the Tricon Controller

Setting the Controller Node Number


The node number of a Tricon controller physically identifies it on a network. Each
controller must have a unique address which is determined during network
planning. The node number is physically set on the ACM or NCM and it must
match the node number that is specified in your TriStation project.
Before installing the ACM or NCM in the controller, you must set the node number
with rotary switches on the module. If your Tricon system includes two ACMs or
NCMs, you must set the switches on both modules to the same node number.

Setting Switches on the ACM


On the ACM, the node number is set with rotary switches which are located on the
front panel of the module. The top switch and the bottom switch specify the node
number in hexadecimal notation.
In the following diagram, the top switch is set to 1 and the bottom switch is set to
zero to specify the default (factory-configured) node number which is 1.

Rotary Switches
for Trinode Address

E 0
2

Top Switch C 4

A 6
8 5678
1 23 4

9 ABC

DEF0

5678
12 34

9 ABC

DEF0

E 0
2

Bottom Switch C 4

A 6
8

Front Panel with Ports


and Status Indicators

Tricon Communication Guide


Connecting TriStation to the Tricon Controller 27

Use the following table to set the rotary switches on the ACM for node numbers 1
through 32.

Top Bottom Top Bottom


Trinode Trinode
Switch Switch Switch Switch
1 0 1 17 1 1
2 0 2 18 1 2
3 0 3 19 1 3
4 0 4 20 1 4
5 0 5 21 1 5
6 0 6 22 1 6
7 0 7 23 1 7
8 0 8 24 1 8
9 0 9 25 1 9
10 0 A 26 1 A
11 0 B 27 1 B
12 0 C 28 1 C
13 0 D 29 1 D
14 0 E 30 1 E
15 0 F 31 1 F
16 1 0 32 2 0

After setting the rotary switches on the ACM, you must specify the node number
in your TriStation project. For instructions, see “Ethernet Port Connection” on
page 36.

Chapter 3 TriStation Communication


28 Connecting TriStation to the Tricon Controller

Setting Switches on the NCM


On the NCM, the node number is set with rotary switches which are located on the
top of the module. Switches 1 and 2 specify the node number in hexadecimal
notation. Switches 3 through 8 are set to zero because they are unused. In the
following diagram, Switch 1 is set to 1 and Switch 2 is set to zero to specify the
default (factory-configured) node number which is 1.

Rotary switches on top of NCM, set to 1 in hexadecimal notation.


1 2 3 4 5 6 7 8
0 0 0 0 0 0 0 0
E 2 E 2 E 2 E 2 E 2 E 2 E 2 E 2

C 4 C 4 C 4 C 4 C 4 C 4 C 4 C 4

A 6 A 6 A 6 A 6 A 6 A 6 A 6 A 6
8 8 8 8 8 8 8 8

Tricon Communication Guide


Connecting TriStation to the Tricon Controller 29

Use the following table to set the rotary switches on the NCM for node numbers 1
through 32. For all addresses, switches 3 through 8 must be set to zero, so they are
not included in the table.

Switch Switch Switch Switch


Trinode Trinode
1 2 1 2
1 1 0 17 1 1
2 2 0 18 2 1
3 3 0 19 3 1
4 4 0 20 4 1
5 5 0 21 5 1
6 6 0 22 6 1
7 7 0 23 7 1
8 8 0 24 8 1
9 9 0 25 9 1
10 A 0 26 A 1
11 B 0 27 B 1
12 C 0 28 C 1
13 D 0 29 D 1
14 E 0 30 E 1
15 F 0 31 F 1
16 0 1 32 0 2

After setting the rotary switches on the NCM, you must specify the node number
in your TriStation project. For instructions, see “Ethernet Port Connection” on
page 36.

Chapter 3 TriStation Communication


30 Connecting TriStation to the Tricon Controller

Changing the Node Number


Although Triconex does not recommend it, you can change the node number
switches on an ACM or NCM that has already been installed. Be prepared to do a
Download All, and use one of the following procedures.

▼ If the Tricon controller includes an EICM:


1 Disconnect the TriStation cable from the NET2 port of the ACM or NCM and
remove the module from its slot.
2 In the TriStation project, change the node number on the Tricon System
Configuration screen of the Configuration window.
3 Connect the TriStation PC to an EICM serial port (using a serial cable).
4 Go to the Control Panel and use the Download All command.
5 Change the switches on the module to match the node number you specified on
the Tricon System Configuration screen.
6 Re-install the module in its slot.

▼ If the Tricon controller does not include an EICM:


1 Prepare for a complete shutdown.
2 Remove all three Main Processors and the ACM or NCM from their respective
slots. Wait 60 seconds, then re-install the Main Processors.
3 Change the switches on the ACM or NCM.
4 Re-install the ACM or NCM in its slot.
5 In the TriStation project, change the node number on the Tricon System
Configuration screen of the Configuration window.
6 Wait for the Pass indicators on the Main Processors and on the ACM or NCM
to illuminate.
7 Go to the Control Panel and use the Download All command.

Tricon Communication Guide


Installing TriStation 31

Installing TriStation
The setup program provided by Triconex installs all the components of the
TriStation 1131 Developer’s Workbench on a PC.
To install TriStation, you must log on to Windows as an administrator or have
administrator privileges.

Note If you have previously installed TriStation on your PC, you must uninstall
it before installing this version. For instructions, see page 32.

▼ To install TriStation:
1 Close all open applications.
2 Insert the TriStation 1131 CD in the CD-ROM drive.
If the installation routine starts automatically, go to Step 6 and follow the
instructions in the Installation Wizard dialog boxes. Otherwise, complete steps
3 through 5.
3 From the Start menu, select Settings, then Control Panel.
4 Double-click the Add/Remove Programs icon.
5 On the Install/Uninstall tab of the Add/Remove Programs Properties dialog box,
click the Install button.
6 Follow the instructions described in the Installation Wizard dialog boxes.
Triconex recommends installing TriStation in the default destination folder,
C:\Program Files\Triconex, designated by the Installation Wizard.
7 To restart your PC when the installation has finished, select Yes.
To restart your PC later, select No.
You must restart your PC before running TriStation.
8 To complete the installation of TriStation, click Finish.

TriStation is now installed on your PC. Start TriStation by selecting


Triconex:\TriStation 1131 on the Windows Programs menu.

Chapter 3 TriStation Communication


32 Installing TriStation

▼ To uninstall a previous version of TriStation:


1 From the Start menu, select Settings, then Control Panel.
2 Double-click the Add/Remove Programs icon.
3 In the Add/Remove Programs dialog box, scroll down the list of installed
programs and select TriStation 1131.
4 Click the Add/Remove button.
The Confirm File Deletion dialog box asks you to confirm the deletion of the
selected application and all its components.
5 Click Yes to complete the removal of the previous version of TriStation.
The Remove Programs from Your Computer dialog box displays as the
previous version of TriStation and all its associated program files, folders,
directories, and registries are removed.

Note If you previously created projects and saved them in the default directory,
C:\Program Files\Triconex\TS1131\Projects\, the uninstall program does not
remove them.

6 Click the Yes or Yes to All button if the Remove Shared File dialog box asks
about removing unused DLLs.
7 When the “Uninstall successfully completed” message is displayed, click OK.
8 When the uninstall is finished, click OK to close the Add/Remove Programs
Properties dialog box.
You are now ready to install TriStation. For instructions, see “To install
TriStation:” on page 31.

Tricon Communication Guide


Installing TriStation 33

Checking for Proper Installation


Before you download an application to the Tricon controller, you can run the
TriStation Install Check program to verify that TriStation is correctly installed on
your PC and no associated files are corrupted. Running TS1131 Install Check is
required for safety-critical applications. For more information, see the Safety
Considerations Guide.

▼ To verify the installation of TriStation:


1 From the Start menu, select Programs.
2 In the Triconex folder, double-click the TS1131 Install Check program.
This standalone program was installed on your hard drive when you installed
TriStation.
3 Click the Validate button.
4 Click the Display Details button for more information, as shown below:

Click here to display details

Chapter 3 TriStation Communication


34 Configuring the TriStation Port

Configuring the TriStation Port


After physically connecting your TriStation cable to a serial or Ethernet port, you
must logically configure the port in the TriStation project. The following
procedures explain how to specify which port the cable is connected to and the
address of the Tricon controller.

Serial Port Connection


▼ To configure an EICM serial port connection to the TriStation PC:
1 Open the TriStation project. From the Project menu, select Project Options and
go to the Communications tab.
2 Under Default Connection, select Tricon Serial Port and select one of the
following options depending on which COM port of the TriStation PC is
physically connected to the serial cable:
• COM1
• COM2
• COM3
• COM4
The Network TCP/IP Addresses area of the dialog box is not related to a serial
port connection.
3 From the Tricon menu, select Edit Configuration.
4 Under Tricon System Configuration in the tree structure, click the Hardware
Allocation icon to display the chassis which are configured for this system.
5 Click the chassis which contains the EICM. This must be either the Main
Chassis or Chassis 2.
6 Double-click the EICM icon to open the Properties dialog box, and click Setup
to display the EICM Configuration dialog box.
7 Under Port Selection, select the port to which the serial cable for the TriStation
connection is physically attached.
An example is Port 4, the default port for TriStation connection. For more
information, see “Configuring a Serial Port for TriStation” on page 21.

Tricon Communication Guide


Configuring the TriStation Port 35

8 Under Protocol in the Port Configuration area, select TriStation 1131 from the
list. There are no other options associated with the TriStation 1131 protocol.
9 To logically connect your TriStation project to an EICM serial port, go to the
Control Panel and select the Connect command on the Commands menu.
Ensure that the option called Tricon Serial Port and the correct COM port are
selected, as shown in the following screen.

Chapter 3 TriStation Communication


36 Configuring the TriStation Port

Ethernet Port Connection


To logically configure a NET2 port on the ACM or NCM for connection to the
TriStation PC, you need an IP address for the Tricon controller. Before starting the
following procedure, get the necessary IP addresses from your Network
Administrator or Information Technology department. For more information, see
“Setting the IP Address” on page 53 and “DDE Server for Triconex” on page 57.

▼ To configure an Ethernet port connection to TriStation:


1 Open your TriStation project. From the Project menu, select Project Options
and go to the Communications tab.
2 Under Default Connection, select Tricon Network.
3 Under Network TCP/IP Addresses, select the node number (TRINODE<node
number) of your Tricon controller and click the Modify button.
This address must match the rotary switch setting on the ACM or NCM. For
more information, see “Setting the Controller Node Number” on page 26.
4 In the Tricon TCP/IP Address dialog box, specify the following properties.

Properties Description
Node Name A user-defined name used to identify the Tricon controller. Can
be any name that is less than or equal to eight characters.
Node Number The number specified by the rotary switches on the ACM or
NCM.
TCP/IP Address The physical address of a Tricon controller on an Ethernet
(IP address) network. If your network topology permits, use a Triconex
default. If not, get an IP address from your Network
Administrator or Information Technology department. If you
cannot get the address from one of these sources, see “Setting the
IP Address” on page 53.

5 From the Tricon menu, select Edit Configuration.


6 Under Tricon System Configuration in the tree structure, click the Hardware
Allocation icon to display the chassis which are configured for this system.
7 Click the chassis which contains the ACM or NCM. This must be either the
Main Chassis or Chassis 2.
8 Double-click the ACM or NCM icon to open the Properties dialog box, and
click Setup to display the module configuration dialog box. The following

Tricon Communication Guide


Configuring the TriStation Port 37

screen shows the NCM Configuration dialog box which is similar to the ACM
Configuration dialog box.

9 Select properties for the Left Slot or Right Slot area, depending on which
module is connected to the TriStation PC.
For the NCM, select the Installed property. For the ACM, select the Used
property.
Ignore the Privilege property, which applies only to TSAA communication, not
TriStation. For more information, see “Configuring Ethernet Ports in
TriStation” on page 48.
10 For TCP/IP Address (dec), do one of the following tasks:
– If you are using a default node number, do not change this property
(leave blank).
– Type the TCP/IP address that identifies the controller on the network.
This must be the same address you entered in step 4.
11 For TCP/IP Subnet (hex), do not change the default setting which is eight
zeroes.
12 To logically connect your TriStation project to an ACM or NCM port, go to the
Control Panel and select the Connect command on the Commands menu.

Chapter 3 TriStation Communication


38 Configuring the TriStation Port

In the Connect To dialog box, ensure that the Tricon Network option is selected,
as shown in the following screen.

13 Click OK to save the configuration.

Tricon Communication Guide


Aliases and Tagnames 39

Aliases and Tagnames


When developing a TriStation project, you must uniquely identify each point
(global variable) by assigning a tagname and optionally, an alias. A tagname
usually corresponds to the physical tag (label) on the connected field device but can
correspond to a memory point. An alias is a five-digit numeric identifier which
defines the data type of a point and its location in the memory of the controller. To
have an alias, a variable must be Read Aliased or Read/Write Aliased.
External devices can access Triconex point values through tagnames or aliases,
depending on the protocol or application that is used.

Access by Access by
Protocol or Application
Tagname Alias
Modbus Master ✓
Modbus Slave ✓
Peer-to-Peer1 ✓
OPC Server, OPC Data Manager, and OPC Redundancy Broker ✓ ✓
DDE Server ✓
User-Written TSAA Application2 ✓ ✓
1. For Triconex controllers only.
2. TSAA provides a look-up table which supports both tagname and alias access.

For more information about accessing Tricon points, see the chapters and
appendices about TSAA, Peer-to-Peer, and Modbus in this guide. For details about
tagnames and aliases, see the TriStation 1131 Developer’s Guide.

System Aliases for Tricon Status


TriStation includes predefined system aliases which external devices can read to
obtain Tricon status information. The system aliases provide information about the
Tricon chassis, slots, Main Processors, communication modules, and system
performance. For more information, see the System Aliases Reference.

Chapter 3 TriStation Communication


40 Write Access by External Devices

Write Access by External Devices


External devices which use supported protocols can write to memory and output
points if you set controls in the TriStation configuration and program logic.
External devices cannot write to input points but can read input, memory, and
output points.
A TriStation application can allow general write access while protecting specific
points from write access through configuration settings. The following table
identifies the write access controls. For detailed instructions, see the TriStation
1131 Developer’s Guide.

Desired Action Controls That Must Be Set


Allow General Write Access The Tricon keyswitch must be physically set to the Remote
position. When Remote mode is active, the COM TX and COM RX
indicators on the Main Processors are lit as network data is
transmitted and received, and general write access is allowed.
Some points can be protected from write access even if general
write access is allowed. See other controls in this table.
Applies to TSAA (client/server) writes and Modbus writes.
Protect All Output Points from The Disable Remote Changes setting must be checked (in the
Writes Tricon System Configuration window of the Configuration editor).
The default setting is checked.
If checked, external devices cannot write to any output points no
matter what other write access controls are used.
Applies to TSAA (client/server) writes and Modbus writes.
Protect All Points from Open The Privilege for each NET2 port on an ACM or NCM must be set
Network Writes to Read. (This setting is in the NET2 area of the ACM or NCM
Configuration dialog box.) The default setting is Read.
If set to Read, an external device connected to a NET2 port on an
ACM or NCM cannot write to any points no matter what other write
access controls are used. For details, see “Configuring Ethernet
Ports in TriStation” on page 48.
Applies to TSAA (client/server) writes only.

Tricon Communication Guide


Scan Time Considerations 41

Scan Time Considerations


Scan time is the interval that is required for evaluations (scans) of your application
as it executes in the controller. Before downloading your TriStation project to the
controller, you should select a scan time which includes execution time for all
executable elements, including conditional statements and message processing
time for network communication. Message processing time includes TriStation and
Peer-to-Peer messages, TSAA writes, and Modbus writes.
The time it actually takes for the controller to complete a scan might be more or
less than the scan time you requested. If the time is less, your application has a
positive scan surplus which allows optimal communication speed. If the time is
more, your application has a negative scan surplus which could cause
communication errors. For more information, see the TriStation 1131 Developer’s
Guide.

Maintaining a Positive Scan Surplus


For effective communication, your TriStation application must maintain a positive
scan surplus at all times. Triconex recommends using a scan surplus which is at
least 10 percent of the actual scan time.

▼ To ensure a positive scan surplus, do the following:


1 Specify the desired scan time during TriStation configuration.
2 Download and run the application to establish the actual scan time.
3 View the system performance information in the Diagnostic Panel to determine
the scan surplus.
4 If the scan surplus is less than 10 percent of the actual scan time, use the Set
Scan Time command in the Control Panel to increase the scan time.
5 Use the Diagnostic Panel to verify that the scan surplus is at least 10 percent of
the actual scan time.
If you do a Download All after changing the scan time in the Control Panel,
TriStation will not use the changed scan time unless you specify it as a system
parameter of the Main Processors before downloading.

Chapter 3 TriStation Communication


42 Rules for Download All

! WARNING
In a Peer-to-Peer network, a scan surplus less than 10 percent could result in
communication errors.

Rules for Download All


You must use the Download All command in TriStation if you make any of these
changes to a Tricon controller or its TriStation application:
• Increase or decrease the maximum number of Send or Receive function
blocks for Peer-to-Peer communication
• Add an ACM or NCM to the Main Chassis or Chassis 2
• Delete an ACM or NCM from the Main Chassis or Chassis 2 (you can add
an ACM or NCM using the Download Change command)
• Change the node number of the controller, that is, the rotary switch
positions on the ACM or NCM and the node definition in the TriStation
project
For detailed information about downloading projects, see the TriStation 1131
Developer’s Guide.

Diagnostic Monitoring
You can monitor a TriStation project that is running in a Tricon controller using
any existing project or an empty project.

▼ To connect to a controller for diagnostic monitoring:


1 Start TriStation on a PC that is physically connected to the target Tricon
controller or to the network to which the target controller is connected.
2 Open an existing project or create a new project.
3 From the Project menu, select Project Options and go to the Communications
tab.
4 Under Default Connection, select Tricon Network.

Tricon Communication Guide


Diagnostic Monitoring 43

5 Under Network TCP/IP Addresses, find the node number (TRINODE<node


number>) of your Tricon controller.
This address must match the address of the Tricon controller that you intend to
monitor. For more information, see “Setting the Controller Node Number” on
page 26.
6 In the Tricon TCP/IP Address dialog box, specify the following properties.

Properties Description
Node Name The user-defined name that identifies the Tricon controller you
intend to monitor.
Node Number The number that identifies the Tricon controller you intend to
monitor.
TCP/IP Address The physical address of a Tricon controller on an Ethernet
(IP address) network. This could be a default or non-default address. If you do
not know the address, contact your Network Administrator or
Information Technology department.

7 From the Tricon menu, select the Tricon Diagnostic Panel command.
8 From the Commands menu, select the Connect command or use the Connect
tool on the toolbar.
9 In the Connect To dialog box, select the desired Tricon node. If your TriStation
PC is connected to an EICM, select a Tricon Serial Port option. If your
TriStation PC is connected to an ACM or NCM, select a Tricon Network option.
10 If the connection to the controller is successful, TriStation displays the alarm
state of the controller as well as performance and project information, as shown
in the following screen.

Chapter 3 TriStation Communication


44 Diagnostic Monitoring

If a chassis displays a red ALARM ON message, at least one of the modules in


the chassis is faulting.
11 To find out which modules or points are faulting, expand the Tricon System
Configuration tree and click the chassis number.

Tricon Communication Guide


CHAPTER 4

TSAA Client/Server Communication

This chapter explains how to configure Ethernet ports on the Tricon controller for
client/server communication and how to use client/server programs.
Topics include:
“Overview” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 46
“Configuring Ethernet Ports in TriStation” . . . . . . . . . . . . . . . . . . . . 48
“DDE Server for Triconex” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57
“OPC Server for Triconex” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 71
“Other OPC Products” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75

Tricon Communication Guide


46 Overview

Overview
Client/server communication with Triconex controllers can be done by using the
DDE Server and OPC Server programs, which use the Triconex System Access
Application (TSAA) protocol. For most process control networks, using DDE
Server or OPC Server is the best solution. However, TSAA protocol can be used to
write custom programs for accessing Triconex data, such as the following:
• Control (read/write) programs for operator workstations that need read
access to Triconex status and write access to Triconex data
• Monitor (read-only) programs such as a sequential events recorder or a
status display that collects and records Triconex data
For more information, see Appendix C, “TSAA Protocol.”

Tricon Controller Trident Controller Tricon Controller


CM

NET1

NET2 NET2
(NCM) NN NN
MM M CC MM M CC
P P P MM P P P MM
A B C 1 2 A B C 1 2

MP

Ethernet Network

To DCS

TriStation PC SOE PC DDE or OPC Server

Tricon Communication Guide


Overview 47

Programs that use TSAA to exchange information with a Tricon controller require
an ACM or an NCM. You can install a maximum of two ACMs and two NCMs in
a Tricon controller. You can physically connect one Ethernet port on each ACM or
NCM to an Ethernet network. Through one Ethernet port, the controller can
communicate with multiple devices on a network, such as a TriStation PC, a print
server, and a client workstation.
The Ethernet port on the ACM and NCM is called NET2 and it operates at 10
megabits per second. If you connect the ACM or NCM to a network that is faster
than 10 megabits per second, you must use a media converter with appropriate
cables.
In your TriStation project, you must configure each Ethernet port by selecting the
mode, access privilege, port type, IP address, and time synchronization properties.
Part of physically connecting an ACM or NCM port to a network is to set the IP
address of the port. The most convenient methods are to use the Triconex default
addresses or a Reverse ARP server. Other ways are discussed in this chapter.
After planning the physical functionality of your network, you should program
each TriStation project for write access from external devices. A project can allow
general write access while protecting specific points from write access through
configuration settings. For more information, see “Write Access by External
Devices” on page 40.

Chapter 4 TSAA Client/Server Communication


48 Configuring Ethernet Ports in TriStation

Configuring Ethernet Ports in TriStation


This section explains how to configure Ethernet ports on the ACM and NCM for
communication with external devices on an Ethernet network. Procedures for
setting the IP address are included.
For an Ethernet connection, a NET2 port on an ACM or NCM must be used. Tricon
supports NET2 connections using ACMs or NCMs, but not both. For example, if
you are using a NET2 port on an NCM for an Ethernet connection, you cannot use
the NET2 port on the ACM.

▼ To configure a NET2 port on the ACM:


1 Open your TriStation project and go to the Tricon Configuration editor.
2 Under System Configuration in the tree structure, click the Hardware Allocation
icon to display the modules that are configured for this project.
3 Double-click the ACM icon to open the Properties dialog box, and click Setup
to display the configuration properties, as shown below.

Tricon Communication Guide


Configuring Ethernet Ports in TriStation 49

4 In the NET2 - Left Slot and NET2 - Right Slot areas, specify the following
properties as needed.

Redundant Mode
The Redundant Mode property specifies whether the Right Slot area is available for
configuration. The default is not selected.

Used
The Used property specifies whether an ACM is installed in the left or right side of
a physical slot in the Tricon controller.

Privilege
The Privilege property specifies whether external devices connected to a NET2
port have Read or Read/Write access to Tricon points.
If set to Read, external devices cannot write to any points no matter what other
write access controls are used. This setting protects safety-critical points from
writes by external devices on an open network.
If set to Read/Write, external devices can write to points depending on the settings
of other write access controls.
The default setting is Read/Write.
The Privilege property must be used in conjunction with other write access
controls. For more information, see “Write Access by External Devices” on
page 40.

TCP/IP Address
The TCP/IP Address property specifies the IP address of the controller on a
network. If your network topology permits, use a Triconex default address. If not,
get an address from your Network Administrator or Information Technology
department. If you have two ACMs in a slot, you can give each module a different
IP address and connect it to a different Ethernet network or device. For more
information, see “Setting the IP Address” on page 53.

Chapter 4 TSAA Client/Server Communication


50 Configuring Ethernet Ports in TriStation

TCP/IP Subnet Mask


Do not change the default setting which is 00000000 (eight zeroes).

Time Synchronization
The Time Synchronization property specifies whether time synchronization is
used. The following types are available.

On NET1 Synchronizes the time with the Foxboro DCS which is


connected to NET1.
On NET2 Synchronizes the time with the master node in a Peer-to-Peer
network of Triconex controllers. Contact Triconex Technical
Support for assistance with this type of network.
None No time synchronization is performed through this module.

For more information, see “Time Synchronization” on page 125.

Tricon Communication Guide


Configuring Ethernet Ports in TriStation 51

▼ To configure a NET2 port on the NCM:


1 Open your TriStation project and go to the Tricon Configuration editor.
2 Under Tricon System Configuration in the tree structure, click the Hardware
Allocation icon to display the modules that are configured for this system.
3 Double-click the NCM icon to open the Properties dialog box, and click Setup
to display the configuration properties for the NCM, as shown below.

4 In the Left Slot and Right Slot areas, specify the following NET2 Port properties
as needed.

Installed
The Installed property specifies whether an NCM is installed in the left or right side
of a physical slot in the Tricon controller.

Privilege
The Privilege property specifies whether external devices connected to a NET2
port have Read or Read/Write access to Tricon points.

Chapter 4 TSAA Client/Server Communication


52 Configuring Ethernet Ports in TriStation

If set to Read, external devices cannot write to any points no matter what other
write access controls are used. This setting protects safety-critical points from
writes by external devices on an open network.
If set to Read/Write, external devices can write to points depending on the settings
of other write access controls.
The default is Read/Write.
The Privilege property must be used in conjunction with other write access
controls. For more information, see “Write Access by External Devices” on
page 40.

TCP/IP Address
The TCP/IP Address property specifies the IP address of the controller on a
network. If your network topology permits, use a Triconex default address. If not,
get an address from your Network Administrator or Information Technology
department. If you have two NCMs in a slot, you can give each module a different
IP address and connect it to a different Ethernet network or device. For more
information, see “Setting the IP Address” on page 53.

TCP/IP Subnet Mask


Do not change the default setting which is 00000000 (eight zeroes).

Time Synchronization
The Time Synchronization property specifies whether time synchronization is
used. The following types are available.

Properties Descriptions
Global Positioning System Select this property if you are using an NCMG and
Installed the Trimble Acutime 2000 Synchronization Kit to
synchronize the Tricon clock with the Global
Positioning System (GPS).
On NET1 enable time Select this property if you want to synchronize the
synchronization with Tricon Tricon clock with the master node (the controller
master node with the lowest node number) in a Peer-to-Peer
network.

Tricon Communication Guide


Configuring Ethernet Ports in TriStation 53

In a network of Triconex controllers which are synchronized with the master node,
the master node can be synchronized with an external device such as an OPC client
or the GPS. For more information, see “Time Synchronization” on page 125.

Setting the IP Address


To enable a Tricon controller for communication with network devices, you must
set the IP addresses of ACMs and NCMs on the network. If your network topology
permits the use of Triconex default IP addresses, the addresses are set on the
network when you download your TriStation project, assuming that the correct
node number and default IP addresses are specified in the project.
If you cannot use default IP addresses, there are other ways to set the IP addresses
of ACMs and NCMs on a network. All begin with asking your Network
Administrator for the intended IP addresses. The easiest way is to use a Reverse
ARP (RARP) server on your subnet that has been configured in advance with the
intended addresses. Other ways entail connecting the TriStation PC to an EICM
serial port, specifying IP addresses in TriStation dialog boxes, downloading the
TriStation project, then reconfiguring the physical connection.
All of the procedures for setting the IP address are based on the assumption that the
controller includes three MPs and at least one ACM or NCM with an Ethernet port
connected to a network. To use the procedures, you should know how to:
• Connect your controller to a network
• Connect your TriStation PC to the controller
• Configure your TriStation project with the Trinode number of your
controller and an IP address
For more information, see Chapter 3, “TriStation Communication.”

Note Typically, Triconex controllers are located on their own subnet which is
connected to a larger network such as a DCS. Your Network Administrator can set
up the subnet for compatibility with the Triconex default IP addresses and can
program any routers that lie between the DCS and the Triconex subnet with
addressing information about the Triconex controllers.

Chapter 4 TSAA Client/Server Communication


54 Configuring Ethernet Ports in TriStation

Method 1—Using a Default IP Address


Use the following procedure if your network topology permits the use of a
Triconex default IP address.

▼ To set the IP address by using a Triconex default:


1 Connect your controller to the network using a NET2 port on an ACM or NCM
and power up the controller.
2 Connect your TriStation PC to the network, or directly to a NET2 port.
3 Make sure that your TriStation project is configured with the node number of
the controller and the following default IP address:
192.168.1.<node number>
If your Tricon controller includes two ACMs or two NCMs, the default address
applies to both modules in a slot.

Note The left and right modules in ACM and NCM slots use the same 48-bit
physical MAC address and cannot be connected to the same network.

4 Go to the Control Panel and connect the TriStation PC to the controller.


5 Wait about 40 seconds for the module to reset and become active.
When the module is active, its Active indicator is green.
6 Download your TriStation project to the controller.
7 Verify the setting of the default IP address on the network by opening a DOS
window and entering the command “ping <IP address>.”
If the IP address is set, DOS gives several consecutive replies in this format:
“Reply from <IP address>: bytes = 32 time < 10 ms TTL=64”
If the IP address is not set, DOS gives the reply “Request timed out.” several
times.

Tricon Communication Guide


Configuring Ethernet Ports in TriStation 55

Method 2—Using a RARP Server to Get an IP Address


The following procedure is based on the assumption that your Network
Administrator has programmed a RARP server on your local network with the
intended IP address for your controller. To do this, the Network Administrator
must know that the MAC address of the ACM and the NCM is 40-00-00-00-00.

▼ To set the IP address of a Tricon controller using a RARP server:


1 Ask your Network Administrator for the IP address that is to be used for the
controller.
2 Connect your controller to the network by means of a NET2 port on an ACM or
NCM and power up the controller.
During initialization, the ACM or NCM sends a request to the RARP server for
an IP address that has been mapped to its own 48-bit MAC address.

Note The left and right modules in ACM and NCM slots use the same 48-bit
physical MAC address and cannot be connected to the same network.

3 Verify the setting of the intended IP address on the network by opening a DOS
window and entering the command “ping <IP address>.”
If the IP address is set, DOS gives several consecutive replies in this format:
“Reply from <IP address>: bytes = 32 time < 10 ms TTL=64”
If the IP address is not set, DOS gives the reply “Request timed out.” several
times.
4 Connect your TriStation PC to the network, or directly to a NET2 port on the
ACM or NCM.
5 Configure your TriStation project with the Trinode number of your controller
and its intended IP address, if you have not already done so.
6 Go to the Control Panel and connect the TriStation PC to the controller.
7 Download your TriStation project to the controller.

Chapter 4 TSAA Client/Server Communication


56 Configuring Ethernet Ports in TriStation

Method 3—Using an EICM Serial Port


The following procedure explains how to set the IP address of the Tricon controller
by initially connecting your TriStation PC to an EICM serial port and downloading
your TriStation project. After the address is set, you can disconnect TriStation from
the EICM serial port and reconnect it to a NET2 port on the ACM or NCM.

▼ To set the IP address by initially connecting TriStation to an EICM serial port:


1 Ask your Network Administrator for the IP address that is to be used for the
controller.
2 Connect your TriStation PC to a serial port on the EICM.
3 Connect the controller to the network by means of a NET2 port on the ACM or
NCM.
4 In your TriStation project, configure the following:
• The EICM serial port and NET2 Ethernet ports
• The Trinode number of the controller
• The intended IP address
5 Power up the controller.
6 Go to the Control Panel and open the Connect To dialog box.
7 Select the Serial Port property and the COM port to which your TriStation cable
is connected.
8 Connect to the Tricon controller and download your TriStation project.
The ACM or NCM initializes (resets) and accepts the IP address you specified
in the TriStation project.
9 Verify the setting of the intended IP address on the network by opening a DOS
window and entering the command “ping <IP address>.”
If the IP address is set, DOS gives several consecutive replies in this format:
“Reply from <IP address>: bytes = 32 time < 10 ms TTL=64”
If the IP address is not set, DOS gives the reply “Request timed out.” several
times.
10 If desired, you can now disconnect the TriStation PC from the EICM serial port
and connect it to a NET2 port or to the network.

Tricon Communication Guide


DDE Server for Triconex 57

DDE Server for Triconex


Triconex DDE Server is a Windows application that enables DDE-compliant
clients to request data and, if allowed, to change data in a Triconex (Tricon or
Trident) control program. A client can request data about input and output
variables, memory variables, and system attributes. Triconex DDE Server is based
on a client/server model in which a client requests information from a server and a
server sends information to a client.
Client applications use DDE (Dynamic Data Exchange) protocol to communicate
with a DDE Server. Any Windows application that supports DDE protocol—such
as Microsoft Excel—can use Triconex DDE Server.
Triconex DDE Server communicates with one or more Triconex controllers
through TSAA (Triconex System Access Application) protocol. To return data to
clients, the DDE Server uses DDE protocol.
The DDE Server workstation must be connected to an Ethernet port on a Triconex
controller. For Tricon, the NET2 port on the ACM (Advanced Communication
Module) or NCM (Network Communication Module) must be used. For Trident,
the NET1 or NET2 port on the CM (Communication Module) must be used.
The following diagram depicts multiple clients communicating with multiple
Triconex controllers through a Triconex DDE Server.

DDE Client Triconex


Application Controller
TSAA
DDE Protocol
Protocol

Triconex TSAA Triconex


DDE Server Protocol Controller
DDE
Protocol TSAA
DDE Client Protocol
Application
Triconex
Controller

The following sections explain how to install, configure, test and use Triconex
DDE Server.

Chapter 4 TSAA Client/Server Communication


58 DDE Server for Triconex

Installing Triconex DDE Server


The setup program provided by Triconex installs all the components of the
Triconex DDE Server on a PC. Before installing DDE Server, close open
applications and uninstall any previous versions of DDE Server. For more
information see, “Uninstalling Triconex DDE Server” on page 59.
To install DDE Server, you must be logged on to Window NT or Windows 2000
as an Administrator or you must have the privileges of an Administrator.

▼ To install Triconex DDE Server:


1 Exit any open applications.
2 Place the Triconex DDE Server disk in the CD ROM drive.
3 Open the TCXDDE folder and double-click the Setup.exe document.
4 Follow the instructions provided by the Installation Wizard.
5 Select a folder on your hard drive to install DDE Server or accept the default.
Triconex recommends that you install DDE Server in the default destination
folder called C:\Program Files\Triconex\TCXDDE\.
6 You must install the Wonderware Factory Suite 2000 product, unless it is
already installed.
7 The Common Components Setup wizard (for Factory Suite 2000) issues a
warning about the Windows service pack installed on your PC. Click OK.
The warning might be displayed several times. Each time, click OK.
8 The Common Components Setup wizard asks if you want to install Adobe
Acrobat 3.0 (an older version of Acrobat Reader). Click Cancel if you do not
want to install this program, then click No.
9 Click Finish to complete the installation.
Wonderware Factory Suite 2000 might cause your PC to restart. After the
restart, the installation of Triconex DDE Server should be successfully
completed.

Tricon Communication Guide


DDE Server for Triconex 59

Uninstalling Triconex DDE Server


Use the following procedure to uninstall a previous version of Triconex DDE
Server from a Windows workstation.

▼ To uninstall a previous version of Triconex DDE Server:


1 From the Start menu, select Settings, then click the Control Panel icon.
2 Double-click the Add/Remove Programs icon to open the Add/Remove
Programs Properties dialog box.
3 Click the Install/Uninstall tab.
4 Scroll down the list of installed programs and select Triconex DDE Server.
5 Click the Add/Remove button to open the Confirm File Deletion dialog box.
6 Click Yes to complete the removal of the previous version.
The Remove Programs from Your Computer dialog box is displayed as the
previous version of DDE Server and all its associated program files, folders,
directories and registries are uninstalled.
7 When the Uninstall successfully completed message is displayed, click OK.
8 Click OK to close the Add/Remove Programs Properties dialog box.
You can now install the new version of DDE Server.

Configuring the DDE Server Application


When you configure the DDE Server application, you specify communication
properties used by a Triconex controller (also called a host or node) to
communicate with DDE clients. These properties allow DDE clients to identify
which controller to communicate with and what communication protocol to use.
If you plan to use a redundant DDE network, you need to use DDE Server PCs and
install redundant communication modules in the controller. For more information,
see “Configuration Requirements for DDE Network Redundancy” on page 65.
You can also modify or delete the configuration of a Triconex controller. Before
modifying a configuration, make sure it is not being used by a DDE client. If you
delete a configuration, the associated controller can no longer be accessed by a
DDE client.

Chapter 4 TSAA Client/Server Communication


60 DDE Server for Triconex

To allow a DDE client to change the values of Triconex variables, you must enable
write access in one of the following ways:
• For Tricon, physically set the keyswitch to the Remote position.
• For Trident, set the MP.SET_REMOTE_WRIT_ENBL control attribute to
True in the TriStation application.
For more information, see “Write Access by External Devices” on page 40.

Configuring Triconex Host Information


You must specify host information for the Triconex controller before a DDE client
can access data from the controller.

▼ To configure Triconex host information:


1 Start DDE Server from the Start menu by selecting Programs, then Triconex
DDE Server. The DDE Server main window appears.
2 From the File menu, click Configure. The dialog box called Configuring Host
Information is displayed.
3 Either select an existing node and click Modify or click Add to add a host.
4 In the Host Name Configuration dialog box, specify the properties as needed.
For property descriptions, see the following pages.

! CAUTION
The default button clears all previous configuration settings for all of the hosts.

Tricon Communication Guide


DDE Server for Triconex 61

2nd Adapter (Tricon Only)


The 2nd Adapter property specifies the number of the second network adapter card
in your redundant PC. This property is enabled only if the Use 802.2 property and
Redundant property are selected.
The second adapter number is usually one (1).
This property is only available for Tricon.

Device Type
The Device Type property specifies whether the host is a Tricon or a Trident
controller.

First Adapter (Tricon Only)


The First Adapter property specifies the number of the first network adapter card
in your primary PC. This property is enabled only if the Use 802.2 property is
selected.
You can have multiple Ethernet adapters in your DDE PC. One is typical; two are
needed for redundancy.
The first adapter number is usually zero (0).
This property is only available for Tricon.

Host Name
The Host Name property specifies the user-defined name for a controller which
must be unique for each controller. (This name is used by the DDE client
application to request data from the controller.)
The default values are:
• For Tricon, TRINODE01 (for node 1) through TRINODE16 (for node 16)
• For Trident, TRINODE01 (for node 1) through TRINODE32 (for node 32)

IP Address
The IP address property specifies the unique 32-bit network address of the primary
communication module in the Triconex controller.

Chapter 4 TSAA Client/Server Communication


62 DDE Server for Triconex

For a Tricon controller, you must specify this property if the Use 802.2 property is
not selected.

Node Number
The Node Number property specifies the node number which must be unique for
each controller.
For Tricon, the node number must match the physical switch settings on the NCM
or ACM and the node number specified in the TriStation project. Default values are
1 to 16.
For Trident, the node number must match the address plug on the MP Baseplate
and the node number specified in the TriStation project. Default values are from 1
to 32.

Poll Time
The Poll Time property specifies how often the Triconex controller refreshes the
data stored as aliases. The polling interval must be greater than the scan time of the
controller. For more information on aliases, see “Aliases and Tagnames” on
page 39 and the TriStation 1131 Developer’s Guide.
The default is 1,000 milliseconds (one second).

Redundant
The Redundant property specifies whether there are redundant paths to the
controller. If the physical configuration is redundant, select this property.
This means that two network adapter cards must be connected to network ports on
two communication modules, as follows:
• For Tricon, the NET2 port on two ACMs or two NCMs
• For Trident, the NET1 or NET2 port on two CMs
For more information, see “Configuration Requirements for DDE Network
Redundancy” on page 65.
The default is not redundant.

Tricon Communication Guide


DDE Server for Triconex 63

Redundant (IP Address)


The Redundant (IP Address) property specifies the IP address of the redundant
communication module in the Triconex controller.
The redundant module must have the same IP address that is specified here.
For a Tricon controller, you cannot specify a redundant IP address if the Use 802.2
property is selected.

Time Sync
The Time Sync property specifies whether a Triconex node (host) is synchronized
with the clock on the DDE Server PC. If there is more than one Triconex controller
in a network, you should select the master node for synchronization with the DDE
Server PC clock. The master node can then synchronize the time of the other
Triconex controllers.
For time-critical applications, Triconex does not recommend selecting the Time
Sync property because PCs are not generally a reliable source for time
synchronization.

! CAUTION
Do not use the Time Sync property if any other type of synchronization is being
used for your Triconex controllers. For more information, see “Time
Synchronization” on page 125.

The default is not synchronized.

Use 802.2 (Tricon Only)


The Use 802.2 property specifies whether 802.2 (DLC) protocol or TCP/IP
protocol is used to communicate with the DDE client. To use this property, you
must install DLC protocol on the DDE PC.
If you configure a node to use DLC protocol, you must also configure the server
parameters. To do so, see the instructions in the section called “Configuring Server
Properties for 802.2 Protocol (Tricon Only)” on page 64.
The default is not selected, which means that TCP/IP protocol is used.
This property is only available for Tricon.

Chapter 4 TSAA Client/Server Communication


64 DDE Server for Triconex

Configuring Server Properties for 802.2 Protocol (Tricon Only)


In the Configuring Host Information dialog box, click Server to specify the server
properties. If you selected the Use 802.2 property when you added a host (using the
Add button), you must specify the server properties.

Server Poll Rate (MS)


The Server Poll Rate property specifies the rate in milliseconds at which DDE
server updates clients such as Microsoft Excel or Wonderware InTouch
applications. The server poll rate must be greater than 20 milliseconds and less than
1,000 milliseconds.

LLC Buffer Size


The LLC Buffer Size property specifies the size of the buffer (in bytes) required by
the DDE server for the LLC. The size depends on the number of Triconex
controllers supported by the DDE server. You must specify a minimum of 100,000
bytes for the buffer to support two controllers. Add 50,000 bytes for each additional
controller.

Tricon Communication Guide


DDE Server for Triconex 65

LLC SAP
The LLC SAP property specifies the address for the DDE Server on the PC. This
number must be a unique address. The default is 4.

Testing a TCP/IP Connection


After completing the configuration of Triconex hosts, you can test a TCP/IP
(Ethernet) network connection using the Ping command from the Command
Prompt. You might want to test the IP addresses of the following devices:
• Network adapter card in the client PC
• Triconex communication modules

▼ To use the ping command:


1 From the Start menu, select the MS-DOS Command Prompt.
2 Type the word ping followed by the IP address to be tested. For example, for an
IP address of 206.32.216.43, you would enter the following:
ping 206.32.216.43
3 If the network connection is valid, a reply is returned which includes the IP
address. In this example, the reply would display “Reply from 206.32.216.43”
followed by byte and time information. If there is a problem with the
connection, the response is a “Request Timed Out” message.

Configuration Requirements for DDE Network Redundancy


A redundant network of Tricon controllers can be configured using either TCP/IP
protocol or 802.2 protocol.
A redundant network of Trident controllers must be configured using TCP/IP
protocol.
Typically, hardware setup is done before software configuration. To configure a
redundant DDE network, the following hardware is required:
• For Tricon, two ACM or NCM modules in one or more Tricon controllers.
• For Trident, two CMs in one or more Trident controllers.
• For the DDE PC, two network adapter cards.

Chapter 4 TSAA Client/Server Communication


66 DDE Server for Triconex

Using TCP/IP Protocol


The following procedure explains how to configure DDE network redundancy with
TCP/IP protocol.
The configuration procedure involves setting IP addresses. If your network
topology permits, use the Triconex default addresses. If not, get the IP addresses
from your Network Administrator.
For Trident only, if a DDE Server PC is not on the same subnet as the Trident
controller, you must specify the destination address during Ethernet port
configuration. For instructions, see the Trident Communication Guide. If
necessary, get help from your Network Administrator.

▼ To configure redundant networks with TCP/IP Protocol:


1 Install two network adapter cards and the TCP/IP protocol on the DDE Server
PC.
2 On the DDE Server PC, use Windows procedures to set the IP addresses of the
network adapter cards. A sample IP address is:
206.32.216.x (where x = 1 to 254)
3 Connect the network adapter cards on the DDE Server PC to Ethernet ports on
the primary and redundant Triconex communication modules
4 In TriStation, set the IP addresses for the primary and redundant communication
modules. For instructions, see “Setting the IP Address” on page 53.
A sample IP address is 206.32.64.y where y is the Trinode number. The Trinode
number is set as follows:
• For Tricon, it is set with physical switches on the NCM or ACM.
• For Trident, it is set with the address plug on the MP Baseplate.
5 From the DDE server application, configure each Triconex node with a host
name. You must use the same IP address for the node configuration in DDE
Server that is used in Step 5 above. For instructions, see “Configuring Triconex
Host Information” on page 60.

Tricon Communication Guide


DDE Server for Triconex 67

Using 802.2 Protocol (Tricon Only)


The following procedure explains how to configure redundant Tricon controllers
which use 802.2 protocol.

▼ To configure redundant networks with 802.2 Protocol:


1 Install two network adapter cards and the DLC protocol in your DDE PC.
2 Connect the first network adapter card in the DDE PC to the left NCM or ACM.
3 Connect the second network adapter card to the right NCM or ACM.
4 In the DDE Server application, select the Redundant and Use 802.2 properties.
(When these properties are selected, it is not necessary to configure IP
addresses.)
5 Set the First Adapter property to 0 (zero) and the 2nd Adapter property to 1
(one).
The 802.2 protocol is only available for Tricon controllers.

Chapter 4 TSAA Client/Server Communication


68 DDE Server for Triconex

Requesting Data with a DDE Client Application


When you use a DDE client application to request data, you identify the DDE
Server application to use, the Triconex controller to be accessed, and the data to be
accessed. This information is referred to as the DDE address. Each DDE client
application uses a three-part DDE address format, but might use slightly different
syntax.
The DDE address format includes the following parts:

Application + Topic + Item

DDE Address Description


Application Specifies the Triconex DDE Server application name which is
TR1DDE.
Topic Specifies the node name for a Triconex controller as configured in
the DDE Server application.
For Tricon, the default node names for controllers 1–16 are
TRINODE01 through TRINODE16.
For Trident, the default node names for controllers 1–32 are
TRINODE01 through TRINODE32.
For more information on defining nodes, see “Configuring Triconex
Host Information” on page 60.
Item Specifies the alias number for the requested Triconex variable. You
can identify one or more items.
For more information, see “Aliases and Tagnames” on page 39.

To begin DDE Server operation, save the address in the DDE client application and
start the DDE Server application. Both the client and server applications must be
running concurrently to request or exchange data. The DDE Server sends the
request to the Triconex controller, then returns the data to the DDE client
application.
As an example, the following address could be entered in a blank cell of a
Microsoft Excel worksheet to request the value for alias 40001 in TRINODE02:
=TR1DDE|TRINODE02!‘40001’
Although you can run only one DDE Server application at a time, you can run as
many DDE client applications as allowed by the virtual memory available on your
PC.

Tricon Communication Guide


DDE Server for Triconex 69

Requesting Network Status


To find out whether the network ports on a Triconex controller are receiving data,
enter either of the following commands in any client application using the
following format.

=tr1dde|TRINODE01!STATUS Reads network status


=tr1dde|TRINODE01!RSTATUS Reads redundant network status

For details on syntax for the DDE address, see the user’s manual for the client
application you are using.

Monitoring Responses from the Controller


DDE Server allows you to monitor responses from the Triconex controller which
can include alert entries as well as log entries that indicate a successful response.
The entries are logged in the order in which they occur. To view the most current
entries, scroll to the bottom of the list. If you select the Stats command on the
Dump menu, older entries might appear at the bottom of the list, as shown in the
following screen.

Changing View Options


To keep the DDE Server main window on top of all other windows, select the
Always on Top command on the View menu. A check mark next to the command
means it is selected.

Chapter 4 TSAA Client/Server Communication


70 DDE Server for Triconex

DDE Menu Commands


The DDE Server includes the following menus and commands.
File Menu
Command Description
Configure... Opens the Configure Host Information dialog box and allows
you to configure up to 16 Tricon or 32 Trident controllers for
use with the DDE Server application.
Exit Closes the DDE Server application.

View Menu
Command Description
Always on Top Keeps the DDE Server main window on top of other
windows.

Dump Menu
Command Description
Stats Displays statistics for all Triconex controllers.

Help Menu
Command Description
Triconex DDE Server Opens the Help documentation.
Help
About Triconex DDE Displays the current version number of the DDE Server
Server application and registered owner information.

Tricon Communication Guide


OPC Server for Triconex 71

OPC Server for Triconex


The Triconex OPC Server is a Windows application which allows OPC clients to
have read and write access to Triconex program variables. OPC stands for OLE for
Process Control, which is a standard set of non-proprietary interfaces used to
develop client/server programs.
The OPC Server workstation must be connected to an Ethernet port on a Triconex
controller (Tricon or Trident). For Tricon, the NET2 port on the ACM or NCM
must be used. For Trident, the NET1 or NET2 port on the Communication Module
must be used.
OPC Server is configured by exporting an XML configuration file from a
TriStation project and opening that file in OPC Server. After OPC Server is
configured, an OPC client can ask OPC Server to get data from a Triconex
controller.

OPC Client Triconex


Application Controller
TSAA
OPC Protocol
Protocol

Triconex TSAA Triconex


OPC Server Protocol Controller
OPC
Protocol TSAA
OPC Client Protocol
Application
Triconex
Controller

You can include TriStation configurations for multiple networked controllers in


one XML file by using the same file name when exporting each configuration. The
information from each TriStation configuration is appended to the file.
In OPC Server, you can edit the properties of aliases and tagnames and other
aspects of the configuration. If you change the name of the configuration or alias,
a new entry is created in the XML configuration file. If you change properties
related to the entry, but do not change the configuration or alias name, those
properties are changed for the entry.

Chapter 4 TSAA Client/Server Communication


72 OPC Server for Triconex

The Triconex OPC Server is available from Triconex and Matrikon. For more
information on the Triconex OPC Server and OPC client applications, see the
Matrikon Web site at www.matrikon.com.

▼ To configure OPC Server:


1 In TriStation, assign all aliases to be accessed by OPC Server.
2 To allow an OPC client to change the values of Triconex variables, you must
enable write access by setting controls in your TriStation application. For
instructions, see “Write Access by External Devices” on page 40.
3 In TriStation, complete your project and download it to the controller.
4 To export the XML configuration file, do the following:
• In the Configuration editor, select Points on the configuration tree.
• From the Edit menu, select Export Points. Select the file type as
Matrikon OPC XML Data Files(*.XML). Name the file using the XML
extension, using a maximum of eight characters. If you include multiple
configurations, use the same file name each time you use the export
command.
5 If not already done, install OPC Server and start it. When OPC Server is loaded,
a gray Triconex icon is displayed on the status bar.
6 To open the XML configuration file, right-click the Triconex icon from the
status bar and select Configure.
The OPC Server for Triconex PLCs window is displayed.
7 From the File menu, select Open, then select the XML file you exported from
TriStation.
As the file loads, statistics are displayed. When finished, you can display Server
Configuration and Alias configuration information.
8 To display Server Configuration information, select a node from the Current
Configuration pane. The following screen shows the Server Configuration
information. You can make changes to these properties by entering the changes
and pressing the Apply button.

Tricon Communication Guide


OPC Server for Triconex 73

Click node to
display Server
Configuration

Specify the
properties of the
Left and Right CMs
on tab 1 and tab 2

9 Under Protocol Settings, specify the TCP/IP address and other properties of the
Triconex communication module on tab 1.
If your controller includes two communication modules, specify the properties
of the left module and the right module on tabs 1 and 2.
Do not use tabs 3 through 7.
10 To display alias information, select a node under Alias Configuration in the
Current Configuration pane. To make changes to an alias, double-click the alias
row. An Edit Alias dialog box is displayed, as shown in the following screen.

Chapter 4 TSAA Client/Server Communication


74 OPC Server for Triconex

The Name column The Item Path column


displays tagnames. displays the node, bin,
and memory offset.

Click node to
display Alias
Configuration.

Double-click
alias row to
edit an alias.

11 Repeat steps 8 through 11 for each TriNode configuration included in your


XML file.
12 If you made changes to any of the configurations and want to keep them, save
the configuration file.
13 To use OPC Server to get data from a Triconex controller, install an OPC client
application. (Matrikon sells OPC client applications.)
14 In the OPC client application, you can specify the tagnames or aliases of the data
to be accessed.
A sample tagname is DO_02, as shown in the preceding screen.
The location of the data is described as node: bin: offset in the Item Path column
for the Alias Configuration.

Tricon Communication Guide


Other OPC Products 75

Redundant Configuration
OPC Server can be configured for dual redundancy by using two OPC Server
workstations. Each workstation must include two Ethernet adapter cards, which
must be connected to a Triconex communication module on the primary network
and a Triconex communication module on the redundant network. You must
specify the properties of the redundant Triconex communication modules on the
OPC Server Configuration screen. For a diagram of redundancy which includes
OPC Server, see “Redundant Devices” on page 15.

Adjusting System Time


An OPC client can use the Device Clock tagname to read or write the system time
of a Triconex controller. The Device Clock tagname is derived from Triconex
status information in the OPC Server Configuration. For more information, see
“Time Synchronization” on page 125. See also the documentation for your OPC
client software.
Before you can use the Device Clock tagname to adjust the system time of a
Triconex controller, you must configure your TriStation project to allow writes by
external devices on an open network. For more information, see “Write Access by
External Devices” on page 40.

Other OPC Products


For users of OPC Server, two additional OPC products are available from Triconex
and Matrikon: the OPC Data Manager and the OPC Redundancy Broker.

OPC Data Manager


The OPC Data Manager (ODM) is an application that transfers data from one OPC
server to another. ODM is useful for sharing data between two or more control
systems such as a Triconex controller and a DCS. Traditional OPC-enabled
systems share data by implementing one application as an OPC client, and another
as an OPC server. If two applications are servers instead of clients, they cannot
exchange data. ODM solves this problem by acting as a double-headed or thin OPC
client to both servers. It requests data from one OPC server and immediately sends
it to the other OPC server.

Chapter 4 TSAA Client/Server Communication


76 Other OPC Products

ODM includes the following features:


• Support for both COM and DCOM architectures
• Support for DDE and OPC message protocols
• Operation as a Windows service or a normal application
• Real-time data monitoring
• Extensive error tracking and management
For more information, see the Matrikon OPC Data Manager User’s Manual.

OPC Redundancy Broker


The OPC Redundancy Broker (ORB) is a messaging application designed for
systems that must use redundant devices to ensure high reliability. ORB constantly
monitors the primary OPC server and redirects communication to the standby OPC
server when a failure is detected. ORB can integrate with any OPC compliant
client/server configuration and can be retrofitted to existing configurations. ORB
includes the following features:
• Intuitive configuration and monitoring features
• Choice of hot, cold, or warm fail-over for each OPC Server
• Automatic fail-over notification by e-mail, fax, log file, or pager
• Extensive error tracking and diagnostic capabilities
For more information, see the Matrikon OPC Redundancy Broker User’s Manual.

Tricon Communication Guide


CHAPTER 5

Peer-to-Peer Communication

This chapter explains how to set up Triconex controllers for communication (with
each other) in a Peer-to-Peer network.
Topics include:
“Overview” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 78
“Configuring Peer-to-Peer Ports in TriStation” . . . . . . . . . . . . . . . . 80
“Allocating Memory for Sends and Receives” . . . . . . . . . . . . . . . . . 82
“Adding Sends and Receives to Programs” . . . . . . . . . . . . . . . . . . . 83
“Estimating Data Transfer Time” . . . . . . . . . . . . . . . . . . . . . . . . . . . 85
“Restrictions on Data Transmission Speed” . . . . . . . . . . . . . . . . . . . 88
“Monitoring Peer-to-Peer Communication” . . . . . . . . . . . . . . . . . . . 89
“Sample Peer-to-Peer Programs” . . . . . . . . . . . . . . . . . . . . . . . . . . . 90

Tricon Communication Guide


78 Overview

Overview
Triconex Peer-to-Peer protocol is designed to allow multiple Tricon and Trident
controllers in a closed network to exchange safety-critical data. (If you plan to
implement a complex Peer-to-Peer network, please contact Triconex Technical
Support.) To enable Peer-to-Peer communication, you must connect each
controller to an Ethernet network by means of a NET1 (Ethernet) port on the NCM.
The controllers exchange data by using Send and Receive function blocks in their
TriStation applications.

Peer-to-Peer Network

CM CM

Tricon
Controller
NN
MM M CC
P P P MM
A B C 1 2
MP MP
Trident Controller Trident Controller

To configure a TriStation application for Peer-to-Peer communication, you must


do the following tasks:
• Configure the physical port connection for Peer-to-Peer mode
• Allocate memory for Send and Receive function blocks
• Add Send and Receive function blocks to your programs
• Observe restrictions on data transmission speed
In addition, Triconex recommends that you calculate the data transfer time to
determine whether your control algorithms will operate correctly.
A TriStation application must use a specific Send function block to send data to a
matching Receive function block in another TriStation application. Each Send
function block has a parameter that identifies the Receive function block to which

Tricon Communication Guide


Overview 79

it sends data. Each Receive function block has a parameter that identifies the Send
function block from which it receives data.
The Send and Receive function blocks can transfer data with BOOL, DINT, or
REAL data types. Some function blocks transfer 20 data values, and others transfer
32 data values. For detailed information about the available Send and Receive
function blocks, see the Triconex Libraries Reference.
Tricon controllers do Peer-to-Peer communication at 10 megabits per second,
however, Trident controllers can do Peer-to-Peer communication at 10 or 100
megabits per second. If your network includes both types of controllers, you can
run the entire network at 10 megabits per second, or you can use a hub that converts
messages from 10 to 100 megabits per second when they are transferred from a
Tricon to a Trident. Triconex suggests using the NET1 port on both Tricon and
Trident communication modules, because 10 megabits per second is the only speed
available on NET1. With this setup, NET2 is available for faster communication
with external devices on an Ethernet network. For more information, see
“Restrictions on Data Transmission Speed” on page 88.
For monitoring Peer-to-Peer data exchange, TriStation provides function blocks
and system aliases to track network communication paths and verify whether your
Ethernet ports are receiving data from other controllers.
The sample programs described in this chapter are in the EXPEER project on the
TriStation CD. These programs show how to send data at high speed and under
controlled conditions, and how to measure the maximum data transfer time.

Chapter 5 Peer-to-Peer Communication


80 Configuring Peer-to-Peer Ports in TriStation

Configuring Peer-to-Peer Ports in TriStation


This procedure explains how to configure an Ethernet port on the NCM for
communication with other Triconex controllers on a Peer-to-Peer network.

▼ To configure a Peer-to-Peer port in TriStation:


1 Open the TriStation project and go to the Configuration editor.
2 Under System Configuration in the tree structure, click the Hardware Allocation
icon to display the chassis that are configured for this system. Click the chassis
where the NCM is installed.
3 Double-click the NCM icon to open the Properties dialog box, and click Setup
to display the configuration options for the NCM, as shown below.

4 In the Left Slot and Right Slot areas, select the Installed option if an NCM is
installed in the left or right position of a physical slot.
The NET1 port on an NCM is pre-configured for Peer-to-Peer communication,
and operates at 10 megabits per second.For more information, see “Restrictions
on Data Transmission Speed” on page 88.

Tricon Communication Guide


Configuring Peer-to-Peer Ports in TriStation 81

5 For an NCMG, you can select the option called Global Positioning System
Installed to synchronize the controller to the GPS (Global Positioning System).
In a Peer-to-Peer network, you should select this option only for an NCMG
which acts as the master node.
6 To synchronize this controller with the master node, select the option called On
NET1 enable time synchronization.
If this controller is the master node, you should still select this option.
For more information, see “Time Synchronization” on page 125.

Chapter 5 Peer-to-Peer Communication


82 Allocating Memory for Sends and Receives

Allocating Memory for Sends and Receives


To allocate memory for send and receive operations, you must set the maximum
number of Send and Receive function blocks for each TriStation application. The
maximum number does not have to be the same for Sends and Receives. For
example, a TriStation application might need to send messages to three other
applications, but need to receive messages from only one other application.
To conserve memory and minimize scan time, set the maximum number
parameters to low values. To reserve memory for adding more Send and Receive
function blocks with a Download Change, set the parameters to the anticipated
maximum number. Changing these parameters requires a Download All.

▼ To set the maximum number of Send and Receive function blocks:


1 From the Tricon menu, select Edit Configuration.
2 Check the message bar to see if the project is the Download All state. If not,
select Change State to Download All from the Tricon menu.
3 On the configuration tree, click System Configuration to display this dialog box:

Tricon Communication Guide


Adding Sends and Receives to Programs 83

4 Use the arrows in the scroll boxes to set the following properties:
• Maximum Number of Peer-to-Peer Send
• Maximum Number of Peer-to-Peer Receive
The default for both properties is 0, and the maximum value of each is 50.

Adding Sends and Receives to Programs


A TriStation application must use a specific Send function block to send data of a
certain type to a matching Receive function block in another TriStation application.
Each Send function block has a parameter that identifies the Receive function
block to which it sends data. Each Receive function block has a parameter that
identifies the Send function block from which it receives data.

Send and Receive Function Blocks


The Send and Receive function blocks that you can include in a TriStation
application have data types of BOOL, DINT, and REAL. You can select the
following Send and Receive function blocks from the Tricon Library:
Send and Receive Function Blocks
Send Function Blocks Receive Function Blocks
TR_USEND_BOOL TR_URCV_BOOL
TR_USEND_DINT TR_URCV_DINT
TR_USEND_REAL TR_URCV_REAL
TR_USEND_BOOL_32 TR_URCV_BOOL_32
TR_USEND_DINT_32 TR_URCV_DINT_32
TR_USEND_REAL_32 TR_URCV_REAL_32

The _32 ending means that the function block can send 32 data values. Function
block names that do not include the _32 ending can send 20 data values.
All Send function blocks—and all Receive function blocks—have the same
parameters, except for the data transfer parameters which are BOOL, DINT, or
REAL. For detailed descriptions, see the Triconex Libraries Reference.

Chapter 5 Peer-to-Peer Communication


84 Adding Sends and Receives to Programs

Sample Send and Receive Pair


The following diagram shows a sample pair of Send and Receive function blocks.
A Send function block in one TriStation application is sending input values from
the field over a Peer-to-Peer network to a matching Receive function block in
another TriStation application. The Recvid and Sendid parameters are used to
cross-reference the Send and Receive function blocks. The Recvnode and
Sendnode parameters are used to cross-reference the sending and receiving nodes
(TriStation applications).
For more information, see “Sample Peer-to-Peer Programs” on page 90.

TriStation Application on Sending Node 1

Send1toNode2

Identifiers for:
Sending Function Block
Receiving Node 21
Receiving Function Block Send1toNode2Status

TriStation Application on Receiving Node 2

Recv1FromNode1

Identifiers for:
Receiving Function Block
Sending Node 1
2 Recv1FromNode1Status
Sending Function Block

Tricon Communication Guide


Estimating Data Transfer Time 85

Estimating Data Transfer Time


For each controller in a Peer-to-Peer network, you should calculate the data
transfer time to determine whether your control algorithms will operate correctly.
Data transfer time includes the time required to initiate a send operation, send the
message over the network, and have the message read by the receiving node. The
sending node needs additional time (at least two scans) to get an acknowledgment
from the MPs that the message has been acted on. These time periods are a function
of the following parameters of the sending and receiving controllers:
• Scan time
• Configuration size
• Number of bytes for aliased variables
• Number of Send function blocks, Receive function blocks, printing function
blocks, and Modbus master function blocks
• Number of controllers on the Peer-to-Peer network
Send function blocks require multiple scans to transfer data from the sending
controller to the receiving controller. The number of send operations initiated in a
scan is limited to 5. The number of pending send operations is limited to 10.
A typical data transfer time (based on a typical scan time) is 1 to 2 seconds, and the
time-out limit for a Peer-to-Peer send (including 3 retries) is 5 seconds.
Consequently, the process-tolerance time of the receiving controller must be
greater than 5 seconds. Process-tolerance time is the maximum length of time that
can elapse before your control algorithms fail to operate correctly. If these
limitations are not acceptable, further analysis of your process is required. For
assistance, please contact Triconex Technical Support.

▼ To estimate the data transfer time for a sending controller:

1 Open your TriStation project.


2 From the Tricon menu, select Edit Configuration to display the configuration
tree.
3 Under System Configuration on the configuration tree, click the Memory
Allocation icon.
The Memory Allocation window to the right of the configuration tree displays
the allocation for Unaliased, Read Aliased, and Read/Write Aliased Memory
points.

Chapter 5 Peer-to-Peer Communication


86 Estimating Data Transfer Time

4 In the Memory Allocation window, scroll down to see the allocations for Input
Points (Read Aliased) and Output Points (Read/Write Aliased).
For each data type (BOOLs, DINTs, and REALs), the Maximum, Allocated,
Forecast, and Current number of aliased variables are displayed.
5 For each data type, add the numbers under Allocated in the Input Points and
Output Points areas, as shown in the following screen.

Add the numbers


under Allocated

6 To calculate the Total Bytes of Aliased Variables (TB) in your project, use the
Allocated total for each data type in the following equation.
TB = 376 + (Total BOOLs ¸ 8) + (Total DINTs • 4) + (Total REALs • 4)
7 To estimate the Data Transfer Time (DT) in milliseconds, use the following
equation and table.
DT = (2 • <Larger of TS or SS>) + (2 <Larger of TR or SR>)

Parameter Description
DT Data transfer time in milliseconds, assuming that the
number of active sends is less than or equal to 10.
TB Total bytes of aliased variables allocated for the TriStation
application (see steps 5 and 6).

Tricon Communication Guide


Estimating Data Transfer Time 87

Parameter Description
TS Time for sending controller to transfer aliased data over the
communication bus in milliseconds.
TS = (TB ÷ 100,000) • 1000

SS Scan time of sending node in milliseconds.


TR Time for receiving controller to transfer aliased data over
the communication bus in milliseconds.
TR = (TB ÷ 100,000) • 1000

SR Scan time of receiving node in milliseconds.

8 If the number of active send requests in your application is greater than 10, you
should adjust the Data Transfer Time (DT) by using the following equation:
DTAdjusted = (Number of Active Send Requests ÷ 10) • DT
9 To calculate the total bytes of aliased variables (TB) which have been allocated
for a receiving controller, repeat steps 1 through 6.

Chapter 5 Peer-to-Peer Communication


88 Restrictions on Data Transmission Speed

Restrictions on Data Transmission Speed


Tricon controllers do Peer-to-Peer communication at 10 megabits per second,
however, Trident controllers can do Peer-to-Peer communication at 10 or 100
megabits per second. If your network includes both types of controllers, you can
choose either of the following solutions.

Solution Description
Run the entire network at Data exchange among Triconex controllers can be
10 megabits effectively done at a rate of 10 megabits per second.
Triconex suggests using the NET1 port on both Trident and
Tricon communication modules, because 10 megabits per
second is the only speed available on NET1. With this
setup, NET2 is available for faster communication with
external devices on an Ethernet network.
Convert messages from The data rate can be converted when messages are
10 to 100 megabits transferred from a Tricon controller to a Trident controller.
A typical method is to connect the Tricon and Trident
controllers to a hub which can convert from 10 to 100
megabits. For Trident controllers, another method is to
connect MAUs, which can convert from 10 to 100
megabits, to CM ports.

Rules for Downloading


You must use the Download All command if you increase or decrease the
maximum number of Send or Receive function blocks in a TriStation project. For
more information, see “Rules for Download All” on page 42.

! CAUTION
A negative scan surplus in your downloaded TriStation application could cause
Peer-to-Peer communication errors. Check the scan surplus using the Diagnostic
Panel. If the scan surplus is less than zero, you must increase the scan time using
the Set Scan Time command in the Control Panel. You should also increase the
scan time in the Tricon System Configuration to make sure the increase is
permanent if you have to another Download All. For instructions, see the
TriStation 1131 Developer’s Guide.

Tricon Communication Guide


Monitoring Peer-to-Peer Communication 89

Monitoring Peer-to-Peer Communication


TriStation provides function blocks for monitoring the status of Peer-to-Peer
communication paths (routes between NCMs on the network) and the status of
NET1 ports on the ACM or NCM. For detailed information, see the Triconex
Libraries Reference.

Status of Communication Paths


A Peer-to-Peer network can communicate over one or two paths, depending on
whether each controller contains one or two NCMs. If there are two paths (two
NCMs), then both are used simultaneously to exchange Peer-to-Peer data. The
failure of one path does not affect Peer-to-Peer communication. To monitor the
paths, use the TR_PEER_STATUS function block in your TriStation application.
Path status is updated every 30 seconds.
The FBD representation of a TR_PEER_STATUS function block is shown below.

Status of NET1 Ports


You can determine whether the NET1 ports on an ACM or an NCM are receiving
Peer-to-Peer data by using the TR_PORT_STATUS function block in your
TriStation application. The FBD representation of a TR_PORT_STATUS function
block is shown below.

Chapter 5 Peer-to-Peer Communication


90 Sample Peer-to-Peer Programs

Sample Peer-to-Peer Programs


The sample programs described in this chapter are in the EXPEER project on the
TriStation CD. These programs show how to send data at high speed and under
controlled conditions, and how to measure the maximum data transfer time. Topics
include:
• Fast send to one controller
• Sending data every second to one controller
• Sending data only when requested
• Fast send of safety-critical data

Fast Send to One Controller


The following programs show how to send data as fast as possible from Tricon
Node 2 to Tricon Node 3. This technique can be used with a scan time as low as
100 milliseconds.
• PEER_EX1_SEND_FBD (for sending Tricon Node 2)
• PEER_EX1_RCV_FBD (for receiving Tricon Node 3)

Sending Data Every Second to One Controller


The following programs show how to send data every second from Tricon Node 2
to Tricon Node 3. This technique can be used with a scan time as low as 100
milliseconds.
• PEER_EX2_SEND_FBD (for sending Tricon Node 2)
• PEER_EX2_RCV_FBD (for receiving Tricon Node 3)

Sending Data Only When Requested


The following programs show how to use Send and Receive function blocks in a
controlled way. The programs send data only when an acknowledgment for the last
send operation is received and new data is available.
• PEER_EX3_SEND_FBD (for sending Tricon Node 2)
• PEER_EX3_RCV_FBD (for receiving Tricon Node 3)

Tricon Communication Guide


Sample Peer-to-Peer Programs 91

Fast Send of Safety-Critical Data


The following programs show how to transfer a small amount of safety-critical data
between two TriStation applications as fast as possible. The programs also show
how to measure the actual maximum time for transferring data from the sending
node to the receiving node.
• PEER_EX4_SEND_FBD (for sending Tricon Node 1)
• PEER_EX4_RCV_FBD (for receiving Tricon Node 3)
Because safety-critical data is being transferred, each controller must have two
NCMs which are connected to redundant Peer-to-Peer networks.
The data transfer time described in this section is calculated using the following
equation.
DT = (2 • <Larger of TS or SS>) + (2 • <Larger of TR or SR>)

Parameter Description
DT Data transfer time in milliseconds.
TBS Total bytes of aliased variables in the sending node.
TS Time for sending controller to transfer aliased data over
the communication bus in milliseconds.
TS = (TBS ÷ 100,000) * 1000

SS Scan time of sending node in milliseconds.


TBR Total bytes of aliased variables in the receiving node.
TR Time for receiving controller to transfer aliased data over
the communication bus in milliseconds.
TR = (TBR ÷ 100,000) * 1000
SR Scan time of receiving node in milliseconds.

Chapter 5 Peer-to-Peer Communication


92 Sample Peer-to-Peer Programs

Sample Timing Calculations


SS = 150 milliseconds
TBS = 2000 bytes
TS = (2000/100,000) • 1000 = 20 milliseconds
SR = 250 milliseconds
TBR = 5000 bytes
TR = (5,000 ¸ 100,000) • 1000 = 50 milliseconds
DT = 2 • 150 + 2 • 250 = 800 milliseconds
Process tolerance time = 4 seconds
The PEER-EX4_SEND_FBD program packs 32 BOOL values into a DINT and
sends the DINT with a diagnostic variable to a receiving node as fast as possible
by permanently setting the SENDFLG parameter to 1. The diagnostic variable is
incremented every time a new send operation is initiated. The receiving node
verifies that the diagnostic variable has changed from the previous value received.
The receiving node also verifies that it has received at least one sample of new data
within the process tolerance time. If not, the receiving program takes an
appropriate action, such as using the last data received or using default data to make
safety-critical decisions.
If the sending controller does not receive acknowledgment from the receiving
controller in 1 second, it automatically retries the last Send message a second time.
Due to network collisions, communication bus loading, or other problems, the
sending controller occasionally has to retry the send a third time. This is why the
general rule for data transfer time is 1 to 2 seconds, even though the estimated time
(DT) is 800 milliseconds.
The application running in the receiving controller includes a network that
measures the actual time so that you can validate the assumed 2-second maximum
transfer time. Since the process tolerance time of the receiving node is 4 seconds,
the maximum time-out limit is set to 2 seconds (half the process tolerance time).
The receiving node should get at least one sample of new data within the maximum
time-out limit. Using this criteria satisfies the basic requirement for using Peer-to-
Peer to transfer safety critical data.

Tricon Communication Guide


CHAPTER 6

Modbus Communication

This chapter explains how to set up your Trident system for communication with
Modbus master and slave devices.
Topics include:
“Overview” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 94
“Physical Features” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 95
“Configuring Serial Ports in TriStation” . . . . . . . . . . . . . . . . . . . . . . 98
“Programming for Tricon Masters” . . . . . . . . . . . . . . . . . . . . . . . . 105
“Programming for Tricon Slaves” . . . . . . . . . . . . . . . . . . . . . . . . . 111
“Sample Modbus Programs” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 120

Tricon Communication Guide


94 Overview

Overview
Modbus is an industry-standard master/slave protocol that is traditionally used for
energy management, transfer line control, pipeline monitoring, and other industrial
processes. A serial port on a Triconex module can operate as a Modbus master,
slave, or both. A DCS, operator workstation, or other Modbus device typically acts
as the master while the Tricon serial port acts as the slave.
Serial ports on the EICM provide many choices for communication with Modbus
devices. Each port can operate in a point-to-point connection with a single Modbus
device, or in a multi-point serial link with several Modbus devices. For an
illustration, see “Topology Options” on page 95.
An EICM serial port can act as a master, slave, or combination master/slave with
the following physical features:
• Point-to-point or multi-point topology
• RS-232, RS-422, or RS-485 electrical interface
• 2-wire (half duplex) or 4-wire (full duplex) cables
• Hardware handshake with or without signal delays
For an EICM serial port configured as a master, the associated TriStation
application can use Modbus Read and Write function blocks to communicate with
slave devices, including other Triconex controllers. Programs in external Modbus
master devices can directly access point values in a Triconex controller if the points
have aliases and if write access controls are correctly applied.
A TriStation application normally uses alphanumeric names to identify Triconex
points (program variables). Numeric identifiers called aliases must also be used to
make the point values accessible to external Modbus devices. An alias has five
digits that define its data type and hardware address in the controller.
Function blocks in the Tricon Library allow you to monitor the communication
status of each EICM serial port. The status information includes the number and
kinds of messages received and sent and milliseconds since the last message was
received.
The sample programs described in this chapter are in the EXMODBUS project on
the TriStation CD. These programs show how to use the Modbus Read and Write
function blocks for transmitting aliased data, how to set time-out and retry values
for Modbus communication, and how to control the flow of data from slave to
master. For detailed information, see Appendix D, “Modbus Protocol.”

Tricon Communication Guide


Physical Features 95

Physical Features
When connecting an EICM serial port to one or more Modbus devices, you can
select from the following physical features.

Feature Option Use for


Point-to-point Connection to one Modbus device
Topology
Multi-point Connection to multiple Modbus devices
RS-232 Maximum speed across distances up to 15 m (50 ft)
Electrical
RS-422 Distances up to 1,220 m (4,000 ft), point-to-point only
Interface
RS-485 Distances up to 1,220 m (4,000 ft)
2-wire Half-duplex data transmission
Cable Type
4-wire Full-duplex data transmission

Hardware Default Devices that do not require signal delays


Handshake Signal delay Devices with slow throughput, other limitations

Topology Options
An EICM serial port can operate in a point-to-point connection with a single
Modbus device, or in a multi-point serial link with several Modbus devices.

Point-to-Point Connection

Tricon Controller

Modbus Slave

Point-to-Point Connection

MM M
P P P
A B C

Chapter 6 Modbus Communication


96 Physical Features

Multi-Point Connection

Tricon Controller

Multi-Point Connection

Modbus Slave Modbus Slave Modbus Slave

M M M
P P P
A B C

Physical Media Rules


The following rules apply to the electrical interfaces and cables you can use with
EICM serial ports:
• RS-232 can be used only for point-to-point connections across distances up
to 15 meters (50 feet)
• RS-422 can be used only for point-to-point connections across distances up
to 1,220 meters (4,000 feet)
• RS-485 can be used:
– for point-to-point connections or multi-point serial links
– with 2-wire or 4-wire cables
– across distances up to 1,220 meters (4,000 feet) on a multi-point serial
link

Hardware Handshake Rules


Hardware handshake refers to signals transmitted back and forth between two
stations to coordinate the timing of data transmission. The following rules apply to
the use of hardware handshake with Modbus devices:
• Generally, hardware handshake can be used with the RS-232 or RS-485
electrical interface.
• With a 2-wire cable, you must use hardware handshake.

Tricon Communication Guide


Physical Features 97

• For a point-to-point configuration, you should use hardware handshake only


if the connected Modbus device requires it.
• For a multi-point configuration that uses 4-wire cables, typically the slaves
use hardware handshake but the master does not.

Valid Configurations
A valid configuration of Modbus devices must use one of the following
combinations of physical features.

Valid Electrical Physical Hardware


Topology
Configuration Interface Media Handshake
Combination 1 Point-to-Point RS-232 Not applicable Optional
Combination 2 Point-to-Point RS-485 2-wire Required
Combination 3 Point-to-Point RS-485 4-wire Optional
Combination 4 Multi-Point RS-485 2-wire Required
Combination 5 Multi-Point RS-485 4-wire Optional

Chapter 6 Modbus Communication


98 Configuring Serial Ports in TriStation

Configuring Serial Ports in TriStation


To configure a serial port on the EICM, you must specify the electrical interface by
setting a switch on the module and select other properties in TriStation. The
properties you select for a serial port must match the properties of the Modbus
device it is connected to.

Specifying Electrical Interfaces


Before installing an EICM in the Tricon chassis, you must specify the electrical
interface for each serial port with a switch block located on the side of the module.
As shown in the following diagram, switches 1, 2, 3, and 4 are used to specify an
electrical interface for serial ports 1, 2, 3, and 4 respectively. If a switch is Off, the
port uses RS-232. If a switch is On, the port uses RS-422 or RS-485.

Switches 1 and 2 are set to Off,


specifying Ports 1 and 2 for RS-232.

Switches 3 and 4 are set to On, specifying


Ports 3 and 4 for RS-422 or RS-485.

1 2 3 4 5 6 7 8
O
Port 1 N

Port 2

Port 3

Port 4

Port 5

Tricon Communication Guide


Configuring Serial Ports in TriStation 99

Selecting Properties in TriStation


▼ To configure a serial port on the EICM:
1 Open your TriStation project and go to the Configuration editor.
2 Click the Hardware Allocation to display the modules that are configured for the
controller.
3 Double-click the EICM icon to open the Properties dialog box, as shown below.

4 Click the Setup button on the Module tab to display the EICM Configuration
dialog box.

Chapter 6 Modbus Communication


100 Configuring Serial Ports in TriStation

5 For Port Configuration Options, specify the following properties as needed.

Port Selection
The Port Selection area specifies the serial port to be configured. Use the following
table to select the number that corresponds to the desired port.

Left Slot Right Slot Type of Port Protocol


01 06 Serial Port Modbus or TriStation
02 07 Serial Port Modbus or TriStation
03 08 Serial Port Modbus or TriStation
04 09 Serial Port Modbus or TriStation
05 10 Parallel (Printer) Port Centronics Interface

For a diagram of the EICM front panel which includes the serial ports, see
“Physical Description” on page 141.

Protocol
The Protocol property specifies the communication mode. For Modbus
communication, select one of the following modes:
• Modbus (slave, ASCII or RTU mode)
• Modbus Master (RTU mode only)
• Modbus Master/Slave (RTU mode only)
For a Modbus slave, you can select the ASCII or RTU mode using the Data Bits
property (described for “Data Bits (ASCII or RTU)” on page 101). For more
information, see “Communication Modes” on page 194.
The TriStation mode can also be selected for ports 1 through 4 and ports 6 through
9. For more information, see “Configuring the TriStation Port” on page 34.

Slave Address
Each serial port which is connected to a Modbus master device must have a
separate Modbus Station Address. Addresses can be 1 to 247.

Tricon Communication Guide


Configuring Serial Ports in TriStation 101

This property is not available if the EICM serial port acts as a Modbus master.
If the EICM serial port acts as a master, the station address of the slave is specified
in the Modbus Read and Write function blocks. For more information, see
“Programming for Tricon Masters” on page 105.

Baud Rate
The Baud Rate property specifies the data transmission speed.
Select 1200, 2400, 4800, 9600, or 19200.

Data Bits (ASCII or RTU)


The Data Bits property specifies whether you are using ASCII mode (7 bits) or
RTU mode (8 bits). This property can be set only if you have set the Protocol
property to Modbus slave mode. With other modes, the default value of RTU mode
(8 bits) applies.

Stop Bits
The Stop Bits property specifies whether 1 bit or 2 bits are transmitted after each
character.

Parity
The Parity property specifies whether to use parity checking on the transmitted
data.
Odd and Even parity counts the number of 1 bits in a one-byte data item then sets
the parity bit (9th bit) to 0 or 1 to result in an Odd or Even total number of 1 bits.
Mark and Space parity (also called high/low parity) set the parity bit to 1 or 0
regardless of the number of 1 bits in the data item.
Settings include:
• Odd sets the parity bit to 0 or 1 to make the total number of 1 bits odd.
• Even sets the parity bit to 0 or 1 to make the total number of 1 bits even.
• Mark sets the parity bit to 1 for each data item.

Chapter 6 Modbus Communication


102 Configuring Serial Ports in TriStation

• Space sets the parity bit to 0 for each data item.


• None deletes the parity bit.

Handshake
The Handshake property specifies whether CTS, RTS, and DCD signals are used
to coordinate the timing of data transmission.
Select Hardware for the following configurations:
• Any 2-wire configuration
• Any multi-point configuration that uses the RS-485 electrical interface

Select None for configurations that do not allow or require Hardware Handshake.
To delay the timing of Modbus data transmission, see “Setting Signal Delays for
Hardware Handshake” on page 103.

Modbus Range
The Modbus Range property specifies the numeric range used by a Modbus master.
The defaults are 0 for Min and 32,767 for Max.
Commonly used Min and Max values are 0 to 32,767 for a generic operator
workstation, and 0 to 9,999 for a Honeywell DHP. TriStation allows Min limits as
low as -32,768 and Max limits as high as 32,767. For more information, see the
user’s manual for your Modbus master.
The Modbus Range operates in conjunction with the MinSpan and MaxSpan limits
that apply to individual REAL points, according to the following linear
transformation equation:
(Real Value – MinSpan) · (Modbus Max – Modbus Min)
Modbus Value = ------------------------------------------------------------------------------------------------------------------------------------------ + Modbus Min
(MaxSpan – MinSpan)

For more information, see “Transmitting Real Values with Scaling” on page 115.

Tricon Communication Guide


Configuring Serial Ports in TriStation 103

Setting Signal Delays for Hardware Handshake


For Modbus devices that use hardware handshake, you can manipulate the CTS
and RTS signals to delay the timing of data transmission. These settings are useful
for devices that have slow throughput or other limitations.
CTS (Clear to Send) signals the transmitting station that it is ready to receive data.
CTS post-delay specifies how long the channel stays open after data is transmitted.
RTS (Request to Send) opens and closes the data transmission channel. RTS pre-
delay specifies the period after the channel is opened and before data is transmitted.

▼ To set a signal delay:


1 Add an MBWRITE function block to your TriStation program.
2 You must specify the following parameters:
• A pre-defined alias number for the desired type of delay:
– For CTS post-delay, use alias number 40001
– For RTS pre-delay, use alias number 40004
• Station address 255
• Delay time in milliseconds—can be 0 to 10,000 milliseconds
3 Specify other parameters in the function block as required by your application.

Examples
The timing diagram that follows shows how alias numbers 40001 and 40004 are
used for RTS pre-delay and CTS post-delay.
40001 40004

RTS CTS
Pre-delay Post-delay
RTS

Data

The following diagram shows how a sample Modbus Write function block in a
TriStation application is used to program a CTS post-delay.

Chapter 6 Modbus Communication


104 Configuring Serial Ports in TriStation

TriStation Programming for CTS Post-Delay

Alias for CTS Post-Delay


EICM Serial Port Number
Slave Station Address
Post-Delay Value of 1000 Milliseconds

Tricon Communication Guide


Programming for Tricon Masters 105

Programming for Tricon Masters


If you configure a serial port on a Tricon controller as a Modbus master, your
TriStation application can use Modbus Read and Write function blocks to
communicate with slave devices, including other Triconex controllers. You can
select the following Read and Write function blocks from the Tricon Library:

• MBREAD_BOOL • MBWRITE_BOOL
• MBREAD_DINT • MBWRITE_DINT
• MBREAD_REAL • MBWRITE_REAL
• MBREAD_REAL_TRD • MBWRITE_REAL_TRD

Read and Write function blocks of types BOOL and DINT can transmit 32 data
values. Read and Write function blocks of type REAL can transmit 25 data values.
The Tricon controller supports BOOL, 32-bit DINT (double integer) and 32-bit
REAL numbers, but traditional Modbus protocol supports only Booleans and 16-
bit integers. For this reason, the Tricon Library provides function blocks which
perform the necessary numeric conversions for integer and REAL values. The
sections beginning on page 106 provide guidelines for use of these function blocks.
For detailed information, see the Triconex Libraries Manual. For examples, see
“Sample Modbus Programs” on page 120.

Chapter 6 Modbus Communication


106 Programming for Tricon Masters

Function Blocks for Communicating with Non-Triconex Slaves


When a Tricon master interfaces with a non-Triconex slave device, the following
function blocks can be used.

Data Type Function Block


Application Notes
in Slave in Tricon Master
MBWRITE_BOOL
Boolean • Values are True (1) and False (0).
MBREAD_BOOL
MBREAD_DINT • Although the DINT data type uses
signed 32-bit integers, only the least
MBWRITE_DINT significant 16 bits are transferred.
Integer
• Values should be limited to the range of
zero through 32,767.
MBREAD_REAL_TRD • REAL values are read from the slave as
two 16-bit consecutive aliases and
concatenated to form a 32-bit REAL
value (see Example 2).
Real
MBWRITE_REAL_TRD • 32-bit REAL values to be written to the
slave are first split into two 16-bit values
which are written to two consecutive
aliases (see Example 1).

Example 1. Writing a Real Value Example 2. Reading a Real Value

Tricon Communication Guide


Programming for Tricon Masters 107

Function Blocks for Communicating with Trident Slaves


When a Tricon master interfaces with a Trident slave, the following function
blocks can be used.

Data Type Function Block


Application Notes
in Slave in Tricon Master
MBWRITE_BOOL
BOOL • Values are True (1) and False (0).
MBREAD_BOOL
MBREAD_DINT • Although the DINT data type uses
signed 32-bit integers, only the least
DINT MBWRITE_DINT significant 16 bits are transferred.
• Values should be limited to the range of
zero through 32,767.
MBREAD_REAL_TRD • Each REAL aliased variable in the
REAL Trident slave must have scaling disabled
MBWRITE_REAL_TRD in the Min/Max dialog box.

Function Blocks for Communicating with Tricon Slaves


When a Tricon master interfaces with a Tricon slave, the following function blocks
can be used.

Data Type Function Block


Application Notes
in Slave in Tricon Master
MBWRITE_BOOL
BOOL • Values are True (1) and False (0).
MBREAD_BOOL
MBREAD_DINT • Although the DINT data type uses
signed 32-bit integers, only the least
MBWRITE_DINT significant 16 bits are transferred.
DINT
• Values should be limited to the range of
zero through 32,767.
MBREAD_REAL • The SPECIAL parameter on each of
REAL these function blocks should be set to
MBWRITE_REAL False.

Chapter 6 Modbus Communication


108 Programming for Tricon Masters

Sample Modbus Read Function Block


The following diagram shows a sample Modbus Read function block in a
TriStation application that includes programming for EICM serial port 1 (as
indicated by the Port parameter). The function block is reading values from Slave
Station 2 (as indicated by the Station parameter) through EICM serial port 1 and
storing the values in local variables.

Slave
Station 2

Modbus Serial Link

TriStation Programming
for Modbus Master Port

Starting Alias 1
31001
Serial Port Number 32
1
Slave Station Address 2

Because the Starting Alias is 31001, the


D01 through D32 data parameters have
aliases 31001 through 31032.

Tricon Communication Guide


Programming for Tricon Masters 109

Sample Modbus Write Function Block


The following diagram shows a sample Modbus Write function block in a
TriStation application that includes programming for EICM serial port 1 (as
indicated by the Port parameter). The function block is writing values to Slave
Station 2 (as indicated by the Station parameter) through EICM serial port 1.

Slave
Station 2

Modbus Serial Link

TriStation Programming
for Modbus Master Port

Starting Alias

Serial Port Number


Slave Station Address

Because the Starting Alias is


40251, the D01 through D32
data parameters have aliases
40251 through 40282.

Chapter 6 Modbus Communication


110 Programming for Tricon Masters

Processing of Modbus Function Blocks


During each scan, a Triconex controller initiates up to five Modbus read or write
operations for each Modbus master port. Each Modbus master port is limited to ten
outstanding requests for a Modbus operation. A Modbus operation might require
up to six scans to complete. When a Modbus operation is completed, the controller
initiates the next pending request for a Modbus operation.
For example, with a single Modbus master port and a TriStation application that
uses twelve MBREAD function blocks and no MBWRITE or MBCTRL function
blocks, the controller initiates the first five Modbus reads during the first scan.
During the second scan, the controller initiates the sixth through tenth Modbus
reads. When a Modbus read is completed, the controller initiates the eleventh
Modbus read. When the next Modbus read is completed, the controller initiates the
twelfth Modbus read. As each Modbus read is completed, the controller initiates
the next pending request for a Modbus read.
For related information, see “Estimating Message Response Time” on page 193.

Tricon Communication Guide


Programming for Tricon Slaves 111

Programming for Tricon Slaves


If you configure an EICM serial port on the Tricon controller as a Modbus slave,
aliases must be assigned to Tricon points that will be accessed by the external
Modbus master. For more information, see “Aliases and Tagnames” on page 39.
The Tricon controller supports BOOL, 32-bit DINT (double integer) and 32-bit
REAL numbers, but traditional Modbus protocol supports only Booleans and
16-bit integers. For DINT points in a Tricon slave, the Tricon transfers only the
least significant 16 bits. For each REAL point in a Tricon slave, you must decide
whether to use special aliases or the scaling feature to transmit REAL values as
Modbus integers. The following sections provide more information about scaling.

Using Special Aliases to Transmit Real Values


For processing Modbus integers as REAL values, the Tricon controller provides
special aliases which map two 16-bit Modbus integers into one 32-bit REAL value.
One Modbus integer is mapped to the 16 most significant bits in the REAL number,
and the other Modbus integer is mapped to the 16 least significant bits in the REAL
number.

Reading Real Values


As shown in the following example, a Modbus master can read a REAL value from
two consecutive special aliases which correspond to a REAL alias. The Tricon
controller splits the 32-bit REAL value into two 16-bit integers and places them in
the special aliases to be read by the Modbus master.

Tricon Controller

Modbus Master
Alias 41001 for
Real Variable

Modbus Reads
Integer - 16 Most Significant Bits Special Alias 42001

Integer - 16 Least Significant Bits Special Alias 42002

Chapter 6 Modbus Communication


112 Programming for Tricon Slaves

Writing Real Values


As shown in the following example, a Modbus master can write a REAL value to
the Tricon controller by transmitting two 16-bit integer values to two consecutive
special aliases. The controller concatenates the two 16-bit integers to form a 32-bit
REAL value.

Tricon Controller

Modbus Master
Alias 41001 for
Real Variable

Modbus Writes
Integer - 16 Most Significant Bits Special Alias 42001

Integer - 16 Least Significant Bits Special Alias 42002

Table of Special Aliases


Use the following table to select special aliases for reads and writes to specific
REAL aliases in the Tricon controller. The Most and Least columns refer to Most
Significant Bits and Least Significant Bits.

Variable Type Aliases Special Aliases


Most Least Most Least
32001 34001 34002 - or - 44001 44002
32002 34003 34004 - or - 44003 44004
Input Real, . . . . . .
Read Only . . . . . .
. . . . . .
32120 34239 34240 - or - 44239 44240

Tricon Communication Guide


Programming for Tricon Slaves 113

Variable Type Aliases Special Aliases


Most Least Most Least
33001 35001 35002 - or - 45001 45002
33002 35003 35004 - or - 45003 45004
Memory Real, Read . . . . . .
Only . . . . . .
. . . . . .
34000 36999 37000 - or - 46999 47000
41001 42001 42002
41002 42003 42004
Memory Real, . . . . . .
Read/Write . . . . . .
. . . . . .
42000 43999 44000

Chapter 6 Modbus Communication


114 Programming for Tricon Slaves

IEEE Standard Format


REAL values processed by the Tricon controller adhere to the IEEE Standard for
Binary Floating-Point Arithmetic. The standard format is illustrated in the
following diagram. For more information, see IEEE Std 754-1985.

Tagname

Aliases 45001 or 35001 45002 or 35002

Byte 0 1 0 1

Bit 31 22 15 0

8-bit exponent 23-bit fraction

Sign of Fraction

Tricon Communication Guide


Programming for Tricon Slaves 115

Transmitting Real Values with Scaling


When scaling is used, the Tricon controller transmits REAL values as Modbus
integers in the following manner:
• When a Modbus master writes a 16-bit integer to a Tricon slave, the Tricon
scales the integer to a 32-bit REAL number before using it in the TriStation
application.
• When a Modbus master reads a 32-bit REAL variable from a Tricon slave,
the Tricon scales the REAL variable to a 16-bit integer before transmitting
it.
The Tricon controller scales integer and REAL numbers using the values you
specify for Min Span/Max Span and the Modbus Range. These properties operate
according to linear transformation equations for Modbus reads and writes. Values
above the Max Span or below the Min Span are clamped to the respective limit.
The same principle applies to values outside the Modbus range.

Note Modbus Min and Modbus Max in the following equations and graphs refer
to the Min and Max limits of the Modbus Range property in the EICM
configuration dialog box for a serial port.

Scaling Integers to REALs (Modbus Writes)


In the following example, a Modbus master with a typical numeric range writes an
in-range integer value to the Tricon controller where it is scaled to a REAL value
for use in the control program.

Tricon Controller

Modbus Master

Numeric Range: 0 to 32767 Real Value


in Alias

Modbus Write
Modbus Integer 15337 Scaling

Chapter 6 Modbus Communication


116 Programming for Tricon Slaves

Linear Transformation Equation and Graph

(MaxSpan – MinSpan)
Real Value = ------------------------------------------------------------------------- ´ (Modbus Value – Modbus Min) + Minspan
(Modbus Max – Modbus Min)

Real
Value

Tricon scales Integer to REAL


Max Span

Min Span

16-bit Integer
Modbus Modbus (Modbus Value)
Min Max

Scaling REALs to Integers (Modbus Reads)


In the following example, a Modbus master with a typical numeric range reads an
in-range integer value from the Tricon controller which scales the REAL value to
an integer before transmitting it.

Tricon Controller

Modbus Master

Numeric Range: 0 to 32767 Real Value


in Alias

Modbus Read
Modbus Integer 15337 Scaling

Tricon Communication Guide


Programming for Tricon Slaves 117

Linear Transformation Equation and Graph

(Modbus Max – Modbus Min)


Modbus Value = ------------------------------------------------------------------------- ´ (Real Value – MinSpan) + ModbusMin
(Maxspan – MinSpan)

16-bit Integer

Tricon scales REAL to Integer


Modbus
Max

Modbus
Min

Real Value
Min Span Max Span

Chapter 6 Modbus Communication


118 Programming for Tricon Slaves

Procedure for Scaling


To use the scaling feature, you must specify the numeric range of 16-bit integers
used by the Modbus master. You can also specify numeric spans for individual
REAL points in your TriStation application.

▼ To use scaling in your TriStation application:


1 Open your TriStation project and go to the Tricon Configuration editor.
2 Under Tricon System Configuration in the tree structure, click the Hardware
Allocation icon to display the modules that are configured for this system.
3 Double-click the EICM icon to open the Properties dialog box.
4 In the Properties dialog box, click Setup to display the configuration dialog box.

5 For Modbus Range, verify that the Min and Max limits apply to the Modbus
master. If not, make the necessary adjustments.
To determine the appropriate Min and Max limits for your application, see the
user’s manual for your Modbus master. Commonly used values are 0 to 32,767
for a generic operator workstation, and 0 to 9,999 for a Honeywell DHP.
TriStation allows Min limits as low as -32,768 and Max limits as high as 32,767.
6 Click OK to close the configuration dialog box.
7 In the Tricon Point Connections window, select the desired REAL tagname and
open the Properties dialog box.

Tricon Communication Guide


Programming for Tricon Slaves 119

The Min/Max tab is displayed, as shown on the following screen.

8 For Span Calibration, enter Min Span and Max Span values for the variable.
9 For Number of decimal places to display, enter the desired value and click the
Confirm button.
Repeat steps 7 through 9 for other REAL points as required by your application.

Chapter 6 Modbus Communication


120 Sample Modbus Programs

Sample Modbus Programs


The sample programs described in this chapter are in the EXMODBUS project on
the TriStation CD. These programs show how to use the Modbus Read and Write
function blocks for transmitting aliased data, how to set time-out and retry values
for Modbus communication, and how to control the flow of data from slave to
master. Topics in this section include:
• Reading and writing DINT data
• Reading and writing REAL data
• Reading and writing BOOL data
• Using MBCTRL to set time-out and retry values
• Controlling the flow of data

Reading and Writing DINT Data


The following programs show how to read and write N values of type DINT from
Port P, Station S, starting at specified aliases.
• MB_EX1_READ_DINT_FBD
• MB_EX4_WRITE_DINT_FBD

Reading and Writing REAL Data


The following programs show how to read and write N values of type REAL from
Port P, Station S, starting at specified aliases.
• MB_EX2_READ_REAL_FBD
• MB_EX5_WRITE_REAL

Reading and Writing BOOL Data


The following programs show how to read and write N values of type BOOL from
Port P, Station S, starting at specified aliases.
• MB_EX3_READ_BOOL_FBD
• MB_EX6_WRITE_BOOL

Tricon Communication Guide


Sample Modbus Programs 121

Setting Time-out and Retry Values


The MB_EX7_CONTROL program shows how to use the MBCTRL function
block in the Tricon Library to set time-out and retry values for the communications
initiated by a Modbus master port.

Controlling the Flow of Data


The MB_EX8_FLOW_CONTROL program shows how to control the flow of data
from a Modbus slave to a Modbus master.

Counting Values and Verifying Outputs


The following programs count the number of errors, reads and writes, time-outs,
and other values; and verify the consistency of outputs.
• MB_READ_TEST
• MB_WRITE_TEST

Chapter 6 Modbus Communication


122 Sample Modbus Programs

Tricon Communication Guide


CHAPTER 7

Related Communication Features

This chapter describes the time synchronization and printing features that can be
used with Tricon controllers.
Topics include:
“Overview” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 124
“Time Synchronization” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 125
“Parallel Printing” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 133

Tricon Communication Guide


124 Overview

Overview
This chapter describes the time synchronization and printing features that can be
used with Tricon controllers.
Time Synchronization protocol allows networks of Tricon and Trident controllers
to be synchronized with each other, and optionally, with external devices. In
addition, a Tricon controller with an NCMG module can receive time adjustments
from the Global Positioning System (GPS) by using the Trimble Acutime 2000
Synchronization Kit.
A Tricon controller can send brief ASCII text messages to a printer that is
connected to a parallel port on an EICM. The printer must be compatible with the
Centronics interface provided by the EICM parallel port. A TriStation application
must include print function blocks to send messages to a printer.

Tricon Communication Guide


Time Synchronization 125

Time Synchronization
If you have multiple Triconex controllers on an Ethernet network, you can
synchronize their time with:
• The master node (the controller with the lowest node number)
• An external device, such as an OPC client, that writes time values to a
TriStation project
• The Global Positioning System (GPS)
• A combination of the master node and an external device or the GPS
The following sections provide more information about these strategies and
instructions for setting the Tricon clock and setting time synchronization properties
on the communication modules.

Master Node in a Network


In a network of Triconex controllers, the master node determines the time for all
controllers that are synchronized with it.
The master node is the controller with the lowest node number. For example, in a
network of five controllers which have node numbers 1, 2, 3, 4, and 5, Node 1 is
the master node. If Node 1 goes down, Node 2 becomes the master node. When
Node 1 comes back online, it again becomes the master node.
In a typical Triconex network, the controllers are synchronized with the master
node within plus or minus 25 milliseconds. When a controller is synchronized with
the master node, it rejects time adjustment attempts from all other sources.
You must use Ethernet ports on ACMs or NCMs to synchronize Tricon controllers
in a network with the master node. For instructions, see “Setting Time
Synchronization Properties” on page 131. If you plan to synchronize ACMs with
the master node, contact Triconex Technical Support for assistance.

! CAUTION
In a network of Triconex controllers, all controllers with low node numbers should
be configured for time synchronization. If a Trident controller becomes the master
node but is not configured for time synchronization, none of the controllers in the
network can be synchronized.

Chapter 7 Related Communication Features


126 Time Synchronization

Time Adjustments from External Devices


A Tricon controller can receive time adjustments from external devices such as a
DCS or an OPC client. When the OPC Server application is used, the OPC client
can adjust the Tricon clock using the Device Clock tagname which is derived from
Tricon system status information in the OPC Server Configuration. For more
information, see the user’s manual for the OPC client application you are using.
The Foxboro DCS is the only external device that can send time adjustments to the
Tricon controller through the ACM. This is done through the NET1 port on the
ACM. For instructions, see the ACM User’s Guide.
Another way for an external device to adjust the Tricon clock is to write aliased
data to the TIMESET or TIMEADJ function blocks in the TriStation application.
This can be done though an Ethernet port or a serial port. If you need assistance
with the specialized programming that is required, please contact Technical
Support.
To allow an external device to adjust the Tricon clock, you must configure an ACM
or NCM for time synchronization, and you must configure the TriStation project to
allow write access. For instructions, see the following sections:
• “Setting Time Synchronization Properties” on page 131
• “Write Access by External Devices” on page 40

Tricon Communication Guide


Time Synchronization 127

GPS Time Adjustments


A Tricon controller with a Network Communication Module for GPS Interface
(NCMG) can receive time adjustments from the Global Positioning System (GPS)
if you use the Trimble Acutime 2000 Synchronization Kit. This kit is available
from Triconex or Trimble. To use the kit, you must connect it to an RS-232 port on
the NCMG for communication using the Trimble Standard Interface Protocol. In
the TriStation project, you must configure the NCMG for GPS time
synchronization. For instructions on installing the Acutime 2000 kit, see the
Acutime 2000 User Guide.
When an NCMG is connected to an Acutime 2000 kit, the GPS adjusts the minutes,
seconds, and milliseconds of the Tricon clock to the nearest 30-minute time zone
within 5 milliseconds. For example, if Tricon time is 14:25 and GPS time is 17:58,
Tricon time is adjusted to 14:28.

! CAUTION
To ensure the accuracy of GPS time adjustments, the Tricon clock must be set to
within 10 minutes of the correct local time. For instructions, see “Setting the
Controller Clock” on page 130.

Redundant Configuration
The GPS feature can be used in a redundant configuration which requires two
NCMG modules and two Acutime 2000 Synchronization Kits, as shown in the
following diagram. Typically, the left (primary) NCMG adjusts the time. The right
(redundant) NCMG begins to adjust the time if the left NCMG detects a problem
with its Acutime kit or if communication with the left module fails.
Several types of faults can cause the Tricon to switch control to the redundant
NCMG module. The following situation is an example. Each NCMG module
requests an event timestamp from the Acutime kit every 10 seconds. If the event is
not received within 5 seconds, the Tricon assumes there is a failure in the NCMG
or the Acutime kit and switches control to the redundant NCMG module. For more
information, see the Acutime 2000 Smart Antenna User Guide.

Chapter 7 Related Communication Features


128 Time Synchronization

Global Positioning
Satellite

Trimble Acutime 2000 Synchronization Kit

Smart Antennas Mounted on Rooftop

RS-485 Cables
Up to 1000 Ft

Tricon Controller

SIMs

RS-232 Cables
M M M
P P P
Up to 25 Ft
A B C

Serial Ports On
Redundant NCMGs

Tricon Communication Guide


Time Synchronization 129

Combination Schemes
In a typical configuration, Triconex controllers on a network are synchronized with
the master node. In addition, the master node can accept time adjustments from an
external device so that the external time prevails for all controllers on the network.
Examples of external time sources are an OPC client and the GPS.

Guidelines for Networks


The following guidelines apply to Triconex controllers in a network whose time is
synchronized with an external device:
• Every controller to be synchronized must have its Ethernet port configured
for time synchronization, including the master node.
• If a controller is synchronized with the master node, it rejects time
adjustment attempts from all other sources.
• In a redundant network of Tricon controllers that each have two NCMs
installed, you can implement redundant time synchronization by selecting
the time synchronization property for both NCMs in TriStation.

! CAUTION
In a network of Triconex controllers, all controllers with low node numbers should
be configured for time synchronization. If a Trident controller becomes the master
node but is not configured for time synchronization, none of the controllers in the
network can be synchronized.

Chapter 7 Related Communication Features


130 Time Synchronization

Setting the Controller Clock


Before implementing a time synchronization strategy, you should ensure that the
clock of the affected controller is set to the correct local time. When an application
is downloaded and run, the controller automatically sets the clock to the PC time.
You can reset the clock at any time while the application is running, without having
to download again. The need for accuracy depends on your application.

▼ To set the controller clock:

1 On the TriStation PC, right-click the time icon in the message bar or open the
Date/Time dialog box from the Control Panel.
2 Ensure that the time is set to the correct local time.
3 Open the TriStation application that is running in the controller which will
receive time adjustments from the GPS.
4 From the Tricon menu, select the Control Panel.
5 From the Commands menu, select the Connect command.
6 From the Commands menu, select the Set Calendar Clock command and click
Yes when the prompt asks whether you want to Set Calendar Clock the current
configuration.
The Tricon clock is now set to the PC time, that is, to the correct local time.

Tricon Communication Guide


Time Synchronization 131

Setting Time Synchronization Properties


To synchronize Tricon controllers in a network with the master node or an external
device, you must use NET2 ports on ACM modules or NET1 ports on NCM and
NCMG modules. This section provides instructions for setting the time
synchronization properties on these modules.

▼ To set time synchronization properties for an ACM:


1 Open your TriStation project and go to the Configuration editor.
2 Under System Configuration in the tree structure, click the Hardware Allocation
icon to display the modules that are configured for this system.
3 Double-click the ACM icon to open the Properties dialog box, then click Setup
to display the configuration properties for the ACM, as shown below.

Time
synchronization
properties

4 Select one of the following properties as needed.

On NET1 enable time synchronization with external source


Select this property if you want to synchronize the Tricon clock with the Foxboro
DCS, which must be connected to NET1.

Chapter 7 Related Communication Features


132 Time Synchronization

On NET2 enable time synchronization with Tricon master node


Select this property if you want to synchronize the Tricon clock with the master
node in a network of Triconex controllers. Please contact Triconex Technical
Support for assistance with this type of network.

None
Select this property if you do not want to use time synchronization.

▼ To set time synchronization properties for an NCM or NCMG:


1 Open your TriStation project and go to the Configuration editor.
2 Under System Configuration in the tree structure, click the Hardware Allocation
icon to display the modules that are configured for this system.
3 Double-click the NCM or NCMG icon to open the Properties dialog box.
4 In the Properties dialog box, click Setup to display the configuration properties,
as shown below.

Time
synchronization
properties

Tricon Communication Guide


Parallel Printing 133

5 For an NCMG, you must select the property called Global Positioning System
Installed to synchronize the controller with the GPS (Global Positioning
System).
In a Peer-to-Peer network, you should select this property only for a master node
NCMG.
6 Select the property called On NET1 enable time synchronization to synchronize
this controller with the master node in a Peer-to-Peer network.
If this controller is the master node, you should still select this property.

Parallel Printing
A Tricon controller can send brief ASCII text messages to a printer that is
connected to a parallel port on an EICM. These messages are typically used for
alarms, status and maintenance. The printer must be compatible with the
Centronics interface provided by an EICM parallel port.
To send messages to a printer, a TriStation application must include standard print
function blocks. Print messages are typically used for alarms, status and
maintenance. A sample alarm message might include the name of an analog input
point, its timestamp and value, and a statement that the value is out of range.
Alarm printing is an economical solution for a closed Tricon system which
includes only four or five modules. When the Tricon system is larger or connected
to a DCS, alarms are typically displayed by an operator workstation.

Printing and Scan Time


The printing feature of a Triconex controller is designed for small printing loads,
that is, critical messages which are printed only if specific events or alarms occur.
Each time a message is printed, the print function blocks in the TriStation
application are executed and the scan time increases.
Typically, the print function blocks are subject to conditional execution which
means they are not executed every scan. When you set the scan time in TriStation,
make sure it includes the execution times for all conditional statements in your
application.
If the scan time is not long enough, the execution of all conditional statements
(when the conditions are true) could result in scan-time overruns. You can

Chapter 7 Related Communication Features


134 Parallel Printing

minimize this problem by limiting the amount of printer output. If this is not
possible due to application requirements, you should use an event logger on a PC
for printing. Triconex provides the SOE Recorder utility for this purpose which is
described in the SOE Recorder User’s Guide.

Printing Setup
A Centronics-compatible printer is connected to the EICM using a standard PC
printer cable, as shown in the following diagram. The maximum cable length is 5
to 6 meters (15 to 20 feet), depending on the quality of the cable. For pin-out
information, see the EICM User’s Guide.

Tricon Controller

Centronics-Compatible
M M M Printer
P P P
A B C
Standard
Printer Cable

Parallel Port 5
on EICM

Installing Your Printer


Most printers require configuration with an install program on a workstation or
other device. Follow the instructions provided by the manufacturer, and run the
diagnostic routine if one is included with the package.
To print from a Triconex controller, the printer driver that comes with the printer
package is not needed. Your TriStation project must identify the EICM parallel
port to which the printer cable is connected, as explained in the following section.

Tricon Communication Guide


Parallel Printing 135

Configuring a Parallel Port for Printing


After you have installed your printer by following the manufacturers’ instructions,
you must use TriStation to configure a parallel port on the EICM.

▼ To configure a parallel port for printing:


1 In your TriStation project, go to the Configuration editor.
2 Under Hardware Allocation, double-click the EICM icon to open the Properties
dialog box.
3 Click the Setup button to open the EICM Configuration dialog box.
4 In the Port Selection area, you must select Port 5 for a left EICM or Port 10 for
a right EICM. These are the only parallel ports on the module.
5 For Protocol, select Printer.
6 For Rows and Columns, enter the desired number of lines per page (rows) and
characters per line (columns). For guidelines, use the specifications from the
printer manufacturer.

7 Click OK to complete the configuration of the parallel port for printing.


To print, you must use function blocks in the TriStation application. For more
information, see “Using Print Function Blocks” on page 136.

Chapter 7 Related Communication Features


136 Parallel Printing

Using Print Function Blocks


A TriStation application must use print function blocks in order to send ASCII
messages to a printer. The following print function blocks are available in the
Tricon Library.

Print Function Block Purpose


PRINT_BOOL Prints a three-character field containing either Off or On.
PRINT_CDT Prints the current date and time.
PRINT_CRLF Prints a new line (carriage return and line feed).
PRINT_CTOD Prints the current time of day.
PRINT_DINT Prints a DINT value.
PRINT_REAL Prints a REAL value.
PRINT_STRING Prints a string of text.
PRINTR_FLUSH Clears the print buffer.

Specifying the Parallel Port


All of the print function blocks have a PRINTER parameter which must be used to
specify the number of the parallel port on the EICM to which the printer cable is
connected. Values of the PRINTER parameter can be 5 for a left EICM port or 10
for a right EICM port. For more information, see the Triconex Libraries Manual.

Tricon Communication Guide


APPENDIX A

EICM Capabilities

This appendix describes the operation and physical characteristics of the Enhanced
Intelligent Communication Module (EICM) for the Tricon controller.
Topics include:
“EICM Operation” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 138
“Physical Description” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 141

Tricon Communication Guide


138 EICM Operation

EICM Operation
The Enhanced Intelligent Communication Module (EICM) enables communica-
tion with the following devices:
• Modbus masters and slaves
• Other Triconex controllers
• TriStation PC
• Centronics-compatible printers
Each EICM has four serial ports and one parallel port which can operate
concurrently. The four serial ports are uniquely addressed and can be used for
Modbus or TriStation communication. Modbus communication can be performed
in either RTU or ASCII mode. The parallel port provides a Centronics interface to
a printer.
A Tricon controller supports up to two EICMs which must reside in one logical
slot. This arrangement provides a total of eight serial ports and two printer ports.
The hot-spare feature is not available for the EICM. However, you can connect
redundant devices to ports on two EICMs in the same logical slot. For more
information, see “Redundant Devices” on page 15.
Each EICM supports an aggregate data rate of 57.6 kilobits per second, that is, the
total data rate for all four ports must be less than or equal to 57.6 kilobits per
second. Each EICM port provides 500 volts DC isolation between the external
signals and Tricon logic ground.
Any standard Modbus device can communicate with the Tricon controller by
means of the EICM, provided that aliases are assigned to the program variables.
For more informations, see “Aliases and Tagnames” on page 39.

Message Processing
As shown in the following diagram, EICM modules communicate with the Main
Processors (MPs) by means of the triplicated COMM Bus. The COMM Bus has
three channels (one for each MP) which are connected to each EICM module.
A message received by an EICM port is passed to all three MPs over the COMM
Bus. The TriBus votes on the message before sending it to the MPs for processing,
and returns the response to the COMM Bus after processing is complete. The
COMM Bus then forwards the response to the EICM port.

Tricon Communication Guide


EICM Operation 139

MP A
TriBus
TriBus

TriBus
MP B MP C

Left Serial 1
Position Serial 2
EICM Serial 3
Serial 4
Comm
Bus Leg C
Serial 1
Comm Bus Leg B Right
Serial 2
Position
Serial 3
EICM Serial 4
Comm Bus Leg A

The EICM processes messages as described in the following sections.

TriStation Messages
1 Receives the message and transmits it to the MPs over the COMM Bus
2 Votes the message request with other MPs over TriBus
3 Receives the message from the COMM Bus, processes the message and
transmits a response

Modbus Read Queries


1 Receives the read query
2 Gets the requested alias from the COMM Bus voted data pool
3 Transmits the response

Modbus Write Commands


1 Receives the write request, transmits it to the MPs over the COMM Bus
2 Votes the write request with the other MPs over TriBus

Appendix A EICM Capabilities


140 EICM Operation

3 Receives the message from the COMM Bus, processes the message and
transmits a write confirmation response

Typical Message Response Time


Because all messages except Modbus read queries require Tribus voting, typical
message response times require three or more scans to complete.
For more information, see “Estimating Message Response Time” on page 193 or
contact Triconex Technical Support.

Tricon Communication Guide


Physical Description 141

Physical Description
Each EICM includes four serial ports and one parallel port with indicators that
blink when data is being transmitted and received.

Serial Port Specifications


An EICM has four serial ports which can be connected to Modbus master or slave
devices in point-to-point or multi-point configurations. Each serial port provides a
DB-25-pin male connector. For each port, you must set a switch on the side of the
EICM module to select the RS-232, RS-422, or RS-485 electrical interface. For
instructions, see “Specifying Electrical Interfaces” on page 98. For pin-out
information, see the EICM User’s Guide.

Feature Specification
Physical features RS-232, RS-422 or RS-485 electrical interface
Other options are configurable from TriStation.
Connectors Male DB-25-pin, DTE standard, shielded
RS-232 maximum cable length 15 m (50 ft)
RS-422 maximum cable length 1.2 km (4,520 ft)
RS-485 maximum cable length 1.2 km (4,520 ft)
Data transmission rates 1200, 2400, 4800, 9600, or 192,000 Kbits per second
Protocols Master, slave, or master/slave
RTU or ASCII mode
Galvanic isolation 500 V DC
Logic power < 10 W

Parallel Port Specifications


An EICM module has one parallel port which can be connected to a Centronics-
compatible printer. The port is galvanically isolated to 500 volts DC and provides
a female 25-pin D series connector for use with a standard printing cable. The
maximum cable length is 5 to 6 meters (15 to 20 feet), depending on the quality of
the cable.

Appendix A EICM Capabilities


142 Physical Description

PASS

FAULT

ACTIVE

1TX
1RX

Serial Port #1
for Modbus interface

2TX
2RX

Serial Port #2
for Modbus interface

3TX
3RX

Serial Port #3
for Modbus interface

4TX
4RX

Serial Port #4
for TriStation
or Modbus

PRT

Parallel Port #5
for Centronics-
compatible printer

EICM
4119

Tricon Communication Guide


Physical Description 143

Port Numbers and Connections


For configuration in TriStation, EICM ports in a left and right logical slot have the
following port numbers and can be connected to the following devices.

Left Slot Right Slot Type of Port Connection


01 06
02 07 Modbus Device
Serial
03 08 or TriStation

04 09
05 10 Centronics-compatible
Parallel
parallel printer

Ports 4 and 9 are the defaults for TriStation connection, although Ports 1 through 3
and Ports 6 through 8 can also be used for TriStation.

EICM Communication Indicators


The EICM has a yellow TX and RX indicator for each serial port. TX blinks each
time an EICM port transmits a message and RX blinks each time an EICM port
receives a message from an external Modbus device or TriStation. If a TX indicator
stops blinking, the EICM module or the controller could have a problem. If an RX
indicator stops blinking, the external Modbus device or TriStation could have a
problem.

Serial 1 Serial 2 Serial 3 Serial 4


RX/TX RX/TX RX/TX RX/TX Description
Yellow Yellow Yellow Yellow Normal response.
blinking blinking blinking blinking EICM is communicating with a
Modbus device or TriStation.

Appendix A EICM Capabilities


144 Physical Description

Protocols Supported
Ports on the EICM support the following protocols.

Protocol Serial Ports Printer Ports


TriStation ✓
Modbus Slave ✓
Modbus Master ✓
Modbus Master/Slave ✓
Parallel Printing ✓

For summary information about the protocols, see Chapter 1, “Introduction.” For
detailed information, see the related chapters and appendices.

Tricon Communication Guide


APPENDIX B

NCM and NCMG Capabilities

This appendix describes the operation and physical characteristics of the Network
Communication Module (NCM) and the Network Communication Module for
GPS Time Synchronization (NCMG).
Topics include:
“NCM Operation” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 146
“Physical Description” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 149

Tricon Communication Guide


146 NCM Operation

NCM Operation
The NCM and NCMG are optional modules for the Tricon controller that can
communicate with other Triconex controllers, with external devices on Ethernet
networks, and with the Global Positioning System (GPS). The NCM and NCMG
support several Triconex protocols and applications and client/server applications
from other manufacturers.
The NCM provides two BNC connectors as ports with the following capabilities:
• NET1 supports Peer-to-Peer protocol for safety networks comprised of
Triconex controllers only.
• NET2 supports open communication with external devices on an Ethernet
network. These devices can include PCs which are running Triconex
applications such as TriStation, SOE Recorder, OPC Server, and DDE
Server or user-written applications.
The NCMG also provides an RS-232 serial port which can be connected to the
Trimble Acutime 2000 Synchronization Kit for GPS time synchronization.
The Tricon controller supports two NCMs or NCMGs in one logical slot, or one of
these modules in the COM slot. If two modules are in one slot, they function
independently, not as hot spares. Each module can be connected to a separate
network, or both can be used in a redundant configuration. For more information,
see “Redundant Devices” on page 15.
The NCM and NCMG are compatible with the IEEE 802.3 electrical interface and
operate at communication speeds up to 10 megabits per second. The modules
connect with external host devices by means of 10Base2 coaxial cabling at typical
distances up to 185 meters (607 feet). Distances up to 4,000 meters (2.5 miles) are
possible using repeaters and standard (thick-net or fiber-optic) cabling.
The Main Processors typically refresh data on the NCM and NCMG once per scan.

Tricon Communication Guide


NCM Operation 147

Message Processing

Note Throughout this section, the name NCM represents both the NCM and the
NCMG modules.

As shown in the following diagram, NCM ports communicate with all three MPs
by means of the COMM Bus. Each NCM supports two COMM Buses—a left bus
and a right bus—so that a fault on one NCM will not affect the other NCM.

MP A
TriBus
TriBus

TriBus
MP B MP C

Left
Position NET1 Ethernet - 10Base2
NET2 Ethernet - 10Base2
NCM

Comm
Bus Leg C
Comm Bus Leg B Right
Position NET2 Ethernet - 10Base2
NET2 Ethernet - 10Base2
NCM
Comm Bus Leg A

A message received by a NCM port is passed to all three MPs over the COMM Bus.
The TriBus votes on the message before sending it to the MPs for processing, and
returns the response to the COMM Bus after processing is complete. The COMM
Bus then forwards the response to the NCM port.
The NCM processes messages as described in the following sections.

TriStation, Peer-to-Peer, and Time Synchronization Messages


1 Receives the message and transmits it to the MPs over the COMM Bus
2 Votes the message request with other MPs over TriBus
3 Receives the message from the COMM Bus, processes the message and
transmits a response

Appendix B NCM and NCMG Capabilities


148 NCM Operation

TSAA Read Queries


1 Receives the read query
2 Gets the requested alias from the COMM Bus voted data pool
3 Transmits the response

TSAA Write Commands


1 Receives the write request, transmits it to the MPs over the COMM Bus
2 Votes the write request with the other MPs over TriBus
3 Receives the message from the COMM Bus, processes the message and
transmits a write confirmation response

Typical Message Response Time


Because most messages (except TSAA read queries) require TriBus voting, typical
message response times require three or more scans to complete. For more
information, contact Triconex Technical Support.

Tricon Communication Guide


Physical Description 149

Physical Description
An NCM includes two Ethernet ports which operate at 10 megabits per second. An
NCMG also includes an RS-232 serial port for communication with the GPS.

Specifications
The following specifications apply to both the NCM and NCMG, except for the
serial port which is functional on the NCMG only.

Feature Specification
Ethernet ports Two BNC connectors that require 10Base2 coaxial
cables
External transceiver ports Reserved
Serial port One RS-232 connector for GPS time synchronization
Maximum cable length is 15 m (50 ft)
Galvanic isolation 500 V DC (applies to Ethernet and serial ports)
Protocols supported See “Protocols Supported” on page 151.
Communication speed 10 Mbps
Status indicators
Module status Pass, Fault, Active
Port activity TX (Transmit) — 1 per port
RX (Receive) — 1 per port
Logic power < 20 W

Front Panels
The following illustration shows ports and indicators on the front panels of the
NCM and NCMG modules.

Appendix B NCM and NCMG Capabilities


150 Physical Description

PASS PASS

FAULT Module Status FAULT


Indicators
ACTIVE ACTIVE

NET 1 NET1 Port NET 1

BNC Connector for


10Base2 Coaxial Cable
TX TX
RX RX

15 Pin D Connector
(Reserved)

NET 2 NET2 Port NET 2

BNC Connector for


10Base2 Coaxial Cable

TX TX
RX RX

15 Pin D Connector
(Reserved)

COMM COMM

TX TX
RX RX
RS-232 Serial Port
(25-Pin D Connector)

For GPS Time


Synchronization on NCMG

Reserved on NCM

NCM NCM
4329G 4329

Tricon Communication Guide


Physical Description 151

Communication Indicators
The NCM and NCMG have yellow TX and RX indicators for the NET1 and NET2
Ethernet ports and for the COMM serial port. TX blinks each time an NCM port
transmits a message and RX blinks each time an NCM port receives a message
from an external device. If a TX indicator stops blinking, the NCM module or the
controller could have a problem. If an RX indicator stops blinking, the external
device could have a problem.

NET1 NET2 COMM


RX/TX RX/TX RX/TX Description
Yellow Yellow Normal response.
blinking blinking —1
The Ethernet port is communicating with an
Ethernet device or TriStation.
— — Yellow Normal response.
blinking The COMM serial port is communicating with the
Trimble Acutime 2000 Synchronization Kit.
1. This symbol ( — ) means the indicator is not important for this condition.

Protocols Supported
Ports on the NCM and NCMG support the following protocols.

NET1 Ethernet NET2 Ethernet COMM Serial


Supported Protocols
(NCM and NCMG) (NCM and NCMG) (NCMG Only)
TriStation ✓
TSAA Client/Server ✓
Peer-to-Peer ✓
Triconex Time Synchronization ✓ ✓
Trimble GPS Time Synchronization ✓

For summary information about the protocols, see Chapter 1, “Introduction.” For
detailed information, see the related chapters and appendices.

Appendix B NCM and NCMG Capabilities


152 Physical Description

Tricon Communication Guide


APPENDIX C

TSAA Protocol

This appendix provides a programmer’s reference to TSAA which is a messaging


protocol used for client/server applications.
Topics include:
“Overview” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 154
“TSAA Messages” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 157
“Response Codes” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 189

Tricon Communication Guide


154 Overview

Overview
Triconex System Access Application (TSAA) protocol is a messaging protocol
which provides message formats used in application programs that read and write
data to Triconex controllers. TSAA is based on a client/server model which allows
a client to request information from an external device using a server application.
You can use TSAA to develop the following types of applications:
• Control (Read/Write) Applications, such as an operator interface station,
that require access to the status of the Triconex controller and the ability to
write data to the controller
• Monitor (Read-Only) Applications, such as SOE Recorder, that receive data
from the controller

Differences Between Tricon and Trident


TSAA protocol works for both Tricon and Trident controllers in essentially the
same way. The difference between Tricon and Trident is in the way bits are ordered
for data and the way symbol table information is accessed.

Bit and Byte Ordering


Ordering refers to the way bits and bytes are arranged and processed. In
little-endian order (used by Tricon), the order is from right to left with the most
significant bits and bytes on the right. In big-endian order (used by Trident), the
order is from left to right with the most significant bits and bytes on the left.
If the controller and PC use different ordering types, the application might need to
convert data to the appropriate order.

Little-Endian Ordering
The Tricon controller uses little-endian ordering which means that data is ordered
with the most significant bits and bytes to the right.

Bit Ordering for Bit Fields

Bit 32 ... Bit 3 Bit 2 Bit 1 Bit 0

Tricon Communication Guide


Overview 155

Byte Ordering for 16 Bit Variables

Byte 1 Byte 0

Byte Ordering for 32 Bit Variables

Byte 3 Byte 2 Byte 1 Byte 0

Big-Endian Ordering
The Trident controller uses big-endian ordering which means that data is ordered
with the most significant bits and bytes to the left.

Bit Ordering for Bit Fields

Bit 0 Bit 1 Bit 2 Bit 3 ... Bit 32

Byte Ordering for 16 Bit Variables

Byte 0 Byte 1

Byte Ordering for 32 Bit Variables

Byte 0 Byte1 Byte 2 Byte 3

Symbol Table Information (Trident Only)


The symbol table includes information about TriStation variables, Modbus alias
numbers, bin numbers, and offset. This information is required when data is read
or written to the controller. The symbol table is downloaded to the controller with
the TriStation application.
Symbol table information can be retrieved in the following ways:
• For Tricon and Trident, by exporting the information from TriStation. For
more information, see the Export Points command in the TriStation 1131
Developer’s Guide.

Appendix C TSAA Protocol


156 Overview

• For Trident only, by retrieving the information from the controller with the
TSAA message TRICON_GET_SYMBOL_REQ.

Structure of Trident Symbol Table


The Trident symbol table has the following structure. (All the fields are unsigned.)

Size in
Field Name Description
Bytes
Tricon_Symbol_Table field Identifies the entries in the table. Includes the
following fields:
4 numberOfEntries • Number of Tricon_Symbol_Entry records in
the symbol table.
4 stringOffset • Not currently used.
4 checksum • Reserved.
Tricon_Symbol_Entry fields Identifies a specific entry; can include multiple
entries. Includes the following fields:
4 nameOffset • Number of bytes offset from the string area
where the tagname for a symbol is stored.
4 binNumber • Bin number for the item.
4 rfu • Reserved.
2 binOffset Number of units from the beginning of the bin to
the location of the item.
• For discrete data types, the unit is number of
bits.
• For integer and real, the unit is the number of
32 bit words.
2 mbNoConversion If true (1), floating point numbers are not
converted to integers.
If false (0), they are converted.
1 mbStation Modbus station ID for a Modbus slave. (Slaves
only respond to messages with their station ID.)
2 mbAlias Alias number for a variable stored in a slave.

Tricon Communication Guide


TSAA Messages 157

Size in
Field Name Description
Bytes
Strings field Tagnames.
CRC field Reserved.

Finding a Tagname (Trident Only)


To find the starting address for a tagname, use the following equation:
Location of tag name = Starting_Address_of_Symbol_Table +
sizeof(Tricon_Symbol_Table) +
sizeof(Tricon_Symbol_Entry) *
Tricon_Symbol_Table::numberOfEntries) +
Tricon_Symbol_Entry::nameOffset;

TSAA Messages
A TSAA message is a request made by a client or a response made by the Triconex
controller. This section describes the format of TSAA messages and the available
types of messages. In this document, the words frame and message mean the same
thing—a unit of data that is transmitted through a network.

Message Format
Each TSAA message adheres to a format which includes the following fields:
• A frame header which identifies the message
• A data area which contains the frame message
• A 32-bit Cyclic Redundancy Check (CRC)

Frame Header Data Area CRC


8 bytes variable length 4 bytes

Note Unless otherwise specified, fields in messages are unsigned.

Appendix C TSAA Protocol


158 TSAA Messages

Frame Header
The frame header in a TSAA message includes the following fields.

Type nodeNumber seqNum version flag id length


1 byte 1 byte 1 byte 1 byte 1 byte 1 byte 1 byte

Type
The Type field in the frame header identifies the message type. The following types
of TSAA messages are available.

Request Triconex
Type Message Type Description from Response
Client
1 TRICON_DATA Returns data in response to a type 2 ü
message.
2 TRICON_DATA_REQ Requests data from the TriStation ü
application.
3 WRITE_TRICON_DATA Requests the controller to write to ü
memory and output variables in the
TriStation application.
4 WRITE_TRICON_DATA_RSP Responds to a request to write to ü
memory and output variables by a
type 3 message.
5 READ_TRICON_CLOCK Requests the current time on the ü
controller clock.
6 READ_TRICON_CLOCK_RSP Returns the current time on the ü
controller clock in response to a
type 5 message.
7 SET_TRICON_CLOCK Requests setting of the controller ü
clock.
8 SET_TRICON_CLOCK_RSP Responds to a request to set the ü
clock made by a type 7 message.
9 ADJUST_TRICON_CLOCK Requests controller to adjust clock ü
forward or backward.

Tricon Communication Guide


TSAA Messages 159

Request Triconex
Type Message Type Description from Response
Client
10 ADJUST_TRICON_CLOCK_RSP Responds to a request to adjust the ü
clock made by a type 9 message.
11 READ_TRICON_DATA Requests data (memory, input, or ü
output variables) to be read from
the TriStation application.
12 READ_TRICON_RSP Returns variable data in response ü
to a type 11 message.
13 TRICON_SOE_REQ Requests SOE (sequence of events) ü
data from the controller.
14 TRICON_SOE_RSP Returns SOE data in response to a ü
type 13 message.
15 TRICON_CPSTATUS_REQ Requests the TriStation application ü
name and version number.
For Triconex internal use only.
16 TRICON_CPSTATUS_RSP Returns program information in ü
response to a type 15 message.
For Triconex internal use only.
17 TRICON_SOE_DATAAVAIL Sends a message to the client when ü
SOE data is available. The message
is sent when SOE data is put into
an empty SOE block and every 10
seconds while there is data
available in any block.
22 TRICON_GET_SYMBOL_REQ Requests part of a symbol table ü
from the controller.
For Trident only.
23 TRICON_GET_SYMBOL_RSP Sends part of a symbol table as ü
requested by a type 22 message.
For Trident only.

nodeNumber
The nodeNumber field identifies the destination node number for the message
which is the node number for the Triconex controller.

Appendix C TSAA Protocol


160 TSAA Messages

seqNum
The seqNum field identifies the number of the message in a multiple-message
response. This field can help determine if there are missing messages.

version
The version field identifies the version number of the protocol used by the sender:
• For Tricon, the number must be 0.
• For Trident, the number must be 1.

flag
The flag field is a bit field that indicates the first or last frame of a response.
• 0x01 identifies the first frame of a multi-frame message.
• 0x02 identifies the last frame of a multi-frame message.
• 0x03 identifies a single frame message.

id
The id field assigns a number to a request and associated response. If a client makes
periodic requests of the same message type and wants to associate them with the
responses, this field can be used to assign an identifier. The request and response
use the same identifier.

length
The length field identifies the length of the frame excluding the CRC32 field.

Tricon Communication Guide


TSAA Messages 161

TRICON_DATA (Type 1)
A TRICON_DATA message replies to a request for data made by a
TRICON_DATA_REQ (type 2) message. If the client sends a data request at least
once every two minutes, the controller continues sending data responses at the
interval specified by the request.
If more than one client sends a TRICON_DATA_REQ to a controller, the
controller response changes to a UDP broadcast which is sent to all the clients.
This message includes the following fields.

Frame_Hdr Data_Hdr Bin (1) Header Bin (2) Header... CRC


8 bytes variable length varies varies 4 bytes

Data_Hdr
The Data_Hdr field includes the following fields.

numberOfBlocks rfu SymbolTableVersion


2 bytes reserved 4 bytes
(Trident only)

numberOfBlocks
The numberOfBlocks field identifies the number of blocks in the data portion of
the message.

SymbolTableVersion (Trident Only)


The SymbolTableVersion field identifies the TriStation application version. If the
version is 1.0, this is 0x00010000.
The SymbolTableVersion field is only available for Trident controllers.

Appendix C TSAA Protocol


162 TSAA Messages

Bin Headers
A TRICON_DATA (Type 1) message can have multiple bin headers followed by
bin data. Each bin header includes the following fields.

bin rfu totalLength offset length BinTime


1 byte 1 byte 2 bytes 2 bytes 2 bytes 8 bytes
reserved (Trident only)

bin
The bin field identifies which bin holds the message data, using a numeric value to
represent the variable type and data type.

For Tricon

Bin Aliases Variable Type Data Type


0 1 - 2000 Output BOOL (Discrete)
1 2001 - 4000 Memory BOOL (Discrete)
2 10001 - 12000 Input BOOL (Discrete)
3 12001 - 14000 Memory BOOL (Discrete)
4 30001 - 31000 Input REAL (Analog)
5 31001 - 31382 Memory DINT (Integer)
6 32001 - 32120 Input REAL (Analog)
7 33001 - 34000 Memory REAL (Analog)
8 14001 - 19999 system status BOOL (Discrete)
9 39631 - 39999 system status DINT (Integer)
10 40001 - 40250 Output REAL (Analog)
11 40251 - 40632 Memory DINT (Integer)
12 41001 - 42000 Memory REAL (Analog)
13 Not applicable Number of bins

Tricon Communication Guide


TSAA Messages 163

For Trident

Bin Variable Type Data Type .

0 Output BOOL (Discrete)


1 Memory BOOL (Discrete)
2 Input BOOL (Discrete)
3 Memory BOOL (Discrete)
4 Input REAL (Analog)
5 Memory DINT (Integer)
6 Input REAL (Analog)
7 Memory REAL (Analog)
10 Output REAL (Analog)
11 Memory DINT (Integer)
12 Memory REAL (Analog)
13 Not applicable Number of bins

totalLength
The totalLength field indicates the length of the bin.

offset
The offset field identifies the starting position of the requested data in the bin.
• For discrete data types, the offset is the number of bits.
• For integer and real data types, the offset is the number of 32-bit words.

length
The Length field contains the length of the data returned.

binTime (Trident only)


The binTime field identifies the time stamp associated with the bin data in
microseconds since 1970.

Appendix C TSAA Protocol


164 TSAA Messages

The binTime field is only available to Trident controllers.

TRICON_DATA_REQ (Type 2)
A TRICON_DATA_REQ message requests one or more bins of data from a
Triconex controller. The controller responds with a TRICON_DATA (type 1)
message. If the client sends a data request at least once every two minutes, the
controller continues sending data responses at the interval specified by the request.
The data request message is designed for applications that require all of the data in
one or more bins. After the request is sent, the controller continuously sends data
responses to the client at specified intervals. The client cannot stop the controller
from sending data, but the controller will stop sending data if a data request is not
received again within two minutes.
If you use TCP protocol (or UDP protocol with connect and disconnect functions),
you must leave the connection open for a minimum of two minutes after sending
this request. If your application requires specifying the range of data, use
READ_TRICON_DATA (type 11).
This message includes the following fields.

Frame_Hdr Data_Req_Hdr CRC


8 bytes variable length 4 bytes

Data_Req_Hdr
The Data_Req_Hdr field contains the following fields.

binsRequested reqTime
2 bytes 2 bytes

Tricon Communication Guide


TSAA Messages 165

binsRequested
The binsRequested field is a binary mask that identifies which bins of data the
Triconex controller should send.
If the request includes an invalid bin number, the response is a bin header with no
data.

Binary Mask Description


0x1fff Masks all bins
0x0001 Masks discrete output
0x0002 Masks read/write discrete memory
0x0004 Masks discrete input
0x0008 Masks read-only discrete memory
0x0010 Masks analog input
0x0020 Masks read-only integer memory
0x0040 Masks real input
0x0080 Masks read-only real memory
0x0100 (Tricon only) Masks discrete system status
0x0200 (Tricon only) Masks integer system status
0x0400 Masks analog output
0x0800 Masks read/write integer memory
0x1000 Masks read/write real memory

reqTime
The reqTime field indicates the time in milliseconds between broadcasts of the
requested bins. For example, a value of 1,000 causes a Triconex controller to
broadcast the data once per second. If this value is zero (0), the controller
broadcasts the data each time the ACM or NCM (Tricon) or CM (Trident) is
updated.

Appendix C TSAA Protocol


166 TSAA Messages

WRITE_TRICON_DATA (Type 3)
A WRITE_TRICON_DATA message requests the Triconex controller to write
data to output and memory variables in the TriStation application. The following
conditions must be met for the controller to accept this request:
• The variables must be defined as read/write.
• For Tricon, the keyswitch must be in the Program or Remote position. For
Trident, the Remote mode must be enabled by setting a system attribute.
• The TriStation configuration setting (Disable Remote Changes to Outputs)
which was downloaded to the controller must allow remote changes. (This
setting only affects changes to discrete outputs and analog outputs.)
• The TriStation configuration for the ACM or NCM (Tricon) and CM
(Trident) must be configured as read/write.
If the controller cannot write the data, it sends a reject response code. For more
information, see “Response Codes” on page 189.
This message includes the following fields.

Frame_Hdr Write_Hdr Write_Data ... Write_Data CRC


8 bytes 4 bytes 6 bytes 6 bytes 4 bytes

Write_Hdr
The Write_Hdr contains the following fields.

numberOfBlocks rfu
2 bytes 2 bytes
reserved

numberOfBlocks
The numberOfBlocks field indicates the number of write data blocks for the
message type.

Tricon Communication Guide


TSAA Messages 167

Write_Data
The Write_Data field includes the following fields.

binNumber rfu offset numberOfValues Values


1 byte 1 byte 2 bytes 2 bytes varies
reserved

binNumber
The binNumber field indicates the number of the bin to be changed.

offset
The offset field identifies the starting position of the requested data in the bin.
• For discrete data types, the offset is the number of bits.
• For integer and real data types, the offset is the number of 32-bit words.

numberOfValues
The numberOfValues field indicates the number of variables to be written starting
at the specified offset.

Values
The Values field contains the values for the variables to be changed. Discrete
variables require one byte each for the new value (0 or 1).

WRITE_TRICON_DATA_RSP (Type 4)
A WRITE_TRICON_DATA_RSP message replies with a success or failure code
to a request to write data sent by a WRITE_TRICON_DATA (type 3) message.
This message includes the following fields.

Frame_Hdr responseCode subReason rfu CRC


8 bytes 1 byte 1 byte 2 bytes 4 bytes
reserved

Appendix C TSAA Protocol


168 TSAA Messages

responseCode
The responseCode field indicates the success or failure of the request. A value of
zero (0) indicates the request was successfully completed.
For more information, see “Response Codes” on page 189.

subReason
The subReason field contains additional information about the failure of the
request.

READ_TRICON_CLOCK (Type 5)
A READ_TRICON_CLOCK message requests the current time on the Triconex
controller. The controller responds with READ_TRICON_CLOCK_RSP (type 6)
which sends the current time to the client.
There are no fields specific to this message.

Frame_Hdr CRC
8 bytes 4 bytes

READ_TRICON_CLOCK_RSP (Type 6)
A READ_TRICON_CLOCK_RSP message sends the current controller time to
the client in response to a READ_TRICON_CLOCK (type 5) request.
This message includes the following fields.

Frame_Hdr Read_Clock_Resp CRC


8 bytes 12 bytes 4 bytes

Read_Clock_Rsp
The Read_Clock_Rsp field includes the following fields.

Tricon Communication Guide


TSAA Messages 169

responseCode subReason rfu relSec milliSec rfu2


1 byte 1 byte 2 bytes 4 bytes 2 bytes 2 bytes
reserved

ResponseCode
The responseCode field indicates the success or failure of the request. A value of
zero (0) indicates the request was successfully completed.
For more information, see “Response Codes” on page 189.

subReason
The subReason field contains additional information about the failure of the
request.

relSec
The relSec field indicates the current Triconex system time expressed in relative
seconds.
• For Tricon, relative seconds are seconds past 00:00 January 1, 1970 based
on local time.
• For Trident, relative seconds are seconds past 1970 based on universal time
(Greenwich Mean Time). (2000 is the earliest date and 2050 is the latest
date.)

milliSec
The milliSec field indicates the millisecond portion of the Triconex system time.

Appendix C TSAA Protocol


170 TSAA Messages

SET_TRICON_CLOCK (Type 7)
A SET_TRICON_CLOCK message requests the time to be set on the Triconex
controller. The controller responds with a SET_TRICON_CLOCK_RSP (type 8)
message.
The following conditions must be met for the controller to accept this request:
• For Tricon, the keyswitch must be in Program mode.
• For Trident, the operational mode must be set to Program.
For Tricon only, the controller does not allow an application or an external device
to set the time continuously. At least five minutes must pass before the controller
responds to a SET_TRICON_CLOCK message. If the application sends this
message before five minutes pass, the message is rejected.
This message includes the following fields.

Frame_Hdr Set_Clock CRC


8 bytes 8 bytes 4 bytes

Set_Clock
The Set_Clock field includes the following fields.

relSec milliSec rfu


4 bytes 2 bytes 2 bytes
reserved

relSec
The relSec field contains the controller system time expressed in relative seconds.
• For Tricon, relative seconds are seconds past 00:00 January 1, 1970 based
on local time.
• For Trident, relative seconds are seconds past 1970 based on universal time
(Greenwich Mean Time). (2000 is the earliest date and 2050 is the latest
date.)

Tricon Communication Guide


TSAA Messages 171

milliSec
The milliSec field contains the millisecond portion of the system time.

SET_TRICON_CLOCK_RSP (Type 8)
A SET_TRICON_CLOCK_RSP message replies with a success or failure code to
a SET_TRICON_CLOCK (type 7) message.
This message includes the following fields.

Frame_Hdr Set_Clock_Rsp CRC


8 bytes 4 bytes 4 bytes

Set_Clock_Rsp
The Set_Clock_Rsp field contains the following fields.

responseCode subReason rfu


1 byte 1 byte 2 bytes
reserved

responseCode
The responseCode field indicates the success or failure of the request. A value of
zero (0) indicates the request was successfully completed.
For more information, see “Response Codes” on page 189.

subReason
The subReason field contains additional information about the failure of the
request.

Appendix C TSAA Protocol


172 TSAA Messages

ADJUST_TRICON_CLOCK (Type 9)
An ADJUST_TRICON_CLOCK message requests the time to be adjusted on the
Triconex controller either forward or backward. The controller responds with an
ADJUST_TRICON_CLOCK_RSP (type 10) message.
The following conditions must be met for the controller to accept this request:
• For Tricon, the keyswitch must be in Program mode.
• For Trident, the operational mode must be set to Program.
For Tricon only, the controller does not allow an application or an external device
to set the time continuously. At least five minutes must pass before the controller
will respond to a SET_TRICON_CLOCK message. If the application program
sends this message before five minutes pass, the message is rejected.
This message includes the following fields.

Frame_Hdr Adjust_Clock CRC


8 bytes 8 bytes 4 bytes

Adjust_Clock
The Adjust_Clock field includes the following fields.

AdjustSeconds AdjustMilliseconds
4 bytes 4 bytes
signed signed

AdjustSeconds
The AdjustSeconds field contains the number of seconds to adjust the controller
clock either forward or backward.

AdjustMilliseconds
The AdjustMilliseconds field contains the number of milliseconds to adjust the
controller clock either forward or backward.

Tricon Communication Guide


TSAA Messages 173

ADJUST_TRICON_CLOCK_RSP (Type 10)


An ADJUST_TRICON_CLOCK_RSP message replies with a success or failure
code to an ADJUST_TRICON_CLOCK (type 9) message.
This message includes the following fields.

Frame_Hdr Adjust_Clock_Rsp CRC


8 bytes 4 bytes 4 bytes

Adjust_Clock_Rsp
The Adjust_Clock_Rsp field contains the following fields.

responseCode subReason rfu


1 byte 1 byte 2 bytes
reserved

responseCode
The responseCode field indicates the success or failure of the request. A value of
zero (0) indicates the request was successfully completed.
For more information, see “Response Codes” on page 189.

subReason
The subReason field contains additional information about the failure of the
request.

Appendix C TSAA Protocol


174 TSAA Messages

READ_TRICON_DATA (Type 11)


A READ_TRICON_DATA message requests variable data from the Triconex
controller. The controller responds with the requested data using one or more
READ_TRICON_RSP (type 12) messages depending on the amount of data
requested.
This message includes the following fields.

Frame_Hdr Read_Hdr Read_Data CRC


8 bytes 4 bytes 6 bytes 4 bytes

Read_Hdr
The Read_Hdr field includes the following fields.

numberOfBlocks rfu
2 bytes 2 bytes
reserved

numberOfBlocks
The numberOfBlocks field indicates the number of Read_Data blocks for this
message.

Read_Data
The Read_Data field includes the following fields.

binNumber rfu offset numberOfValues


1 byte 3 bytes 2 bytes 2 bytes
reserved

binNumber
The binNumber field contains the number of the bin to be read.

Tricon Communication Guide


TSAA Messages 175

offset
The offset field identifies the starting position of the requested data in the bin.
• For discrete data types, the offset is the number of bits.
• For integer and real data types, the offset is the number of 32-bit words.
If the numberOfValues field is zero (0), this field is ignored.

numberOfValues
The numberOfValues field contains the number of variables to be read from the
bin. If the number is zero (0), all of the data in the bin is returned.

READ_TRICON_RSP (Type 12)


A READ_TRICON_RSP message responds to a request to read data on the
controller made by a READ_TRICON_DATA (type 11) message. The controller
sends one or more of these messages depending on the amount of data requested.
This message includes the following fields.

Frame_Hdr Read_Rsp_Hdr Read_Data_Rsp Data ... CRC


8 bytes 4 bytes 12 bytes varies 4 bytes

Read_Rsp_Hdr

The Read_Rsp_Hdr field includes the following fields.

responseCode subReason numberOfBlocks


1 byte 1 byte 2 bytes

responseCode
The responseCode field indicates the success or failure of the request. A value of
zero (0) indicates the request was successfully completed.
For more information, see “Response Codes” on page 189.

Appendix C TSAA Protocol


176 TSAA Messages

subReason
The subReason field contains additional information about the failure of the
request.

numberOfBlocks
The numberOfBlocks field indicates the number of Read_Data_Rsp blocks in the
message.

Read_Data_Rsp
The Read_Data_Rsp field includes the following fields.

binNumber rfu offset relSec milliSec numberOfValues


1 byte 1 byte 2 bytes 4 bytes 2 bytes 2 bytes
reserved

binNumber
The binNumber field contains the number of the bin to be read.

offset
The offset field contains the number of variables from the beginning of the bin.
• For discrete data types, the offset is the number of bits.
• For integer and real data types, the offset is the number of 32-bit words.

relSec and milliSec


The relSec field contains the controller time stamp for bin data expressed in relative
seconds. The milliSec field contains the millisecond portion of the controller time
stamp.
• For Tricon, relative seconds are seconds past 00:00 January 1, 1970 based
on local time.
• For Trident, relative seconds are seconds past 1970 based on universal time
(Greenwich Mean Time). (2000 is the earliest date and 2050 is the latest
date.)

Tricon Communication Guide


TSAA Messages 177

numberOfValues
The numberOfValues field indicates the number of variables that are read starting
at the specified offset.

Data
The Data field contains data from the bin.
• For Tricon, the data is ordered in little-endian format.
• For Trident, the data is ordered in big-endian format.
For more information about Trident data, see “Symbol Table Information (Trident
Only)” on page 155.

TRICON_SOE_REQ (Type 13)


A TRICON_SOE_REQ message requests the Triconex controller to send event
data collected in an SOE block. The controller responds with a
TRICON_SOE_RSP (type 14) message.
This message includes the following fields.

Frame_Hdr Soe_Req CRC


8 bytes 4 bytes 4 bytes

Frame_Hdr
The Frame_Hdr field includes the following fields.

soeNumber firstFlag ackFlag rfu1 getIndex rfu2 wrapCount generation


1 byte 1 byte 1 byte 1 byte 2 bytes 2 bytes 4 bytes 4 bytes
reserved

soeNumber
The soeNumber field contains the SOE block number which can be 1 to 16. (SOE
blocks are configured in TriStation.)

Appendix C TSAA Protocol


178 TSAA Messages

firstFlag
The firstFlag field indicates whether this is the first data request for this SOE block.
This value should be set to one (1) for the first request. For all subsequent requests,
it should be set it to zero (0).

ackFlag
The ackFlag field indicates whether the last TRICON_SOE_RSP message was
received correctly. If the message was received correctly, set the field to one (1). If
not, set it to zero (0).

getIndex
The getIndex field is a pointer into the SOE data block that indicates the start of the
data being requested.

wrapCount
The wrapCount field indicates the number of times the buffer has been filled since
the last time the TriStation application issued an SOECLR command for this block.

generation
The generation field indicates the number of times the TriStation application has
issued the SOECLR command.

TRICON_SOE_RSP (Type 14)


A TRICON_SOE_RSP message responds to a TRICON_SOE_REQ (type 13)
request by sending data from the SOE block.
The values for the getIndex, wrapCount, and generation fields may not match the
numbers requested because their values change depending on how frequently you
request data and whether events are occurring.
This message includes the following fields.

Frame_Hdr Soe_Rsp Entry Entry ... CRC


8 bytes 16 bytes 8 bytes 8 bytes 4 bytes

Tricon Communication Guide


TSAA Messages 179

Soe_Rsp
The Soe_Rsp field includes the following fields.

soe response sub next numberOf wrap


rfu generation
Number Code Reason Index Entries Count
1 byte 1 byte 1 byte 1 byte 2 bytes 1 byte 4 bytes 4 bytes
reserved

soeNumber
The soeNumber field indicates the number of the SOE block.

responseCode
The responseCode field indicates the success or failure of the request. A value of
zero (0) indicates the request was successfully completed.
For more information, see “Response Codes” on page 189.

subReason
The subReason field identifies the subcode for the request. Used for debugging.

nextIndex
The nextIndex field is a pointer into the SOE data block that indicates the start of
the data being requested.

numberOfEntries
The numberOfEntries field indicates the number of entries in the response. There
are two types of entry: time stamp and event data. For more information, see “entry
(SOE Data Entry)” on page 180 and “entry (SOE Time Stamp)” on page 182.

wrapCount
The wrapCount field indicates the number of times the buffer has been filled since
the last time the TriStation application issued an SOECLR command for this block.

Appendix C TSAA Protocol


180 TSAA Messages

generation
The generation field indicates the number of times the TriStation application has
issued the SOECLR command.

entry (SOE Data Entry)


The entry field for an SOE data entry includes the following fields.

offset dataType bin type soeNumber value


16 bits 3 bits 5 bits 3 bits 3 bits 32 bits

offset
The offset field contains the number of variables from the beginning of the bin.
• For discrete data types, the offset is the number of bits.
• For integer and real data types, the offset is the number of 32-bit words.

dataType
The type field identifies the data type of the SOE entry with a numeric value.

Data Type Value


BOOL (Discrete) 0
DINT (Integer) 1
REAL (Analog) 2

bin
The bin field identifies which bin holds the message data, using a numeric value to
represent the variable type and data type.

For Tricon

Bin Aliases Variable Type Data Type


0 1 - 2000 Output BOOL (Discrete)
1 2001 - 4000 Memory BOOL (Discrete)

Tricon Communication Guide


TSAA Messages 181

Bin Aliases Variable Type Data Type


2 10001 - 12000 Input BOOL (Discrete)
3 12001 - 14000 Memory BOOL (Discrete)
4 30001 - 31000 Input REAL (Analog)
5 31001 - 31382 Memory DINT (Integer)
6 32001 - 32120 Input REAL (Analog)
7 33001 - 34000 Memory REAL (Analog)
8 14001 - 19999 system status BOOL (Discrete)
9 39631 - 39999 system status DINT (Integer)
10 40001 - 40250 Output REAL (Analog)
11 40251 - 40632 Memory DINT (Integer)
12 41001 - 42000 Memory REAL (Analog)
13 Not applicable Number of bins

For Trident

Bin Variable Type Data Type .

0 Output BOOL (Discrete)


1 Memory BOOL (Discrete)
2 Input BOOL (Discrete)
3 Memory BOOL (Discrete)
4 Input REAL (Analog)
5 Memory DINT (Integer)
6 Input REAL (Analog)
7 Memory REAL (Analog)
10 Output REAL (Analog)
11 Memory DINT (Integer)

Appendix C TSAA Protocol


182 TSAA Messages

Bin Variable Type Data Type


12 Memory REAL (Analog)
13 Not applicable Number of bins

type
The type field indicates whether the entry is an SOE time stamp or an SOE data
entry.
• If 1, the entry is a time stamp.
• If 2, the entry is a data entry.

soeNumber
The soeNumber field identifies the SOE block number.

value
The value field contains the value of the aliased variable. If On, it is 0x00000001;
if Off, it is 0x00000000.

entry (SOE Time Stamp)


The entry fields for an SOE time stamp include the following fields.

microseconds reason type soeNumber seconds


20 bits 4 bits 3 bits 5 bits 32 bits

microseconds
The microseconds field contains the microseconds part of the time stamp which
can be from 0 to 999,999.

Tricon Communication Guide


TSAA Messages 183

reason
The reason field indicates the reason a time stamp entry was made. The reasons are
described in the following table.

Value Reason
1 SOESTRT command processed.
2 SOESTOP command processed or buffer full for First Out block.
3 SOECLR command processed.
4 Event has been detected. It can be collected from the Entry field of the
TRICON_SOE_RSP message.

type
The type field indicates whether the entry is an SOE time stamp or an SOE data
entry.
• If 1, the entry is a time stamp.
• If 2, the entry is a data entry.

soeNumber
The soeNumber field identifies the SOE block number.

second
The second field contains the seconds part of the time stamp which can be from 0
to 59.

TRICON_CPSTATUS_REQ (Type 15)


A TRICON_CPSTATUS_REQ message requests the TriStation application name
and version number from the Triconex controller. This message does not require
any data. The controller responds with a TRICON_CPSTATUS_RSP (type 16)
message.
This message type is for Triconex internal use only.

Appendix C TSAA Protocol


184 TSAA Messages

TRICON_CPSTATUS_RSP (Type 16)


A TRICON_CPSTATUS_RSP message replies to the request for TriStation
application name and version number made by a TRICON_CPSTATUS_REQ
(type 15) message.
This message type is for Triconex internal use only.

TRICON_SOE_DATAAVAIL (Type 17)


A TRICON_SOE_DATAAVAIL message sends a message to the client when
SOE data is available. The message is sent when SOE data is put into an empty
SOE block and every 10 seconds while there is data available in any block.
This message includes the following fields.

Frame_Hdr SoeDataAvail CRC


8 bytes 16 bytes 4 bytes

SoeDataAvail
The SoeDataAvail field includes the following fields.

putIndex firstIndex size state rfu wrapCount generation

2 bytes 2 bytes 2 bytes 1 byte 1 byte 4 bytes 4 bytes


reserved

putIndex
The putIndex field contains a pointer to the last data available in the SOE data
block.

firstIndex
The firstIndex field contains a pointer to the beginning of the available data in the
SOE data block.

Tricon Communication Guide


TSAA Messages 185

size
The size field contains the number of entries in the block. The block size is
specified in TriStation.

state
The state field contains a number representing the status of the SOE block. The
states are as follows:
0 Block is not defined or block is not started.
1 Block is collecting.
2 Block is stopped or cleared.
3 Block is full.

wrapCount
The wrapCount field contains the number of times the buffer has been filled since
the last time the TriStation application issued an SOECLR command for this block.

generation
The generation field contains the number of times the TriStation application has
issued the SOECLR command.

Appendix C TSAA Protocol


186 TSAA Messages

TRICON_GET_SYMBOL_REQ (Type 22, Trident Only)


A TRICON_GET_SYMBOL_REQ message requests a part of the symbol table
from the Trident controller. When the controller receives this message, it sends a
TRICON_GET_SYMBOL_RSP (type 23) message to the client.
This message type is only available for Trident controllers.
The symbol table can be large, up to 1.2 megabytes, which means you may have to
download the table in parts and then assemble the table on the client. The client can
then parse the symbol table (after correcting endian) and extract all the relevant
information related to a symbol.
This message includes the following fields.

Frame_Hdr Tricon_Get_Symbol CRC


8 bytes 12 bytes 4 bytes

Tricon_Get_Symbol
The Tricon_Get_Symbol field includes the following fields.

totalSize offset CRC


4 bytes 4 bytes 4 bytes

totalSize
The totalSize field must be set to zero (0).

offset
The offset field identifies the starting position of the requested data in the symbol
table.
• For discrete data types, the offset is the number of bits.
• For integer and real data types, the offset is the number of 32-bit words.

Tricon Communication Guide


TSAA Messages 187

TRICON_GET_SYMBOL_RSP (Type 23, Trident Only)


A TRICON_GET_SYMBOL_RSP message sends symbol table data requested by
a TRICON_GET_SYMBOL_REQ (type 22) message.
This message type is only available for Trident controllers.
This message includes the following fields.

Frame_Hdr Symbol_Table_Rsp Data[ ] CRC


8 bytes 20 bytes varies 4 bytes

Symbol_Table_Rsp
The Symbol_Table_Rsp field includes the following fields.

responseCode subReason rfu totalSize offset length symbolVersion


1 byte 1 byte 2 bytes 4 bytes 4 bytes 4 bytes 4 bytes
reserved

responseCode
The responseCode field indicates the success or failure of the request. A value of
zero (0) indicates the request was successfully completed.
For more information, see “Response Codes” on page 189.

subReason
The subReason field identifies the sub code for the request. Used for debugging.

totalSize
The totalSize field identifies the total size of the symbol table.

Appendix C TSAA Protocol


188 TSAA Messages

offset
The offset field identifies the starting position of the requested data in the symbol
table.
• For discrete data types, the offset is the number of bits.
• For integer and real data types, the offset is the number of 32-bit words.

Length
The Length field contains the length of the data returned.

symbolVersion
The symbolVersion field contains the version of the symbol table which is the same
TriStation application version.
After conversion to little-endian format on the client PC, this is a 32 bit number
with the following format:
MMMMnnn: where MMMM is the 16 bit major version number and nnnn is the
TriStation application minor version number.

Data
The Data field contains the part of the symbol table returned by the controller. The
size of this field is defined by the length of the Symbol_Table_Rsp field. The
maximum size is 480 bytes.

Tricon Communication Guide


Response Codes 189

Response Codes
Every response sent by a Triconex controller in reply to an external device includes
a code which indicates the result of the request. A response code of zero (0)
indicates the message was successful. Other codes indicate specific errors.

Code Description
0 Request was successful.
1 No buffer available to process the request. Retry the request.
2 Bin number specified in the request was not in the range from 0 to12.
3 For Tricon, the NCM is busy processing previous requests and cannot accept
another request. This can happen if more than four WRITE_TRICON_DATA
requests are outstanding at one time.
4 No MP is running.
5 TSX has rejected the request. The subReason field contains the specific
reason.
6 Request to TSX timed out.
7 Invalid response from TX.
8 Message was too big.
9 Offset or numberOfValues in the request was invalid.
10 No control program (TriStation application).
11 Read-only port.
236 Bad SOE number.
237 Invalid SOE type.
238 Invalid SOE state.

Appendix C TSAA Protocol


190 Response Codes

Tricon Communication Guide


APPENDIX D

Modbus Protocol

This appendix provides detailed information about Modbus protocol which can be
used by EICM serial ports.
Topics include:
“Overview” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 192
“Estimating Message Response Time” . . . . . . . . . . . . . . . . . . . . . . 193
“Communication Modes” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 194
“Modbus Functions” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 195
“Transmission Errors and Exception Conditions” . . . . . . . . . . . . . 212

Tricon Communication Guide


192 Overview

Overview
This appendix provides detailed information about Modbus protocol which can be
used by EICM serial ports. This protocol defines the query and response exchange
between a Modbus master and its slaves. A Modbus serial link transmits data in
both directions, but in only one direction at a time.
The master initiates all query-response sessions, which consist of the following
actions:
• The master sends a query to the slave.
• The master starts a fail-safe timer while the slave executes the query and
prepares the response. Typical slave execution times are in hundreds of
milliseconds.
• The slave returns a response to the master.
• The master waits until it has received the response from the slave before
sending another query.
To use Modbus protocol, you must select either the Remote Terminal Unit (RTU)
or ASCII mode of communication. (To select a mode, see “Configuring Serial
Ports in TriStation” on page 98.) If both modes are available, you should choose
RTU because it is more robust and efficient than ASCII. A port configured for
combination Modbus master and slave operation must use RTU mode.
The section “Modbus Functions” on page 195 describes the Modbus message
formats and functions (queries and responses) that are supported by the EICM
serial ports. Each description includes the function name and code, the query
format, the response format, and other relevant information.
During Modbus communication, transmission errors and exception conditions can
occur. The section “Transmission Errors and Exception Conditions” on page 212
explains how Modbus protocol handles these problems and describes the exception
conditions and responses that can take place.

Tricon Communication Guide


Estimating Message Response Time 193

Estimating Message Response Time


This section provides information you can use to estimate message response time
for Modbus master and slave communication. Message response time is the sum of
the times required by the operations listed in the following table.

Modbus Master Operation Modbus Slave Operation


Prepare Query
Transmit Query ¾¾¾¾¾® Receive Query
Processing Time
Receive Response ¬¾¾¾¾ Transmit Response
Process Response

Transmission Time
Transmission time pertains to serial ports which are configured as masters or
slaves.
The time required by a serial port to transmit a query or response is a function of
the baud rate and message size. Use the following equation to calculate the
transmission time in milliseconds.
Transmission Time = 1000 ¸ Baud Rate • Bits per Characters • Number of Characters

Processing Time for Reads and Writes


Processing time pertains only to serial ports which are configured as Modbus
slaves.
The processing time for a Modbus read is 10 milliseconds.
Use the following equation to calculate the processing time for Modbus writes in
milliseconds. In the equation, 3 milliseconds is an approximate time. If you need
to be more exact, contact Triconex Technical Support.
Write Processing Time = (3 • Scan Time)

Appendix D Modbus Protocol


194 Communication Modes

Setting Time-out and Retry Values


Use the MBCTRL function block to set time-out and retry values for a Modbus
master port. For more information, see the Triconex Libraries Manual.

Communication Modes
A Modbus serial link must use either the Remote Terminal Unit (RTU) or ASCII
mode of communication. If both modes are available, you should choose RTU
because it is more efficient and robust than ASCII. Each EICM serial port can use
a different communication mode, assuming that each port is connected to a
separate Modbus master or slave device. If you configure a port for combination
Modbus master and slave operation, you must use RTU mode.

RTU Mode
In RTU mode, data is sent in eight-bit binary characters. Gaps between characters
cannot exceed three character times (the time it takes to send a character). RTU
mode uses a 16-bit cyclic redundancy check (CRC) to detect transmission errors.
For more information, see “CRC Error Check — RTU Mode” on page 197.

ASCII Mode
In ASCII mode, data is transmitted in pairs of ASCII characters. The first character
is the ASCII representation of the most significant four bits of the corresponding
RTU character. The second character is the ASCII representation of the least
significant four bits of the corresponding RTU character. For example, the RTU
character 010011112 (4F16) is sent as the two ASCII characters 4 and F (3416 and
4616). Each ASCII message has a colon at the beginning and a carriage return and
line feed at the end. Gaps between characters in an ASCII message are not
significant.

Tricon Communication Guide


Modbus Functions 195

Modbus Functions
This section describes the Modbus functions (query and response pairs) that the
EICM supports. The following table lists the function names and codes.

Function Name Code


Read Coil Status 01
Read Input Status 02
Read Holding Registers 03
Read Input Registers 04
Force Single Coil 05
Preset Single Register 06
Read Exception Status 07
Loop Back Diagnostic Test 08
Force Multiple Coils 15
Preset Multiple Registers 16

The description of each function includes the function name, code, the query
format, the response format, and other relevant information.
The starting address field of a Modbus message ranges from 0 to one less than the
number of coils or registers available. A CM or MP serial port maps the Modbus
starting address field to an alias by adding a constant determined by the function
code, as shown in the following table. For more information about aliases, see
“Aliases and Tagnames” on page 39 and the TriStation 1131 Developer’s Guide.

Code Coil or Register Constant


01 Coil 1
02 Coil 10001
03 Register 40001
04 Register 30001
05 Coil 1
06 Register 40001
15 Coil 1
16 Register 40001

Appendix D Modbus Protocol


196 Modbus Functions

Modbus Message Formats


For each Modbus function, the message formats for RTU and ASCII modes are
depicted as shown in the following figures.

RTU Mode
Bytes
1 2 3 4 5 6 7 8
Station Function
Data Data CRC
Address Code

ASCII Mode
Bytes
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
Station Function
: Data Data LRC CR LF
Address Code

Message Header Field (ASCII Only)


The Message Header in ASCII mode is a colon (:) and is required. There is no
message header in RTU mode.

Station Address Field


The Station Address field identifies the station to which a query is directed or the
station that is sending a response. In RTU mode, the station address has one
character (eight bits). In ASCII mode, the station address has two characters.
The range for station addresses is 1 through 247. Each station connected to a
Modbus serial link must have a unique address. Station address 0 (zero) is the
broadcast address and addresses all slaves. When a slave receives a query with the
broadcast address, the slave processes the query but does not send a response.

Function Code Field


The Function Code field identifies the operation to be performed (the query), or the
operation that was performed (the response). If the most significant bit of the
function code in a response is 1, the response is an exception response. For more
information, see “Exception Responses” on page 214.

Tricon Communication Guide


Modbus Functions 197

Data Fields
The Data fields contain information that is specific to the query or response. The
length of the data varies, depending on the function code.

Checksum Field (CRC or LRC)


The Checksum field is a 16-bit word which is a CRC in RTU mode or an LRC in
ASCII mode. The error check is performed by both the transmitting and the
receiving units to detect transmission errors. For more information about error
checking, see “Transmission Errors” on page 212. The following sections describe
the error check calculations that are performed for CRC and LRC.

CRC Error Check — RTU Mode


During a CRC error check, the CRC-16 polynomial is used to compute a checksum
for the entire message. The CRC-16 polynomial is:
x16 + x15 +x2 + 1
The CRC is computed across the station address, the function code, and the data
and appended to the end of the message.

LRC Error Check — ASCII Mode


The LRC checksum is an eight-bit binary number represented and transmitted as
two ASCII hexadecimal characters. The checksum is produced in the following
manner:
• The hex characters that comprise the content of a message are converted to
binary notation. The colon, carriage return, and line feed are ignored.
• The binary characters are summed without wrap-around carry.
• The resulting sum is negated.

Appendix D Modbus Protocol


198 Modbus Functions

The following table shows how to calculate the LRC for the sample message
presented earlier in this chapter.
Sample LRC Checksum Calculation
Message Content Checksum Calculation
Address 0 2 0000 0010
Function Code 0 1 0000 0001
Starting Address (H.O.) 0 0 0000 0000
Starting Address (L.O.) 1 3 0001 0011
Quantity of Points (H.O.) 0 0 0000 0000
Quantity of Points (L.O.) 2 5 + 0010 0101
0011 1011
One’s-Complement: 1100 0100
Add 1: + 0000 0001
Two’s-Complement: 1100 0101
Error Check C 5

CR Field and LF Field (ASCII Only)


The CR field contains an ASCII carriage return and the LF field contains an ASCII
line feed.

Tricon Communication Guide


Modbus Functions 199

Sample Query and Response Messages


The following table shows the content of a sample query and response in RTU and
ASCII modes. The query is a Read Input Status (Function 02) requesting 37 (2516)
points starting at point 20 (1316 + 1). The response packs the 37 points into five
8-bit bytes, and clears the three high-order bits of the last byte.

Query Message RTU ASCII


Header None :
Station Address 0000 0010 0 2
Function Code 0000 0001 0 1
Starting Address (High Order) 0000 0000 0 0
Starting Address (Low Order) 0001 0011 1 3
Number of Points (High Order) 0000 0000 0 0
Number of Points (Low Order) 0010 0101 2 5
Error Check 0000 1100 C 5
0010 0111
Trailer None CR LF

Response Message RTU ASCII


Header None :
Station Address 0000 0010 0 2
Function Code 0000 0001 0 1
Byte Count 0000 0101 0 5
Data Byte 1 11001 11012 C D
Data Byte 2 0110 1011 6 B
Data Byte 3 1011 0010 B 2
Data Byte 4 0000 1110 0 E
Data Byte 5 0001 1011 1 B
Error Check 0000 0100 E 5
1111 1111
Trailer None CR LF
1. The underscored digit indicates that Coil #27 is in the On state.
2. The underscored digit indicates that Coil #20 is in the On state.

Appendix D Modbus Protocol


200 Modbus Functions

Modbus Message Lengths


The length of a Modbus message depends on the function being used and whether
the message is a query or a response.

Function Number of RTU Number of ASCII


Query
Code Characters Characters
01 Read Coil Status 8 17
02 Read Input Status 8 17
03 Read Holding 8 17
Registers
04 Read Input Registers 8 17
05 Force Single Coil 8 17
06 Preset Single 8 17
Register
15 Force Multiple Coils 9 + (1 per 8 coils) 19 + (2 per 8 coils)
16 Preset Multiple 9 + (2 per register) 19 + (4 per register)
Registers

Function Number of RTU Number of ASCII


Response
Code Characters Characters
01 Read Coil Status 5 + (1 per 8 coils) 11 + (2 per 8 coils)
02 Read Input Status 5 + (1 per 8 coils) 11 + (2 per 8 coils)
03 Read Holding 5 + (2 per register) 11 + (4 per register)
Registers
04 Read Input Register 5 + (2 per register) 11 + (4 per register)
05 Force Single Coil 8 17
06 Preset Single 8 17
Register
15 Force Multiple Coils 8 17
16 Preset Multiple 8 17
Registers

Tricon Communication Guide


Modbus Functions 201

Read Coil Status Function (Function 01)

Query Format
The Read Coil Status query requests the On/Off status of a group of logic coils
from a station. You can request the status of as many as 2,000 coils with each
query, but some Modbus devices have lower limits. The coils are numbered
starting at 0; for example, coil 0 is alias 1, coil 1 is alias 2, and so forth.
The Read Coil Status query is also known as the Read Output Status query.
RTU Mode
Bytes
1 2 3 4 5 6 7 8
Station
0000 0001 Starting Address Number of Coils CRC
Address

ASCII Mode
Bytes
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
Station
: Address 0 1 Starting Address Number of Coils LRC CR LF

Response Format
The Read Coil Status response data is packed with one bit for each coil, where
1=On, and 0=Off. The low-order bit of the first RTU character contains the status
of the first coil. For coil quantities that are not even multiples of eight, the last RTU
character is zero-filled at the high-order end.

RTU Mode
Bytes
1 2 3 4 n n+1 n+2
ò ò
Station 0000 0001 Data Length Data CRC
Address Data
ò ò

ASCII Mode
Bytes
1 2 3 4 5 6 7 8 n n+1 n+2 n+3 n+4
ò ò
: Station 0 1 Data Length Data Data LRC CR LF
Address
ò ò

Appendix D Modbus Protocol


202 Modbus Functions

Read Input Status (Function 02)

Query Format
The Read Input Status function operates in the same manner as Read Coil Status
(Function Code 01), except that the status of digital inputs is obtained. Inputs are
also numbered starting at 0. For example, input status 0 is alias 10001, input status
1 is alias 10002, and so forth. You can request the status of as many as 2,000 coils
with each query, but some Modbus devices have lower limits.

RTU Mode
Bytes
1 2 3 4 5 6 7 8
Station
0000 0010 Starting Address Number of Input Points CRC
Address

ASCII Mode
Bytes
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
Station
: Address 0 2 Starting Addresses Number of Input Points LRC CR LF

Response Format
RTU Mode
Bytes
1 2 3 4 n n+1 n+2
ò ò
Station
Address 0000 0010 Data Length Data Data CRC
ò ò

ASCII Mode
Bytes
1 2 3 4 5 6 7 8 n n+1 n+2 n+3 n+4
ò ò
Station
: Address
0 2 Data Length Data Data LRC CR LF
ò ò

Tricon Communication Guide


Modbus Functions 203

Read Holding Registers (Function Code 03)

Query Format
The Read Holding Registers query requests the binary content of holding registers
from a station. You can request the status of as many as 125 registers with each
query, but some Modbus devices have lower limits. The registers are numbered
beginning with 0. For example, register 0 is alias 40001, register 1 is alias 40002,
and so forth.
The Read Holding Registers query is also known as the Read Output Registers
query.

RTU Mode
Bytes
1 2 3 4 5 6 7 8
Station
Address 0000 0011 Starting Address Number of Registers CRC

ASCII Mode
Bytes
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
Station
: Address 0 3 Starting Address Number of Registers LRC CR LF

Response Format
The Read Holding Registers response data consists of two bytes for each register
queried, with the binary content right-justified. The leftmost character includes the
high-order bits, and the rightmost character includes the low-order bits.
RTU Mode
Bytes
1 2 3 4 n n+1 n+2
ò ò
Station
Address
0000 0011 Data Length Data Data CRC
ò ò

ASCII Mode
Bytes
1 2 3 4 5 6 7 8 n n+1 n+2 n+3 n+4
ò ò
Station
: Address 0 3 Data Length Data Data LRC CR LF
ò ò

Appendix D Modbus Protocol


204 Modbus Functions

Read Input Registers (Function Code 04)

Query Format
The Read Input Registers function operates in the same manner as the Read
Holding Registers query (Function Code 03), except that it obtains the status of
input registers. You can request the status of as many as 125 registers with each
query, but some Modbus devices have lower limits. The registers are numbered
beginning with 0. For example, register 0 is alias 30001, register 1 is alias 30002,
and so forth.
RTU Mode
Bytes
1 2 3 4 5 6 7 8
Station 0000 0100 Number of Registers CRC
Address Starting Address

ASCII Mode
Bytes
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
Station
: Address
0 4 Starting Address Number of Registers LRC CR LF

Response Format
RTU Mode
Bytes
1 2 3 4 n n+1 n+2
ò ò
Station
Address 0000 0100 Data Length Data Data CRC
ò ò

ASCII Mode
Bytes
1 2 3 4 5 6 7 8 n n+1 n+2 n+3 n+4
ò ò
Station
: Address
0 4 Data Length Data Data LRC CR LF
ò ò

Tricon Communication Guide


Modbus Functions 205

Force Single Coil (Function Code 05)

Query Format
The Force Single Coil function turns a single coil On or Off, depending on its
current state. Because the slave is actively scanning, it can also alter the state of the
coil (unless the coil is disabled). Coils are numbered beginning with 0; for example,
coil 0 is alias 1, coil 1 is alias 2, and so forth.
A coil value of 65,280 (FF0016) turns the coil On, and a coil value of zero (000016)
turns the coil Off. All other values are illegal and do not affect the coil. If the query
contains legal values, the slave responds after the coil state has been altered.
RTU Mode
Bytes
1 2 3 4 5 6 7 8
Station 0000 0101 Coil Value CRC
Address Address to Modify

ASCII Mode
Bytes
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17

: Station 0 5 Address to Modify Coil Value LRC CR LF


Address

Response Format
RTU Mode
Bytes
1 2 3 4 5 6 7 8
Station 0000 0101 Coil Value CRC
Address Modified
Address

ASCII Mode
Bytes
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17

: Station 0 5 Address Modified Coil Value LRC CR LF


Address

Appendix D Modbus Protocol


206 Modbus Functions

Preset Single Register (Function Code 06)


The Preset Single Register function modifies the content of one holding register.
Because the slave is actively scanning, it can also alter the register’s content.
Register values are 16 bits. Holding registers are numbered starting at 0; for
example, register 0 is alias 40001, register 1 is alias 40002.

Query Format
RTU Mode
Bytes
1 2 3 4 5 6 7 8
Station 0000 0101 Register Value CRC
Address Address to Modify

ASCII Mode
Bytes
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17

: Station 0 5 Address to Modify Register Value LRC CR LF


Address

Response Format
RTU Mode
Bytes
1 2 3 4 5 6 7 8
Station
0000 0110 Address to Modify Register Value CRC
Address

ASCII Mode
Bytes
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
Station
: 0 6 Address to Modify Register Value LRC CR LF
Address

Tricon Communication Guide


Modbus Functions 207

Read Exception Status (Function Code 07)

Query Format
The Read Exception Status function returns the status of eight coils from the slave
application running in the controller. Which coils and what they represent depends
on the slave. When a serial port, configured as a slave, responds to this query, it
sends the status of the first eight coils (aliases 00001 through 00008) defined in the
application. Coils are numbered from 0; for example, coil 0 is alias 1, coil 1 is alias
2, and so forth. The status of each coil is packed in the data field, one bit for each
coil (1=On, 0=Off). You can program these coils to hold any type of information;
for example, machine on or off, heads retracted, safeties satisfied, and receipt-in-
process error conditions.

Note An EICM serial port configured as a Modbus master cannot use the Read
Exception Status function.

RTU Mode
Bytes
1 2 3 4
Station
0000 0111 CRC
Address

ASCII Mode
Bytes
1 2 3 4 5 6 7 8 9
Station
: 0 7 LRC CR LF
Address

Response Format
RTU Mode
Bytes
1 2 3 4 5
Station Coil Data
0000 0111 CRC
Address

ASCII Mode
Bytes
1 2 3 4 5 6 7 8 9 10 11
Station
: Address
0 7 Coil Data LRC CR LF

Appendix D Modbus Protocol


208 Modbus Functions

Loop-Back Diagnostic Test (Function 08)

Query Format
The Loop-Back Diagnostics Test query tests the communications link between the
Modbus master and slave. This query does not affect point values in the slave.
When the serial port acting as a slave receives this query, it re-transmits the query
as the response.
RTU Mode
Bytes
1 2 3 4 5 6 7 8
Station
0000 1000 Data CRC
Address

ASCII Mode
Bytes
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
Station
: 0 8 Data LRC CR LF
Address

Response Format
RTU Mode
Bytes
1 2 3 4 5 6 7 8
Station
0000 1000 Data CRC
Address

ASCII Mode
Bytes
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
Station
: 0 8 Data LRC CR LF
Address

Note An EICM serial port configured as a Modbus Master cannot use the Loop-
Back Diagnostic Test function.

Tricon Communication Guide


Modbus Functions 209

Force Multiple Coils (Function Code 15)

Query Format
The Force Multiple Coils query sets each coil in a consecutive block of coils to the
specified state (On or Off) regardless of whether the coils are enabled or disabled.
Because the slave is actively scanning, it can also alter the state of a coil (unless it
is disabled). Coils are numbered from 0; for example, coil 0 is alias 1, coil 1 is alias
2, and so forth. The status of each coil is packed in the data field, one bit for each
coil (1=On, 0=Off).
A single Force Multiple Coils query can set a maximum of 128 coils. The query-
response time required by some Modbus masters might require a much smaller
quantity.
RTU Mode
Bytes
1 2 3 4 5 6 7 8 n n+1 n+2
ò ò
Station Starting Byte Coil Coil
0000 1111 Quantity CRC
Address Address Count Data Data
ò ò

ASCII Mode
Bytes
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 n n+1n+2 n+3 n+4
ò ò
Station Starting Byte Coil Coil
: 0 F
Address
Quantity
Count
LRC CR LF
Address Data Data
ò ò

Response Format
RTU Mode
Bytes
1 2 3 4 5 6 7 8 n n+1 n+2
ò ò
Station Starting Byte Coil Coil
0000 1111 Quantity CRC
Address Address Count Data Data
ò ò

ASCII Mode
Bytes
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 n n+1n+2 n+3 n+4
ò ò
Station Starting Byte Coil Coil
: Address
0 F
Address
Quantity
Count
LRC CR LF
Data Data
ò ò

Appendix D Modbus Protocol


210 Modbus Functions

Preset Multiple Registers (Function Code 16)

Query Format
The Preset Multiple Registers query can change the contents of a maximum of 60
consecutive holding registers, however, some Modbus devices have lower limits.
Because the slave is actively scanning, it can also alter the state of the registers
(unless they are disabled). The values are provided in binary code up to the
maximum valid register value of the controller (16-bit for Trident). Unused high-
order bits must be set to zero. The registers are numbered beginning with 0; for
example, register 0 is alias 40001, register 1 is alias 40002, and so forth.
RTU Mode
Bytes
1 2 3 4 5 6 7 8 n n+1 n+2
ò ò
Station Starting Byte Register Register
0001 0000 Quantity CRC
Address Address Count Data Data
ò ò

ASCII Mode
Bytes
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 n n+1n+2 n+3 n+4
ò ò
Station Starting Byte Register Register
: Address
1 0
Address
Quantity
Count
LRC CR LF
Data Data
ò ò

Response Format
RTU Mode
Bytes
1 2 3 4 5 6 7 8
Station
0001 0000 Starting Address Quantity CRC
Address

ASCII Mode
Bytes
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
Station
: 1 0 Starting Address Quantity LRC CR LF
Address

Tricon Communication Guide


Performance Considerations 211

Performance Considerations
Modbus performance degrades slightly as the scan time of the controller increases.

With the controller operating as a slave, the functions most affected by scan time
increases are:
• Force Single Coil (Function Code 05)
• Preset Single Register (Function Code 06)
• Force Multiple Coils (Function Code 15)
• Preset Multiple Registers (Function Code 16)
The functions least affected by scan time increases are:
• Read Coil Status (Function Code 01)
• Read Input Status (Function Code 02)
• Read Holding Registers (Function Code 03)
• Read Input Registers (Function Code 04)

Appendix D Modbus Protocol


212 Transmission Errors and Exception Conditions

Transmission Errors and Exception Conditions


During Modbus communication, transmission errors and exception conditions can
occur. Transmission errors do not cause exception conditions and are not
acknowledged by Modbus slaves. Programming and operation errors do cause
exception conditions which elicit exception responses from slaves.

Transmission Errors
The most frequent cause of transmission errors is noise. Noise sources include
improperly installed or broken connectors, damaged cables, electrical equipment
such as generators and elevators, and lightning. Transmission errors can be
detected through the use of character framing, parity checking, and redundancy
checking.
When a slave detects a transmission error, it does not act on or respond to the
message. The master assumes a communications error has occurred if there is no
response within a specified time, usually three seconds.
Parity checking helps detect single-bit transmission errors. However, if there are
two errors within a single character, parity checking cannot detect a change. For
example, if 1100 0100 is distorted to 1111 0100, the number of 1 bits in the data is
still odd.
Modbus protocol provides several levels of error checking in order to assure the
accuracy of data transmission. To detect multiple bit errors, the system uses cyclic
redundancy check (CRC) for RTU mode, or longitudinal redundancy check (LRC)
for ASCII mode. For more information, see “Checksum Field (CRC or LRC)” on
page 197.

Tricon Communication Guide


Transmission Errors and Exception Conditions 213

Exception Conditions
If a programming or operation error causes a master to send an incorrect query, the
slave responds with one of the following exception conditions.

Exception
Description
Condition
Query Message The slave does not respond, because the error could be in the
CRC or LRC station address. The master uses its response fail-safe timer to
Error recover.
Query Function The slave sends an Illegal Function (01) response code when it
Code Error detects an error in the function code field.
Query Address The slave sends an Illegal Data Address (02) response code when
Error it detects an error in the starting address field.
Query Data Error The slave sends an Illegal Data Value (03) response code when it
detects an error in the data field.
Main Processors This exception applies only to EICM serial ports which are
not communicat- configured as slaves.
ing If the slave port receives a query requiring a data exchange and it
cannot communicate with the Main Processors, it sends a Busy,
Reject Message (06) response code and turns off the Active
indicator on the EICM.
Remote Write The slave port sends a Busy, Reject Message (06) response code if
Disabled a master sends one of the following queries and the slave port is
not enabled for remote (external) writes:
• Force Single Coil (Function Code 05)
• Preset Single Register (Function Code 06)
• Force Multiple Coils (Function Code 15)
• Preset Multiple Registers (Function Code 16)

If a master detects an exception in a response to a query or does not receive a


response, it takes appropriate actions which usually include re-transmitting the
query.

Appendix D Modbus Protocol


214 Transmission Errors and Exception Conditions

Exception Responses
When a slave detects an exception condition, it sends a response message to the
master consisting of the slave’s station address, function code, error code, and
error-check fields. To indicate that the message is an exception response, the slave
sets the high-order bit of the function code to 1. The following example shows an
exception response to a Preset Multiple Registers query.

Sample Query
RTU Mode
Bytes
1 2 3 4 5 6 7 8 n n+1 n+2
ò ò
Station Starting Byte Register Register
0001 0000 Quantity CRC
Address Address Count Data Data
ò ò

ASCII Mode
Bytes
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 n n+1n+2 n+3 n+4
ò ò
Station Starting Byte Register Register
: 1 0
Address
Quantity
Count
LRC CR LF
Address Data Data
ò ò

Sample Exception Response


RTU Mode
Bytes
1 2 3 4 5 6
Station Exception
1001 0000 CRC
Address Code

ASCII Mode
Bytes
1 2 3 4 5 6 7 8 9 10 11 12 13
Station Exception
: 9 0
Code
LRC CR LF
Address

Tricon Communication Guide


Transmission Errors and Exception Conditions 215

Exception Response Codes


After an invalid query, the slave sends one of the following exception response
codes to the master.

Code Name Description n

01 Illegal The requested function is not in the slave’s repertoire.


Function
02 Illegal Data The alias in the query does not exist in the slave.
Address
03 Illegal Data The value is not in the range allowed for the alias.
Value
04 Failure in The slave failed to respond to a message or an error that
Associated occurred in the controller. When a master receives this
Device response code, it must issue a supervisory alert.
05 Acknowledge A slave port does not send this exception response code.
06 Busy, The query was received without error, but the slave cannot
Rejected comply.
Message
07 Negative A slave port does not send this exception response code.
Acknowledge
08 Memory A slave port does not send this exception response code.
Parity Error

Appendix D Modbus Protocol


216 Transmission Errors and Exception Conditions

Tricon Communication Guide


Glossary

10Base2 The standard for an Ethernet LAN capable of transmitting 10 megabits of data per
second through thin coaxial cables, to a maximum distance of 200 meters (656
feet).

10BaseT The standard for an Ethernet LAN capable of transmitting 10 megabits of data per
second through twisted-pair wire.

100BaseTX The predominant standard for a Fast Ethernet LAN capable of transmitting 100
megabits of data per second through Category 5 twisted-pair cable only.

AUI Attachment Unit Interface. A coaxial cable connected to a transceiver that plugs
into a 15-pin socket on the network interface card (NIC), to a maximum distance
of 100 meters (328 feet).

ARP Stands for Address Resolution Protocol which is a TCP/IP protocol used to obtain
the physical address of a node on an Ethernet network. A client station broadcasts
an ARP request onto the network with the IP address of the target node it wants to
communicate with. The node with that address responds by sending back its
physical address so that packets can be transmitted to it.

Centronics A standard 36-pin parallel interface for connecting printers and other devices to a
computer.

client/server An architecture in which the client (PC or workstation) is the requesting machine
and the server is the supplying machine, both of which are connected by means of
a local area network (LAN) or wide area network (WAN).

closed network A network designed for maximum safety which includes only Triconex devices. A
Peer-to-Peer network is an example of a closed network.

communication The route between any two nodes. Same as line, channel, link, or circuit.
path

communication Hardware and software standards that govern data transmission between two
protocol computers or communications devices. There are several layers (levels) of
functionality in a protocol. Each layer may be available as a separate software
component, or several layers may be combined into one.

Tricon Communication Guide


218 Glossary

CTS signal In Modbus communication, an RS-232 signal sent from the receiving station to the
transmitting station which indicates it is ready to accept data.

data bits The number of bits used to represent one character of data. When a Modbus slave
transmits ASCII text, either seven or eight bits can be used. When a Modbus master
or slave uses the RTU mode, eight data bits are required.

data transfer In a Peer-to-Peer network, the time required to initiate a send operation, send the
time data over the network, and get an acknowledgment from the receiving controller.

default gateway A router that forwards all messages not addressed to stations within the local
subnet.

duplex See full duplex and half duplex.

Ethernet A type of computer network which is defined by the IEEE 802.3 standard. An
Ethernet network is typically a shared media LAN. All stations on the segment
share the total bandwidth, which is either 10 megabits (Ethernet), 100 megabits
(Fast Ethernet) or 1,000 megabits (Gigabit Ethernet) per second.

exception In Modbus communication, a programming or operation error which involves an


condition illegal or illogical query by the master.

exception In Modbus communication, the response of a slave to a programming or operation


response error.

Fast Ethernet Another name for 100BaseTX Ethernet communication. Fast Ethernet transmits
data at 100 megabits per second rather than 10 megabits per second as in regular
Ethernet. Fast Ethernet operates in a LAN (local area network) that shares the 100
megabit per second bandwidth with all transmitting stations.

full duplex Serial communication using two pairs of wires—one pair for Modbus reads and the
other pair for Modbus writes. Called 4-wire in TriStation.

gateway A computer that performs protocol conversion between different types of networks
or applications. For example, a gateway can convert a TCP/IP packet to a NetWare
IPX packet and vice versa.

GPS Stands for Global Positioning System which is a system of 24 satellites for
identifying earth locations, launched by the U.S. Department of Defense. The GPS
is used for navigation and is the most accurate time source for a local clock.

half duplex Serial communication using one pair of wires to transmit Modbus reads and writes.
Called 2-wire in TriStation.

Tricon Communication Guide


Glossary 219

hardware Signals transmitted back and forth between two stations to coordinate the timing of
handshake data transmission.

hub A connecting device in a network that joins communication lines together in a star
configuration. Passive hubs are connecting units that add nothing to the data
passing through them. Active hubs (multi-port repeaters) regenerate the data bits to
maintain a strong signal. Intelligent hubs provide added functionality.

IP address The unique 32-bit address of a computer attached to an Ethernet network. Every
client and server in an Ethernet network requires an IP address which is either
permanently assigned or dynamically assigned at startup.

JetDirect A print server for LaserJet printers from HP which is available as an internal card
or external unit. It supports its own proprietary printing protocol and several others,
depending on the model. The JetAdmin printer management software is used to
configure and control the JetDirect print server.

MAC address The unique physical address of a network device that is burned into the Network
Interface Card (NIC) of the device when it is manufactured.

master In Modbus communication, a device that initiates all query and response exchanges
with the slave devices.

MAU Stands for media adapter unit which is a device used to convert one type of Ethernet
media to another. In a Trident system, a MAU can be used to convert a CM port to
another Ethernet media type or to extend network distances.

message For a TSAA client/server or Modbus master/slave data exchange, the time required
response time to initiate and send a query and get a response from the receiving controller.

MII Stands for media independent interface which is a bus used between network
controllers and physical interfaces that is based on the MII interface specification.

Modbus An industry-standard master/slave protocol that is traditionally used for energy


protocol management, transfer line control, pipeline monitoring, and other rugged industrial
processes. A Modbus communication link can use either the Remote Terminal
(RTU) or ASCII mode of transmission.

multi-point In Modbus communication, a link that interconnects three or more master or slave
devices.

NIC Stands for Network Interface Card which is a printed circuit board that plugs into
both a client and a server device and controls the exchange of data between them.
Also called a network adapter card.
220 Glossary

node In computer communication, a node is a network junction or connection point. For


example, a Trident controller in an Ethernet network is a node. A terminal
connected to a minicomputer or mainframe is a node.

open network An Ethernet network to which Triconex controllers and other Ethernet devices,
including routers and gateways to other networks, can be connected.

OPC Stands for OLE for Process Control which is a standard set of non-proprietary
interfaces used to develop client/server programs. OPC supports interoperability
between field devices and applications for process control, factory automation, and
business.

parallel port A socket on a computer used to connect a printer or other parallel device to the
computer's parallel interface.

parity checking An error detection method that tests the integrity of digital data during transmission
over a serial communication path. Parity checking counts the number of 1 bits in a
one-byte data item and sets the parity bit (the ninth bit) to 0 or 1, resulting in an odd
or even total number of bits.

path In computer communication, the route between any two nodes. Also called line,
channel, link, or circuit.

print server A hardware device with multiple Ethernet ports that enables a printer to be located
anywhere in an Ethernet network.

Peer-to-Peer An Ethernet-based Triconex protocol that allows two applications running on


protocol separate Triconex controllers to exchange a limited amount of process control data.
Because a Peer-to-Peer network is restricted to Triconex controllers, the cable can
be isolated and protected more securely than an Ethernet cable. A Peer-to-Peer
network requires the use of Ethernet ports on NCMs.

point-to-point In Modbus communication, a link that connects one master or slave device to
another.

process- The maximum length of time that can elapse before the control algorithms in a
tolerance time TriStation application fail to operate correctly.

protocol Rules that govern transmitting and receiving of data. See communication protocol.

RARP Stands for Reverse Address Resolution Protocol which is a TCP/IP protocol used
by a diskless workstation to obtain its IP address.

redundancy The practice of using a spare device in parallel with a primary device so that, if the
primary device fails, the spare device is easily or automatically placed into service.

Tricon Communication Guide


Glossary 221

Examples are redundant modules which protect against internal faults, redundant
cables which protect against cable breakage, and redundant workstations which
protect against network failures.

router A device that forwards data packets from one local area network (LAN) or wide
area network (WAN) to another. Based on routing tables and routing protocols,
routers read the network address in each transmitted frame and decide how to send
it based on factors like network traffic, speed, or bad lines.

RS-232 Stands for Recommended Standard 232 which is a standard interface approved by
the Electronic Industries Association (EIA) for connecting serial devices in point-
to-point configurations.

RS-422 Stands for Recommended Standard 422 which is a standard interface approved by
the Electronic Industries Association (EIA) for connecting serial devices in point-
to-point differential configurations.

RS-485 Stands for Recommended Standard 485 which is a standard interface approved by
the Electronic Industries Association (EIA) for connecting serial devices in multi-
point differential configurations.

RTS signal In Modbus communication, an RS-232 signal sent from the transmitting station to
the receiving station requesting permission to transmit.

scan surplus A component of the scan time of a controller, the scan surplus is the time left after
the executable elements and communication messages have been processed. The
scan surplus should be positive. If the scan surplus is negative, the scan time should
be increased.

scan time The time required by a controller for the cycle of required control functions. The
scan time includes input poll time; execution time for all executable elements in the
TriStation project; processing time for TriStation and Peer-to-Peer messages,
TSAA writes, and Modbus writes; and output poll time.

slave In Modbus communication, a device that is controlled by another device called the
master. The master initiates all query and response exchanges, and the slave can
only respond.

station A computer, workstation or terminal in a network. Also called a node.

subnet A division of a network into an interconnected, but independent, segment (domain)


to improve performance and security. Typically, Triconex controllers are
configured in a subnet that is part of a large network for process control.
222 Glossary

subnet mask The addressing method used to split networks into subnets. The mask is a binary
pattern that subdivides a single IP address into a subnet number and a new host
number. A typical subnet mask is 255.255.255.0, which means that 254 Class C
addresses are available.

TCP/IP Stands for Transmission Control Protocol/Internet Protocol which is the global
standard communication protocol for the Internet. Can also be used for private
networks such as corporate intranets and distributed control systems.
TCP/IP is a routable protocol, which means that all messages contain not only the
address of the destination station, but the address of a destination network. This
allows TCP/IP messages to be sent to multiple networks within an organization or
around the world, hence its use in the Internet.

time A Triconex protocol used to establish and maintain a synchronized, network-wide


synchronization time basis. A controller’s time can be synchronized with the master node in a
network of Tricon or Trident controllers, or with a Distributed Control System
(DCS).

topology In a network, the pattern of interconnection between nodes; for example, a bus, ring
or star configuration.

TSAA Stands for Triconex System Access Application, a protocol that enables
client/server communication between Triconex controllers and PCs. Two
client/server programs, OPC Server and DDE Server, use TSAA protocol to
exchange data with Triconex controllers. TSAA protocol can also be used to write
other programs for accessing Trident points.

transceiver A transmitter and receiver of analog or digital signals, such as a transponder or


network adapter.

TriStation A Triconex master/slave protocol in which the master (a TriStation PC)


protocol communicates with the slave (a Triconex controller) over an Ethernet network.
TriStation communicates with the Main Processors in order to download the
application to the Triconex controller and upload diagnostic information.

Tricon Communication Guide


Index

Numerics BNC connectors


100BaseTX cable 24 Network Accessory Kit 10
10Base2 cable on network card 24
connecting to media converter 25 terminating if unused 13, 24
converting to faster media 13
10BaseT cable 24 C
25-pin to 9-pin adapter 9 cables
2-wire configuration 102 100BaseTX 24
802.2 protocol 10Base2 coaxial 10
configuring DDE Server properties 64 10BaseT 24
configuring redundant networks 67 Category 5 shielded 10
Modbus 9
A non-Triconex manufacturers 10
ACM, protocols supported 2 null modem 10
Acutime 2000 Synchronization Kit 127 RS-232 10
adapter card. See network adapter card. standard lengths 10
adapter, 25-pin to 9-pin 9 twisted-pair 10, 24
ADJUST_TRICON_CLOCK 172 Category 5 shielded cable 10
ADJUST_TRICON_CLOCK_RSP 173 Centronics printing
aliases brief description 5
defined 39, 94 EICM parallel port 16
memory allocation 86 printing setup 134
used in Modbus programming 111 using EICM parallel port 133–136
ASCII mode chassis, rules for selection 12
characters in station address 196 checksum field
defined 194 in Modbus message format 197
client/server communication
model 57
B
overview 46–47
baud rate property of EICM serial port 101
using DDE Server 57–70
big-endian order 154
using OPC Server 71–75
bins (TSAA)
writing your own program 46
binary mask used to identify 165
clock. See controller clock.
requesting data 164
coaxial cables 10
bit and byte ordering 154
COMM Bus 138, 147

Tricon Communication Guide


224 Index

communication DDE Server (continued)


indicators on EICM front panel 143 uninstalling 59
indicators on NCM and NCMG 151 view options 69
modes for Modbus protocol 100 DDE. see also DDE Server.
non-Triconex hardware 11 See also
protocols, brief descriptions 2–5 Device Clock tagname 75, 126
Triconex hardware products 8 DHP Modbus range 102
connection accessories diagnostic monitoring 42
for Ethernet ports 24 DLC protocol. See 802.2 protocol.
for serial ports 21 Download All
Triconex products 9–10 general rules 42
connectors rules for Peer-to-Peer 88
BNC 10, 13 dual redundancy, OPC Server 75
RJ-45 10 Dynamic Data Exchange. See DDE.
contacting Triconex xv–xvii
control programs (TSAA) 46 E
controller clock, setting 130 EICM
CR field 198 aggregate data rate 138
CRC error check 197 available ports 138
CTS wire, EICM serial port 103 communication indicators 143
customer support xv–xvii front panel 142
cyclic redundancy check. See CRC. hot spare feature unavailable 138
parallel port specifications 141
D physical description 141–144
data bits property, EICM serial port 101 port numbers and connections 143
data transfer time protocols supported 2
calculated for sample program 91 serial port specifications 141
defined 85 Enhanced Intelligent Communication
equation for correcting 87 Module. See EICM.
equation for estimating 86 errors, Modbus data transmission 212
estimating for Peer-to-Peer network 85 Ethernet adapter. See network adapter card.
typical for Peer-to-Peer network 85, 92 Ethernet connection, testing in DDE Server
DDE 65
address format 68 Ethernet ports on ACM or NCM
client application 68 connecting to Ethernet devices 13
network redundancy 66 connection accessories 24
protocol defined 57 converting to faster media 13
DDE Server limitations 6
brief description 3 overview 47
configuring application 59 Peer-to-Peer configuration 80
configuring Triconex host 60 TriStation configuration 48–53
installing 58 even parity 101
overview 57 exception conditions, Modbus 213

Tricon Communication Guide


Index 225

exception responses, Modbus 214–215 IP address


execution time methods for setting 53
defined 41 property of Ethernet port 49, 52
for Modbus slave 192 specifying in OPC Server 73
external writes. See write access. using default 54
using EICM to set 56
F using RARP server to set 55
fail-safe timer, started by master 192
First Out block (SOE) 183 K
FM certification 11 keyswitch, Tricon
Force Multiple Coils function 209 Program mode 170
Force Single Coil function 205 Remote mode 166
function blocks
Modbus reads and writes 105–110 L
Peer-to-Peer Sends and Receives 83 LF field in Modbus message 198
printing 133 little-endian ordering 154
time adjustment 126 longitudinal redundancy check. See LRC
checksum.
G Loop-Back Diagnostic Test function 208
Global Positioning System. See GPS. LRC checksum
GPS calculation 198
redundant configuration 127 defined 197
setting property on NCMG 81
time adjustments 127 M
time synchronization protocol 4 mark parity 101
master (Modbus), programming instruc-
H tions 105–110
hardware handshake master node, defined 125
property of EICM serial port 102 MAUs, converting transmission speeds 88
rules 96 Max Span property 115
See also signal delays MBCTRL function block 121
Honeywell DHP Modbus range 102 media converter
available from Triconex 24
I TriStation connection 25
ICM. See EICM. memory allocation
IEEE standard for real numbers 114 Peer-to-Peer data transfer time 86
indicators Peer-to-Peer Sends and Receives 82
EICM front panel 143 message
NCM and NCMG front panel 151 processing, EICM 138–140
Intelligent Communication Module. See processing, NCM and NCMG 147–148
EICM. response time, Modbus 140
response time, NCM and NCMG 148

Tricon Communication Guide


226 Index

message processing time 41 Modbus Range property


Min Span property 115 scaling real values 115
Modbus communication specifying for EICM serial port 102
brief description 4 typical Modbus master values 118
overview 94 Modbus Read function blocks. See Read
Modbus devices function blocks (Modbus).
estimating response time 193–194 Modbus read queries 139
RTU and ASCII modes 194 Modbus Slave Address property, EICM se-
setting signal delays 103 rial port 100
Modbus function blocks Modbus write commands 139
processing 110 Modbus Write function blocks. See Write
sample programs 120 function blocks (Modbus).
using with non-Triconex slaves 106 modules, rules for selection 12
using with Tricon slaves 107 monitor programs (TSAA) 46
using with Trident slaves 107 monitoring
Modbus functions Peer-to-Peer communication 89
list of names and codes 195 Triconex response in DDE Server 69
supported by EICM 195–210 multi-point configuration
Modbus integers 111, 115 diagram 96
Modbus Max property 115 with hardware handshake 102
Modbus message response time 140
Modbus Min property 115 N
Modbus protocol NCM and NCMG
checksum field 197 communication indicators 151
effects of scan time increases 211 front panel 150
exception conditions 213 message processing 147–148
exception responses 214–215 operation 146
function code field, described 196 physical description 149–151
master programming instructions 105– protocols supported 2, 151
110 specifications 149
message format, RTU and ASCII modes negative scan surplus 41
196 network adapter card
message header 196 DDE PC 66
message lengths 200 TriStation PC 19
performance considerations 211 Network Hardware Accessory Kit 9, 24
query and response, RTU and ASCII network interface card 10
modes 199 network redundancy
query processing time 193 DDE Server 66
slave programming instructions 111– diagram 15
119 OPC Server 75
station address field 196 node number
supports only 16-bit integers 105, 111 changing and Download All 42
changing on ACM or NCM 30

Tricon Communication Guide


Index 227

node number (continued) ping command, IP address verification 54,


master node defined 125 55, 56, 65
setting on ACM 26–27 point-to-point configuration, diagram 95
setting on NCM 28–29 poll time 62
noise sources, Modbus communication positive scan surplus 41
212 Preset Multiple Registers function 210
null modem cable 10 Preset Single Register function 206
print function blocks
O available in library 136
odd parity 101 common parameters 136
OPC client application 74 purpose 133
OPC Data Manager (ODM) 75 scan time increases 133
OPC Redundancy Broker (ORB) 76 printer port (EICM) 138
OPC Server printers
brief description 3 characters per line 135
configuration procedure 72–74 lines per page 135
network redundancy 75 printing devices
overview 71 basic setup 134
using with multiple controllers 71 Centronics-compatible 16
ordering of bits and bytes in Triconex con- configuring 135
trollers 154 installing 134
process tolerance time
defined 85
P in Peer-to-Peer sample program 92
parallel ports (EICM) processing time, Modbus slaves 193
brief description 138
specifications 141
parallel printing, overview 133 Q
parity checking query-response exchange
defined 101 between Modbus master and slave 192
Modbus transmission errors 212
property of EICM serial port 101 R
Peer-to-Peer communication Read Coil Status function 201
brief description 3 Read Exception Status function 207
estimating data transfer time 85 Read function blocks (Modbus)
overview 78 list 105
speed restrictions 79, 88 sample diagram 108
using Send and Receive function blocks sample programs 120
83–84 Read Holding Registers function 203
Peer-to-Peer Receive. See Receive func- Read Input Registers function 204
tion blocks. Read Input Status function 202
Peer-to-Peer Send. See Send function read queries
blocks. Modbus 139
performance, Modbus 211 TSAA 148

Tricon Communication Guide


228 Index

READ_TRICON_CLOCK 168 sample programs


READ_TRICON_CLOCK_RSP 168 Modbus communication 120
READ_TRICON_DATA 174 Peer-to-Peer communication 90
READ_TRICON_RSP 175 scaling
real values graph, integers to REALs 115
IEEE standard 114 graph, REALs to integers 116
numeric spans for points 118 procedure in TriStation 118–119
transmitting with scaling 115–119 scan surplus
Receive function blocks (Peer-to-Peer) ensuring positive 41
changing maximum number 42 Peer-to-Peer network 42
general usage 79, 83 scan time
setting maximum number 83 defined 41
Recvid input parameter 84 effect of conditional statements 133
Recvnode input parameter 84 effect on Modbus performance 211
redundancy testing 16 scan-time overruns 134
redundant DDE networks Send function blocks (Peer-to-Peer)
configuring with 802.2 protocol 67 available in library 83
configuring with TCP/IP protocol 66 changing maximum number 42
required hardware 65 general usage 79, 83
redundant devices scans required for data transfer 85
operation 15–16 setting maximum number 83
testing for hardware failures 16 Sendid input parameter 84
two NCMGs and GPS 127 Sendnode input parameter 84
workstations 16 sequential events recorder (TSAA) 46
remote access. See write access. serial port specifications (EICM) 141
Remote mode, Trident and Tricon 166 serial ports on EICM
Remote Terminal Unit. See RTU. configuration 98–102
response codes (TSAA) 189 connection accessories 21
response time, Modbus devices 193 electrical interface 98
retry values, Modbus master 194 master, slave, or combination 94
RJ-45 connectors 10 physical features 95–97
RS-232 transceiver mode server 57
rules 96 session execution time 193
RS-485 transceiver mode SET_TRICON_CLOCK 170
rules 96 SET_TRICON_CLOCK_RSP 171
RTS wire, EICM serial port 103 signal delays
RTU mode 194 setting for Modbus devices 103
See also hardware handshake
S SOE
safety-critical applications 2 availability of data (TSAA) 184
running Install Check 33 block status (TSAA) 185
where to find guidelines 2 commands (TSAA) 183
time stamp in message (TSAA) 182

Tricon Communication Guide


Index 229

space parity 101 time stamp (TSAA) (continued)


special aliases SOE entry fields 182
processing Modbus integers as real val- time synchronization
ues 111–112 GPS time adjustments 127
reading real values 111 guidelines for networks 129
table 112 multiple controllers on network 125
writing real values 112 overview 125
Special parameter, Modbus function property of Ethernet port 50, 52, 81
blocks 107 protocol defined 4
station address field, Modbus message setting properties for ACM 131
196 setting properties for an NCM or NCMG
status, Peer-to-Peer communication paths 132
89 TIMEADJ function block 126
stop bits property, EICM serial port 101 time-out values, Modbus master 194
subnet of Triconex controllers 53 TIMESET function block 126
symbol table (TSAA) timing
information retrieval 155 diagram for EICM serial port 103
requesting part of 186 serial data transmission 103
sending requested data 187 TR_PEER_STATUS function block 89
structure for Trident 156 TR_PORT_STATUS function block 89
system aliases 39 training xvii
system time (TSAA) transmission errors, Modbus 212
adjusting 172 transmission time, Modbus data exchange
in relative seconds 169 193
TriBus voting 138–140, 147
T Tricon as Modbus master
tagnames programming instructions 105–110
defined 39 Tricon as Modbus slave
finding starting address (TSAA) 157 programming instructions 111–119
TCP/IP address. See IP address. Tricon clock. See controller clock.
TCP/IP protocol TRICON_CPSTATUS_REQ 183
installing on Windows 2000 PC 20 TRICON_CPSTATUS_RSP 184
installing on Windows NT PC 20 TRICON_DATA 161
technical support xv–xvii TRICON_DATA_REQ 164
throughput, Modbus devices 103 TRICON_GET_SYMBOL_REQ 186
time TRICON_GET_SYMBOL_RSP 187
adjusting (TSAA) 172 TRICON_SOE_DATAAVAIL 184
for Modbus data transmission 193 TRICON_SOE_REQ 177
requesting for controller (TSAA) 168 TRICON_SOE_RSP 178
setting on controller (TSAA) 170 Triconex DDE Server. See DDE Server.
time stamp (TSAA) Triconex support xv–xvii
associated with bin data 163 Triconex System Access Application pro-
bin data in relative seconds 176 tocol. See TSAA.

Tricon Communication Guide


230 Index

Trident symbol table. See symbol table. Write function blocks (Modbus)
Trimble list 105
Acutime 2000 Synchronization Kit 127 sample diagrams 103, 109
Standard Interface protocol 127 sample programs 120
TriStation 1131 Developer’s Workbench WRITE_TRICON_DATA 166
installing 31 WRITE_TRICON_DATA_RSP 167
uninstalling 32
TriStation PC X
connecting to Ethernet port 24–25 XML configuration file
connecting to serial port 21–23 exporting from TriStation 72
TriStation ports OPC Server overview 71
configuring EICM serial port 34–35
configuring Ethernet port 36
default on EICM 21
setting switches on EICM 21–23
TSAA client/server communication
brief description 3
overview 46–47
using DDE Server 57–70
using OPC Server 71–75
writing your own program 46
TSAA protocol, DDE communication 57
TSAA read queries 148
TSAA write commands 148
twisted-pair cables 10, 24

V
view options, DDE Server 69

W
workstation redundancy, OPC Server 75
write access
by DDE client 60, 68
by OPC client 72
by tagname or alias 39
configuring ACM port 40, 49
configuring NCM port 40, 51
disabling changes to outputs 40
setting write controls 40, 47
write commands
Modbus 139
TSAA 148

Tricon Communication Guide

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy