Device Interface Guide
Device Interface Guide
Version 7.0
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
Device Interface Guide
NOTICE:
The information contained in this document (and other media provided herewith) constitutes confidential
information of United States Data Corporation (“USDATA”) and is protected by copyright laws and
international copyright treaties, as well as other intellectual property laws and treaties. Such information is
not to be disclosed, used or copied by, or transferred to, any individual, corporation, company or other entity,
in any form, by any means or for any purpose, without the express written permission of USDATA.
The information contained in this document and related media constitutes documentation relating to a
software product and is being provided solely for use with such software product. The software product was
provided pursuant to a separate license or other agreement and such information is subject to the restrictions
and other terms and conditions of such license or other agreement.
The information contained in this document and related media is subject to change without notice and does
not represent a commitment on the part of USDATA. Except for warranties, if any, set forth in the separate
license or other agreement relating to the applicable software product, USDATA makes no warranty, express
or implied, with respect to such information or such software product.
USDATA and FactoryLink are registered trademarks of United States Data Corporation in the United States
and/or other countries. Open Software Bus is a registered trademark licensed to United States Data
Corporation. All other brand or product names are trademarks or registered trademarks of their respective
holders.
.
Part I External Device Interface
By sending messages to remote devices through the FactoryLink EDI task, you
can automate tasks associated with processes, such as when valves are opened or
closed, when machines are turned on or off, or when data such as temperature or
pressure is collected. Each remote device uses a specific communication protocol.
The protocol used varies by device type; therefore, FactoryLink translates the
protocol to ensure an accurate exchange of data with the device.
17
Chapter 1
•
•
•
•
External Device
Interface Overview 1
External Device
Interface
The External Device Interface (EDI) task allows you to configure FactoryLink to
communicate with remote devices. Remote devices, such as programmable
controllers and remote terminal units, are used in virtually every type of industry
to monitor and control processes, such as the production of goods at a factory, the
movement of liquid or gas down a pipeline, or the periodic collection of data.
By sending messages to remote devices via the EDI task, you can use FactoryLink
to automate tasks associated with processes, such as when valves are opened or
closed, when machines are turned on or off, or when data such as temperature or
pressure is collected.
Each remote device uses a specific communication protocol. The protocol used by a
device varies from one device type to another; therefore, FactoryLink must be able
to translate a particular device’s protocol to ensure an accurate exchange of data
with the device. A set of protocol-specific modules is supplied with FactoryLink to
address these protocol translation needs. Each protocol module translates
messages sent from FactoryLink into a format understood by the supported device
type and translates messages sent from the device to a format understood by
FactoryLink.
Open
0 ö
1
Closed ì
ú
ó
÷
ø
í 1 0 1 0 1 0
MTR
External Device
SOL
ì
Interface
ó
1 0 1 0 1 0
FactoryLink
Computer
Port
Using an additional port, FactoryLink can communicate with devices that share
another communications protocol.
Figure 1-4 Multiple Ports, Multiple Protocols
FactoryLink
Computer Port
Port
Each communications port supports one type of protocol. This means only one
protocol module can be used per port. The number of supported devices per port
depends on your hardware configuration. See “Device Topologies” on page 27 for
descriptions of various types of hardware configurations.
External Device
Figure 1-5 Interface Topology
Interface
A FactoryLink application requires only one EDI task running to communicate
with multiple devices. EDI, however, can provide a common interface to the
real-time database for one or more instances of the same protocol module or one or
more unique modules that support devices of varying manufacturers and types.
Use more than one protocol module when you need to communicate with different
types of devices through separate ports, as shown in Figure 1-6 and Figure 1-9.
FactoryLink
Port Computer
Port
EDI and one protocol module can communicate with devices that share the same
protocol. Figure 1-7 illustrates FactoryLink communicating with three devices out
of one port.
Figure 1-7 Communication Through One Protocol Module
Note
EDI and multiple instances of one protocol module can communicate with devices
that share the same communication protocol. Figure 1-8 illustrates FactoryLink 1
communicating with devices via three different ports. When you use instances of a
protocol module, the distribution of system resources allows better throughput,
thus speeding up communications. This type of configuration is typical in
External Device
point-to-point communications, discussed in “Device Topologies” on page 27.
Interface
Figure 1-8 Communication Through Multiple Instances of One Protocol Module
Note
D EVICE TOPOLOGIES
1
The diagrams in this section illustrate some possible ways FactoryLink
communicates with devices. For information about communications with devices
using specific protocol modules, refer to the table on page 30.
External Device
Interface
Serial Port
For a serial system unit communications (COM) port connection, FactoryLink can
communicate with devices in two ways: directly (one point to one point) as shown
in Figure 1-10, or through a network interface module as shown in Figure 1-11. An
interface module can be an RS232-to-RS422 external converter or a device that
bridges an RS232 communications link to a proprietary network.
Figure 1-10 Point-To-Point Connection
FactoryLink
COM
Computer
Port
COM
Port
RS422 or
FactoryLink proprietary
Computer RS232 network
COM
Port
FactoryLink
Computer
DigiBoard
FactoryLink
Computer
Ethernet
Board
Port
Combination
1
Topologies can be combined. The way in which you successfully combine topologies
depends on a combination of limitations in hardware, system resources, and
FactoryLink.
External Device
Figure 1-14 illustrates simultaneous communications with four devices: three are
Interface
linked via a network through an RS232-to-RS422 converter and one device is
connected directly to a COM port.
Figure 1-14 Point-To-Point and Network Module Connection
RS232 RS422
FactoryLinkCOM
Computer Port
COM
Port
Ports
Protocol Module
Serial DigiBoard Ethernet
Allen-Bradley ✔ ✔
Modicon Modbus™ ✔ ✔
Siemens CP525® ✔ ✔
Siemens Sinec H1 ✔
Square D ✔ ✔ ✔
Texas Instruments™
✔ ✔
TIWAY/Point-to-Point
External Device
For a COM port connection, the two components are the device and the COM port
to which it is connected.
Interface
Figure 1-15 Two Components of a COM Port Connection
FactoryLink
COM
Computer
Port
Port Device
For a DigiBoard port connection, the two components of a communication path are
the device and the board port to which it is connected.
Figure 1-16 Two Components of a DigiBoard Port Connection
FactoryLink
Computer
DigiBoard Device
Port
Port
For an Ethernet board port connection, the two components are the device and the
board port to which it is connected.
Figure 1-17 Two Components of an Ethernet Port Connection
FactoryLink
Computer
Ethernet
Board Device
Port
Port
Some examples of possible numbering schemas are illustrated in the next two
diagrams.
Figure 1-18 Point-To-Point Connection
Logical Port 0
Logical
FactoryLink
COM
Station 0
Computer Logical
Port
Station 1
COM
Port
Logical Port 1
Logical
1
Station 1
Logical
External Device
Station 2
Logical
Interface
Station 3
FactoryLink Logical
Computer Station 4
DigiBoard
Logical Port 4
Logical Port 3
Logical Port 2
Logical Port 1
FactoryLink
Computer
Ethernet
Board
Port
Logical Port 1
COM
Port
Logical Port 2
Logical
Station 4
The number you assign to a device (the logical station number) is tied to the
number you assign to represent the port through which communications with the
device occurs (the logical port number). No logical station number assigned to a
device can match the station number of another device for a given protocol type.
The logical port number you assign to represent a port can match a logical station
number assigned to a device (you can have logical port 1 and logical station 1), but
device numbers for a given protocol type must be unique (you cannot assign
logical station number 1 to two different devices).
Figure 1-23 Logical Port Numbers Tied to Logical Device Numbers
External Device
protocol-specific configuration table designed for defining both types of operations.
Interface
Each protocol module in the FactoryLink 6.6.0 device interface base set supports
triggered read operations and write operations. Selected protocol modules support
unsolicited read operations. Refer to Table 1-2 on page 38 for protocol-specific read
and write information.
FactoryLink requests
data from a device.
Write Operations
1
In a write operation, data is retrieved from the real-time database and transferred
to a device. FactoryLink reads the values of real-time database elements, then
writes them to specific locations in a device.
External Device
Figure 1-26 Write Operation
Interface
FactoryLink reads
database elements
and sends their
values to a device.
Two types of EDI write operations can occur: block and exception.
• Block Write—In a block write request, a change in the value of a trigger element
prompts FactoryLink to write one or more database element values to specific
device locations.
• Exception Write—In an exception write request, a change in the value of an
element prompts FactoryLink to write that value to a specific device location.
The difference in these two operations is the way each is triggered. Both
operations write data from FactoryLink to the device when a trigger is activated.
For a block write, the trigger is an element defined specifically for prompting a
write operation. For an exception write, the trigger is the change in status of the
element to be written.
Read
Operations Write
Protocol Module
Operations
Triggered Unsolicited
Allen-Bradley ✔ ✔ ✔
Modicon Modbus™ ✔ ✔
Siemens CP525® ✔ ✔ ✔
Siemens Sinec H1 ✔ ✔ ✔
Square D ✔ ✔ ✔
Texas Instruments™
✔ ✔
TIWAY/Point-to-Point
External Device
is a FactoryLink tag name assigned to a group of elements.
Interface
See FactoryLink ECS Fundamentals for more information about working with
FactoryLink tags.
Read and write operations use a limited area of the computer’s system memory
shared by a protocol module and the EDI module. If your configuration includes
more than one protocol module, a separate area of shared memory is associated
with each module.
Figure 1-27 and subsequent diagrams in this section depict shared memory as a
mailbox. Mail can go into and be retrieved from a mailbox. In the same way,
outgoing messages from EDI and incoming responses from a device are filtered
through shared memory.
Figure 1-27 Shared Memory with Each Protocol Module
External Device
• Because the capacity of a shared memory area is limited (like a mailbox), when
Interface
the memory fills up, nothing more can be added to it. A shared memory area
fills up when the protocol module does not process data as fast as EDI requests
it, or when the protocol module sends requested data to EDI faster than EDI
can process it.
This discussion focuses on how the filling up of shared memory affects triggering
rates in your application. When you understand how shared memory works, you
can apply this knowledge and use work-around triggering schemes (these are
described later on) that result in an efficiently operating application.
ó
ì
If the operation is not successful, the device returns an error message. If the
device does not respond, the protocol module will indicate a time-out error.
External Device
Interface
The protocol module matches the incoming data to the command and puts the
requested data, acknowledgment, or error message into shared memory.
Figure 1-32 Protocol Module Puts Data into Shared Memory
When EDI finds a response to the data transfer command in shared memory, it
retrieves the data, writes it to the real-time database, then clears the device’s
response from memory.
Figure 1-33 EDI Gets Data, Writes It to FactoryLink, Clears Data and Command
C ONFIGURATION C ONSIDERATIONS
1
Following are guidelines and examples to help you determine which types of read
and write operations work best for specific situations and how to configure these
operations to optimize FactoryLink’s performance.
External Device
Interface
Triggered Read Operations
A triggered read operation is the best choice for reading data that changes
frequently and at regular intervals. Use the following types of triggered read
operations under the described circumstances.
Interval If an application does not require all data to be collected at the
same time, you can increase FactoryLink’s efficiency by
configuring several read tables, each reading at a different
interval and only as often as necessary. For example, configure a
table with timed reads that occur every five seconds for elements
with values that change frequently, and every thirty seconds for
elements with values that change less frequently.
Event If events occur infrequently, you can reduce the number of
requests sent between FactoryLink and the device and increase
overall efficiency by configuring several read tables, each
triggered by a different event. For example, If a graphic screen
contains a large number of variables that are only useful on that
screen (that is, they are not alarm points and are not being
trended), you could configure a separate read table containing
only these variables. FactoryLink will only read the elements on
that screen when the operator triggers this read table by
selecting the graphic screen for viewing. Using this technique can
reduce traffic between FactoryLink and the device when an
application has a large number of graphic screens.
As another example of an event-driven read operation, you could
configure FactoryLink to trigger a particular read table only if an
alarm condition occurs. The element that detects the alarm
condition can trigger EDI to collect additional information from
the device about the status of related processes.
Write Operations
Use the following types of write operations under the described circumstances.
Block If an application writes values of real-time database elements
that change frequently to the device, use a block write operation
because FactoryLink sends the minimum number of write
commands necessary to write the specified data. A block write is
most efficient when your application writes a group of elements
at one time to the device (for example, when the application
requires a new recipe).
Exception If an application writes values of real-time database elements
that change infrequently to the device or if the application only
needs to change one value at a time (for example, a new
user-entered setpoint), use an exception write operation. For each
exception write, EDI sends one packet of data per tag. See the
discussion of data organization in “Optimization Guidelines” on
page 48 for more information about data packets.
Triggering Guidelines
1
With the discussion of read and write configuration considerations beginning on
page 45 in mind, consider the following triggering guidelines:
• Only Trigger When Data is Needed—How often you choose to trigger data to be
External Device
read or written depends on several factors, including how often the data
Interface
changes and whether the changes occur regularly, the timing of the events in
the application, and the types of reads and write operations the device supports.
• Only Trigger When on Specific Screens—Trigger data needed more often at
faster rates while slowing down other requests.
• Daisy Chain Tables—Link or daisy chain tables together in several loops by
defining elements in such a way that the completion of one task triggers the
beginning of another. The discussion of cascaded tables in “Efficient Triggering”
on page 172 provides additional details.
• Combine Unsolicited Read Operations—If each item in a list of data is being
read from a device as an unsolicited read operation, consider merging the data
into a block read request. You can then trigger the block read operation with an
unsolicited forced write of a digital element to the device. If each item on the list
is configured as an unsolicited read, a separate data packet is sent for each
item. If each list item is combined and put into a block read, however, fewer
data packets are required and the transmission time is quicker.
Note
Tip
For a discussion and examples of the differences in read and write table
processing, see “Processing Differences in Read and Write Operations” on page 1
166.
• Define Multiple Operations in a Single Table—Because the EDI task can process
multiple messages destined for a single device simultaneously, you can define
External Device
several read or write operations (within reason and based on the architecture of
Interface
the application) in a single table for maximum throughput. Each additional
table you define results in more messages the task must generate. The more
messages generated, the longer the read or write operation takes to complete.
• Keep Disabled Messages Together—Put entries that might need to be disabled
periodically in their own table, separate from entries that will not be disabled.
• Prioritize read and write operations—The priority of read and write operations
can affect the speed and performance of an application. EDI places each read
and write table you define into a user-specified priority queue. You can assign a
high priority to the most critical data to be read or written. EDI gives
preference to high priority read and write tables if it receives more than one
table at a time. For more information about how you can use priority queues to
improve an application’s performance, see “Specifying Priority” on page 171.
The reason for this failure is in most instances (unless a leased-line modem is
being used), handshaking signals need to be “tied back.” This can be effectively
done using a modem eliminator, also called a null modem cable, which contains
handshaking tie-backs.
•
•
•
•
Tag Definition Dialog
2
External Device
Interface
Read and write operations for each device protocol module except the General
Purpose Interface (GPI) can be configured using the Tag Definition dialog in the
Application Editor.
In all EDI drivers there is a 255 character limit on the length of message tags. If
any message tags are defined larger than 255, the excess data is truncated.
•
•
•
•
Setting Operating
System Parameters 3
External Device
Interface
This chapter contains information for setting up the Windows NT Ethernet
operating system environment for FactoryLink communications.
W INDOWS NT E THERNET
Setting up a Windows NT Ethernet environment for FactoryLink EDI
communications involves adding the DLC Protocol to the network.
Click on Add Software in the Network Software and Adapter Cards box in the
Network Settings window.
Choose DLC Protocol from the list of options in the Add Network Software window
and click on Continue.
Enter the full path name in the Windows NT Setup window identifying the
location of the DLC Protocol files. Windows NT loads the software and then
redisplays the Network Settings window.
Open the Network Settings window again (steps and above) after Windows NT
reboots.
•
•
•
•
Setting Up Serial
Communications 4
External Device
Interface
This chapter contains reference information to help you set up serial system unit
COM port communications between FactoryLink and your devices.
• “Electrical Interface Signals” on page 56 contains a table describing general
information about the electrical modem interface control signals the device
interface hardware and software configuration uses to establish and maintain
communication.
• “RS-232 Mechanical Interface Standard Reference” on page 57 describes RS-232
standard signal names and their corresponding pin settings for 25-pin and 9-pin
connectors.
• “Cable Description and Diagrams” on page 59 includes diagrams of two common
types of cabling scenarios used in device communications with FactoryLink.
Additional cable information, when available, is provided in the protocol-specific
reference chapters.
• “Worksheet for Cable Connections” on page 62 provides a worksheet and sample
pin-out diagrams designed to help you connect a device to a host computer’s
COM port.
• “Using ComWiz to Configure Ports” on page 64 provides information about the
different com port control signals and also gives you some hints on how to use
COMWiz.
Before proceeding to the table, know that data terminal equipment is a generic
term used to describe terminals, computers, and printers. In this discussion, DTE
refers to the FactoryLink computer. Data communications equipment provides all
the functions needed to establish, maintain, and terminate a connection. In this
discussion, DCE refers to the external device.
Signal Description
RTS Request to send. When the data terminal equipment (DTE) has
something to transmit, it sends an RTS to the data
communications equipment (DCE). For FactoryLink
communications with devices other than modems, RTS and CTS
must be tied together.
CTS Clear to send. CTS is a response to an RTS. After the DTE sends
the RTS to the DCE, the DCE returns a CTS to the DTE,
indicating the DTE device can begin transmitting. Before
FactoryLink can receive data from a device, the device must first
transmit a CTS signal to FactoryLink.
DSR Data set ready. When the DCE is powered on, it sends this signal
to the DTE to indicate it is ready to transmit.
DTR Data terminal ready. When the DTE is powered on, it sends this
signal to the DCE. If the port is open, this signal remains set
high.
External Device
referenced signal names.
Interface
Table 4-2 DB-25 Pin Reference for RS-232 Standard
7 Signal Ground SG
8 Carrier Detect CD
1 2 3 4 5 6 7 8 9 10 11 12 13
14 15 16 17 18 19 20 21 22 23 24 25
5 Signal Ground SG
1 2 3 4 5
6 7 8 9
External Device
device connectors. DSR, CD, and DTR must also be tied back to both connectors.
Interface
Figure 4-3 illustrates a current (pre 6.6.0) RS-232 cable connection. Because
handshaking signals are tied back, this cable does not rely on the device for proper
signal manipulation.
Figure 4-3 RS-232 Cable to Device
TxD TxD
RxD RxD
SG SG
RTS RTS
CTS CTS
Device-Dependent
DSR DSR Signals
CD CD
DTR DTR
Using COMWiz the port can be configured to not need handshaking signals,
allowing the use of a standard null modem cable as shown in Figure 4-4 or a
minimum 3-wire cable as shown in Figure 4-4, if the external device supports it.
DSR DSR
CD CD
DTR DTR
TxD TxD
RxD RxD
SG SG
RTS RTS
CTS CTS
Device-Dependent
DSR DSR Signals
CD CD
DTR DTR
External Device
Interface
FactoryLink Port Device
Shield
TxD+ TxD+
TxD- TxD-
RxD+ RxD+
RxD- RxD-
COM COM
Figure 4-7 illustrates an RS-485 two wire cable connection between the
FactoryLink computer’s serial port and a device. The RS-485 is an electrical
rather than a mechanical interface standard and specifies no pin assignments.
TxD+ +
TxD- -
RxD+
RxD-
COM COM
___ SG SG ___
Note
Note the number of pins on the cable connectors for the FactoryLink station port
and the device port. Record this information in the blanks next to FactoryLink Port
and Device Port at the top of the worksheet. For example, write 25-pin next to
FactoryLink Port and 9-pin next to Device Port.
Record the pin numbers corresponding to the cable on the FactoryLink side of the
configuration in the blanks next to the appropriate signals on the worksheet. For 4
example, write 2 in the first row of the first Pin column to indicate the
FactoryLink TXD is 2.
External Device
Enter the pin numbers corresponding to the cable on the device side of the
configuration in the blanks next to the appropriate signals. For example, write 2
Interface
in first row of the second Pin column to indicate the device RxD is 2.
Any changes that you make while using COMWiz are stored in your application
(FLAPP) and are saved with this application. When your saved application file is
restored, the serial options that you selected are restored with it. If at anytime
during the configuration you want to change the settings back to default, click the
Standard button on the COMPort Extended Setup and the settings for the
standard cable will be restored.
Note
The extended com setup dialog will be invoked from FLCM - Main Menu.
External Device
Interface
Choices for Handshaking
Table 4-5 lists each COMWiz parameter, its value(s), and describes how the
parameter works. 4
Table 4-5 COMWiz Parameters
External Device
Parameter Values Description
Interface
cts_out On Specifies whether the clear-to-send (CTS) signal
Off is monitored for output flow control. If this
member is TRUE and CTS is turned off, the
output is suspended until CTS is re-resent.
dtr_control None Disables the DTR line when the device is opened
and leaves it disabled.
rts_control None Disables the RTS line when the device is opened
and leaves it disabled.
•
•
•
•
Configuring Communication
Paths 5
External Device
Interface
Once each device is connected properly and communicating with the computer running
FactoryLink, you are ready to establish the paths (or routes) over which FactoryLink will
communicate with the devices.
This chapter describes how to establish these communication paths by configuring two tables:
External Device Definition and Logical Station.
• On the External Device Definition table, you identify your device to the FactoryLink system
and define each logical port in your configuration. For a description of the steps involved in
filling out the External Device Definition table, see “Identifying Protocol Types and
Defining Logical Ports” on page 70.
• On the protocol-specific Logical Station table, you define the paths to be used for
communications between the devices and FactoryLink. For a description of the steps
involved in filling out the Logical Station table, see “Creating Logical Station Definitions”
on page 77.
If your FactoryLink application will communicate with devices via several different ports,
complete the Logical Station Worksheet. Refer to “Completing the Logical Station Worksheet”
on page 71 for details.
Note
This worksheet can be used with any protocol module in the FactoryLink
6.6.0 base set. It can be especially helpful, however, in documenting
numbering schemes for hardware configurations that not only include
multiple ports but that also use one or more network interface modules to
route communications to devices across a proprietary network.
Allen-Bradley and Square D are examples of protocol modules that provide
this type of support. A sample worksheet is provided on page 72 in which the
Allen-Bradley protocol module is used as an example.
Create the logical port definitions for each physical port. Refer to “Creating the Logical Port
Definitions” on page 73 for details.
External Device
Logical Station tables. A sample worksheet is provided on page 72.
Interface
Table 5-1 Logical Station Worksheet
1 PLC-3 2
For the corresponding External Device Definition and Logical Station table entries, see “Table
Entries for Sample Worksheet” on page 87.
External Device
Ensure the current domain selection is SHARED in the Configuration Manager Domain
Selection box.
Interface
Choose External Device Definition from the Main Menu. The External Device Definition
panel is displayed.
Using the field descriptions provided below, complete a row in the panel for each port to which
a device in the configuration is connected. Sample entries are provided in “Sample External
Device Definition Table Entries” on page 75.
Logical Port Enter a unique number to logically represent each port to which a device is
connected.
Valid Entry: 0 - 999
Physical Port For each logical port number, enter a number referencing the physical port
to which the device is connected.
Serial Ports—For each logical port, enter the number matching the
physical port to which the device is connected. Be sure to enter an
appropriate number for your hardware configuration. If the system unit
does not contain an expansion card, not all valid port number entries can be
used.
Function For each logical port, identify the type of communications. For the protocol
modules in the FactoryLink 6.6.0 base set, specify SYSCOM for serial 5
communications (including DigiBoard) or ETHERNET for Ethernet
communications if supported for the protocol module (see page 30).
External Device
Valid Entry: Ctrl+K
Comment Optionally, enter descriptive information about this logical port.
Interface
Valid Entry: alphanumeric string of up to 14 characters
When each logical port has been defined, click on Enter to validate the information. Next,
click on Exit to return to the Main Menu.
Create logical station definitions for each logical port. These define the paths to be used for
communications between each device and FactoryLink. For details, see “Creating Logical
Station Definitions” on page 77.
FactoryLink
COM
Computer
Port
COM
Port
Logical Port 1
First
DigiBoard
Second
DigiBoard
Logical Port 4
FactoryLink
Computer
Logical Port 3
Logical Port 2 Logical Port 8
Logical Port 7
Logical Port 1
Logical Port 6
Logical Port 5
This sample panel configures two
DigiBoards with devices connected to four
ports on each board. Logical port 1
identifies the first port on the first board.
Logical ports 2, 3, and 4 identify the
second, third, and fourth ports on the first
board. Logical port 5 identifies the first port
on the second board. Logical ports 6, 7,
and 8 identify the second, third, and fourth
ports on the second board. One instance of
the Allen-Bradley protocol is configured for
each port, meaning eight instances of
Allen-Bradley are configured.
External Device
between the devices and the interface software.
Interface
The logical station definitions identify sources and destinations for the read and write requests
you will configure later in read and write tables, and can include FactoryLink real-time
database elements to which system messages from the EDI task and the device protocol
module will be written.
The Logical Station table, where you create these definitions, consists of two panels, Logical
Station Control and Logical Station Information. These panels are part of the cascading group
of protocol-specific panels displayed from the Main Menu when you choose the option for the
protocol module you are configuring.
The following steps describe how to create logical station definitions for each logical port that
communicates with a device.
Note
Ensure the current domain selection is SHARED in the Configuration Manager Domain
Selection box.
Choose the option for the protocol module you are configuring from the Main Menu. A
cascaded view of all the configuration panels for that module is displayed.
Display the Logical Station Control panel by clicking on its title bar in the display of all panels.
On the Logical Station Control panel, you define pertinent information about each
communication path to a device so FactoryLink can establish communications with all the
devices. This information varies from one protocol module to another.
In general, however, a definition for a communication path can include (but is not limited to)
the following information:
• The logical port number, to create the association with the External Device Definition table
Refer to your completed logical station worksheet to help you identify logical ports and
associate them with logical stations. See “Completing the Logical Station Worksheet” on page
71 for details.
Table 5-3 lists references to instructions for creating the logical station definitions for each
protocol-specific module in the base set. To create the definitions for the protocol module your
devices will communicate with, go to the specified page in the appropriate reference.
Note
Before going to the section describing the Logical Station panel entries for
the protocol module you are configuring, you may want to first review the
procedure for creating logical station definitions for Modbus Plus in
“Modicon Modbus Plus Logical Station Table” on page 80. The information
in the sections describing the panel entries for the other protocol modules is
presented in a reference format and will not necessarily show the associations
and results of the entries as the information in this section does.
External Device
page 196
Interface
General ElectricFanuc “Configuring the Logical Station Control Panel” on
page 238
Modicon Modbus Plus™ “Modicon Modbus Plus Logical Station Table” on page
80
OMRON™ Host Link Protocol “Configuring the Logical Station Control Panel” on
page 390
Texas Instruments™ Before completing the Logical Station table, you must
TIWAY/Point-to-Point complete the Unilink Setup table. For details, see
“Configuring the Unilink Setup Table” on page 530.
Once the Unilink Setup table is completed, refer to
“Configuring the Logical Station Control Panel” on
page 534.
When the Logical Station Control panel is complete, click on Enter to validate the data.
The Tag Definition dialog is displayed for each specified tag name that is not defined
elsewhere in FactoryLink. For each tag name, choose the type of data to be stored in the
element for Type and accept the default of SHARED for Domain. Refer to the tag’s field
description for the valid data types.
Complete a row in the panel for each device to communicate through this logical port.
The Tag Definition dialog is displayed for each specified tag name that is not defined
elsewhere in FactoryLink. For each tag name, choose the type of data to be stored in the
element for Type and accept the default of SHARED for Domain. Refer to the tag’s field
description for the valid data types.
To configure another logical port, click on Prev to return to the Logical Station Control panel
and repeat the steps beginning with step 5.
When you are ready to define the read and write operations expected to occur between this
logical port and the associated Modbus Plus devices configured as logical stations, refer to the
appropriate chapter: Chapter 6, “Reading Data from a Device,” or Chapter 7, “Writing Data to
a Device.”
Using the following field descriptions, complete a row in the Logical Station Control panel for
each logical port defined in the External Device Definition table you want to include in the
communication path. Sample entries are provided in “Sample Logical Station Table Entries”
on page 85.
Logical Port Enter a number, defined in the External Device Definition table Logical
Port field, to represent a particular communication path to a Modbus Plus 5
device.
Valid Entry: previously defined logical port number
External Device
Interface
The External Device Definition panel
logical port definition identifies the
port to EDI as a designated Modbus
Plus port.
Adapter Number Enter either 0 or 1 to logically represent the SA85 host adapter. The default
is 0.
In a Windows environment, the Adapter Number entry must match the /n
parameter of the line for the SA85 device assignment (MBHOST.SYS for
Windows) in the CONFIG.SYS file.
Valid Entry: 0, 1
LPORT Status Optionally, enter a tag name for a message element to which a text string
Message Tag will be written to indicate a communications error associated with this
logical port.
Valid Entry: standard element tag name
Valid Data Type: message
Data Master Paths Enter a number from 1 to 8 to represent the number of communications
channels to be used for command/response transactions between the SA85
card and the Modbus Plus device this logical port represents. Be sure the
number of master paths you define does not conflict with paths defined for
other software (such as the device programming software) using the card.
When the Logical Station Control panel is complete, click on Enter to validate the data.
The Tag Definition dialog is displayed for each specified tag name that is not defined
elsewhere in FactoryLink. For each tag name, choose MESSAGE for Type and accept the
default of SHARED for Domain.
Select the row for the logical port you are configuring. Click on Next to display the Logical
Station Information panel.
The logical port number is displayed in the Logical Port field on the lower left side of the
panel. 5
On the Logical Station Information panel, you define the following information:
• Long analog elements to which error codes for particular devices (logical stations) will be
External Device
written
Interface
• For each logical port, logical station numbers that identify the device address, network
router address, and the device type for each device in the configuration
• The number of consecutive times FactoryLink will send a read or write command to a
logical station after an unsuccessful transmission attempt, the amount of time FactoryLink
will wait before retrying a transmission attempt, and tag names for elements reporting the
success or failure of these attempts
Using the following field descriptions, complete a row in the panel for each device to
communicate through this logical port.
LSTA Status Optionally, enter a tag name for an analog element to receive
Analog Tag communication error codes associated with this device (logical station).
Valid Entry: standard element tag name
Valid Data Type: analog
Logical Station Enter a number to identify the logical station to which the information in
(Decimal) this row pertains. A logical station represents the combination of a logical
port with a physical station. Assign a unique number to each device
communicating through this logical port. This number must be unique
among all Modicon devices across all ports.
You will later enter this logical station number in a read or write table to
represent the device defined in this row. In a read or write table, this number
will identify the device to or from which data is to be sent or received.
Valid Entry: unique numeric value from 0 - 999 (default = 0)
PLC Type Define the type of Modbus Plus device to which communications are to be
directed: 984 or 984BITWRITE for devices that support the mask write
function (A120, A130, A141, A145, 685E, 785E, AT4, and VM4).
Valid Entry: Ctrl+K (default = 984)
Physical Station Enter the physical address of the Modbus Plus device. This address must
match the configured address of the equipment.
Valid Entry: numeric value from 0 - 64 (default = 0)
Router1... Router4 Define the Modbus Plus network address of each router or bridge to a
logical station. Up to four routers can be defined for each physical station.
Valid Entry: numeric value from 0 - 64 (default = 0)
The Tag Definition dialog is displayed for each specified tag name that is not defined
elsewhere in FactoryLink. For each tag name, choose the type of data to be stored in the
element for Type and accept the default of SHARED for Domain. Refer to the tag’s field
description for the valid data types. 5
To configure another logical port, click on Prev to return to the Logical Station Control panel
and repeat these steps beginning with step on page 80.
External Device
When you are ready to define the read and write operations expected to occur between this
Interface
logical port and the associated Modbus Plus devices configured as logical stations, refer to the
appropriate chapter: Chapter 6, “Reading Data from a Device,” or Chapter 7, “Writing Data to
a Device.”
Continued
Continued
In this example, logical port 0 of the SA85 card configured as 0 in the CONFIG.SYS file has
six allocated data master paths over which command/response transactions for read and write
operations can travel. Four data slave paths are available for transmission of unsolicited data
from any device communicating with FactoryLink through this logical port (in this instance,
logical station 0 defined on the Logical Station Information panel). Additionally, the EDI task
will store communications error messages associated with this logical port in a message
element, MODP_LPORT0_MSG.
Continued
Continued Continued
Continued
External Device
Figure 5-4 Table Entries Corresponding to Sample Logical Station Worksheet
First, you assign a logical
Interface
port number to each
physical port in the External
Device Definition table.
•
•
•
•
Reading Data from a
Device 6
External Device
Interface
After setting up the communication paths in the External Device Definition and
Logical Station configuration tables, the next step is to define information about
the data to be read from and written to the devices.
This chapter describes how to define a request to read locations in a device and
store the information read in FactoryLink database elements. See Chapter 7,
“Writing Data to a Device,” for procedures describing how to define a request to
write the values of FactoryLink database elements to locations in a device.
To define a read request, you configure the Read/Write table which consists of two
panels: Read/Write Control and Read/Write Information. Like the Logical Station
panels, the Read/Write panels are part of the cascading protocol-specific panels
displayed when you choose the option for the protocol module you are configuring
from the Configuration Manager Main Menu.
Note
When filling out a read request, you specify in which elements the device data
read during the operation will be stored. For each element, you specify:
• The tag name assigned to the FactoryLink database elements storing the data
• The logical station from which the data will be read
• The register address in that logical station containing the data to be read
Depending on the protocol module used, you can configure two types of read
requests, triggered and unsolicited, or a combination of these. Refer to Table 1-2
on page 38 for supported read functions.
FactoryLink reads the values read then stores them in real-time database
elements for which you specify tag names in the Read/Write Information panel.
Figure 6-1 How a Triggered Read Operation Works
When the block
read trigger is
forced on,...
External Device
addresses from which data is expected and the type of data expected.
Interface
When FactoryLink receives data from the device that matches this criteria, the
data is stored in real-time database elements for which you specify tag names in
the Read/Write Information panel.
Figure 6-2 How an Unsolicited Read Operation Works
If the Logical Station Information panel is currently displayed, click on Next and
go to step . If another protocol-specific panel is currently displayed, go to step .
Choose the protocol module name from the Main Menu. A cascaded view of all the
protocol-specific configuration panels is displayed.
Figure 6-3 Protocol-Specific Configuration Dialog Boxes
To make Read/
Write Control the
active panel, click
on its title bar.
External Device
Interface
For each read request you want transmitted over a device communication path,
add a panel entry. The information you provide depends on the type of request you
are defining.
Refer to the appropriate section for the type of read request you are defining:
• “Triggered Read Request” below
• “Unsolicited Read Request” on page 96
• “Combination Read Request” on page 97
Using the following field descriptions, add a panel entry for each triggered read
request you want to define. Leave all other fields blank. Sample entries are
provided in “Sample Triggered Read Request” on page 118.
Table Name Give this read request a name. Define one request (table) per line
and do not include spaces in the name. You can define as many
requests in this panel as available memory allows. Try to make
the table name reflective of the operation it represents.
When the Block Read Trigger element defined for this table is
forced to 1, or on, the element prompts FactoryLink to process
this read table and any other read table with a Table Name entry
associated with the same trigger.
Valid Entry: alphanumeric string of up to 16 characters
Block Read Optionally, enter a tag name for a digital element to disable a
Disable block read of the elements specified in this table. When this tag’s 6
value is forced to 1 (ON), the read operation is not executed, even
when the block read trigger is set.
This element can be used to disable a block read operation that is
External Device
either part of a cascaded loop or is self-triggered. The triggering
Interface
cycle will cease upon disabling, however. To re-enable a cascaded
loop or a self-triggered read table, the Block Read Trigger element
must be toggled or forced to 1. Refer to Chapter 8, “Application
Design Tips and Techniques,” for further details.
Valid Entry: standard element tag name
Valid Data Type: digital
Note: If you are defining a Block Read Complete or Block Read State element to be
used for more than one logical port, create a separate table for each port.
Block Read Optionally, enter a tag name for a digital element the EDI task
Complete forces to 1 (ON), when it starts up, and each time it receives and
processes a read request from a device protocol module. After the
elements defined in the associated Read/Write Information panel
have been updated in the FactoryLink database, EDI forces the
element to 1 again.
Valid Entry: standard element tag name
Valid Data Type: digital
Block Read State Optionally, enter a tag name for a digital element the EDI task
forces to 1 (ON), when it starts up, and each time it receives and
processes a read request from a device protocol module. During
EDI's transmission of the request, it sets the element to 0 (OFF).
After the elements defined in the associated Read/Write
Information panel have been updated in the FactoryLink
database, EDI forces the element back to 1.
Valid Entry: standard element tag name
Valid Data Type: digital
When you have finished filling out the information on this panel, click on Enter.
The Tag Definition dialog is displayed for each specified tag name that is not
defined elsewhere in FactoryLink. For each tag name, choose DIGITAL for Type
and accept the default of SHARED for Domain.
Define the data to be read and the target addresses in the Read/Write Information
panel. Refer to “Specifying What to Read and Where to Store It” on page 98.
Using the following field descriptions, add a panel entry for each unsolicited read
request you want to define. Leave all other fields blank. Sample entries are
provided in “Sample Unsolicited Read Request” on page 121.
Table Name Give this read request a name. Define one request (table) per line
and do not include spaces in the name. You can define as many
requests in this panel as available memory allows. Try to make
the table name reflective of the operation it represents.
Valid Entry: alphanumeric string of up to 16 characters
Unsolicited Read Enter YES. EDI will interpret this operation as an unsolicited
read and emulate the device’s addressing structure based on
entries you make in the Read/Write Information panel.
The data is written to the element specified in the Read/Write
Information panel. The change-status indicator is set only if the
element’s value has changed since the most recent write to the
element. If the current value of the element is equal to the value
being written, the change-status indicator is unaffected. If,
however, the value being written to the element is a new value, it
will overwrite the existing value and the element’s change-status
indicator will be set to 1 (ON).
Valid Entry: yes
Exception Write Accept the default of NO, which indicates this is not an exception
write.
Valid Entry: no
Block Read Accept the default of 1. This field is ignored for unsolicited read
Priority operations.
Valid Entry: 1
When you have finished filling out the information on this panel, click on Enter.
Define the data to be read and the target addresses in the Read/Write Information
panel. Refer to “Specifying What to Read and Where to Store It” on page 98 for
details.
External Device
For example, you could configure a combination triggered block read and
unsolicited read table if you want to read a register and write its value to an
Interface
element upon start up and thereafter, only update that element when the register
value changes.
Fill out a control panel with the information described in “Triggered Read
Request” on page 93, but enter YES in the Unsolicited Read field instead of NO.
When you have finished filling out the information on this panel, click on Enter.
Define the data to be read and the target addresses in the Read/Write Information
panel. Refer to “Specifying What to Read and Where to Store It” on page 98 for
details.
Each address that will be read from a memory location in a device is represented
by a separate tag name for an element in the FactoryLink database. For a read
request, you add an entry in the Read/Write Information panel for each element to
which data will be written when the operation is executed.
The following steps describe how to fill out the Read/Write Information panel.
On the Read/Write Control panel, select the row for the read request you are
defining. Click on Next to display the Read/Write Information panel.
The table name is displayed in the Table Name field on the lower left side of the
panel.
The information you provide in this panel depends on the type of register to be
accessed and the type of data to be read. Refer to the data type reference table on 6
page 100 to determine where to go for instructions on filling out this panel for
your particular application.
External Device
Each section listed in the table provides sample panel entries for a specific type of
read request. Additional sample entries are provided in “Sample Read Requests”
Interface
on page 118.
When you have finished defining all the register addresses to be read and all the
FactoryLink database tags to which the data is to be written, click on Enter to
validate the data.
The Tag Definition dialog is displayed for each specified tag name that is not
defined elsewhere in FactoryLink. For each tag name, choose the type of data to
be stored in the element for Type and accept the default of SHARED for Domain.
Refer to the tag’s field description for the valid data types.
When all read requests are complete, either click on Exit to return to the Main
Menu or click on Prev to return to the Read/Write Control panel and define the
write requests required for your application. Refer to Chapter 7, “Writing Data to
a Device,” for details.
A read table should not contain more than the maximum number of contiguous
registers allowed for a single message accessing a type of register. The maximum 6
number allowed varies from one register type to the next.
If more than the maximum number of contiguous register addresses are defined,
External Device
multiple messages are generated for the operation. For example, if a block read
table for a holding register in a 984 device contains entries that access contiguous
Interface
addresses from 100 to 127, two messages are generated. The first message reads
the first 125 addresses (addresses 100 to 124). The second message reads
addresses 125 through 127.
The following table lists the maximum number of contiguous registers included in
a single block read message for each supported register type.
Coil 2000
Holding 125
Input 125
Memory 100
Using the following field descriptions, add a panel entry for each element in which
data read from the device will be stored when the operation executes.
Tag Name Specify a tag name for an analog element in which FactoryLink
will store the data read from the device.
Valid Entry: standard element tag name
Valid Data Type: analog
Logical Station Enter the number representing the device from which the data is
to be read. This number was originally defined in the Logical
Station Information panel for the logical port through which
communications with this device occurs.
Valid Entry: previously defined logical station number
External Device
Interface
...the Logical Station number
defined on the Logical Station
Information panel...
Reg. Address Enter the register address in the device’s memory where the
value to be stored in this element is located.
Do not include the register address prefix (4 for holding and 3 for
input) or leading zeros. The prefix indicates the register type,
which is specified in the Data Type field. For example, for holding
register address 400001, just enter 1; for input register address
345902, enter 45902.
Valid Entry: 1 - 65535
Bit Offset/ Accept the default of 1.
MSG Length
Valid Entry: 1
Data Type Specify the type of register to be read as HREG for holding register
or IREG for input register.
Valid Entry: HREG, IREG
Using the following field descriptions, add a panel entry for each element in which
data read from the device will be stored when the operation executes.
Tag Name Specify a tag name for a digital element in which FactoryLink
will store the data read from the device.
Valid Entry: standard element tag name
Valid Data Type: digital
Logical Station Enter the number representing the device from which the data is
to be read. This number was originally defined in the Logical
Station Information panel for the logical port through which
communications with this device occurs.
Valid Entry: previously defined logical station number
External Device
Interface
...the Logical Station number
defined on the Logical Station
Information panel...
Reg. Address Enter the register address in the device’s memory where the
value to be stored in this element is located.
Do not include the register address prefix (4 for holding and 3 for
input) or leading zeros. The prefix indicates the register type,
which is specified in the Data Type field. For example, for holding
register address 400001, just enter 1; for input register address
345902, enter 45902.
Valid Entry: 1 - 65535
Bit Offset/ Specify the bit offset within a register word that contains the
MSG Length value to be read. Bit 1 is the most significant bit (MSB) and bit 16
is the least significant bit (LSB).
MSB LSB
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
Valid Entry: 1 - 16
Data Type Specify the type of register to be read as HREG for holding register
or IREG for input register.
Valid Entry: HREG, IREG
Using the following field descriptions, add a panel entry for each element in which
data read from the device will be stored when the operation executes.
Tag Name Specify a tag name for a floating-point or long analog element in
which FactoryLink will store the data read from the device.
Valid Entry: standard element tag name
Valid Data Type: float, longana
Logical Station Enter the number representing the device from which the data is
to be read. This number was originally defined in the Logical
Station Information panel for the logical port through which
communications with this device occurs.
Valid Entry: previously defined logical station number
External Device
Interface
...the Logical Station number
defined on the Logical Station
Information panel...
Reg. Address Enter the register address in the device’s memory where the
value to be stored in this element is located.
Floating-point or long analog tag types are addressed in pairs.
The first register in the pair contains the high order word; the
second register contains the low order word. Enter the address for
only the starting register in a register pair. The companion
register is implied.
Try to maintain consistency when using register addresses for
floating-point and long analog tag types. Adopt either an odd or
even starting register sequence and maintain that sequence. For
example, 1, 3, 5, 7, 9,... or 2, 4, 6, 8, 10,....
Do not include the register address prefix (4) or leading zeros.
The prefix indicates the register type, which is specified in the
Data Type field. For example, for holding register address 400001,
just enter 1.
Valid Entry: 1 - 65535
Bit Offset/ Accept the default of 1.
MSG Length
Valid Entry: 1
Data Type Specify HREG as the type of register to be read.
Valid Entry: HREG
Using the following field descriptions, add a panel entry for each element in which
data read from the device will be stored when the operation executes.
Tag Name Specify a tag name for a message element in which FactoryLink
will store the data read from the device.
Valid Entry: standard element tag name
Valid Data Type: message
Logical Station Enter the number representing the device from which the data is
to be read. This number was originally defined in the Logical
Station Information panel for the logical port through which
communications with this device occurs.
Valid Entry: previously defined logical station number
External Device
Interface
...the Logical Station number
defined on the Logical Station
Information panel...
Reg. Address Enter the register address in the device’s memory where the
value to be stored in this element is located.
Enter the first address in the group of registers containing the
message characters. The number of registers to be read is defined in
the Bit Offset/MSG Length field of this panel.
Do not include the register address prefix (4) or leading zeros.
The prefix indicates the register type, which is specified in the
Data Type field. For example, for holding register address 400001,
just enter 1.
Valid Entry: 1 - 65535
Bit Offset/ Specify the number of bytes in the device’s memory containing
MSG Length the message. These bytes, starting from the location specified in
the previous field, Reg. Address, are read and the values are
stored in the Tag Name message element as raw binary data.
FactoryLink does not perform verification on these bytes to
ensure the data is printable ASCII.
Valid Entry: 1 - 80
Data Type Specify HREG as the type of register to be read.
Valid Entry: HREG
Using the following field descriptions, add a panel entry for each element in which
data read from the device will be stored when the operation executes.
Tag Name Specify a tag name for a digital element in which FactoryLink
will store the data read from the device.
Valid Entry: standard element tag name
Valid Data Type: digital
Logical Station Enter the number representing the device from which the data is
to be read. This number was originally defined in the Logical
Station Information panel for the logical port through which
communications with this device occurs.
Valid Entry: previously defined logical station number
External Device
Interface
...the Logical Station number
defined on the Logical Station
Information panel...
Reg. Address Enter the register address in the device’s memory where the
value to be stored in this element is located.
Do not include the register address prefix (0 for coil and 3 for
input status) or leading zeros. The prefix indicates the register
type, which is specified in the Data Type field. For example, for
coil address 023451, enter 23451; for input status register
address 300001, just enter 1.
Valid Entry: 1 - 65535
Bit Offset/ Accept the default of 1.
MSG Length
Valid Entry: 1
Data Type Specify the type of register to be read as COIL for coil register or
INP for input status register.
Valid Entry: COIL, INP
Using the following field descriptions, add a panel entry for each element in which
data read from the device will be stored when the operation executes.
Tag Name Specify a tag name for an analog element in which FactoryLink
will store the data read from the device.
Valid Entry: standard element tag name
Valid Data Type: analog
Logical Station Enter the number representing the device from which the data is
to be read. This number was originally defined in the Logical
Station Information panel for the logical port through which
communications with this device occurs.
Valid Entry: previously defined logical station number
External Device
Interface
...the Logical Station number
defined on the Logical Station
Information panel...
Reg. Address Enter the register address in the device’s memory where the
value to be stored in this element is located.
Do not include the register address prefix (6) or leading zeros.
The prefix indicates the register type, which is specified in the
Data Type field. For example, for memory address 600001, just
enter 1.
Valid Entry: 1 - 65535
Bit Offset/ Accept the default of 1.
MSG Length
Valid Entry: 1
Data Type Specify the type of register to be read as XMEMnn where nn is a
numeric value from 1 to 10.
Valid Entry: XMEM1 - XMEM10
Note
Reference the high and low bytes of a statistics word in one block read
table to ensure the information retrieved for a single word is
synchronized. To access the high and low bytes of a single word,
enter the same register address twice for two separate analog tags.
Specify STATHI in the Data Type field for the first tag and STATLO
for the second tag. To create a single word value, use FactoryLink
Math & Logic to “OR” the words together.
Using the following field descriptions, add a panel entry for each element in which
data read from the device will be stored when the operation executes.
Tag Name Specify a tag name for an analog element in which FactoryLink
will store the data read from the device.
Valid Entry: standard element tag name
Valid Data Type: analog
Logical Station Enter the number representing the device from which the data is
to be read. This number was originally defined in the Logical 6
Station Information panel for the logical port through which
communications with this device occurs.
Valid Entry: previously defined logical station number
External Device
Interface
The Logical Station number
defined on the Read/Write
Information panel must match...
Reg. Address Enter the register address in the device’s memory where the
value to be stored in this element is located.
Valid Entry: 1 - 65535
Bit Offset/ Accept the default of 1.
MSG Length
Valid Entry: 1
Data Type Specify STATHI to access a high byte of a statistics word and
STATLO to access a low byte. Refer to the IBM Host Devices
User’s Guide for Modbus Plus network based statistics word
assignments.
Valid Entry: STATHI, STATLO
Using the following field descriptions, add a panel entry for each element in which
data read from the device will be stored when the operation executes.
Tag Name Specify a tag name for an analog element in which FactoryLink
will store the data read from the device.
Valid Entry: standard element tag name
Valid Data Type: analog
Logical Station Enter the number representing the device from which the data is
to be read. This number was originally defined in the Logical
Station Information panel for the logical port through which
communications with this device occurs.
Valid Entry: previously defined logical station number
6
The Logical Station number
defined on the Read/Write
Information panel must match...
External Device
Interface
...the Logical Station number
defined on the Logical Station
Information panel...
Reg. Address Enter the register address in the device’s memory where the
value to be stored in this element is located.
The first global data word received is always assumed to be word 1,
the second is word 2, and so on. If you specify a register address
larger than the total number of global data words that will actually be
received, an error is generated.
Valid Entry: 1 - 32
Bit Offset/ Accept the default of 1.
MSG Length
Valid Entry: 1
Data Type Specify GLBL to access a global data word.
Valid Entry: GLBL
Continued
Continued
READ is
discussed in
this example.
External Device
forces a value of 1 to the digital Block Read State element,
Interface
MODP_READ_STATE, and to the Block Read Complete element,
MODP_READ_COMPLETE. During the read operation, MODP_READ_STATE
is set to 0.
External Device
Figure 6-7 Sample Read/Write Control Panel for Unsolicited Read
Interface
Continued
Continued
UNSOL_READ is
discussed in
this example.
In this example, FactoryLink reads the incoming data upon its arrival then stores
it in a message element, HOLD_MSG1.
Figure 6-9 How This Unsolicited Read Request Works
•
•
•
•
Writing Data to a
Device 7
External Device
Interface
This chapter describes how to define a request to write the values of FactoryLink
database elements to specified locations in a device. See Chapter 6, “Reading Data
from a Device,” for procedures describing how to define a request to read specified
locations in a device and store the values read in FactoryLink database elements.
To define a write request, you configure the Read/Write table which consists of two
panels: Read/Write Control and Read/Write Information. Like the Logical Station
panels, the Read/Write panels are part of the cascading protocol-specific panels
displayed when you choose the option for the protocol module you are configuring
from the Configuration Manager Main Menu.
Note
When filling out a write request, you specify the following basic information:
• The tag name assigned to the FactoryLink database element containing the
data to be written
• The logical station to which the data will be written
• The register address in that logical station to which the data will be written
FactoryLink can write data to a device in two ways: as a block write when
prompted by a digital trigger element, or as an exception write when prompted by
the data changing.
Continued
Continued
External Device
and re-enable an exception write table and a trigger element to update the
equipment once the table is re-enabled. Each defined exception write results in a
Interface
separate write command.
Figure 7-2 How an Exception Write Operation Works
Continued
Continued
If the Logical Station Information panel is currently displayed, click on Next and
go to step 5. If another panel is currently displayed, go to step 4.
Choose the protocol module name from the Main Menu. A cascaded view of all the
protocol-specific configuration panels is displayed.
To make Read/
Write Control the
active panel, click
on its title bar.
External Device
Interface
For each write request you want transmitted over a device communication path,
add a panel entry. The information you provide depends on the type of request you
are defining.
Refer to the appropriate section for the type of write request you are defining:
• “Block write request” on page 127
• “Exception write request” on page 130
• “Combination write request” page 132
Using the following field descriptions, add a panel entry for each block write
request you want to define. Leave all other fields blank. Sample entries are
provided in “Sample Triggered Block Write Request” on page 153.
Table Name Give this write request a name. Define one request (table) per
line and do not include spaces in the name. You can define as
many requests in this panel as available memory allows. Try to
make the table name reflective of the operation it represents.
When the Block Write Trigger element defined for this table is
forced to 1, or on, the element prompts FactoryLink to process
this write table and any other write table with a Table Name entry
associated with the same trigger.
Valid Entry: alphanumeric string of up to 16 characters
External Device
Valid Data Type: digital
Block Write Optionally, enter a tag name for a digital element to disable a
Interface
Disable block write to the device addresses specified in this table. When
this tag’s value is forced to 1, the write operation is not executed,
even when the block write trigger is set.
This element can be used to disable a block write operation that is
either part of a cascaded loop or is self-triggered. The triggering
cycle will cease upon disabling, however. To re-enable a cascaded
loop or a self-triggered write table, the Block Write Trigger element
must be toggled or forced to 1. Refer to Chapter 8, “Application
Design Tips and Techniques,” for further details.
Valid Entry: standard element tag name
Valid Data Type: digital
Block Write Optionally, enter a tag name for a digital element the EDI task
Complete forces to 1 (ON), when it starts up, and each time it receives and
processes a write request from a protocol module. After the data
has been written to the device, EDI forces the element to 1 again.
If you are defining a Block Write Complete element to be used for
more than one logical port, create a separate table for each port.
Valid Entry: standard element tag name
Valid Data Type: digital
Block Write State Optionally, enter a tag name for a digital element the EDI task
forces to 1 (ON), when it starts up, and each time it receives and
processes a write request from a protocol module. During EDI's
transmission of the request, it sets the element to 0 (OFF). After
the data has been written to the device, EDI force-writes the
element back to 1.
If you are defining a Block Write State element to be used for more
than one logical port, create a separate table for each port.
Valid Entry: standard element tag name
Valid Data Type: digital
When you have finished filling out the information on this panel, click on Enter.
Define the data to be written and the target addresses in the Read/Write
Information panel. Refer to “Specifying What to Write and Where to Write It” on
page 133 for details.
To fill out a control panel for an exception write request, perform the following
steps.
Using the following field descriptions, add a panel entry for each exception write
request you want to define. Leave all other fields blank. Sample entries are
provided in “Sample Exception Write Request” on page 156.
Table Name Give this write request a name. Define one request (table) per
line and do not include spaces in the name. You can define as
many requests in this panel as available memory allows. Try to
make the table name reflective of the operation it represents.
When the values of the elements you define in the associated
Read/Write Information panel change, FactoryLink processes this
exception write table and any other exception write table with a
Table Name entry associated with the same elements.
Unsolicited Read To indicate this is not an unsolicited read, accept the default of
NO.
Valid Entry: no
Exception Write For the task to write element values only when those values
change, enter YES.
Valid Entry: yes
Block Write Priority Accept the default of 1. This field is ignored for exception write
operations. 7
Valid Entry: 1
External Device
Note
Interface
If you plan to periodically disable this table, both a Block Write
Trigger and a Block Write Disable element are required. Refer to the
following field descriptions. If you do not plan to disable this table,
do not define either of these elements.
Block Write Trigger Enter a tag name for a digital element to trigger the table once it
has been disabled then subsequently re-enabled by a Block Write
Disable element.
Valid Entry: standard element tag name
Valid Data Type: digital
Block Write Enter a tag name for a digital element to temporarily disable this
Disable table. When the value of this element is 1, it disables an exception
write of the defined elements to the device addresses specified in
the Read/Write Information panel. When the tag’s value is set to
0 again, the table is re-enabled.
Once a table has been re-enabled, a Block Write Trigger element
can be used to write any values that changed while the table was
disabled.
Valid Entry: standard element tag name
Valid Data Type: digital
When you have finished filling out the information on this panel, click on Enter.
The Tag Definition dialog is displayed for each specified tag name that is not
defined elsewhere in FactoryLink. For each tag name, choose DIGITAL for Type
and accept the default of SHARED for Domain.
Define the data to be written and the target addresses in the Read/Write
Information panel. Refer to “Specifying What to Write and Where to Write It” on
page 133 for details.
For example, you could configure a combination block write and exception write
table if you want to write the current value of an element to a register address in
the device upon start up and thereafter, only write the element’s value to the
device when it changes.
Fill out a control panel with the information described in“Block Write Request” on
page 127, but enter YES in the Exception Write field instead of NO.
When you have finished filling out the information on this panel, click on Enter.
Define the data to be written and the target addresses in the Read/Write
Information panel. Refer to “Specifying What to Write and Where to Write It” on
page 133 for details.
External Device
The data to be written is represented by one or more elements in the FactoryLink
Interface
database. For a write request, you add an entry in the Read/Write Information
panel for each element to be written when the operation is executed.
The following steps describe how to fill out the Read/Write Information panel.
On the Read/Write Control panel, select the row for the write request you are
defining. Click on Next to display the Read/Write Information panel.
The table name is displayed in the Table Name field on the lower left side of the
panel.
The information you provide in this panel depends on the type of register to be
accessed and the type of data to be written. Refer to the data type reference table
on page 135 to determine where to go for instructions on filling out this panel for
your particular application.
Each section listed in the table provides sample panel entries for a specific type of
write request. Additional sample entries are provided in “Sample Write Requests”
on page 153.
When you have finished defining all the FactoryLink database tags and the
register addresses to which their contents are to be written, click on Enter to
validate the data.
The Tag Definition dialog is displayed for each specified tag name that is not
defined elsewhere in FactoryLink. For each tag name, choose the type of data to
be stored in the element for Type and accept the default of SHARED for Domain.
Refer to the tag’s field description for the valid data types.
When all write requests are complete, click on Exit to return to the Main Menu.
External Device
Holding Analog “Write Analog Element Value to Holding
Register” on page 137
Interface
Digital “Write Digital Element Value to Holding
Register” on page 138
Note: For the maximum number of contiguous registers that can be included in
a single block write message for each supported register type, see Table 7-2 on
page 136.
A write table should not contain more than the maximum number of contiguous
registers allowed for a single message accessing a type of register. The maximum
number allowed varies from one register type to the next. If more than the
maximum number of contiguous register addresses are defined, multiple
messages are generated for the operation.
Coil 800
Holding 100
1 exception write for
mask operation
Memory 100
External Device
Using the following field descriptions, add a panel entry for each element to be
written and define the register addresses to receive each element value when the
Interface
operation executes.
Tag Name Specify a tag name for an analog element containing a value to be
written to the device.
Valid Entry: standard element tag name
Valid Data Type: analog
Logical Station Enter the number representing the device to which the element’s
value will be written. This number was originally defined in the
Logical Station Information panel for the logical port through
which communications with this device occurs.
Valid Entry: previously defined logical station number
Reg. Address Enter the register address in the device’s memory to which the
element value will be written.
Do not include the register address prefix (4) or leading zeros.
The prefix indicates the register type, which is specified in the
Data Type field. For example, for holding register address 400001,
just enter 1.
Valid Entry: 1 - 65535
Bit Offset/ Accept the default of 1.
MSG Length
Valid Entry: 1
Data Type Specify HREG as the type of register to which the element value
will be written.
Valid Entry: HREG
Using the following field descriptions, add a panel entry for each element to be
written and define the register addresses to receive each element value when the
operation executes.
When a digital tag is written to a holding register, two messages are sent to the
device. The first message reads the entire holding register; the second message 7
writes the new value to the specified bit.
External Device
Interface
Tag Name Specify a tag name for a digital element containing a value to be
written to the device.
Valid Entry: standard element tag name
Valid Data Type: digital
Logical Station Enter the number representing the device to which the element’s
value will be written. This number was originally defined in the
Logical Station Information panel for the logical port through
which communications with this device occurs.
Valid Entry: previously defined logical station number
Reg. Address Enter the register address in the device’s memory to which the
element value will be written.
Do not include the register address prefix (4) or leading zeros.
The prefix indicates the register type, which is specified in the
Data Type field. For example, for holding register address 400001,
just enter 1.
Valid Entry: 1 - 65535
Bit Offset/ Specify the bit offset within a register word to which the element
MSG Length value will be written. Bit 1 is the most significant bit (MSB) and
bit 16 the least significant bit (LSB).
MSB LSB
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
Valid Entry: 1 - 16
Data Type Specify HREG as the type of register to which the element value
will be written.
Valid Entry: HREG
External Device
model types support mask write operations: A120, A130, A141, A145, 685E, 785E,
AT4, and VM4.
Interface
To fill out an information panel for a request to send a mask write to a holding
register, perform the following steps.
Using the following field descriptions, add a panel entry for each for each bit to be
set or cleared when the value of any bit defined in the table changes. Each bit is
referenced by a separate tag name on the Read/Write Information panel.
Tag Name Specify a tag name for a digital element containing a value to be
written to the device.
When a digital tag is written to a holding register, two messages
are sent to the device. The first message reads the entire holding
register; the second one writes the new value to the specified bit.
Valid Entry: standard element tag name
Valid Data Type: digital
Logical Station Enter the number representing the device to which the element
value will be written. This number was originally defined in the
Logical Station Information panel for the logical port through
which communications with this device occurs.
Valid Entry: previously defined logical station number
Reg. Address Enter the register address of the word containing the bit to be set
or cleared.
Do not include the register address prefix (4) or leading zeros.
The prefix indicates the register type, which is specified in the
Data Type field. For example, for holding register address 400001,
just enter 1.
Valid Entry: 1 - 65535
Bit Offset/ Specify the bit within the register word that will change as a
MSG Length result of the mask write. Bit 1 is the most significant bit (MSB)
and 16 the least significant bit (LSB).
MSB LSB
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
Valid Entry: 1 - 16
Data Type Specify MASK to indicate the type of operation.
Valid Entry: MASK
External Device
Using the following field descriptions, add a panel entry for each element to be
written and define the register addresses to receive each element value when the
Interface
operation executes.
Tag Name Specify a tag name for a floating-point or a long analog element
containing a value to be written to the device.
Valid Entry: standard element tag name
Valid Data Type: float, longana
Logical Station Enter the number representing the device to which the element’s
value will be written. This number was originally defined in the
Logical Station Information panel for the logical port through
which communications with this device occurs.
Valid Entry: previously defined logical station number
Reg. Address Enter the register address in the device’s memory to which the
element value will be written.
Floating-point or long analog tag types are addressed in pairs.
The first register in the pair contains the high order word; the
second register contains the low order word. Enter the address for
only the starting register in a register pair. The companion
register is implied.
Try to maintain consistency when using register addresses for
floating-point and long analog tag types. Adopt either an odd or
even starting register sequence and maintain that sequence. For
example, 1, 3, 5, 7, 9,... or 2, 4, 6, 8, 10,....
Do not include the register address prefix (4) or leading zeros.
The prefix indicates the register type, which is specified in the
Data Type field. For example, for holding register address 400001,
just enter 1.
Valid Entry: 1 - 65535
Bit Offset/ Accept the default of 1.
MSG Length
Valid Entry: 1
Data Type Specify HREG as the type of register to which the element value
will be written.
Valid Entry: HREG
External Device
Using the following field descriptions, add a panel entry for each element to be
written and define the register addresses to receive each element value when the
Interface
operation executes.
Tag Name Specify a tag name for a message element containing a value to
be written to the device.
Valid Entry: standard element tag name
Valid Data Type: message
Logical Station Enter the number representing the device to which the element’s
value will be written.This number was originally defined in the
Logical Station Information panel for the logical port through
which communications with this device occurs.
Valid Entry: previously defined logical station number
Reg. Address Enter the register address in the device’s memory to which the
element value will be written.
Enter the first address in the group of registers to which the value
will be written. The number of registers to which the data is to be
written is defined in the Bit Offset/MSG Length field of this panel.
Do not include the register address prefix (4) or leading zeros.
The prefix indicates the register type, which is specified in the
Data Type field. For example, for holding register address 400001,
just enter 1.
Valid Entry: 1 - 65535
Bit Offset/ Specify the number of bytes in the device’s memory to which the
MSG Length element value will be written.
Valid Entry: 1 - 80
Data Type Specify HREG as the type of register to which the element value
will be written.
Valid Entry: HREG
External Device
Using the following field descriptions, add a panel entry for each element to be
written and define the register addresses to receive each element value when the
Interface
operation executes.
Tag Name Specify a tag name for a digital element containing a value to be
written to the device.
Valid Entry: standard element tag name
Valid Data Type: digital
Logical Station Enter the number representing the device to which the element’s
value will be written.This number was originally defined in the
Logical Station Information panel for the logical port through
which communications with this device occurs.
Valid Entry: previously defined logical station number
Reg. Address Enter the register address in the device’s memory to which the
element value will be written.
Do not include the register address prefix (0) or leading zeros.
The prefix indicates the register type, which is specified in the
Data Type field. For example, for coil address 023451, enter 23451.
Valid Entry: 1 - 65535
Bit Offset/ Accept the default of 1.
MSG Length
Valid Entry: 1
Data Type Specify COIL as the type of register to which the element value
will be written.
Valid Entry: COIL
External Device
Using the following field descriptions, add a panel entry for each element to be
written and define the register addresses to receive each element value when the
Interface
operation executes.
Tag Name Specify a tag name for an analog element containing a value to be
written to the device.
Valid Entry: standard element tag name
Valid Data Type: analog
Logical Station Enter the number representing the device to which the data in
this element will be written.This number was originally defined
in the Logical Station Information panel for the logical port
through which communications with this device occurs.
Valid Entry: previously defined logical station number
Reg. Address Enter the register address in the device’s memory to which the
element value will be written.
Do not include the register address prefix, 6, or leading zeros. The
prefix indicates the register type, which is specified in the Data
Type field. For example, for memory address 600001, just enter 1.
Valid Entry: 1 - 65535
Bit Offset/ Accept the default of 1.
MSG Length
Valid Entry: 1
Data Type Specify the type of register to which the element value will be
written as XMEMnn where nn is a numeric value from 1 to 10.
Valid Entry: XMEM1 - XMEM10
External Device
Note
Interface
Although global data is considered contiguous in block write
tables, you can define register addresses that do not appear
contiguous on the information panel. For example, if you specify
register address 1, 5, 7, 20, and 25 for a write operation, a message
is generated for registers 1 through 25. A value of 0 is stored for
those registers within the range that do not appear in the
read/write information table.
Using the following field descriptions, add a panel entry for each element to be
written and define the register addresses to receive each element value when the
operation executes.
Tag Name Specify a tag name for an analog element containing a value to be
written to the device.
Valid Entry: standard element tag name
Valid Data Type: analog
Reg. Address Enter the register address in the device’s memory to which the
element value will be written.
The first global data word received is always assumed to be word 1,
the second is word 2, and so on. If you specify a register address
larger than the total number of global data words that will actually be
received, an error is generated.
Valid Entry: 1 - 32
Bit Offset/ Accept the default of 1.
MSG Length
Valid Entry: 1
Data Type Specify GLBL to access a global data word.
Valid Entry: GLBL
External Device
Sample Triggered Block Write Request
Interface
This section provides descriptions of some possible Read/Write Control and
Read/Write Information panel entries for a triggered block write request.
Figure 7-3 Read/Write Control Panel for Triggered Block Write
Continued
Continued
WRITE is
discussed in
this example.
External Device
Interface
Continued
Continued
Continued
EXCEPTION is
discussed in
this example.
External Device
Interface
In this example, whenever the value of the digital element HOLD_DIG1 changes,
FactoryLink processes the EXCEPTION table. This table writes the value of
HOLD_DIG1 to holding register 140 in the device configured as logical station 0.
If the table is disabled then re-enabled and MODP_EXCEPTION_TRIGGER is set
to 1, holding register 140 is updated with the value of HOLD_DIG1 if the value
has changed since the table was disabled.
Continued
External Device
Figure 7-9 Read/Write Control Panel for Combination Write
Interface
Continued
Continued
EXCEPTION is
discussed in
this example.
In this example, when FactoryLink starts up and whenever the value of the
analog element HOLD_ANA1 changes, FactoryLink processes the EXCEPTION
table. This table writes the value of HOLD_ANA1 to holding register address 200
in the device configured as logical station 0.
External Device
to 1, it writes the value of
HOLD_ANA1 to the device.
Interface
Continued
Because this is an
exception write
table...
... whenever the value
of HOLD_ANA1
changes...
...FactoryLink writes
its value into holding
register address 200.
•
•
•
•
Application Design Tips and
Techniques 8
External Device
Interface
This chapter describes application tips and techniques that can improve the throughput and
efficiency of data communications between the EDI task and the devices in your configuration.
These techniques involve the order in which you specify read and write table entries,
specification of the priority in which the task processes read and write operations, and methods
of triggering the tables and tags defined in the Read/Write Control panel.
Note
When grouping table entries, keep the following types of information together:
• Logical Stations—Keep data being read from or written to a particular logical station
together; that is, for best results, do not define more than one logical station in a table.
• Data Types—Keep like data types (FactoryLink and protocol-specific) together. Any break
in data type results in the generation of an additional packet.
• Contiguous Addresses—Keep data being read from or written to contiguous or near
contiguous addresses together.
For example, if the following conditions are met, FactoryLink can process a table in one
message:
The table only contains data of an amount not exceeding the maximum size the device can
handle for one transmission.
The data is stored in elements of the same FactoryLink data type.
Tip
Naturally, all conditions cannot be met for each table you define. If your goal
is to minimize the number of messages generated, however, you should
attempt to group read and write table entries the same way in which
FactoryLink internally groups and processes them.
External Device
generate one
message to process
Interface
this table because
conditions 1 through
4 are met.
In the read table illustrated in Figure 8-2, only conditions 1, 2, and 4 are met. To process this
table, FactoryLink must generate two messages.
Figure 8-2 Read Operation Completed in Two Messages
FactoryLink would
need to generate two
messages to
process this table:
one to read the
specified holding
registers and
another to read the
memory registers.
For example, the table illustrated in Figure 8-3 reads all addresses in the range 201 to 208 but
only stores values read from addresses 201 and 208.
Figure 8-3 Table That Reads an Address Range but Stores Selected Values
FactoryLink generates one message to process this table. All data at addresses ranging from
201 to 208 are read, but only the values at addresses 201 and 208 are stored in database
elements.
Note the differences in the tables shown in Figure 8-1Figure 8-1Figure 8-1Figure 8-1 and in
Figure 8-3 (see Figure 8-4). The data FactoryLink reads is identical. Each table results in 8
FactoryLink reading addresses 201 through 208. The difference in the two tables is the data
FactoryLink stores in database elements. The first table stores eight of the values read. The
second table stores only two values.
External Device
Figure 8-4 Both Tables Read the Same Addresses
Interface
If the same entries made in the read table shown in Figure 8-3 are made in a write table, each
row generates a separate message resulting in two messages being sent to the device (see the
first panel in Figure 8-5). To send a message to write to addresses 201 through 208, you would
need to define each address separately (see the second panel in Figure 8-5). Only contiguous
groups of data (up to the maximum allowed by the device) are put in one message for a write
operation.
Figure 8-5 Table That Sends Four Messages to Four Addresses
FactoryLink
generates two
messages to
process this table.
FactoryLink
generates one
message to process
this table.
External Device
Figure 8-6 Messages Generated for Read and Write Table
Interface
Continued
Continued
ó
ì
ó
ì
ö
ú
Continued
Continued
ó
ì
ö
ó
ì
S PECIFYING P RIORITY
8
The Read/Write Control panel contains two columns for specifying the priority of block reads
and block or exception writes: Block Read Priority and Block Write Priority. The priority of an
operation can range from 1 to 4. These values correspond to four first-in/first-out (FIFO)
External Device
priority queues which are set up in order of importance. Priority queue 1 has the highest
priority.
Interface
The queues are polled for tables according to the rank of the priority. The priority 1 queue is
polled the most frequently and the priority 4 queue is polled the least frequently. Every table is
eventually processed but the ones in the priority 4 queue are not processed as often as the
tables in the priority 1 queue.
All tables are placed by default in the priority 1 queue, which is appropriate in most cases.
When an application contains a large number of tables, however, or when an exception write
table contains tag names for rapidly changing elements, the priority 1 queue can fill up.
To more evenly distribute tables across the four priority queues (thus reducing the priority 1
queue’s burden of handling all the pending I/O requests), you could assign priority 1 or 2 to
tables containing more important data and priority 3 or 4 to tables containing less important
data.
Using this logic, you would, for instance, assign a high priority to an exception write table for
an operation that acknowledges a loud annoying alarm, and a low priority to a block write table
that downloads a batch recipe once a day.
E FFICIENT TRIGGERING
To design your application for optimum performance and avoid overtriggering, consider the
following triggering techniques.
Timed
The easiest and most basic way to trigger a block read or write operation is with a timed
element. To define a timed trigger element, you enter a tag name for a Block Read Trigger or
Block Write Trigger element in the Read/Write Control panel that matches the tag name of an
interval timer element (defined in the Interval Timer Information panel). If you define this
element to change once per second, the table is placed in its shared memory once every second.
Using timed elements as triggers is acceptable in most cases. An overtriggering situation can
occur, however, if the trigger rate causes tables to be placed into shared memory faster than
EDI or the protocol module can process them.
A situation in which triggers overlap can occur as well. To illustrate, suppose a 5-second, a
15-second, and a 30-second timed element are used to trigger various tables. Each table is
placed in its designated queue every 30 seconds when the various triggers line up. The use of
prime numbers quickly solves this problem, but a more effective method follows.
Note
The next two triggering methods, cascaded and self-triggered, can solve
potential overtriggering situations in many cases. These methods, however,
might not be appropriate for every read or write table you define. For
instance, the timed method works best for tables that do not need to be
updated at the highest possible rate.
Cascaded
The cascading of tables is an alternative to using timed triggers. It uses the Block Read State
and Block Write State elements, which are reset to 1 after EDI processes the table.
In the Read/Write Control panel, if either the complete or state element is defined as the trigger
element for the table in the row below the current table, that table is not triggered and placed 8
into shared memory until the preceding table is processed. If the table defined in the final row
of the Read/Write Control panel contains a tag name for a complete or state element that
matches the tag name of the trigger element for the table defined in the first row, the
External Device
completion of the final table triggers the first table. This endless loop results in the sequential
processing of tables at an optimal rate.
Interface
Figure 8-8 illustrates a series of read tables created using the cascading technique. This type of
table setup is also referred to as a “daisy chain” of tables.
Figure 8-8 Cascaded Read Tables
Continued
READ1 NO NO 1 r5_state
READ2 NO NO 1 r1_state
READ3 NO NO 1 r2_state
READ4 NO NO 1 r3_state
READ5 NO NO 1 r4_state
Continued
When the READ1 table
has been processed, its r1_state
r2_state
state tag, r1_state, is r3_state
forced back to 1. r4_state
r5_state
A table is placed into shared memory only after the previous table has been processed. If you
use the Block Read State or Block Write State element to perform the cascade, the successful
processing of a table prior to the next table in the loop being triggered is not guaranteed; but
overtriggering is prevented. Regardless of communications, the loop continues to process.
If a table is to be placed into shared memory that has become full, the value of the state
element for that table does not change. Consequently, the next table is not triggered until room
is available in shared memory for the current table.
If you use the Block Read Complete or Block Write Complete element to perform the
cascade, the next table in the loop is placed into shared memory after the previous table is
successfully communicated. In this case, successful processing of the transaction is
guaranteed. (A time-out error occurring somewhere in the loop slows the performance of the
cascade.)
For example, experimentation determines that when one 3.2-second timed digital element is
used as the same trigger element for a number of tables, the application can trigger the tables
without the overtrigger message appearing.
Self-Triggered
The use of self-triggered tables can increase the throughput and efficiency of read and write
operations.
In a self-triggered table, instead of a state or complete element serving as a trigger for the next
table in a cascaded loop, a state or complete element serves as a Block Read Trigger or Block
Write Trigger element for the table in which it is defined. In other words, one tag name is
defined for both the trigger element and the complete or state element in a single table:
Figure 8-9 Self-Triggered Read Table
Continued
R_AGAIN NO NO 1 selftrig
Continued
selftrig
When FactoryLink starts up, the complete or state element is automatically set to 1. If you
have defined this same element as the trigger element, the table is also placed in its priority
queue at startup. When the complete or state element is set again as a result of the operation,
the cycle starts over and the table is placed in its priority queue again (because the complete or
state element is also the trigger).
Overtriggering does not occur with a self-triggered table because a table destined for a device
is placed into shared memory only after the previous table has been processed. 8
Note
External Device
The continuation of a cascaded loop or self-triggered table ceases if the Block
Interface
Read Disable or Block Write Disable element is set to 1. To restart after the
disable element is set to 0 again, the Block Read Trigger or Block Write
Trigger element must be reset to 1.
Figure 8-10 illustrates the methodology of a self-triggered read table that uses the state element
to self trigger.
Figure 8-10 Self-Triggered Read Table
At FactoryLink startup, selftrig (as a
state element) is set to 1.
Continued
•
•
•
•
Testing and
Troubleshooting 9
External Device
Interface
This chapter contains information to help you prevent, identify, and correct
problems with EDI and the device task. The sections included are listed below.
• For a series of flowcharts to assist you in identifying and solving problems with
EDI, see “EDI Flowcharts” on page 178.
• For information about configuring and testing a simple triggered read table, see
“Verifying Proper Communications” on page 182.
Begin here to
troubleshoot EDI.
Has anything
Was this
about the See the flowchart, See the flowchart,
No No operation
configuration "Basic Troubleshooting." "Basic Troubleshooting."
successful?
changed?
Yes
Yes
Hardware
Basic Troubleshooting
9
Begin here for basic
troubleshooting. The baud rate, parity
Do the
and stop bits should
communication
External Device
match. Refer to the
parameters No
device
match those of
manufacturer’s
the device?
Interface
documentation.
RunUKEY -Lto verify all
necessary license options Yes
(protection bits) are
present
. Check the listing For testing purposes
for COM and for the Is the logical set this value up to
protocol-specific interface station timeout No eliminate timing
product you are using. setting too low? considerations as a
problem.
Yes
Use the correct cable. Do not If this flow chart does not
Does the cable use a cable from another address your problem, note
configuration software package unless it any signs of communication
match the No matches the cable specified in (such as transmit and receiv
applicable diagram Chapter 4. Also see the section, lights on the device, or line
in Chapter 4? "The Cable Connection," in No analyzer output) and
Chapter 1. document your test
application, if applicable.
Yes
Then, contact Customer
See Chapter 1 for a discussion Support for further assistan
Do all entries for of logical stations and logical
logical station ports. To help you configure
No
and logical port multiple ports and stations, a
match? logical station worksheet is
provided in Chapter 5.
Yes
Yes
Is the memory
setting correct in For appropriate memory
the External No settings for the system
Device Definition hardware, refer to Chapter 5.
table?
External Device
Test the communication path by
following the procedure
Interface
described in "Verifying Proper
Communications" in this chapter.
Check the
Was the test
No cable
successful?
connection.
Yes
Since the simple read and write operation from one point to one
device works, the error is probably in the larger application. Gradually
add parts of the larger application to the test application. For instance,
add a logical station for another device and try to read and write to it.
Yes
Yes
Note any signs of communicat
See the flowchart, such as transmit and receive
Common errors. lights on the device, or line
analyzer output.
Configure two tables: a triggered read table and an exception write table. These
should look similar to the ones shown below.
In the write table, define an element (in the sample panel, VALUE2) to hold a
value that will be written to the same address configured in the read table. You
will change this element’s value in RTMON to prompt the processing of this table.
The next steps in the procedure involve the use of the FactoryLink Real-Time
Monitor. For detailed instructions on using RTMON, refer to the FactoryLink ECS 9
Fundamentals manual.
In RTMON, create a watch list containing the elements defined in the two tables
External Device
(TEST_RTRIG, VALUE1, and VALUE2 in the sample panels). To create a watch
list, use the Watch option on the RTMON Options menu.
Interface
Prompt the processing of the triggered read table by forcing a 1 to the read trigger
using the Tag Input option on the RTMON Options menu. You can watch the value
of the trigger change in the watch list.
When the triggered read table is processed, the element defined to hold the value
read (VALUE1 in the sample panel) is updated with the current value of the
specified register address.
•
•
•
•
Messages and Codes
10
External Device
Interface
During normal operations and upon detecting an error condition, FactoryLink
generates and displays messages for the EDI task, the device protocol module, and
the devices in your application configured for FactoryLink communications. These
messages are briefly displayed on the Run-Time Manager screen. For FactoryLink
to store system messages, you define database tags to which the messages are
written when they occur. These database tags are configured in the Logical
Station Control and Information panels. To view the stored messages, you
configure these tags as graphic objects using the Application Editor.
This chapter explains the formats for system messages, as well as a descriptive
list of the potential messages FactoryLink can generate for EDI and display at
startup and while an application is running. For descriptions of protocol module
messages, refer to the protocol-specific reference chapter.
where
LPORT:xxx is the logical port number assigned to the physical port
experiencing the error.
LSTA:xx is the logical station number assigned to the physical station
experiencing the error.
ER:xxxx is an error code in decimal format. Refer to the protocol-specific
reference chapter for details on the error code generated.
TBL:xxx is the number of the read or write table experiencing the error.
PKT:xxx is the number of the message packet experiencing the error.
means an error code 2 occurred for port 0, logical station 2, involving the third
table in the Read/Write Control panel for the second message packet generated.
To view the contents of a message tag on an application screen, you define the tag
as a graphic object using the Application Editor.
In a message tag, the LPORT field of an EDI Run-Time Manager message is stored
in the following format: 10
Lsta n: MessageText, nnnn
External Device
where
n: is the number assigned to the logical port causing the message.
Interface
MessageText is a description of the condition causing the error.
nnnn is the code number assigned to the message generated. For
information about the protocol-specific codes, refer to the protocol
module reference chapter.
For example:
Lsta 2: Read Response Error, 0x03
The information in italic text in the message descriptions will vary depending
upon certain factors. In the message you will see in your application, what is
shown in italics will be replaced by information specific to your application (for
example, port or table number).
Some of the messages described in this chapter can also be found in Chapter 9,
“Testing and Troubleshooting,” in a flowchart that describes how to respond to
some common error messages generated and displayed by the EDI task.
EDI Messages
10
The following messages report operations and error conditions specific to EDI.
External Device
Cause: A protocol module was experiencing an error at the time the EDI
Interface
task was shutting down.
Action: None. This is only an information message.
External Device
Interface
Error reading device definition
Cause: A necessary device definition file for the EDI task is corrupt.
Action: Verify the External Device Definition table entries are correct.
LPORT logical port LSTA logical station err hexcode table table pkt:packet
Cause: An error occurred during a read or write operation to the
specified logical station.
Action: The error code specified after err is associated with the port,
station, table, and packet indicated. Refer to the description for
the hexadecimal number that is displayed after err in the
protocol-specific reference chapter for information about
correcting the error.
Cause: The EDI task does not recognize any read or write operations
because the .DCT files were not properly built.
Action: Check the FLAPP\DCT directory to verify the .DCT files were
built. If necessary, execute EDISTART -R -V to regenerate the
files.
Cause: The EDI task does not recognize any read or write operations
because the task is unable to read the FLAPP\DCT directory.
Action: Verify the FLAPP\DCT directory has read and write privileges.
Grant these privileges if necessary.
Cause: The EDI task does not recognize any read or write operations
because none have been defined.
Action: Create a read or write table.
Normal shutdown
Cause: The EDI task is shutting down in response to a normal 10
FactoryLink termination request.
Action: None. This is only an information message.
External Device
Interface
Out of RAM EDI task function
Cause: The EDI task cannot perform the specified function because the
system has run out of memory.
Action: Increase the amount of virtual memory.
FactoryLink Ver: n EDI Ver: n.nn protocol module EDI Module Ver: n.nn
Cause: The protocol module has started up successfully.
Action: None. This is only an information message.
protocol module: Software Protection bit failure; bits (x) and number (y) required
Cause: One or both of the option bits (where x and y are decimal values)
required to run this protocol module are missing.
Action: Install the required option bits in the master key.
•
•
•
•
Allen-Bradley
11
External Device
Interface
This chapter contains information needed to set up and configure bidirectional
communications between the FactoryLink real-time database and the following devices, either
directly or through the Allen-Bradley Data Highway protocol:
• PLC-2
• PLC-3
• PLC-4
• PLC-5
• PLC-250
• PLC-1774
When you choose Allen-Bradley from the Configuration Manager Main Menu, the
Allen-Bradley
Allen-Bradley configuration panels are displayed.
Note
To bring the Logical Station Control panel to the foreground, click its title bar in the display of
all configuration panels.
Complete a row for each logical port specified in the External Device Definition panel you
want to define as a communication path for read and write operations.
Logical Port Enter a number, defined in the External Device Definition panel Logical
Port column, to represent a particular communication path to a device.
Valid Entry: previously defined logical port number
Baud Rate Enter the speed at which the protocol module communicates with the
devices linked to FactoryLink via this logical port. This entry must match
the baud rate configuration of the devices. Refer to the device
manufacturer’s documentation for details.
Valid Entry: 110 - 115200 (default=9600)
Parity Enter the parity error correction during transmission via this logical port.
This entry must match the configuration of the devices communicating via 11
this port. Refer to the device manufacturer’s documentation for details.
Valid Entry: none, even, odd (default=none)
External Device
Data Bits Enter the number of data bits used during transmission via this logical port.
This entry must match the configuration of the devices communicating via
Interface
this port. Refer to the device manufacturer’s documentation for details.
Valid Entry: 7, 8 (default=8)
Stop Bits Enter the number of bits sent after a character to create a pause before the
start of the next character. This entry must match the configuration of the
devices communicating via this port. Refer to the device manufacturer’s
documentation for details.
Valid Entry: 1, 2 (default=1)
Response Timeout Enter the length of time, in tenths of seconds, the protocol module will wait
0.1 sec to receive a response to a read or write command before timing out. You
must enter a value greater than 0 for the protocol module to timeout.
Valid Entry: 0-9999 (default=55)
Allen-Bradley
Data Highway I/F Enter the address of the asynchronous communications module on the Data
Address (Octal) Highway. Most current modules accept or require 0. Some older
Allen-Bradley Data Highway interface modules may require their Data
Highway address.
Valid Entry: 0 - 377 (unless specifically required by the Data
Highway interface, enter 0.)
Duplex Enter the type of Allen-Bradley protocol support.
Valid Entry: full (default)
LRC Error Enter the type of longitudinal range error checking used by the
Detection Allen-Bradley asynchronous communications interface.
Ensure that the communication device matches the setting you choose. If
you specify no setting, the LRC error detection defaults to CRC.
Valid Entry: B, C, BCC, CRC (default=CRC)
Retry Request (For use with BCC longitudinal error checking only.) Enter the maximum
number of times the protocol module will retry a read or write command to
a device communicating through this logical port if the command response
is invalid or is not received.
Valid Entry: 0 - 32767 (default=3)
When the panel is complete, click Enter to validate the information. Define the data type
(message) for any tag names displayed in the Tag Definition dialog.
Table 11-1 provides sample entries for the Allen-Bradley Logical Station Control panel. In this
example, logical port 0 is configured for a baud rate of 9600, 8 data bits, 1 stop bit, no parity,
and a 5.5-second response timeout. The Data Highway I/F address is 0, using FULL duplex.
LRC Error detection is CRC, the retry request is 3 with a link timeout of 150 seconds. The
ENQ Retry count is 10 and the NAK Retry Count is 3. The EDI task will store
communications error messages associated with this logical port in a message element,
AB_LPORT0_MSG
Field Entry
Logical Port 0
Baud Rate 9600
Parity NONE
Data Bits 8
Stop Bits 1
External Device
Response Timeout 0.1 sec 55
Interface
Data Highway I/F address (OCTAL) 0
Duplex FULL
Retry Request 3
Link Timeout 0.001 sec 150
Allen-Bradley
Status Msg Tag AB_LPORT0_MSG
Complete a row for each device to communicate through this logical port.
Error/Status Tag (Optional) Enter a tag name for an analog element in which to store
Name communications error codes associated with this device (logical station).
For information about displaying the codes stored in an Error/Status Tag
Name element for an operator using this application, see the FactoryLink
ECS Application Editor.
Valid Entry: standard element tag name
Valid Data Type: analog
Logical Station Enter a number to identify the logical station to which the information in
(Decimal) this row pertains. A logical station represents the combination of a logical
port with a physical station. Assign a unique number to each device
communicating through this logical port.
You will later enter this logical station number in a read or write table to
represent the device defined in this row. In a read or write table, this number
will identify the device to or from which data is to be sent or received.
Valid Entry: 0 - 999
Device Type Enter the type of Allen-Bradley device to which communications are to be
directed. 11
Valid Entry: PLC (valid for 1774-PLC and PLC-4), PLC-2 (also valid
for 1774-PLC and PLC-4), PLC-3, PLC-5, PLC-250
External Device
Station Address Enter the physical Data Highway address of the Allen-Bradley device.
(Octal)
Interface
For some Data Highway types, some addresses may be invalid. For further
information about valid addresses for a specific Data Highway type, refer to
the Allen-Bradley documentation.
Valid Entry: 0 - 377 (octal)
Comment (Optional) Enter reference information about this logical station.
Valid Entry: alphanumeric string of up to 21 characters
When the panel is complete, click Enter to validate the information. Define the data type
(analog) for any tag names displayed in the Tag Definition dialog.
Table 11-2 provides sample entries for the Allen-Bradley Logical Station Information panel. In
this example, logical station 0 is a PLC-5 on logical port 0, with a data highway address of 1.
The analog element defined in the Error/Status Tag Name field, AB_STATION0_STATUS, is
Allen-Bradley
configured to hold port errors for logical station 0.
Field Entry
Comment
Tip
Table Name Give this read or write request a name. Define one request (table) per line
and do not include spaces in the name. You can define as many tables in this
panel as available memory allows. Try to make the table name reflective of
the operation it represents.
If this is a triggered read or a block write table, when the trigger element
(Block Read Trigger for a read operation or Block Write Trigger for a write
operation) is forced to 1 (ON), the element prompts FactoryLink to process
this table and any other table in which the same trigger is defined.
Valid Entry: alphanumeric string of up to 16 characters
Unsolicited Read For EDI to interpret this operation as a triggered block read or as a write
operation, accept the default of NO.
External Device
If you enter YES, the incoming data will be stored in the element
Interface
represented by the tag name specified in the Read/Write Information panel.
If the current value of the element is equal to the new value, the
change-status indicator is unaffected. If a different value is being stored the
element, however, it will overwrite the current value and the element’s
change-status indicator will be set to 1 (ON).
If you enter FORCE, the data is stored in the specified element and the
change-status indicator is automatically set to 1, regardless of whether the
current value matches the new value.
Valid Entry: yes, no, force (default=no)
Exception Write For EDI to interpret this operation as a triggered block write or as a read
operation, accept the default of NO.
For EDI to interpret this operation as an exception write and write element
Allen-Bradley
values to the device only when those values change, enter YES.
In an exception write, an internal change-status indicator within the element
containing the data to be written prompts the write operation. If an element
is configured for an exception write and EDI recognizes this indicator has
been set since the last scan of the real-time database (indicating the value of
the element has changed), EDI writes this element’s value to the device.
Valid Entry: yes, no (default=no)
Tip
Block Read If this is a block read operation, enter a number to indicate the priority of
Priority this table, relative to other read operations. The highest priority is 1. This
number influences the order in which the EDI task handles the queuing of
block read requests. If EDI receives two requests at the same time, it
processes the request with the highest priority first. The default is 1.
Note
The Block Read Trigger, Block Read Disable, Block Read Complete, and
Block Read State elements apply only to triggered read operations. Do not
define these elements for unsolicited read operations or for write operations.
Block Read If this is an unsolicited read or a write operation, ignore this field.
Trigger
If this is a triggered read operation, this field is required. Enter a tag name
for a digital element to initiate a block read of the addresses specified in the
Read/Write Information panel. When this element’s value is forced to 1
(ON), the addresses are read.
Valid Entry: standard element tag name
Valid Data Type: digital
Block Read If this is an unsolicited read or a write operation, ignore this field.
Disable
If this is a triggered read operation, this field is optional. If you need a
digital element to disable a block read of the elements specified in this
table, enter a tag name. When this tag’s value is forced to 1 (ON), the read
operation is not executed, even when the block read trigger is set to 1.
To re-enable a block read table that has been disabled, set this element back
to 0 (OFF).
Valid Entry: standard element tag name
Valid Data Type: digital
Tip
This element can be used to disable a block read operation that is either part
of a cascaded loop or is self-triggered. The triggering cycle will cease upon
disabling, however. To re-enable a cascaded loop or a self-triggered read
table, the Block Read Trigger element must be toggled or forced to 1. Refer
to Chapter 8, “Application Design Tips and Techniques,” for further details.
Block Read If this is an unsolicited read or a write operation, ignore this field.
Complete
If this is a triggered read operation, this field is optional. If you need a 11
digital element to indicate when this operation is complete, enter a tag
name. This element is forced to 1 (ON) at startup. After the elements
External Device
defined in the Read/Write Information panel have been updated in the
FactoryLink database, the complete element is forced to 1 again.
Interface
Do not use this element when more than one logical port is specified in a
single table.
Valid Entry: standard element tag name
Valid Data Type: digital
Block Read State If this is an unsolicited read or a write operation, ignore this field.
If this is a triggered read operation, this field is optional. If you need a
digital element to indicate the state of this operation (in progress or
complete), enter a tag name. This element is forced to 1 (ON) at startup.
While the table is being processed, the element is set to 0 (OFF). After the
elements defined in the Read/Write Information panel have been updated in
the FactoryLink database, the state element is forced back to 1.
Allen-Bradley
Valid Entry: standard element tag name
Valid Data Type: digital
Block Write If this is a block or exception write operation, enter a number to indicate the
Priority priority of this table, relative to other write operations. The highest priority
is 1. This number influences the order in which the EDI task handles the
queuing of write requests. If EDI receives two requests at the same time, it
processes the request with the highest priority first. The default is 1.
If this is a read operation, accept the default of 1. This field defaults to 1
regardless of whether the operation being defined is a block or exception
write.
Valid Entry: 1 - 4 (default=1)
Note
The Block Write Trigger, Block Write Disable, Block Write Complete, and
Block Write State elements apply only to write operations. Do not define
these elements for read operations.
Block Write Trigger If this is a read operation or an exception write operation you do not plan to
periodically disable, ignore this field.
Tip
This element can be used to disable a block write operation that is either part
of a cascaded loop or is self-triggered. The triggering cycle will cease upon
disabling, however. To re-enable a cascaded loop or a self-triggered write
table, the Block Write Trigger element must be toggled or forced to 1. Refer
to Chapter 8, “Application Design Tips and Techniques,” for further details.
Block Write If this is a read or exception write operation, ignore this field.
Complete
If this is a block write table, this field is optional. If you need a digital
element to indicate when this operation is complete, enter a tag name. This
element is forced to 1 (ON) at startup. After the data defined in this table’s
Read/Write Information panel has been written to the device, the complete
element is forced to 1 again.
Do not use this element when more than one logical port is specified in a
single table.
Valid Entry: standard element tag name
Valid Data Type: digital
Block Write State If this is a read or exception write operation, ignore this field.
If this is a block write operation, this field is optional. If you need a digital 11
element to indicate the state of this operation (in progress or complete),
enter a tag name. This element is forced to 1 (ON) at startup. While the
External Device
table is being processed, the element is set to 0 (OFF). After the data
defined in this table’s Read/Write Information panel has been written to the
Interface
device, the state element is forced back to 1.
Do not use this element when more than one logical port is specified in a
single table.
Valid Entry: standard element tag name
Valid Data Type: digital
When the panel is complete, click Enter to validate the information. Define the data type
(digital) for any tag names displayed in the Tag Definition dialog.
Table 11-3 provides sample entries for the Allen-Bradley Read/Write Control panel. In this
example, the READ table is configured as follows:
• When the value of the digital Block Read Trigger element AB_READ_TRIGGER is 1,
FactoryLink reads the configured register address and writes its value to the element
Allen-Bradley
configured for this table (in the Read/Write Information panel). The block read priority,
which is set automatically if you do not enter a value, is set to the default of 1, the highest
priority.
• When the value of the digital element AB_READ_DISABLE is 1, FactoryLink disregards
the trigger element, AB_READ_TRIGGER, and does not process the READ_MSG table.
• Once FactoryLink reads the data and writes it to the database element defined to receive it
(MBRDR1 in the Read/Write Information panel), FactoryLink forces a value of 1 to the
digital Block Read State element, AB_READ_STATE, and to the Block Read Complete
element, AB_READ_COMPLETE. During the read operation, AB_READ_STATE is set to
0.
Field Entry
Field Entry
Block Write Priority The write priority for this table is set
to 1 by default.
External Device
Interface
Allen-Bradley
For a Read Table—Add a panel entry for each FactoryLink database element in which data
read from the device will be stored when the operation executes.
For a Write Table—Add a panel entry for each element to be written when the operation
executes.
Tip
Tag Name For a read table, specify a tag name for an element in which FactoryLink
will store the data read from the device.
For a write table, specify a tag name for an element containing a value to be
written to the device.
Valid Entry: standard element tag name
Valid Data Type: digital, analog, longana, float, message
When the panel is complete, click Enter to validate the information. Define the data type
(digital, analog, long analog, floating-point, or message) for any tag names displayed in the
Tag Definition dialog.
Table 11-4 provides sample entries for the Allen-Bradley Read/Write Information panel. In this
example, the protocol module reads data from address 310/00 in the PLC configured as logical
station 0. The data is stored in a digital element, MBRDR1. The protocol module transfers this
untranslated binary value (BIN) to the real-time database without conversion.
External Device
Logical Station 0
Interface
Address 310/00
Data Type BIN
Allen-Bradley
BCD3 Unsigned, 2-byte word representing 3 BCD digits Binary Coded Decimal
value
BCD4 Unsigned, 2-byte word representing 4 BCD digits Binary Coded Decimal
value
UBCD Unsigned, 2-byte word representing 4 BCD digits most significant nibble
ignored for reads, zero on writes
FLT4 Signed, 4-byte floating-point number
ASC Two ASCII characters stored in one word: first character in least
significant byte; second character in most significant byte
External Device
Interface
Digital Elements
The Allen-Bradley protocol module supports only the following digital conversion:
BIN to Digital
The value (1 or 0) of the bit at the specified address is transferred to the digital element without
conversion. If no bit number is specified, the value of bit 0 at the specified address is
transferred to the digital element.
Analog Elements
The Allen-Bradley protocol module supports only the following analog conversions:
Allen-Bradley
BIN to Analog
The value of the word at the specified address is transferred to the analog element without
conversion.
INT2 to Analog
The value of the word at the specified address is transferred to the analog element without
conversion.
INT4 to Analog
The value of the 4-byte integer at the specified address is converted to a 2-byte integer value
and is transferred to the analog element.
BCD3 to Analog
The 3-digit BCD value at the specified address is converted to a 2-byte integer value and is
transferred to the analog element.
BCD4 to Analog
The 4-digit BCD value at the specified address is converted to a 2-byte integer value and is
transferred to the analog element.
The 3-digit BCD value at the specified address is converted to a 2-byte integer value and is
transferred to the analog element.
FLT4 to Analog
The 4-byte floating-point value at the specified address is converted to a 2-byte integer value
and is transferred to the analog element.
FLT8 to Analog
The 8-byte floating-point value at the specified address is converted to a 2-byte integer value
and is transferred to the analog element.
Floating-Point Elements
The Allen-Bradley protocol module supports only the following floating-point conversions:
The 8-byte floating-point value at the specified address is transferred to the floating-point
element without conversion.
The value of the 2-byte integer at the specified address is converted to an 8-byte floating-point
value and is transferred to the floating-point element.
The value of the 4-byte integer at the specified address is converted to an 8-byte floating-point
value and is transferred to the floating-point element.
The value of the 3-digit BCD word at the specified address is converted to an 8-byte
floating-point value and is transferred to the floating-point element.
The value of the 4-digit BCD word at the specified address is converted to an 8-byte
floating-point value and is transferred to the floating-point element.
External Device
FLT4 to Floating Point
Interface
The 4-byte floating-point value at the specified address is converted to an 8-byte floating-point
value and is transferred to the floating-point element.
The 8-byte floating-point value at the specified address is transferred to the floating-point
element without conversion.
Longana Elements
The Allen-Bradley protocol module supports only the following longana conversions:
BIN to Longana
Allen-Bradley
The value of the 4-byte integer at the specified address is transferred to the longana element
without conversion.
INT2 to Longana
The value of the word at the specified address is transferred to the longana element without
conversion.
INT4 to longana
The value of the 4-byte integer at the specified address is transferred to the longana element
without conversion.
BCD3 to Longana
The 3-digit BCD value at the specified address is converted to a 4-byte integer value and is
transferred to the longana element.
BCD4 to Longana
The 4-digit BCD value at the specified address is converted to a 4-byte integer value and is
transferred to the longana element.
The 3-digit BCD value at the specified address is converted to a 4-byte integer value and is
transferred to the longana element.
FLT4 to Longana
The 4-byte floating-point value at the specified address is converted to a 4-byte integer value
and is transferred to the longana element.
FLT8 to Longana
The 8-byte floating-point value at the specified address is converted to a 4-byte integer value
and is transferred to the longana element.
Message Elements
The Allen-Bradley protocol module supports only the following message conversions:
BIN to Message
The values of the words specified in the address are transferred to the message element without
conversion.
ASC to Message
The values of the words specified in the address are copied to the message element with
low-order and high-order bytes inverted.
External Device
Digital Elements
Interface
The Allen-Bradley protocol module supports only the following digital conversion:
Digital to BIN
The value (1 or 0) of the digital element is transferred to the bit at the specified address without
conversion. If no bit number is specified, the value of the digital element is transferred to bit 0
at the specified address.
Analog Elements
The Allen-Bradley protocol module supports only the following analog conversions:
Analog to BIN
Allen-Bradley
The value of the analog element is transferred to the specified address without conversion.
Analog to INT2
The value of the analog element is transferred to the specified address without conversion.
Analog to INT4
The value of the analog element is converted to a 4-byte integer value and is transferred to the
specified address.
Analog to BCD3
The analog value is converted to a 3-digit BCD value and is transferred to the specified
address.
Analog to BCD4
The analog value is converted to a 4-digit BCD value and is transferred to the specified
address.
The analog value is converted to a 3-digit BCD value and is transferred to the specified
address.
Analog to FLT4
The analog value is converted to a 4-byte floating-point value and is transferred to the
specified address.
Analog to FLT8
The analog value is converted to an 8-byte floating-point value and is transferred to the
specified address.
Floating-Point Elements
The Allen-Bradley protocol module supports only the following floating-point conversions:
The value of the floating-point element is transferred to the four-word address without
conversion.
The value of the floating-point element is converted to a 2-byte integer and is transferred to the
specified address.
The value of the floating-point element is converted to a 4-byte integer and is transferred to the
specified address.
The value of the floating-point element is converted to a 3-digit BCD word and is transferred
to the specified address.
The value of the floating-point element is converted to a 4-digit BCD word and is transferred
to the specified address.
External Device
Floating Point to FLT4
Interface
The value of the floating-point element is converted to a 4-byte floating-point value and is
transferred to the specified address.
The value of the floating-point element is transferred to the specified address without
conversion.
Longana Elements
The Allen-Bradley protocol module supports only the following longana conversions:
Longana to BIN
Allen-Bradley
The value of the longana element is transferred to the specified address without conversion.
Longana to INT2
The value of the longana element is converted to a 2-byte integer value and is transferred to the
specified address.
Longana to INT4
The value of the longana element is transferred to the specified address without conversion.
Longana to BCD3
The longana value is converted to a 3-digit BCD value and is transferred to the specified
address.
Longana to BCD4
The longana value is converted to a 4-digit BCD value and is transferred to the specified
address.
The longana value is converted to a 3-digit BCD value and is transferred to the specified
address.
Longana to FLT4
The longana value is converted to a 4-byte floating-point value and is transferred to the
specified address.
Longana to FLT8
The longana value is converted to an 8-byte floating-point value and is transferred to the
specified address.
Message Elements
The Allen-Bradley protocol module supports only the following message conversions:
Message to BIN
The values of the message elements are written to the words specified in the address without
conversion.
Message to ASC
The values of the message elements are written to the words specified in the address with the
low-order and high-order bytes inverted.
External Device
PLC-2 Addresses
Interface
For the Allen-Bradley PLC-2, FactoryLink supports the following address formats:
word
word/bit
word, length
where
word (Required) Word address of the data table in octal
Valid Entry: 0 - 7777 (octal) (The actual high address depends
on the specific PLC that is addressed.)
bit (Optional) Bit address of the specified word in octal
Allen-Bradley
Valid Entry: 0 - 17 (octal) (0 least significant bit; 17 most significant
bit)
length (Optional) Number of words in a message string in decimal
Examples:
17 Word 15 decimal
23/17 Bit 17 of word 23 (word 19 decimal)
7/7 Bit 7 of word 7 (word 15 decimal)
0,100 First 100 decimal words
Note
If you configure PLC-3 and PLC-5 for PLC-2 compatibility, these addresses
are also valid for PLC-3 and PLC-5.
where
W (Optional) Logical word addressing—default if no other addressing type is
specified
filetype (Required) One of the letters specifying a PLC-3 file type shown in Table
11-6.
O Output image 1 1
I Input image 2 1
T Timer 3 3
C Counter 4 3
N Integer 5 1
F Floating-point 6 2
D BCD 7 1
B Binary 8 1
Table 11-6 PLC-3 File Types for Logical Word Addressing (Continued)
11
Type Description Section # Words/Element
A ASCII 9 1
External Device
H High-order integer 10 2
Interface
P Pointer 11 2
S Status 13 1
Allen-Bradley
length (Optional) Number of words in decimal
When you use logical file addressing, all numbers are in decimal, regardless of file type. Bit 16
refers to the least significant bit of the next word in the PLC’s memory.
where
O Output image 1 1
I Input image 2 1
T Timer 3 3
C Counter 4 3
N Integer 5 1
F Floating-point 6 2
D BCD 7 1
B Binary 8 1
A ASCII 9 1
H High-order integer 10 2
P Pointer 11 2
S Status 13 1
FI5:/256 Bit 0 of word 16 of input file 5 (Word 16 is the 17th word in the file.)
FI10/256 Bit 0 of word 26 of input file 0 (Word 26 is the 27th word in the file.) 11
FI5:10/256 Bit 0 of word 26 of input file 5 (Word 26 is the 27th word in the file.)
External Device
FF3:2 Floating-point value 2, floating-point file 3 (Floating-point value number 2
is the 5th and 6th words in this file.)
Interface
Symbolic Word Addressing
where
@ (Required) The symbolic addressing flag character
AAAAAAAA (Required) 1- to 8-character symbolic name defined in the PLC (use only
Allen-Bradley
uppercase characters)
bit (Optional) Bit number in octal
length (Optional) Number of words in message string in decimal
@AAAAAAAA:word
@AAAAAAAA:word/bit
@AAAAAAAA:word,length
where
@ (Required) The symbolic addressing flag character
PLC-5 Addresses
Depending on the file type being addressed, the Allen-Bradley protocol module supports two
formats for addressing PLC-5s.
The Allen-Bradley PLC-5 Input and Output Image tables use two address formats:
filetype:[wordnumber][/bit]
filetype:[wordnumber][,length]
where
filetype (Required) One of the letters (I or O) specifying a PLC-5 Input or Output
Image table
wordnumber (Optional) Word number in octal
Valid Entry: 0 - 777 (default=0)
bit (Optional) Bit address in octal
length (Optional) Number of words in decimal
I:34/17 Bit 17 of word 28 in the Input Image table
O:/0 Bit 0 of Word 0 in the Output Image table
I:,100 First 100 word of the Input Image table
The rest of the Allen-Bradley PLC-5 data table files use two address formats:
11
filetype[filenumber]:[element][.subelement][/bit]
filetype[filenumber]:[element][.subelement][,length]
External Device
where
Interface
filetype (Required) One of the letters specifying a PLC-5 file type shown in the
following table:
S Status 2 1
B Binary 3 1
T Timer 4 3
C Counter 5 3
Allen-Bradley
R Control 6 3
N Integer 7 1
F Floating-point 8 2
A ASCII N/A 1
D BCD N/A 1
filenumber (Optional) File number in decimal. If not specified, file number is assumed
to be the default file number for the file type specified.
Valid Entry: 0 - 999
element (Optional) Element number in specified file in decimal (default=0).
subelement (Optional) Subelement number in decimal (default=0).
bit (Optional) Bit address in decimal.
length (Optional) Number of words in decimal.
N7:23/15 Bit 15 of word 23 of integer file 7. (Word 23 is the 24th word in the file.)
Use the PLC type PLC-250 in the Logical Station table to describe a logical station as a
PLC5-250. This PLC type supports limited native addressing to a PLC5-250.
Create a logical station with a PLC type of PLC-2 for unsolicited reads from the PLC5-250.
The PLC5-250 may then send Unprotected Write (PLC-2 format) commands to the protocol
module. The protocol module ignores any definitions of unsolicited reads on a station with a
PLC type of PLC-250.
Native Addressing
Address Format
spaces Are for readability only; do not include them in the actual address string
brackets [] Are optional in the address string 11
colon (:) Are required in the address string
External Device
MODULE_ID
Interface
If 0, the MODULE_ID is the resource manager; if 1-8, MODULE_ID is a logic processor. If a
logic processor is specified, this number is the value set on the thumbwheel on the front of the
logic processor. If the MODULE_ID is omitted, the resource manager will be assumed.
FILE_ID
The FILE_ID specifies the type of file. It consists of a single uppercase alphabetic character.
Valid FILE_IDs are:
B Binary files
N Integer files
L Long integer files
Allen-Bradley
F Floating-point files
FILE_NUMBER
The FILE_NUMBER specifies which file of the FILE_ID file is addressed. It consists of a 1-
to 4-character decimal number ranging from 0 to 9999. If the FILE_NUMBER is omitted, it is
assumed to equal 0.
FILE_ELEMENT
The BIT_NUMBER and MESSAGE_LENGTH are the same as the other PLC types, except
that the BIT_NUMBER must range between 0 and 15. Bit 0 is the least-significant bit; bit 15 is
the most-significant bit.
The following sample strings illustrate PLC5-250 native mode addressing format:
Address Description
0B14:10/15 The most significant bit of the 11th binary word (address 10) of the 15th
binary file (address 14) in the resource manager
3N5:3 The fourth (address 3) integer element of the sixth (address 5) integer file
in logic processor 3
Use the same conversions (INT2, INT4. . .) as with logical stations of type PLC-5. Refer to
“PLC-5 Addresses” on page 226 for more information.
External Device
The following are the switch settings and addresses for the 1770-KF2 Series B.
Interface
Table 11-10 Switch Settings for 1770-KF2 Series B
1771-KA2
Allen-Bradley
The following are the switch settings for the 1771-KA2.
1771-KE
The following are the switch settings and addresses for the 1771-KE.
1785-KA
The following are the switch settings for the 1785-KA.
12 12 12 12 123 123
DD DD DD DD UDD DUD
External Device
Logical Station Control Panel” on page 196. For information about configuring an analog tag,
see “Configuring the Logical Station Information Panel” on page 200.
Interface
For information about the messages displayed for the EDI task and the format in which
protocol module messages are generated, see Chapter 10, “Messages and Codes.”
The ER:xxxx string in a message can contain a single-digit or a double-digit error code. In
following descriptions, N represents significant digits and x represents digits not significant to
the error.
• Single-Digit Code Format
ER:xxxN is a single-digit format in which one digit represents a single error condition. In
some cases, two individual codes appear within a string to indicate multiple error
conditions.
• Double-Digit Code Format
Allen-Bradley
ER:xxNN is a double-digit format in which two digits represent a single error condition.
Single-Digit Codes
Hexadecimal error codes 0001 through 000F are Allen-Bradley protocol module internal
errors:
Error
Description
Message
0008 Invalid extended status (above 080h) from Data Highway Interface
Error
Description
Message
Double-Digit Codes
Error codes received from the Data Highway interface can signify Local, Extended, or Remote
STS errors.
EDI error codes from 0010 through 001F denote Local STS errors received from the Data
Highway Interface. Read the least significant nibble of the EDI error code to obtain the local
error code.
Table 11-16 Local STS Errors Received from the Data Highway Interface
Error
Description
Message
0012 Remote node specified does not acknowledge (ACK) the command
message
External Device
Table 11-17 Remote STS Errors Received from the Data Highway Interface
Interface
Error Code Description
0024 The host could not complete function because of hardware fault
Allen-Bradley
0027 Processor is in program mode
EDI error codes above 002F denote Extended STS errors received from the Data Highway
interface. Subtract 0030 from the EDI error code to obtain the Extended error code.
Table 11-18 Extended STS Errors Received from the Data Highway Interface
Error
Description
Message
Error
Description
Message
0038 Cannot complete request; situation has changed since the start of the
command
Note
•
•
•
•
General Electric
12
External Device
Interface
This chapter contains information needed to set up and configure bidirectional
communications between the FactoryLink real-time database and one or more
General Electric devices, using GE CCM protocol.
When you choose General Electric Fanuc from the Configuration Manager Main
Menu, the General Electric configuration panels are displayed:
General Electric
Note
To bring the Logical Station Control panel to the foreground, click its title bar in
the display of all configuration panels.
Complete a row for each logical port specified in the External Device Definition
panel you want to define as a communication path for read and write operations.
Logical Port Enter a number, defined in the External Device Definition panel
Logical Port column, to represent a particular communication path
to a device.
Valid Entry: previously defined logical port number
(default=0)
Baud Rate Enter the speed at which the protocol module communicates with
the devices linked to FactoryLink via this logical port. This entry 12
must match the baud rate configuration of the devices. Refer to
the device manufacturer’s documentation for details.
Valid Entry: 110 - 115200 (default=9600)
External Device
Parity Enter the parity error correction during transmission via this
Interface
logical port. This entry must match the configuration of the
devices communicating via this port. Refer to the device
manufacturer’s documentation for details.
Valid Entry: none, even, odd (default=none)
Data Bits Enter the number of data bits used during transmission via this
logical port. This entry must match the configuration of the
devices communicating via this port. Refer to the device
manufacturer’s documentation for details.
Valid Entry: 8
Stop Bits Enter the number of bits sent after a character to create a pause
before the start of the next character. This entry must match the
configuration of the devices communicating via this port. Refer to
the device manufacturer’s documentation for details.
Valid Entry: 1
Timeout Enter the length of time, in tenths of a second, the protocol
module will wait to receive a response to a read or write command
before timing out. You must enter a value greater than 0 for the
protocol module to timeout.
Valid Entry: 0 - 9999 (default=20 or 2 seconds)
Status Msg (Optional) Enter a tag name for a message element to which a
Tag Name text string will be written to indicate a communications error
associated with this logical port.
For information about displaying the text stored in a Status Msg
Tag Name element for an operator using this application, see the
General Electric
Application Editor User Guide.
Valid Entry: standard element tag name
Valid Data Type: message
When the panel is complete, click Enter to validate the information. Define the
data type (message) for any tag names displayed in the Tag Definition dialog.
External Device
Interface
Complete a row for each device to communicate through this logical port.
Error/Status Tag (Optional) Enter a tag name for an analog element in which to
Name store communications error codes associated with this device
(logical station).
For information about displaying the codes stored in an
Error/Status Tag Name element for an operator using this
application, see the Application Editor User Guide.
Valid Entry: standard element tag name General Electric
Valid Data Type: analog
Logical Station Enter a number to identify the logical station to which the
(Decimal) information in this row pertains. A logical station represents the
combination of a logical port with a physical station. Assign a
unique number to each device communicating through this
logical port.
When the panel is complete, click Enter to validate the information. Define the
data type (analog) for any tag names displayed in the Tag Definition dialog.
Table 12-2 provides sample entries for the General Electric Logical Station
Information panel: 12
Table 12-2 Sample General Electric Logical Station Information Panel
External Device
Field Entry Description
Interface
Error/Status Tag Name GENE_STATION0_ Contains information about
STATUS communication errors.
General Electric
Tip
Table Name Give this read or write request a name. Define one request (table)
per line and do not include spaces in the name. You can define as
many tables in this panel as available memory allows. Try to
make the table name reflective of the operation it represents.
External Device
Valid Entry: alphanumeric string of up to 16 characters
Interface
Exception Write For EDI to interpret this operation as a triggered block write or
as a read operation, accept the default of NO.
For EDI to interpret this operation as an exception write and
write element values to the device only when those values
change, enter YES.
In an exception write, an internal change-status indicator within
the element containing the data to be written prompts the write
operation. If an element is configured for an exception write and
EDI recognizes this indicator has been set since the last scan of
the real-time database (indicating the value of the element has
changed), EDI writes this element’s value to the device.
Valid Entry: yes, no
Tip
Block Read If this is a block read operation, enter a number to indicate the
Priority priority of this table, relative to other read operations. The
highest priority is 1. This number influences the order in which General Electric
the EDI task handles the queuing of block read requests. If EDI
receives two requests at the same time, it processes the request
with the highest priority first. The default is 1.
Note
The Block Read Trigger, Block Read Disable, Block Read Complete, and
Block Read State elements apply only to triggered read operations.
Do not define these elements for write operations.
Tip
External Device
Information panel have been updated in the FactoryLink
Interface
database, the complete element is forced to 1 again.
Do not use this element when more than one logical port is
specified in a single table.
Valid Entry: standard element tag name
Valid Data Type: digital
Block Read State If this is a write operation, ignore this field.
If this is a triggered read operation, this field is optional. If you
need a digital element to indicate the state of this operation (in
progress or complete), enter a tag name. This element is forced to
1 (ON) at startup. While the table is being processed, the element
is set to 0 (OFF). After the elements defined in the Read/Write
Information panel have been updated in the FactoryLink
database, the state element is forced back to 1.
Valid Entry: standard element tag name
Valid Data Type: digital
Block Write If this is a block or exception write operation, enter a number to
Priority indicate the priority of this table, relative to other write
operations. The highest priority is 1. This number influences the
order in which the EDI task handles the queuing of write
requests. If EDI receives two requests at the same time, it
processes the request with the highest priority first. The default
is 1.
If this is a read operation, accept the default of 1. This field
defaults to 1 regardless of whether the operation being defined is
a block or exception write. General Electric
Valid Entry: 1 - 4 (default=1)
Note
The Block Write Trigger, Block Write Disable, Block Write Complete, and
Block Write State elements apply only to write operations. Do not
define these elements for read operations.
Tip
Block Write If this is a read or exception write operation, ignore this field.
Complete
If this is a block write table, this field is optional. If you need a 12
digital element to indicate when this operation is complete, enter
a tag name. This element is forced to 1 (ON) at startup. After the
data defined in this table’s Read/Write Information panel has
External Device
been written to the device, the complete element is forced to 1
Interface
again.
Do not use this element when more than one logical port is
specified in a single table.
Valid Entry: standard element tag name
Valid Data Type: digital
Block Write State If this is a read or exception write operation, ignore this field.
If this is a block write operation, this field is optional. If you need
a digital element to indicate the state of this operation (in
progress or complete), enter a tag name. This element is forced to
1 (ON) at startup. While the table is being processed, the element
is set to 0 (OFF). After the data defined in this table’s Read/Write
Information panel has been written to the device, the state
element is forced back to 1.
Do not use this element when more than one logical port is
specified in a single table.
Valid Entry: standard element tag name
Valid Data Type: digital
When the panel is complete, click Enter to validate the information. Define the
data type (digital) for any tag names displayed in the Tag Definition dialog.
General Electric
External Device
Interface
For a Read Table—Add a panel entry for each FactoryLink database element in
which data read from the device will be stored when the operation executes.
For a Write Table—Add a panel entry for each element to be written when the
operation executes.
Tip
External Device
D_REG Series 1, and 3 Data Registers
PORT Port ON/OFF
Interface
Channel Enter the channel number in the controller on which the address
is located.
Valid Entry: 0 - 15
This channel number is valid for Series 6 and the following data
types: REAL_O, REAL_I, DESC_O, and DESC_I.
Address For a read table, enter the address in the device’s memory where
Dec the value to be stored in this element is located.
For a write table, enter the address in the device’s memory to
which the element value will be written.
Valid Entry: 1 - 16384 (decimal address for Series 5 and 6,
9030, 9070)
Address For a read table, enter the address in the device’s memory where
Octal the value to be stored in this element is located.
For a write table, enter the address in the device’s memory to
which the element value will be written.
Valid Entry: 1 - 10000 (octal address for Series 1, 1+ JR, and 3)
Bit This field is required for digital data type. If the element (entry in
Offset the Tag Name column) associated with this entry is digital, enter
the bit offset within the word that contains the value to be read or
to which the element value is to be written. Bit 1 is the most
significant bit (MSB) and bit 16 is the least significant bit.
Leave this field blank for all other FactoryLink data types. General Electric
Valid Entry: 0 - 15
If you enter a FactoryLink digital element in the Tag Name field
and specify the data type as REG, TIMER, or D_REG, the
protocol module reads the Bit Offset; otherwise, it is ignored.
When the panel is complete, click Enter to validate the information. Define the
data type (digital, analog, long analog, or floating-point) for any tag names
displayed in the Tag Definition dialog.
External Device
configuring a message tag, see “Configuring the Logical Station Control Panel” on
page 238. For information about configuring an analog tag, see “Configuring the
Interface
Logical Station Information Panel” on page 241.
For information about the messages displayed for the EDI task and the format in
which protocol module messages are generated, see Chapter 10, “Messages and
Codes.”
ER:xxxx
The ER:xxxx string can contain a single-digit or a double-digit error code. In the
examples shown below, N represents significant digits and x represents digits not
significant to the error.
• Single-Digit Code Format
ER:xxxN and ER:xxNx are single-digit formats in which one digit represents a
single error condition.
• Double-Digit Code Format
ER:xNNx is a double-digit format in which two digits represent a single error
condition.
If you define message elements in the General Electric Logical Station Control
panel for all logical stations on this logical port, the protocol module copies these
error messages in the following format:
GENE read request status: [1]. GE error: [2]
GENE read response for write request: [1]. GE error: [2]
GENE write response: [1]. GE error: [2]
General Electric
where
[1] is one of the message codes 1 - 4 listed in Table 12-5 on page 256.
This message code is displayed as a text string.
[2] is one of the message codes 1 - F listed in Table 12-6 on page 256.
This message code is displayed as a text string.
Single-Digit Codes
The following tables list the single-digit error codes that can be generated and
displayed by the General Electric protocol module.
External Device
xxBx XMIT_NAK_ERR Error transmitting NAK message
Interface
xxCx RCV_ENQ_TIMEOUT Timeout error receiving ENQ
message
Double-Digit Codes
The double-digit format is displayed in the error string’s middle two digits. This
format contains a 1 in the hundredth’s position (ER: x1Nx). Table 12-7 lists the
double-digit error codes that can be generated and displayed by the General
Electric protocol module.
•
•
•
•
General Purpose
Interface 13
External Device
Interface
The General Purpose Interface (GPI) protocol module provides a communication
interface between a FactoryLink application and external devices using
asynchronous communication techniques and protocols such as ASCII or binary.
The GPI is a general purpose protocol module that was written for no specific
external device.
You can use the GPI protocol module with a variety of devices. To determine the
cable connections needed to set up your particular external device, refer to the
documentation available from the manufacturer.
General Purpose
Interface
External Device
asynchronous protocols at the FactoryLink application level.
Interface
While it is quite flexible, the GPI protocol module cannot support every
asynchronous protocol. Since the GPI was not written for a specific device, it is
difficult to describe all of its capabilities and limitations. To determine if the GPI
is suitable for your particular application, evaluate it based on the following
concerning its capabilities and limitations. Then, decide if the GPI is suitable for
your specific external device.
Capabilities
The GPI has the following capabilities:
• Handles more than one protocol at a time.
General Purpose
• Communicates with more than one device at a time.
• Makes available a wide selection of checksum routines.
Interface
• Handles up to eight different response formats for an outgoing message. Each
response must share the same end-of-response indicator. (For example, if eight
response tables define the response formats, each table might have the
response data length in field 2).
Limitations
In general, the GPI has the following limitations:
• Permits only single handshaking protocols
• Lacks support for protocols which require checksums to handle
special-character sequences
• Lacks support for protocols which require character substitutions for
special-character sequences
Note
When you choose General Purpose Interface from the Configuration Manager Main
Menu, the GPI configuration panels are displayed.
External Device
Interface
General Purpose
Interface
Complete a row for each logical port specified in the External Device Definition
panel you want to define as a communication path for read and write operations.
Logical Enter a number, defined in the External Device Definition panel
Port Logical Port column, to represent a particular communication path
to a device.
Valid Entry: previously defined logical port number
(default=0)
LPORT Status (Optional) Enter a tag name for a message element to which a
Message Tag text string will be written to indicate a communications error
associated with this logical port.
For information about displaying the text stored in an LPORT
Status Message Tag element for an operator using this
application, refer to the Application Editor User Guide.
Valid Entry: standard element tag name
Valid Data Type: message
Inter Char Enter the maximum amount of time, in tenths of a second, the
Timeout protocol module allows between the reception of two consecutive 13
(0.1 Sec) characters.
Valid Entry: 1 - 32000 (default=30 or 3 seconds)
External Device
Unsolicited This field is required for the protocol module to time out while in
Timeout unsolicited mode.
Interface
(0.1 Sec)
Enter the maximum amount of time, in tenths of a second, the
protocol module will wait to receive the first character of a device
response after an outgoing command table that puts the GPI in
unsolicited mode is triggered. For the protocol module to time out,
you must enter a value greater than 0.
Valid Entry: 1 - 32000 (default=30 or 3 seconds)
Send Buff Size Specify the size of the buffer required to hold the outgoing
message (the response command).
Valid Entry: 256 - 32000 (default=1024 bytes)
Receive Buff Size Specify the size of the buffer required to hold the incoming
General Purpose
response (the response data).
Valid Entry: 256 - 32000 (default=1024 bytes)
Interface
Device Type (Optional) Enter reference information about the device type.
Valid Entry: alphanumeric string of up to 10 characters
Protocol Type (Reserved for future use)
Port On/Off Enter a tag name for a digital element to temporarily disable the
sending and receiving of messages to and from devices
communicating via this port. When this element’s value is 1, the
port is disabled for GPI messages.
Valid Entry: standard element tag name
Valid Data Type: digital
CAUTION
When the panel is complete, click Enter to validate the information. Define the
data type (message) for any tag names displayed in the Tag Definition dialog.
External Device
Interface
General Purpose
Interface
Complete a row for each device to communicate through this logical port.
LSTA Status (Optional) Enter a tag name for an analog element in which to
Analog Tag store communications error codes associated with this device
(logical station).
You can animate output-text objects to display the codes stored in
an Error/Status Tag Name element on a graphics screen. For
more information, see the Application Editor User Guide.
Valid Entry: standard element tag name
Valid Data Type: analog
When the panel is complete, click Enter to validate the information. Define the
data type (analog) for any tag names displayed in the Tag Definition dialog.
External Device
and a response coming from the external device to the GPI (an “incoming
response,” which you configure as a response).
Interface
A GPI Command/Response table consists of two panels: GPI Command/Response
Control and GPI Command/Response Information. Because you use the same type
of GPI Command/Response table to configure both commands and responses, it is
important to be able to distinguish between a command table and a response
table. The panels are referred to with the type of table being configured in
boldfaced, italicized type to help you readily identify the type of table being
discussed in this chapter.
General Purpose
The panel name is displayed in regular italicized text when the panel referred to
could apply to either a command or a response table.
Interface
Use the GPI Command/Response table to define:
• The outgoing message sent by the GPI (in a command table)
• The information needed to parse the incoming response from the external
device (in a response table)
Note
If you expect a response to the outgoing message, you must configure the
command table to specify one or more other response tables that define the
possible responses to the outgoing message.
The section, “Summary of Basic Concepts” on page 289 contains a diagram that
shows how these concepts relate to one another.
Response Table
The response table defines the information needed to parse an incoming response
to an asynchronous communication (outgoing message). The entries consist of the
following information:
• Data to be parsed out of the response, converted, and returned to FactoryLink
elements
• Special characters (such as preamble/postamble strings or delimiters)
• Special processing (such as checking embedded message lengths,
checksumming, data format conversions, or mathematical functions)
The GPI parses the incoming response from the external device and matches it to
the incoming response formats. The GPI then extracts the relevant data from the
incoming response and writes it to the FactoryLink elements.
External Device
Interface
General Purpose
Interface
Complete a row for each command or response table you want transmitted to a
device. Each row represents a table and includes the table name, table type, and
(for a command table) one or more trigger elements.
Table Name Give this command or response table a name. Define one table
per line and do not include spaces in the name. You can define as
many tables in this panel as available memory allows. Try to
make the table name reflective of the operation it represents.
When the Command Trigger element is forced to 1 (ON),
FactoryLink processes this table and any other table in which the
same trigger is defined.
Valid Entry: alphanumeric string of up to 16 characters
Enable For EDI to interpret this table as an outgoing command, accept
Response the default of NO.
For EDI to interpret this table as an incoming response, enter
YES or FORCE to indicate whether all change-status indicators
are to be set to 1 (ON) when an incoming response occurs, or just
the ones for values that have changed.
Note
External Device
table.
Interface
Valid Entry: standard element tag name
Valid Data Type: digital
Tip
General Purpose
Disable
If this is an outgoing command table you plan to periodically
disable, this field is optional. Enter a tag name for a digital
Interface
element to disable the operation defined in the
Command/Response Information panel. When this element’s
value is forced to 1 (ON), the operation is not executed, even when
the Command Trigger element is set to 1.
To re-enable a command table that has been disabled, set this
element back to 0 (OFF).
Tip
External Device
protocol and the processing needed to format one outgoing message to the external
device. In addition, the GPI Command/Response Information panel identifies one
Interface
or more responses to the communication. The entries in the GPI
Command/Response Information panel consist of data from FactoryLink
elements; special characters such as preamble/postamble strings or delimiters;
and special processing such as computed message lengths, checksumming, data
format conversions, or mathematical functions.
Each line of the GPI Command/Response Information panel specifies one of the
following GPI functions:
• Defines a field of the outgoing message or incoming response
• Modifies a previously defined field
• Specifies a method to detect the end-of-expected-response to the outgoing
General Purpose
message in this table
• Defines STAT_TAG elements to report the status of transactions
Interface
• Defines the connector (unique response ID) between the outgoing message and
its plausible incoming response
CAUTION
For further information about configuring the GPI for the unsolicited mode, refer
to “Putting the Protocol Module in Unsolicited Mode” on page 299.
From the Command/Response Control panel, select the row for the table you are
configuring and click Next to bring the Command/Response Information panel to
the foreground.
Tag Name For a read table, specify a tag name for an element in which
FactoryLink will store the data read from the device. For a write 13
table, specify a tag name for an element containing a value to be
written to the device.
Valid Entry: standard element tag name
External Device
Valid Data Type: digital, analog, longana, float, message
Interface
Field Type Specify either the source of the field value, an end-of-response,
the command/ response table link, the debug status of the
outgoing message or incoming response, or notification to the
application that database updates for the response are done. To
determine what to enter, use the following descriptions:
To specify the source of the field value:
General Purpose
STRING The field’s value is specified in the Constant
String column for this row.
Interface
NUMERIC The field’s value is specified in the Constant
Numeric column for this row.
External Device
a numeric value. The message element
Interface
reports an informative message. Enter
STAT_TAG in the Field Type column and the
element name in the Tag Name column.
General Purpose
STAT_TAG entry).
Note that because of the DB_DONE tag is
Interface
only set when tag values have been updated,
it cannot be used with a response packet type
of MULT_RSP (see definition of Response
Packet).
Allowed DB_DONE tag types are digital,
analog, float, long analog, or message. The tag
is set to 1 or “1” for a message tag. It is the
responsibility of the application to clear the
tag if required.
Field Pos. Enter a decimal number to identify this field’s position in the
completed communication message.
Valid Entry: 1 - 999
Field Len. Enter a decimal number to identify the field’s length in bytes.
Valid Entry: 1 - 999 (bytes)
Response ID If you enter RESP_ID in the Field Type column, this field is
required. Define a unique numeric identifier that specifies which 13
response format from a GPI Command/Response Information
panel to use to parse the reply to this command. Every incoming
response defines one unique identifier (ID). Every outgoing
External Device
message references from 1 to 8 response Ids.
Interface
Valid Entry: 1 - 255
Response LN, If you enter RESP_FXD, RESP_VAR, RESP_TM, or RESP_STR
POS, TM in the Field Type column, this field is required. Define the length,
position, or timeout of the expected response. Depending upon the
conditions, you might also need to enter information in the Field
Type column, the Constant String column, or both.
Valid Entry: 1 - 999
If: Enter:
General Purpose
response length in advance column, and the response
length in this column
Interface
You do not know the response RESP_VAR in the Field Type
length in advance but it is column, and the position of the
given at the beginning of the byte specifying the length in
response this column
External Device
to know only the byte’s value and its position in the message.
Interface
Enter the following information in the columns of the command tables you
configure to describe these bytes:
• The Field Type, which specifies where to obtain or enter the field’s value
• The Field Pos, which specifies the field’s position in the outgoing message or
incoming response
Note
Throughout this chapter, the term “column” refers to areas for data
within the GPI configuration tables, and the term “field” refers to
the fields of a communication message. When you enter
General Purpose
information in the columns of a command or response table, you
are configuring an outgoing message or an incoming response
Interface
containing fields that are composed of bytes.
If you do not know the value of a field or byte at configuration, the value must be
calculated at run time. If you know the value at configuration, then specify it as a
constant (numeric or string). If the field’s value must be calculated at run time,
the value must come either from a FactoryLink element or from the result of a
calculation on other fields. For example, a checksum value may be the result of an
exclusive-or (XOR) on the bytes of an outgoing message. Refer to “Using Process
Functions” on page 302 for further information about the process function XOR.
The next sections provide the following information for these components:
• A diagram of the format and sources of information in the outgoing message
• A discussion of the field entries
• A sample GPI Command/Response Information panel for a command table
The illustration describes only one possible scenario. In this diagram, the
breakdown of the outgoing message into fields and the length of each field is
provided to clarify and to demonstrate the various parts of an outgoing message.
Using other features of the GPI, you could construct other divisions or
combinations.
13
External Device
Interface
General Purpose
Interface
The fields described in the following table correspond to the fields in the outgoing
message illustrated in the previous diagram.
Field Description
Field 2 Two-byte Device Address whose value comes from the analog
element, ATAG.
Field 3 One-byte digital Data field consisting of 8-bits where only bit6,
bit4, and bit2 change during the command; these correspond to
digital elements DTAG6, DTAG4, and DTAG2, respectively. The
other bits do not change.
Field Description
Field 4 Four-byte Data area whose value comes from the floating point
element, FTAG.
Field 5 Ten-byte Data area whose value comes from the message
element, MTAG.
Constan Constan
Tag Field Field Field Bit Process
Fld# Fld# Arg. tNumeri t Comment
Name Type Pos Len Pos. Funct.
c String
External Device
* PROCESS 6 1 * XOR 2 5 * * * Checksum
Interface
* STRING 7 1 * * * * * * \x03 ETX
For simplification purposes, some of the columns in this panel are omitted. For a complete
GPI Command/Response Information panel, refer to “Configuring the Command/Response
Control Panel” on page 271.
Note: An asterisk (*) indicates a “don’t care” entry. The GPI does not need this entry and will
not use it.
General Purpose
Interface
Status/Debug Levels
When enabled, this feature logs information about the steps the GPI protocol
module takes to compose each outgoing message and to parse each incoming
response. You can use the logged information to debug the application. Disable
this feature during normal operations.
STAT_ON Reports analog error values and message error text to the
FactoryLink element
LOG2 Reports LOG2 plus prints the analog error value and error
message to the screen
For further information about the Debug/Status Level, refer to the “Configuring
the Command/Response Control Panel” on page 271.
RAW VALUE
This feature allows up to 255 bytes of the incoming response to be read into a
FactoryLink message element before parsing the response.
STAT_TAG
This feature provides alphanumeric status information at different stages of the
GPI response or command operation. This information is then passed on via
FactoryLink analog and message elements.
External Device
this outgoing message, the value and position of these bytes is of major concern.
• The value of the bytes is either known at the time of configuration or the
Interface
value is obtained at run time.
• The position of each field/byte is always known at configuration.
• The format of the outgoing message is described to the GPI protocol module via
an outgoing message configured in a command table.
• The format of the incoming response is described to the GPI protocol module via
an incoming response configured in a response table.
• At configuration, through unique identifiers (IDs), you correlate the command
and response tables.
General Purpose
unique ID (configured in the ID field of the GPI Command/Response Information
panel).
Interface
Command Table
ID 101
Response Table
ID 101
GPI F UNCTIONS
13
This section describes the functions of the GPI protocol module and shows the
relationships among the different columns of the GPI configuration tables.
External Device
The sample tables omit some fields to simplify some of the discussions in this
section. Refer to “Configuring the Command/Response Control Panel” on page 271
Interface
for complete descriptions of the entries in the GPI configuration tables.
Principles of Operation
You must configure the GPI Command/Response tables with the following
information to enable communications to occur between a FactoryLink application
and an external device via the GPI protocol module:
• The format of the outgoing message
• The format of the incoming response from the external device
General Purpose
The GPI Command/Response table describes the external device protocol to the
GPI in a “language” the GPI understands. The GPI provides this language as a set
Interface
of tools for you to use to set up communications.
External Device
Field Type
Interface
Specify an entry (RESP_FXD, RESP_VAR, RESP_TM, or RESP_STR) in the Field
Type column for each entry in the Response Packets column.
Response Packet
In the command table, specify which of the following types of response packets you
expect to receive from the external device:
• No response – If you do not expect a response to the outgoing message, do not
configure a response table (so there will be no unique response identifier).
• Single-packet response – If you expect a single-packet response, the GPI
protocol module can return the entire incoming response to the FactoryLink
real-time database as the response to a single outgoing message.
General Purpose
• Multiple packet and buffered responses – If you expect a multiple-packet
response, the collection of data may be too large for a single response table
Interface
(incoming message) to handle. To transfer large amounts of data to the
FactoryLink real-time database from the GPI internal buffers, you may need to
trigger the response table several times. To do this, enter MULT_RSP in the
Response Packet column of the outgoing message. The MULT_RSP command
sets up the queues for the internal buffer but returns no packets until another
outgoing message with BUFR_RSP is triggered. Repeat this triggering as
needed until the GPI processes all the buffered data in the Response Packet
column.
Table 13-4 describes the valid entries for the Response Packet column in the GPI
Command/Response Information panel of a command table:
Note
Define the format of the incoming message (the expected response) in the GPI
Command/Response Information panel for the response table using real-time
database elements so the GPI can return the response to the FactoryLink
database. Like the outgoing message, the incoming response is composed of fields
or bytes. Indicate the position of each field of the incoming response by
configuring the position in the Field Pos column of the response table’s GPI
Command/Response Information panel.
External Device
• If the field’s value is to be returned to FactoryLink, enter the keyword
TAGVALUE in the Field Type column and an element name in the Tag Name
Interface
column.
• If the field type is NUMERIC or STRING, then the GPI protocol module parses
the field as a response delimiter and expects to find the content of the field in
the Constant Numeric and Constant String columns.
Refer to “Defining the Outgoing Message” on page 291 for further information
about entries for the columns of the incoming response.
General Purpose
response:
Interface
In the GPI Command/Response Information panel, for the outgoing message and
incoming response, enter an identification (ID) number in the Response ID column
and the keyword RESP_ID in the Field Type column.
External Device
• Field Type
Interface
• Response LN, POS, TM
• Constant Numeric
• Constant String
Define how the GPI protocol module detects an end-of-response for each outgoing
message. In the Field Type column of the GPI Command/Response Information
panel, enter one of the end-of-responses described; if indicated, also enter
corresponding information in the Response LN, POS, TM column:
RESP_FXD If the external device returns a fixed response, enter RESP_FXD
in the Field Type column. In the Response LN, POS, TM column,
enter the length of the response in bytes. To determine the type of
response, refer to documentation for your specific external device.
General Purpose
RESP_VAR If the external device returns a variable length response, enter
Interface
RESP_VAR in the Field Type column. In the Response LN, POS, TM
column, enter the byte position in the response that specifies the
number of bytes to follow before you reach the end of the
response. To determine the type of response, refer to
documentation for your specific external device.
RESP_TM If the GPI receives the response length in a reasonable amount of
time, enter RESP_TM in the Field Type column. Also, enter the
response time in the Response LN, POS, TM column.
RESP_STR If special characters terminate the response, enter RESP_STR in
the Field Type column. Also, enter the special characters in the
Constant String column.
Note
After the entry \x, you must enter two hexadecimal digits.
Table 13-5 lists special non-printable characters used with the GPI protocol
module: 13
Table 13-5 Non-Printable Characters Used With the GPI Protocol
External Device
Non-Printable Characters
Interface
\t or \T Tab
\n or \N New line
\r or \R Carriage return
\\ Backslash (\)
A response can be terminated by a special string of characters; some are fixed and
some are variable (such as a checksum). Use the fixed characters to detect the end
of a response, but ignore the variable characters. Treat the variable characters
like “don’t care” characters and enter \xxx in the variable character’s position(s)
General Purpose
in the string.
Interface
Initiating a Transmission
Use the Command Trigger column in the outgoing message command table’s GPI
Command/Response Control panel to initiate a transmission. To initiate the
transmission of an outgoing message, trigger the command table’s GPI
Command/Response Information panel that defines the outgoing message.
If your application requires that the GPI receive data from an external device
without requesting it, then you must configure and trigger a GPI
Command/Response Information panel with no field positions specified. (In other
words, do not build an outgoing message.) This puts the GPI in unsolicited mode.
For information about putting the protocol module in solicited mode, refer to
“Defining the Outgoing Message” on page 291.
If you configure the proper real-time database elements, the GPI can report the
status of each outgoing message or incoming response to FactoryLink.
Enter the element name in Tag Name column of the GPI Command/Response
Information panel and the keyword STAT_TAG in the Field Type column. Define a
separate set of elements for each outgoing message and incoming response.
Note
You should use different elements for the STAT_TAG entry for
different tables. If you use the same set of elements for the
STAT_TAG in different tables, information from one table
overwrites information from another table.
External Device
• Field Type
Interface
• Field Pos
• Field Len
• Conversion Function
General Purpose
element can be converted to ASCII before transmission.
Interface
In the incoming response, when parsing the received response and returning
values to FactoryLink, similar conversions are possible.
For further information about each process function, refer to “Using Process
Functions” on page 320
In the outgoing message and the incoming response, you can associate a
FactoryLink digital element to a bit and can also map up to eight FactoryLink
digital elements into a single byte.
To link a digital element to a bit of a field, enter the FactoryLink digital element
in the Tag Name column of the GPI Command/Response Information panel, and 13
the position of the bit (1 through 8) in the Bit Pos column. For all digital elements
accessing the same byte, the field position will be the same. Enter one (1) in the
Field Len column.
External Device
Interface
Note
Bit 1 is the LSB (Least Significant Bit) and bit 8 is the MSB (Most
Significant Bit) of the byte.
General Purpose
• Field Type
• Process Function
Interface
• Constant Numeric
• Constant String
Note
If you know the value of a field at configuration, then you can specify it as a
numeric constant or string constant. If the value must be determined at run-time,
then it either comes from a FactoryLink element or results from a calculation. For
example, an LRC value is the result of XOR (exclusive-or) on specific bytes of an
outgoing message.
Extracted from a FactoryLink element TAGVALUE for Field Type, the element
at run-time name for Tag Name, and the length of
the field for Field Len
By making multiple entries that reference the same Field Position column in the
command table, you can modify the same field more than once. For example, use
the process function LEN to calculate the number of bytes in a range of fields.
Enter the result in the field being defined. Finally, use either the process function
ADD or SUB to add or subtract a number from this value.
GPI C ONFIGURATION
13
This section illustrates how to configure an outgoing message for the GPI to
communicate with the PMD 300 Programmable Message Display.
External Device
Configuration Example
Interface
This section provides configuration table entries for an outgoing message from the
GPI and for an expected incoming response from a PMD 300 programmable
device. The outgoing message contains instructions for displaying operator
messages. The incoming response parameters and tags prepare FactoryLink for
the expected reply from the device.
The PMD 300 is an intelligent, alphanumeric display panel that interfaces with
any type of controller. The device provides complete information about machine or
process diagnostics, operator prompting, and fault indications. For further
information about the PMD 300, refer to the manufacturer’s documentation.
External Device
numerous panel entry columns.
Interface
OUTGOING_MSG
Field
Bit
Tag Name
Field Field Field Pos....
Type Pos. Len.
NUMERIC 1 1
PROCESS 2 1
NUMERIC 3 1
NUMERIC 4 1
NUMERIC 5 1
NUMERIC 6 1
PROCESS 7 1
Field
Bit
Tag Name
Field Field Field Pos....
Type Pos. Len.
RESP_VAR
RESP_ID
Process Function
LEN 2 13
External Device
...Process
Arg....
Function
Interface
Fld# Fld#
LEN 7 11
cb1_0 (digital)
cb1_4 (digital)
cb1_6 (digital)
cb2_4 (digital)
cb2_6 (digital)
cb3_0 (digital)
cb3_1 (digital)
cb3_2 (digital)
cb3_3 (digital)
cb3_4 (digital)
cb3_5 (digital)
cb3_6 (digital)
scrlmsg (message)
XOR 2 11
ONESCOMP 12
Process Function
stat_msg (message)
stat_ana (analog)
cb1_0 (digital)
cb1_4 (digital)
cb1_6 (digital)
cb2_4 (digital)
cb2_6 (digital)
Table 13-9 OUTGOING_MSG: Conversion Function through Resp. LN, POS, TM (Continued)
13
Conversion Function Response
Tag Name...
...Conversion Format Response Response
External Device
Function String ID LN, POS, TM...
Interface
cb3_0 (digital)
cb3_1 (digital)
cb3_2 (digital)
cb3_3 (digital)
cb3_4 (digital)
cb3_5 (digital)
cb3_6 (digital)
scrlmsg (message)
111
stat_msg (message)
stat_ana (analog)
Response Command/Response
Tag Name... Comment
...Response Constant Constant
Packets Numeric String
170 Hex AA
CMD Length
Response Command/Response
Tag Name... Comment
...Response Constant Constant
Packets Numeric String
16 Unit Addr
2 Unit Addr
2 Msg Len
1 Ctrl
Msg Len
Exclusive-Or
One’s Complement
External Device
Packets Numeric String
Interface
sngl_rsp Response Variable
Response ID
INCOMING_RSP
Field
Bit
Tag Name
Field Field Field Pos....
Type Pos. Len.
NUMERIC 1 1
length TAGVALUE 2 1
uaddr TAGVALUE 3 2
NUMERIC 4 1
reply TAGVALUE 5 1
error TAGVALUE 6 1
cksum TAGVALUE 7 2
Field
Bit
Tag Name
Field Field Field Pos....
Type Pos. Len.
RESP_ID
astring STAT_TAG
mstring STAT_TAG
Process Function
length
uaddr
reply
error
cksum
astring
mstring
External Device
Function String ID LN, POS, TM...
Interface
length
uaddr HI-LOW16
reply
error
cksum HI-LOW16
astring
mstring
Response Command/Response
Tag Name... Comment
...Response Constant Constant
Packets Numeric String
170 Hex AA
length Length
0 Place Holder
(Delimiter)
Response Command/Response
Tag Name... Comment
...Response Constant Constant
Packets Numeric String
Response ID
8, 9, 10 These are control bytes. The PMD 300 customizes the string
displayed on its screen using the value of these control bytes. The 13
FactoryLink application controls the PMD device’s capabilities by
linking various digital elements (up to eight per byte) to
individual bits of these control bytes. This provides much
External Device
flexibility at the application level.
Interface
This example defines the digital elements in the following
manner:
The FactoryLink application links three digital elements—
CB1_0, CB1_4, and CB1_6—to bits 1, 5, and 7 of field 8 (control
byte 1).
The FactoryLink links two digital elements—CB2_4 and CB2_6—
to bits 5 and 7 of Field 9 (control byte 2). (Field 7 in this example
is the second control byte for the PMD 300 protocol.)
The FactoryLink application links seven digital elements—cb3_0,
CB3_1, CB3_2, CB3_3, CB3_4, CB3_5, and CB3_6—to field 3
(control byte 3).
11 TAGVALUE. The FactoryLink message element SCRLMSG,
which is 56 bytes long and linked to field 11, contains the string
that the PMD 300 will display on screen.
12, 13 Process functions that calculate the checksum using the PMD 300
protocol. Field 12 is the exclusive-or (XOR) of all the bytes from
fields 2 - 11 (inclusive); therefore, use process function XOR on
this range of fields. Field 13 is the one's complement of the
previous field.
The following three entries for the sample GPI configuration do
not require field positions:
RESP_ID The unique response ID is 111.
RESP_VAR Single packet response; length is the second byte of the response
data.
STAT_TAG FactoryLink message element STAT_MSG and analog element
STAT_ANA.
In the Field Type column of the PMD 300 GPI Command/Response table, the
single-packet response, SNGL_RSP, specifies a variable-length response.
According to the PMD 300 protocol, the second byte of the response specifies the
length of the response. For the GPI protocol module to detect the end-of-response,
enter a 2 (for the second byte) in the Response LN, POS, TM column. The number
of bytes in the response begins with third byte.
The next line in the table matches the response to the response format required by
the outgoing message with the unique response ID, 111.
The last two lines of the table define FactoryLink analog and message elements.
This allows the GPI protocol module to report the status of the outgoing message
to the FactoryLink application.
External Device
value AA)
2 One-byte length of the incoming message stored in a FactoryLink
Interface
analog element
3 Two-byte unit address received in HILOW format
4 One-byte numeric place holder (delimiter)
5 One-byte reply code that will be stored in a FactoryLink analog
element
6 One-byte error code that will be stored in a FactoryLink analog
element
7 Two-byte checksum received in HILOW format that will be stored
in a FactoryLink analog element
Note
For the Field Type PROCESS, the Field Length can only be 1 or 2
bytes. Also, if a PROCESS FUNCTION has entries in the FLD# or
Arg columns, then, depending on the value specified in the Field
Length, it is a “char” (1-byte) or a “short” (2-bytes).
External Device
range using a CRC_SEED=0x8005
(inclusive). Uses Arg to set the initial
Interface
value.
External Device
• During configuration, from a constant
Interface
Before substituting these values in the field, you can convert them to some other
type of value. For example, the binary value of a field whose source is a
FactoryLink element can be converted to ASCII before transmission. When
parsing the incoming message or returning values to the FactoryLink elements, it
is possible to perform similar conversions.
The table below shows various conversion functions to use with the GPI protocol
module:
Name Description
BINARY Base 2
DECIMAL Base 10
HEX Base 16
Name Description
External Device
String column; the TSPRINTF function is a “tiny” sprintf( ) that
handles %s, %d, %u, %x, %0, %lu, %lx, %lX, %l0, and %%. It
Interface
recognizes width and pad specifications (%3d, %03d, etc.), long
values, and left or right justification. Is tiny sprintf() correct?
Note: Because the TSPRINTF function does not recognize floating point formats
(%e, %f, %g) and minimum widths, use it with FactoryLink Analog, Longana,
and Message types with the appropriate format string.
Response Protocols
Table 13-17 Sample Outgoing Message, Request Protocol
13
Table 13-18 Sample Incoming Response, Response Protocol
External Device
# 0001 xxxx xxxx xxxx FCS * CR
Interface
Field 1 (1 byte) Preamble
Constant value
Field 2 (2 byte) PLC device address
Constant value
Field 3 (2 byte) Response chars
FactoryLink analog element
Field 4 (2 byte) Response header chars
FactoryLink analog element
Field 5 (2 byte) Frame check sequence
FactoryLink analog, digital, or float element
Field 6 (1 byte) FCS Checksum codes
Constant value (Optional)
Field 7 (1 byte) Command terminator
Constant value (Optional)
Field 8 (1 byte) Postamble
Constant value (Optional)
RESP_ID 101
13
Table 13-20 Sample Incoming Response, Response Protocol
External Device
# 0001 xxxx xxxx FCS * CR
Interface
Field 1 (1 byte) Preamble
Constant value
Field 2 (2 byte) PLC device address
Constant value
Field 3 (2 byte) Response chars
FactoryLink analog element
Field 4 (2 byte) Response header chars
FactoryLink analog element
Field 5 (2 byte) Frame check sequence
Constant value (Optional)
Field 6 (1 byte) Response terminator
Constant value (Optional)
Field 7 (1 byte) Postamble
Constant value (Optional)
RESP_ID 222
Field Field Field Field Field Field Field Field Field Field Field
1 2 3 4 5 6 7 8 9 10 11
13
Table 13-22 Sample Incoming Message, Response Protocol
Field Field Field Field Field Field Field Field Field Field Field
External Device
1 2 3 4 5 6 7 8 9 10 11
Interface
: xxxx 01 xx 0006 20 xx xxxx xxxx xxxx ;
Field Field Field Field Field Field Field Field Field Field Field
1 2 3 4 5 6 7 8 9 10 11
13
Table 13-24 Sample Incoming Response, Response Protocol
Field Field Field Field Field Field Field Field Field Field Field Field
External Device
1 2 3 4 5 6 7 8 9 10 11 12
Interface
: xxxx 01 xx 0005 xx 30 HH EE FF xxxx ;
For information about the messages displayed for the EDI task and the format in
which protocol module messages are generated, see Chapter 10, “Messages and
Codes.”
Table 13-25
External Device
101 ASYNDSF.C(DSF_WRITE): cmnd length of %d exceeds
Interface
SND_BUF_LEN, FLD#%D
Table 13-27
Table 13-28
External Device
FLD# %D
Interface
223 ASYNDSF.C(RD_DO_TAGVALUE): Invalid cnvr for analog;
FLD# %D
Table 13-29
Table 13-30
External Device
317 ASYNCPT.C(XMIT): xmit error
Interface
319 ASYNCPT.C(XMIT): CPT_SND_USL returned: %04XH
•
•
•
•
Modicon Modbus
14
External Device
Interface
This chapter contains information needed to set up and configure bidirectional
communications between the FactoryLink real-time database and any Modicon
Modbus PLC.
Note
When you choose Modicon Modbus from the Configuration Manager Main Menu,
the Modicon Modbus configuration panels are displayed.
Modicon Modbus
Complete a row for each logical port specified in the External Device Definition
panel you want to define as a communication path for read and write operations.
Logical Port Enter a number, defined in the External Device Definition panel
Logical Port column, to represent a particular communication path
to a Modicon Modbus device.
Valid Entry: previously defined logical port number
Baud Rate Enter the speed at which the protocol module communicates with
the devices linked to FactoryLink via this logical port. This entry
must match the baud rate configuration of the devices. Refer to
the device manufacturer’s documentation for details.
Valid Entry: 110 - 115200 (default=9600)
Parity Enter the parity error correction during transmission via this
logical port. This entry must match the configuration of the
devices communicating via this port. Refer to the device
manufacturer’s documentation for details.
Valid Entry: none, even, or odd (default=odd)
Data Bits Enter the number of data bits used during transmission via this
logical port. This entry must match the configuration of the 14
devices communicating via this port. Refer to the device
manufacturer’s documentation for details.
Valid Entry: 7, 8 (default=8)
External Device
Stop Bits Enter the number of bits sent after a character to create a pause
Interface
before the start of the next character. This entry must match the
configuration of the devices communicating via this port. Refer to
the device manufacturer’s documentation for details.
Valid Entry: 1, 2 (default=1)
Timeout Enter the length of time, in tenths of a second, the protocol
module will wait to receive a response to a read or write command
before timing out. You must enter a value greater than 0 for the
protocol module to timeout.
Valid Entry: 1 - 32000 (default=30)
RTU ASCII Enter the communication mode for this logical port.
Valid Entry: RTU, ASCII (default=RTU)
Message Tag Enter a tag name for a message element to which a text string
will be written to indicate a communications error associated
with this logical port.
Valid Entry: standard element tag name
Valid Data Type: message
When the panel is complete, click Enter to validate the information. Define the
data type (message) for any tag names displayed in the Tag Definition dialog.
Modicon Modbus
Complete a row for each device to communicate through this logical port.
Error/Status Tag (Optional) Enter a tag name for an analog element in which to
Name store communications error codes associated with this device
(logical station).
You can animate output-text objects to display the codes stored in
an Error/Status Tag Name element on a graphics screen. Refer to
the Application Editor User Guide for more information.
Valid Entry: standard element tag name
Valid Data Type: analog
Logical Station Enter a number to identify the logical station to which the
information in this row pertains. A logical station represents the 14
combination of a logical port with a physical station. Assign a
unique number to each device communicating through this
logical port.
External Device
You will later enter this logical station number in a read or write
Interface
table to represent the device defined in this row. In a read or
write table, this number will identify the device to or from which
data is to be sent or received.
Valid Entry: 0 - 999
Device Type Enter the type of Modicon device represented by this entry. The
following table lists the valid entries and their variations. You
can specify any of the valid entry variations in this field.
184 184, 1, or 18
384 384, 3, or 38
484 484, 4, or 48
584 584, 5, or 58
884 884, 8, or 88
984 984, 9, or 98
984BITWRITE 984-BW
(Used for mask writes)
Station Address Enter the physical address of the Modicon device represented by Modicon Modbus
this entry.
Valid Entry: 1 - 24 (default=1)
Comment (Optional) Enter reference information about this logical station.
Valid Entry: 1 - 31
When the panel is complete, click Enter to validate the information. Define the
data type (analog) for any tag names displayed in the Tag Definition dialog.
A read or write table should not contain more than the maximum number of
contiguous registers allowed for a single message accessing a type of register. The
maximum number allowed varies from one register type to the next.
If more than the maximum number of contiguous register addresses are defined,
multiple messages are generated for the operation. For example, if a block read
table for a holding register contains entries that access contiguous addresses from
100 to 127, two messages are generated. The first message reads the first 125
addresses (addresses 100 to 124). The second message reads addresses 125
through 127.
The following table lists the maximum number of contiguous registers included in
a single block read or write message for each supported register type.
External Device
Coil 184, 384 800 800
Interface
484 512 800
M84 64 64
484 254 60
M84 32 32
484 512
M84 64
484 32
M84 4
Tip
Table Name Give this read or write request a name. Define one request (table)
per line and do not include spaces in the name. You can define as
many tables in this panel as available memory allows. Try to
make the table name reflective of the operation it represents.
If this is a triggered read or a block write table, when the trigger
element (Block Read Trigger for a read operation or Block Write
Trigger for a write operation) is forced to 1 (ON), the element
prompts FactoryLink to process this table and any other table in
which the same trigger is defined.
Valid Entry: alphanumeric string of up to 16 characters
Exception Write For EDI to interpret this operation as a triggered block write or
as a read operation, accept the default of NO.
For EDI to interpret this operation as an exception write and
write element values to the device only when those values
change, enter YES.
In an exception write, an internal change-status indicator within
the element containing the data to be written prompts the write
operation. If an element is configured for an exception write and
EDI recognizes this indicator has been set since the last scan of
the real-time database (indicating the value of the element has
changed), EDI writes this element’s value to the device.
Tip
Block Read Priority If this is a block read operation, enter a number to indicate the
priority of this table, relative to other read operations. The 14
highest priority is 1. This number influences the order in which
the EDI task handles the queuing of block read requests. If EDI
receives two requests at the same time, it processes the request
External Device
with the highest priority first. The default is 1.
Interface
If this is a write operation, accept the default of 1. This field
defaults to 1 regardless of whether the operation being defined is
a block read.
Valid Entry: 1 - 4 (default=1)
Note
The Block Read Trigger, Block Read Disable, Block Read Complete, and
Block Read State elements apply only to triggered read operations.
Do not define these elements for write operations.
Tip
External Device
If this is a read operation, accept the default of 1. This field
defaults to 1 regardless of whether the operation being defined is
Interface
a block or exception write.
Valid Entry: 1 - 4 (default=1)
Note
The Block Write Trigger, Block Write Disable, Block Write Complete, and
Block Write State elements apply only to write operations. Do not
define these elements for read operations.
Block Write Trigger If this is a read operation or an exception write operation you do
not plan to periodically disable, ignore this field.
If this is a block write table or an exception write table you plan
to periodically disable, this field is required. Enter a tag name for
a digital element to initiate a block write of the element values
specified in the Read/Write Information panel to the addresses
defined to receive the values. When this element’s value is forced
to 1 (ON), FactoryLink writes the values.
Valid Entry: standard element tag name
Valid Data Type: digital
Tip
The Block Write Disable element can be used to disable a block write
operation that is either part of a cascaded loop or is self-triggered.
The triggering cycle will cease upon disabling, however. To Modicon Modbus
re-enable a cascaded loop or a self-triggered write table, the Block
Write Trigger element must be toggled or forced to 1. Refer to
Chapter 8, “Application Design Tips and Techniques,” for details.
When the panel is complete, click Enter to validate the information. Define the
data type (digital) for any tag names displayed in the Tag Definition dialog.
External Device
Interface
For a Read Table—Add a panel entry for each FactoryLink database element in
which data read from the device will be stored when the operation executes.
For a Write Table—Add a panel entry for each element to be written when the
operation executes.
Tip
Tag Name For a read table, specify a tag name for an element in which
FactoryLink will store the data read from the device.
Valid for
Tag Type Element Description Register
Types:
Logical Station Enter the number representing the device from which the data is
to be read or to which the element’s value will be written. This
number was originally defined in the Logical Station Information
panel for the logical port through which communications with
this device occurs.
Valid Entry: previously defined logical station number
Reg Address Enter the register address in Modicon memory where this
element’s value is located. The format of a register address is:
paaaaa
where
p Address prefix that identifies the Modicon register
type
External Device
The leading zeros are extraneous.
For example, for holding register address 400001, enter 1. The 4
Interface
indicates the register type, and the leading zeros are not
necessary.
If you are defining an address for floating-point or long analog tag
types, keep in mind that these tag types are addressed in pairs.
The first register in the pair contains the high-order word; the
second register contains the low-order word.
Enter the address for the starting register in a register pair; the
companion register is implied.
Try to maintain consistency when using register addresses for
floating-point and long analog FactoryLink data types. Adopt
either an odd or even starting register sequence and maintain
that sequence. For example:
1, 3, 5, 7, 9, ...
or
2, 4, 6, 8, 10, ...
If you are defining an address for a message tag type, the
address specifies the first in a group of registers that contain the
message characters. The message length is specified in the Bit
Offset/MSG Length field.
If you are reading or writing to extended memory, a block
read, block write, or exception write operation may read or write
multiple register addresses for the same register file.
Modicon Modbus
External Device
Block write and exception write operations are
Interface
used to set the contents of a holding register.
When the panel is complete, click Enter to validate the information. Define the
data type (digital, analog, long analog, or floating-point) for any tag names
displayed in the Tag Definition dialog.
Modicon Modbus
For information about the messages displayed for the EDI task, see Chapter 10,
“Messages and Codes.”
1 (Decimal equivalent: 1)
Cause: Unknown I/O state.
Action: Verify the device configuration and cabling. The FactoryLink
configuration tables must contain the proper station addresses
and parameters. The Logical Station Control panel must contain
the proper baud rate, parity, and data format parameters.
2 (Decimal equivalent: 2)
Cause: I/O error in transmitting or receiving data.
Action: Refer to the previous description of code 1.
3 (Decimal equivalent: 3)
Cause: I/O aborted because of a time-out while the protocol module is
waiting for a device response.
Action: Refer to the description of code 1.
4 (Decimal equivalent: 4)
Cause: I/O data translation error.
Action: Refer to the description of code 1.
External Device
valid for the destination device.
Interface
25 (Decimal equivalent: 37)
Cause: Exception response—The data address received in the query by
the device is not valid.
Action: Verify the register addresses in the table experiencing the error.
In Message Tags
This section describes the run-time messages as they appear in the message tags.
Modbus: Communications OK
Cause: Normal.
Action: None. This is only an information message.
External Device
error code. For details, refer to “Run-Time Manager Codes” on
page 358.
Interface
Modbus: Read error decimalcode to Lsta logical station
Cause: An error occurred on a read request to the specified logical
station.
Action: The specified error is the decimal equivalent of a hexadecimal
error code. For details, refer to “Run-Time Manager Codes” on
page 358.
Modicon Modbus
•
•
•
•
Modicon Modbus Plus
15
External Device
Interface
The FactoryLink EDI task allows you to configure bidirectional communications
between the FactoryLink real-time database and any Modicon Modbus Plus PLC.
Note
Sample panel entries are provided in Chapter 6, “Reading Data from a Device,”
and Chapter 7, “Writing Data to a Device.”
Complete a row for each logical port specified in the External Device Definition
panel you want to define as a communication path for read and write operations.
Logical Port Enter a number, defined in the External Device Definition panel
Logical Port column, to represent a particular communication path
to a device.
Valid Entry: previously defined logical port number
Adapter Number Enter the number assigned to the SA85 host adapter.
In a Windows environment, follow the installation procedure
in the appropriate LNET (LocalNet Library) software manual to
set up the SA85 driver for your specific hardware system.
Configure the SA85 card as adapter 0 or 1.
Valid Entry: 0 or 1
LPORT Status (Optional) Enter a tag name for a message element to which a
Message Tag text string will be written to indicate a communications error
associated with this logical port.
Valid Entry: standard element tag name
Valid Data Type: message
Data Master Paths Enter a number between 1 and 8 that defines the number of
internal master paths on the SA85 device for command/response 15
transactions.
Valid Entry: 1 - 8
External Device
DS1 through DS8 Specify whether or not this path can be used as a data slave (DS)
path for unsolicited data. This can be one of the following:
Interface
YES This path can be used as a data slave path.
NO This path cannot be used as a data slave path.
These fields let you specify up to eight paths. For information
about data slave paths, refer to the Modicon Modbus Plus
Network Programming Guide.
When the panel is complete, click Enter to validate the information. Define the
data type (message) for any tag names displayed in the Tag Definition dialog.
Complete a row for each device to communicate through this logical port.
LSTA Status (Optional) Enter a tag name for an analog element in which to
Analog Tag store communications error codes associated with this device
(logical station).
You can animate output-text objects to display the codes stored in
an Error/Status Tag Name element on a graphics screen. Refer to
the Application Editor User Guide for more information.
Valid Entry: standard element tag name
Valid Data Type: analog
Logical Station Enter a number to identify the logical station to which the
Decimal information in this row pertains. A logical station represents the
combination of a logical port with a physical station. Assign a
unique number to each device communicating through this
logical port.
You will later enter this logical station number in a read or write
table to represent the device defined in this row. In a read or 15
write table, this number will identify the device to or from which
data is to be sent or received.
External Device
Valid Entry: 0 - 999 (default=0)
PLC Type Enter the type of Modicon device represented by this entry. Use
Interface
984-BITWRITE if mask write operations are supported by this
device. You can specify 984-BITWRITE for the following Modicon
models: A120, A130, A141, A145, 685E, 785E, AT4, VM4.
Valid Entry: 984 or 984-BITWRITE
Physical Station Enter the physical address of the Modicon device represented by
this entry. Be sure this number corresponds to the actual address
setting of the device.
Valid Entry: 1 - 64 (default=1)
Router 1 - Router 4 Enter a number between 1 and 64 that defines the Modbus Plus
When the panel is complete, click Enter to validate the information. Define the
data type (analog) for any tag names displayed in the Tag Definition dialog.
External Device
Interface
Modicon Modbus Plus
A read or write table should not contain more than the maximum number of
contiguous registers allowed for a single message accessing a type of register. The
maximum number allowed varies from one register type to the next.
If more than the maximum number of contiguous register addresses are defined,
multiple messages are generated for the operation. For example, if a block read
table for a holding register in a 984 device contains entries that access contiguous
addresses from 100 to 127, two messages are generated. The first message reads
the first 125 addresses (addresses 100 to 124). The second message reads
addresses 125 through 127.
The following table lists the maximum number of contiguous registers included in
a single block read or write message for each supported register type.
Input 125
Statistics 54 words
Word
Tip
Table Name Give this read or write request a name. Define one request (table)
per line and do not include spaces in the name. You can define as
many tables in this panel as available memory allows. Try to
make the table name reflective of the operation it represents.
If this is a triggered read or a block write table, when the trigger
element (Block Read Trigger for a read operation or Block Write
Trigger for a write operation) is forced to 1 (ON), the element
prompts FactoryLink to process this table and any other table in
which the same trigger is defined.
Valid Entry: alphanumeric string of up to 16 characters
Unsolicited Read For EDI to interpret this operation as a triggered block read or as
a write operation, accept the default of NO. 15
If this is an unsolicited read operation, enter YES. EDI will
interpret this operation as an unsolicited read and emulate the
device’s addressing structure based on entries you make in the
External Device
Read/Write Information panel. The incoming data will be stored
Interface
in the real-time database as specified in this field.
If you enter YES, the incoming data will be stored in the element
represented by the tag name specified in the Read/Write
Information panel. If the current value of the element is equal to
the new value, the change-status indicator is unaffected. If a
different value is being stored the element, however, it will
overwrite the current value and the element’s change-status
indicator will be set to 1 (ON).
Valid Entry: yes, no (default=no)
Exception Write For EDI to interpret this operation as a triggered block write or
Note
The Block Read Trigger, Block Read Disable, Block Read Complete, and
Block Read State elements apply only to triggered read operations.
Do not define these elements for unsolicited read operations or for
write operations.
Block Read Trigger If this is an unsolicited read or a write operation, ignore this field.
If this is a triggered read operation, this field is required. Enter a
tag name for a digital element to initiate a block read of the
addresses specified in the Read/Write Information panel. When
this element’s value is forced to 1 (ON), the addresses are read.
Valid Entry: standard element tag name
Valid Data Type: digital
Tip
The Block Read Disable element can be used to disable a block read
operation that is either part of a cascaded loop or is self-triggered.
The triggering cycle will cease upon disabling, however. To
re-enable a cascaded loop or a self-triggered read table, the Block
Read Trigger element must be toggled or forced to 1. Refer to
Chapter 8, “Application Design Tips and Techniques,” for details.
Block Read If this is an unsolicited read or a write operation, ignore this field.
Disable
If this is a triggered read operation, this field is optional. If you 15
need a digital element to disable a block read of the elements
specified in this table, enter a tag name. When this tag’s value is
forced to 1 (ON), the read operation is not executed, even when
External Device
the block read trigger is set to 1.
Interface
To re-enable a block read table that has been disabled, set this
element back to 0 (OFF).
Valid Entry: standard element tag name
Valid Data Type: digital
Block Read If this is an unsolicited read or a write operation, ignore this field.
Complete
If this is a triggered read operation, this field is optional. If you
need a digital element to indicate when this operation is
complete, enter a tag name. This element is forced to 1 (ON) at
startup. After the elements defined in the Read/Write
Note
The Block Write Trigger, Block Write Disable, Block Write Complete, and
Block Write State elements apply only to write operations. Do not
define these elements for read operations.
Block Write Trigger If this is a read operation or an exception write operation you do
not plan to periodically disable, ignore this field.
If this is a block write table or an exception write table you plan
to periodically disable, this field is required. Enter a tag name for
a digital element to initiate a block write of the element values
specified in the Read/Write Information panel to the addresses
defined to receive the values. When this element’s value is forced
to 1 (ON), FactoryLink writes the values.
Valid Entry: standard element tag name
Valid Data Type: digital
Tip
The Block Write Disable element can be used to disable a block write
operation that is either part of a cascaded loop or is self-triggered.
The triggering cycle will cease upon disabling, however. To
re-enable a cascaded loop or a self-triggered write table, the Block
Write Trigger element must be toggled or forced to 1. Refer to
Chapter 8, “Application Design Tips and Techniques,” for details.
To re-enable a block write table that has been disabled, set this
element back to 0 (OFF). 15
Valid Entry: standard element tag name
Valid Data Type: digital
External Device
Block Write If this is a read or exception write operation, ignore this field.
Complete
Interface
If this is a block write table, this field is optional. If you need a
digital element to indicate when this operation is complete, enter
a tag name. This element is forced to 1 (ON) at startup. After the
data defined in this table’s Read/Write Information panel has
been written to the device, the complete element is forced to 1
again.
Do not use this element when more than one logical port is
specified in a single table.
Valid Entry: standard element tag name
Valid Data Type: digital
When the panel is complete, click Enter to validate the information. Define the
data type (digital) for any tag names displayed in the Tag Definition dialog.
For a Read Table—Add a panel entry for each FactoryLink database element in
which data read from the device will be stored when the operation executes.
For a Write Table—Add a panel entry for each element to be written when the
operation executes.
Tip
Tag Name For a read table, specify a tag name for an element in which
FactoryLink will store the data read from the device. 15
For a write table, specify a tag name for an element containing a
value to be written to the device.
External Device
Valid Entry: standard element tag name
Valid Data Type: The following table lists valid tag types for each
Interface
register type. (Refer to the Data Type field of this
panel for a discussion on register types.)
Valid for
Tag Type Element Description Register
Types
External Device
If you are defining an address for global data words, they
are in the register address range of 1 to 32.
Interface
For global data word read operations, it is assumed the first
global data word received is always word 1, the second is word 2,
and so on. If you specify a register address in the block read table
that is larger than the total number of global data words that will
actually be received, an error is generated.
Although global data is considered contiguous in block write
tables, you can define register addresses that do not appear
contiguous on the information panel. For example, if you specify
register address 1, 5, 7, 20, and 25, a message is generated for
registers 1 through 25. A value of 0 is stored for those registers
External Device
Block write and exception write operations are
Interface
used to set the contents of a holding register.
External Device
For complete information about Modbus Plus cable diagrams, refer to AEG’s
Modicon Modbus Plus Network Planning and Installation Guide.
Interface
Figure 15-1 Pin-out Diagram—Connecting an SA85 Card to a Modicon Controller
Modbus Plus: Software Protection bit failure; bits (x) and number (y) required
Cause: One or both of the option bits (where x and y are decimal values)
required to run this protocol module are missing.
Action: Install the required option bits in the master key.
Run-Time Messages
15
The following logical port and logical station messages occur after the application
starts up:
External Device
Logical Port Messages
Interface
The EDI task writes logical port messages to the LPORT tag when this tag is
defined on the Read/Write table.
Modbus Plus: Illegal func code 0xnn rcvd for unsol data
Cause: An illegal command function code was detected in an unsolicited
message. Modbus Plus only expects the Preset Multiple Regs
command—Modbus command function 0x10—as the only valid
command for unsolicited operations.
Action: Decrease the rate at which unsolicited data is sent to
FactoryLink; or be certain the PLC is attempting to send only
function code 0x10 for unsolicited messages.
The EDI task writes logical station messages to the LSTA tag when this tag is
defined on the Read/Write table.
Lsta: n Communications OK
Cause: Normal.
Action: None.
External Device
have a faulty cable connection?
Interface
Lsta: n Exception Response Error x
Cause: An exception response 0xnn, a hexadecimal value, was received
from logical station n. A controller encountered a programming
or operation error while attempting to carry out a Modbus
command request. Typically, this error flags an illegal data
reference in a message or controller problems, a no response to
an interface panel or communication difficulties with a slave.
Action: Refer to the section discussing NetBIOS Error Return Codes in
the Modicon IBM Host-Based Devices Users Guide for details.
•
•
•
•
OMRON
16
External Device
Interface
This chapter contains information needed to set up and configure bidirectional
communications between the FactoryLink real-time database and the following
devices, either directly or using the OMRON Host Link:
• C120
• C200H
• C500
• C1000
• C2000
When you choose OMRON Host Link Protocol from the Configuration Manager Main
Menu, the OMRON Host Link Protocol configuration panels are displayed.
OMRON
Note
To bring the Logical Station Control panel to the foreground, click its title bar in
the display of all configuration panels.
Complete a row for each logical port specified in the External Device Definition
panel you want to define as a communication path for read and write operations.
Logical Port Enter a number, defined in the External Device Definition panel
Logical Port column, to represent a particular communication path
to a device.
Valid Entry: previously defined logical port number
(default=0)
Baud Rate Enter the speed at which the protocol module communicates with
the devices linked to FactoryLink via this logical port. This entry
must match the baud rate configuration of the devices. Refer to
the device manufacturer’s documentation for details.
External Device
manufacturers documentation for details.
Valid Entry: odd
Interface
Data Bits Enter the number of data bits used during transmission via this
logical port. This entry must match the configuration of the
devices communicating via this port. Refer to the device
manufacturers documentation for details.
Valid Entry: 8
Stop Bits Enter the number of bits sent after a character to create a pause
before the start of the next character. This entry must match the
configuration of the devices communicating via this port. Refer to
the device manufacturers documentation for details.
Valid Entry: 1
Timeout Enter the length of time the protocol module will wait to receive a
response to a read or write command before timing out. You must
enter a value greater than 0 for the protocol module to timeout.
Valid Entry: 1 - 32767 (default=10)
When the panel is complete, click Enter to validate the information. Define the
data type (message) for any tag names displayed in the Tag Definition dialog.
Table 16-1 provides sample entries for the OMRON Logical Station Control panel:
External Device
Interface
Complete a row for each device to communicate through this logical port.
Error/Status Tag (Optional) Enter a tag name for an analog element in which to
Name store communications error codes associated with this device
(logical station).
You can animate output-text objects to display the codes stored in
an Error/Status Tag Name element on a graphics screen. Refer to
the Application Editor User Guide for more information.
Valid Entry: standard element tag name
Valid Data Type: analog
OMRON
When the panel is complete, click Enter to validate the information. Define the
data type (analog) for any tag names displayed in the Tag Definition dialog.
Table 16-2 provides sample entries for the OMRON Logical Station Information
panel: 16
Table 16-2 Sample OMRON Logical Station Information Panel Entries
External Device
Field Entry Description
Interface
Error/Status Tag Name OMRN_STATION0_ Contains information about
STATUS communication errors
Logical Station 0 Specifies the logical
communication path
Physical Station 0 Specifies the physical station
address associated with this
logical station
Device Type C200H Specifies the external device type
associated with this logical
station
OMRON
Tip
Table Name Give this read or write request a name. Define one request (table)
per line and do not include spaces in the name. You can define as
many tables in this panel as available memory allows. Try to
make the table name reflective of the operation it represents.
If this is a triggered read or a block write table, when the trigger
element (Block Read Trigger for a read operation or Block Write
Trigger for a write operation) is forced to 1 (ON), the element
prompts FactoryLink to process this table and any other table in
which the same trigger is defined.
Valid Entry: alphanumeric string of up to 16 characters
Exception Write For EDI to interpret this operation as a triggered block write or
as a read operation, accept the default of NO. 16
For EDI to interpret this operation as an exception write and
write element values to the device only when those values
change, enter YES.
External Device
In an exception write, an internal change-status indicator within
Interface
the element containing the data to be written prompts the write
operation. If an element is configured for an exception write and
EDI recognizes this indicator has been set since the last scan of
the real-time database (indicating the value of the element has
changed), EDI writes this element’s value to the device.
Tip
Block Read If this is a block read operation, enter a number to indicate the
Priority priority of this table, relative to other read operations. The
highest priority is 1. This number influences the order in which
the EDI task handles the queuing of block read requests. If EDI
receives two requests at the same time, it processes the request
with the highest priority first. The default is 1.
If this is a write operation, accept the default of 1. This field
defaults to 1 regardless of whether the operation being defined is
a block read.
Valid Entry: 1 - 4 (default=1)
Note
OMRON
The Block Read Trigger, Block Read Disable, Block Read Complete, and
Block Read State elements apply only to triggered read operations.
Do not define these elements for write operations.
Tip
External Device
is set to 0 (OFF). After the elements defined in the Read/Write
Interface
Information panel have been updated in the FactoryLink
database, the state element is forced back to 1.
Valid Entry: standard element tag name
Valid Data Type: digital
Block Write If this is a block or exception write operation, enter a number to
Priority indicate the priority of this table, relative to other write
operations. The highest priority is 1. This number influences the
order in which the EDI task handles the queuing of write
requests. If EDI receives two requests at the same time, it
processes the request with the highest priority first. The default
is 1.
If this is a read operation, accept the default of 1. This field
defaults to 1 regardless of whether the operation being defined is
a block or exception write.
Valid Entry: 1 - 4 (default=1)
Note
The Block Write Trigger, Block Write Disable, Block Write Complete, and
Block Write State elements apply only to write operations. Do not
define these elements for read operations.
Block Write Trigger If this is a read operation or an exception write operation you do
not plan to periodically disable, ignore this field.
If this is a block write table or an exception write table you plan
to periodically disable, this field is required. Enter a tag name for
OMRON
Tip
Block Write If this is a read or exception write operation, ignore this field.
Complete
If this is a block write table, this field is optional. If you need a
digital element to indicate when this operation is complete, enter
a tag name. This element is forced to 1 (ON) at startup. After the
data defined in this table’s Read/Write Information panel has
been written to the device, the complete element is forced to 1
again.
Do not use this element when more than one logical port is
specified in a single table.
Valid Entry: standard element tag name
Valid Data Type: digital
Block Write State If this is a read or exception write operation, ignore this field.
If this is a block write operation, this field is optional. If you need
a digital element to indicate the state of this operation (in
progress or complete), enter a tag name. This element is forced to
1 (ON) at startup. While the table is being processed, the element
External Device
specified in a single table.
Valid Entry: standard element tag name
Interface
Valid Data Type: digital
When the panel is complete, click Enter to validate the information. Define the
data type (digital) for any tag names displayed in the Tag Definition dialog.
Table 16-3 provides sample entries for the OMRON Read/Write Control panel:
read is complete.
Block Read State OMRN_READ_ The value for OMRN_READ_
STATE STATE is set to 1 if a read
operation of table 1 is in
progress, and the value is 0 if it
is inactive.
External Device
Interface
For a Read Table—Add a panel entry for each FactoryLink database element in
which data read from the device will be stored when the operation executes.
For a Write Table—Add a panel entry for each element to be written when the
operation executes.
Tip
Tag Name For a read table, specify a tag name for an element in which
FactoryLink will store the data read from the device.
For a write table, specify a tag name for an element containing a
value to be written to the device.
Valid Entry: standard element tag name
Valid Data Type: digital, analog, float
Data Type Specify the type of data being read from or written to the device
for each element defined in the Tag Name field. Refer to “OMRON 16
Data Types and PLC Data Areas” on page 408 for valid data
types.
BIN1 16-bit binary value (-32768 to 32767). Use
External Device
element type D or A.
Interface
BIN2 Two consecutive 16-bit binary values or 32-bit
binary value (0 to 4294967295). Use element type
F.
BCD1 16-bit BCD value (0 to 9999). Use element type A.
BCD2 Two consecutive 16-bit BCD values or 32-bit BCD
value (0 to 9999999). Use element type F.
TIM 16-bit timer BCD value with units of 0.1 second
(0.0 to 999.9). Use element type F.
TIMH 16-bit high-speed timer BCD value with units of
0.01 second (0.00 to 99.99). Use element type F.
TCTR One-bit timer/counter value (0 or 1). Use element
type D and data area TC.
When the panel is complete, click Enter to validate the information. Define the
data type (digital, analog, or floating-point) for any tag names displayed in the
Tag Definition dialog.
OMRON
External Device
OMRON Programming Console to MONITOR. In this mode, the OMRON PLC
monitors bit or channel data from the data areas or specific program addresses
Interface
and reads it to the FactoryLink real-time database.
Other OMRON factory configurations may require that the PLC operate in RUN
or PROGRAM mode. If this is necessary, override the setting on the Programming
Console and place the PLC in MONITOR mode using the following procedure:
Enter ST in the Data Area field (for the OMRON PLC operating status) and enter
BIN1 in the Data Type field.
To change the operating mode of the PLC to the MONITOR mode, force write an
02 (which represents MONITOR mode in the ST area) to the FactoryLink analog
element.
For further information about the OMRON Status Write and changing the
operating mode, refer to the OMRON Host Link Unit Operation Manual.
To avoid manually performing this procedure each time you start FactoryLink,
configure Math and Logic to perform this operation automatically at startup. For
further information about configuring the Math and Logic task, refer to
“Configuring Math & Logic” in the FactoryLink ECS Configuration Guide.
OMRON
FactoryLink Data Type OMRON Data Type OMRON PLC Data Area
D BIN1 ER
TCTR TC
A BIN1 ST
BIN1 ER
BCD1 LR and DM
BCD1 PV
BCD2 LR and DM
TIM LR and DM
TIMH LR and DM
BCD2 PV
TIM PV
External Device
message tag, see “Configuring the Logical Station Control Panel” on page 390 of
this guide. For information about configuring an analog tag, see “Configuring the
Interface
Logical Station Information Panel” on page 393 of this guide.
For information about the messages displayed for the EDI task and the format in
which protocol module messages are generated, see Chapter 10, “Messages and
Codes,” of this guide.
OMRON
1
Cause: Not executable in RUN mode.
Action: Command request cannot be performed with the device in RUN
mode.
2
Cause: Not executable in MONITOR mode.
Action: Command request cannot be performed with the device in
MONITOR mode.
3
Cause: Not executable with PROM mounted.
Action: Command request cannot be performed with the device with
PROM mounted.
4
Cause: Address over (data overflow).
B
Cause: Not executable in PROGRAM mode.
Action: Command request cannot be performed with the device in
PROGRAM mode.
C
Cause: Not executable with PROM mounted. 16
Action: Command request cannot be performed with the device with
PROM mounted.
External Device
Interface
D
Cause: Not executable in LOCAL mode.
Action: Command request cannot be performed with the device in
LOCAL mode.
0
Cause: Parity error.
Action: Verify the parity setup matches the device.
1
Cause: Framing error.
Action: Verify the number of data and stop bits set up matches the
device.
2
Cause: Overrun.
Action: Verify the number of data and stop bits setup matches the
device.
3
Cause: FCS error.
Action: Verify the parity and the number of data and stop bits setup
OMRON
5
Cause: Entry number data error (parameter error, data code error, data
length error).
Action: Verify the Read/Write configuration panel entries are valid for
device parameter. Contact Customer Support if the problem
persists.
6
Cause: Instruction not found.
Action: Verify the Read/Write configuration panel entries are valid for
device parameter. Contact Customer Support if the problem
persists.
8
Cause: Frame length error.
Action: Verify the Read/Write configuration panel entries are valid for
device parameter. Contact Customer Support if the problem
persists.
9
Cause: Command not executable due to inexecutable error clear,
non-registration of I/O table, etc.
Action: Contact OMRON for more information.
External Device
Unit, channel over, or duplication of Optical Transmitting I/O
Unit.
Interface
Action: Contact OMRON for more information.
1
Cause: Transmit error.
Action: Verify the cable has been constructed properly and that it is
connected to the logical port and device.
2
Cause: Timeout error.
Action: Verify the cable has been connected to the logical port and
device. Also, check that the timeout period has been defined for
the recommended time.
3
Cause: Received invalid response character.
Action: Verify the parity and the number of data and stop bits are
configured properly for the device. Also, verify the cable ground
wire is connected properly.
4
OMRON
6
Cause: Received NAK response for command request.
Action: Verify the Read/Write configuration panel entries are valid for
device parameter. Also, verify the parity and the number of data
and stop bits are configured properly for the device and that the
cable ground wire is connected properly.
0
Cause: Queuing read request error.
Action: Verify the IBM RIC/ARTIC board and the OMRON protocol
module have sufficient data storage defined. Contact Customer
Support if the problem persists.
1
Cause: Queuing write request error.
Action: Verify the IBM RIC/ARTIC board and the OMRON protocol
module have sufficient data storage defined. Contact Customer
Support if the problem persists.
2
Cause: Read or write request too large for the transmit buffer.
Action: Contact Customer Support immediately.
3
Cause: OMRON read/write response produced an unknown error.
Action: Contact Customer Support immediately.
External Device
Action: Verify the parity setup matches the device.
Interface
1
Cause: Aborted due to framing error in transmit data.
Action: Verify the number of data and stop bits setup matches the
device.
2
Cause: Aborted due to overrun in transmit data.
Action: Verify the number of data and stop bits set up matches the
device.
4
Cause: Aborted due to format error in transmit data.
Action: Verify the Read/Write configuration panel entries are valid for
device parameter. Contact Customer Support if the problem
persists.
5
Cause: Aborted due to entry number data error in transmit data.
Action: Verify the Read/Write configuration panel entries are valid for
device parameter. Contact Customer Support if the problem
persists.
8
OMRON
0
Cause: Not executable because program area is not 16K bytes.
•
•
•
•
Siemens CP525
17
External Device
Interface
This chapter contains information to set up and configure bidirectional
communications between the FactoryLink real-time database and the Siemens
CP525 using RK512 with either 3964 or 3964R protocol.
Note
When you choose Siemens CP525 from the Configuration Manager Main Menu, the
Siemens CP525
Siemens CP525 configuration panels are displayed.
Complete a row for each logical port specified in the External Device Definition
panel you want to define as a communication path for read and write operations.
Logical Port Enter a number, defined in the External Device Definition panel
Logical Port column, to represent a particular communication path
to a device.
Valid Entry: previously defined logical port number
Baud Rate Enter the speed at which the protocol module communicates with
the devices linked to FactoryLink via this logical port. This entry
must match the baud rate configuration of the devices. Refer to
the device manufacturer’s documentation for details.
Valid Entry: 110 - 115200 (default=9600)
Parity Enter the parity error correction during transmission via this
logical port. This entry must match the configuration of the
devices communicating via this port. Refer to the device
manufacturer’s documentation for details.
Valid Entry: none, even, odd (default=even)
Data Bits Enter the number of data bits used during transmission via this
logical port. This entry must match the configuration of the 17
devices communicating via this port. Refer to the device
manufacturer’s documentation for details.
Valid Entry: 7, 8 (default=8)
External Device
Stop Bits Enter the number of bits sent after a character to create a pause
Interface
before the start of the next character. This entry must match the
configuration of the devices communicating via this port. Refer to
the device manufacturer’s documentation for details.
Valid Entry: 1, 2 (default=1)
Response Enter the length of time, in tenths of a second, the protocol
Timeout 0.1 Sec module will wait to receive a response to a read or write command
before timing out. You must enter a value greater than 0 for the
protocol module to timeout.
Valid Entry: standard Siemens timeouts, based on the baud
rate (default=0)
LRC Error Enter the type of error detection protocol.
Siemens CP525
Detection
None Siemens Procedure 3964
BCC (Default) Siemens Procedure 3964R
Retry Request Enter the maximum number of times the protocol module will
retry a read or write command to a device communicating
through this logical port if the command response is invalid or is
not received.
Valid Entry: 0 - 65535 (default=3)
Master/Slave Indicate whether the FactoryLink station is the Master or the
Slave of the communications channel.
M (Default) Master
S Slave
Status Msg Tag (Optional) Enter a tag name for a message element to which a
text string will be written to indicate a communications error
associated with this logical port.
Valid Entry: standard element tag name
Valid Data Type: message
Table 17-1 provides sample entries for the Siemens 525 Logical Station Control
panel:
Table 17-1 Sample Siemens 525 Logical Station Control Panel Entries
External Device
Interface
Siemens CP525
Complete a row for each device to communicate through this logical port.
Error /Status Tag (Optional) Enter a tag name for an analog element in which to
Name store communications error codes associated with this device
(logical station).
You can animate output-text objects to display the codes stored in
an Error/Status Tag Name element on a graphics screen. Refer to
the Application Editor User Guide for more information.
Valid Entry: standard element tag name
Valid Data Type: analog
Logical Station Enter a number to identify the logical station to which the
information in this row pertains. A logical station represents the
combination of a logical port with a physical station. Assign a
unique number to each device communicating through this
logical port.
When the panel is complete, click Enter to validate the information. Define the
data type (analog) for any tag names displayed in the Tag Definition dialog.
Table 17-2 provides sample entries for the Siemens 525 Logical Station
Information panel:
Table 17-2 Sample Siemens 525 Logical Station Information Panel Entries
External Device
Interface
Siemens CP525
Complete a row for each read or write table.
Tip
Table Name Give this read or write request a name. Define one request (table)
per line and do not include spaces in the name. You can define as
many tables in this panel as available memory allows. Try to
make the table name reflective of the operation it represents.
If this is a triggered read or a block write table, when the trigger
element (Block Read Trigger for a read operation or Block Write
Trigger for a write operation) is forced to 1 (ON), the element
prompts FactoryLink to process this table and any other table in
which the same trigger is defined.
Valid Entry: alphanumeric string of up to 16 characters
Block Read If this is a block read operation, enter a number to indicate the
Priority priority of this table, relative to other read operations. The 17
highest priority is 1. This number influences the order in which
the EDI task handles the queuing of block read requests. If EDI
receives two requests at the same time, it processes the request
External Device
with the highest priority first. The default is 1.
Interface
If this is an unsolicited read or a write operation, accept the
default of 1. This field defaults to 1 regardless of whether the
operation being defined is a block read.
Valid Entry: 1 - 4 (default=1)
Note
The Block Read Trigger, Block Read Disable, Block Read Complete, and
Block Read State elements apply only to triggered read operations.
Do not define these elements for unsolicited read operations or for
write operations.
Siemens CP525
Block Read If this is an unsolicited read or a write operation, ignore this field.
Trigger
If this is a triggered read operation, this field is required. Enter a
tag name for a digital element to initiate a block read of the
addresses specified in the Read/Write Information panel. When
this element’s value is forced to 1 (ON), the addresses are read.
Valid Entry: standard element tag name
Valid Data Type: digital
Tip
The Block Read Disable element can be used to disable a block read
operation that is either part of a cascaded loop or is self-triggered.
The triggering cycle will cease upon disabling, however. To
re-enable a cascaded loop or a self-triggered read table, the Block
Read Trigger element must be toggled or forced to 1. Refer to
Chapter 8, “Application Design Tips and Techniques,” for details.
External Device
Note
Interface
The Block Write Trigger, Block Write Disable, Block Write Complete, and
Block Write State elements apply only to write operations. Do not
define these elements for read operations.
Block Write Trigger If this is a read operation or an exception write operation you do
not plan to periodically disable, ignore this field.
If this is a block write table or an exception write table you plan
to periodically disable, this field is required. Enter a tag name for
a digital element to initiate a block write of the element values
specified in the Read/Write Information panel to the addresses
defined to receive the values. When this element’s value is forced
Siemens CP525
to 1 (ON), FactoryLink writes the values.
Valid Entry: standard element tag name
Valid Data Type: digital
Tip
When the panel is complete, click Enter to validate the information. Define the
data type (digital) for any tag names displayed in the Tag Definition dialog.
Table 17-3 provides sample entries for the Siemens 525 Read/Write Control panel:
17
Table 17-3 Sample Siemens 525 Read/Write Control Panel Entries
External Device
Table Name READ Specifies the table name.
Interface
Unsolicited Read NO Table will not perform
unsolicited reads.
Exception Write NO Table will not perform exception
writes.
Block Read Priority 1 Priority for tables set to 1.
Block Read Trigger SIEM_READ_ When the value of SIEM_READ_
TRIGGER TRIGGER is 1 or (on), a block
read of values specified by the
Read/Write Information panel
Siemens CP525
associated with SIEMBRD
occurs.
Block Write Priority 1 The write priority for this table is
set to 1 by default.
Block Write Trigger Since this is a read table, the
elements specific to write
requests are not defined.
Block Write Complete
For a Read Table—Add a panel entry for each FactoryLink database element in
which data read from the device will be stored when the operation executes.
For a Write Table—Add a panel entry for each element to be written when the
operation executes.
Tip
Tag Name For a read table, specify a tag name for an element in which
FactoryLink will store the data read from the device. 17
For a write table, specify a tag name for an element containing a
value to be written to the device.
External Device
Valid Entry: standard element tag name
Valid Data Type: digital, analog, longana, float, message
Interface
Logical Station Enter the number representing the device from which the data is
to be read or to which the element’s value will be written. This
number was originally defined in the Logical Station Information
panel for the logical port through which communications with
this device occurs.
Valid Entry: previously defined logical station number
PLC Region Enter the data area of the PLC to be read/written.
For read operations:
CB Counters
DB Data block
Siemens CP525
DX Extended data block
FB Flag bytes
IB Input bytes
OB Output bytes
PB Peripheral blocks
TB Timers
For write operations:
DB Data block
DX Extended data block
Data Block Enter the data block number of the address to be read or written.
Valid Entry: 3 - 255
Word/ Byte Enter the address of word in word regions or address of byte in
byte regions that is read or written.
0-255 CB, DB, DX, FB, PB, TB
0-127 IB, OB
When the panel is complete, click Enter to validate the information. Define the
data type (digital, analog, long analog, or floating-point) for any tag names
displayed in the Tag Definition dialog.
Table 17-4 provides sample entries for the Siemens 525 Read/Write Information
panel: 17
Table 17-4 Sample Siemens 525 Read/Write Information Panel Entries
External Device
Field Entry Description
Interface
Table Name READ Specifies the Read/Write table
name.
Tag Name SIEMDIG1 The value read from the device
will be stored in SIEMDIG1.
Logical Station 0 Specifies the path to send the
request.
PLC Region DB Data block.
Data Block 10 Data block in the PLC to write
the value of SIEMDIG1.
Siemens CP525
Word/Byte 6 Word/byte in the PLC to write
the value of SIEMDIG1.
Bit/Length 3 Bit/length of the value written.
Data Type DW Defaults to Siemens data type
BIN.
Coordination Flag CPU NONE
Coordination Flag Byte NONE
Coordination Flag Bit NONE
External Device
configuration table. (For compatibility with previous versions, the Data Type DW
defaults to BIN.) The following table shows the default conversions for each of the
Interface
FactoryLink data types.
Digital DIG
Analog INT2
Longana INT4
Float FLT
Siemens CP525
Message LOHI
Each FactoryLink data type also has a range of valid Siemens PLC data types.
You may choose to specify a Siemens PLC data type. The following table shows the
FactoryLink data types, and the corresponding Siemens PLC data types.
BYTE (Valid only in byte PLC regions) Converts the FactoryLink value
to or from a single unsigned byte (0 - 255)
BYTE (Valid only in byte PLC regions) Converts the FactoryLink value
to or from a single unsigned byte (0 - 255)
External Device
integer
Interface
INT4 Converts the FactoryLink value to or from a 4-byte, signed
integer
BYTE (Valid only in byte PLC regions) Converts the FactoryLink value
Siemens CP525
to or from a single, unsigned byte (0 - 255)
For information about the messages displayed for the EDI task and the format in
which protocol module messages are generated, see Chapter 10, “Messages and
Codes.”
0001h
Cause: Internal error.
Action: Contact Customer Support.
0002h
Cause: Unable to successfully communicate with PLC.
Action: Check line parameters (baud rate, data bits, etc.), cable, CP525
programming.
0003h
Cause: Unable to receive response to read/write request.
Action: Check CP525 programming.
0004h
Cause: Internal error.
Action: Contact Customer Support.
XX05h
Cause: Received error code XXh from Siemens PLC in response packet. 17
Action: Refer to Siemens CP525 documentation.
External Device
0006h
Interface
Cause: After retry count, received more or fewer bytes than requested in
read request packet.
Action: Contact Customer Support.
0007h
Cause: Internal error.
Action: Contact Customer Support.
Siemens CP525
•
•
•
•
Siemens H1
18
External Device
Interface
This chapter contains information needed to set up and configure bidirectional
communications between the FactoryLink real-time database and any Siemens
Simatic S5 or S505 PLC using one of the following interfaces:
• CP-535, CP-143 card
• CP-1433, CP-1434
• Ethernet interface card over an Ethernet network
S IEMENS H1 C OMMUNICATIONS
Communication in the Siemens H1 protocol module occurs between the Siemens
Ethernet Interface and the Device Control Module (DCM) using logical entities
called Transport Service Access Points (TSAPs).
TSAPs are communication points that link the Siemens Ethernet Interface and
the DCM. TSAPs work in pairs. A DCM TSAP works with a Siemens Ethernet
Interface TSAP, with one TSAP on each side of the communication link.
Types of Communication
On one side of the communication link, the DCM performs three types of
communication. Each type of communication has an associated TSAP pair. The
DCM performs the following types of communication:
• Solicited Reads—Block reads of data from the Siemens PLC to the real-time
database.
S5—The Read Active/Passive TSAP pair consists of a Fetch active TSAP in the
DCM and a Fetch passive TSAP in the Siemens Ethernet Interface card.
Siemens H1
S505—The Read Active/Passive TSAP pair consists of a Read active TSAP in
the DCM and a Read passive TSAP in the Siemens Ethernet Interface card.
• Solicited Writes—Block and exception writes of data from the real-time
database to the Siemens PLC.
S5—The Write Active/Passive TSAP pair consists of a Send active TSAP in the
DCM and a Receive passive TSAP in the Siemens Ethernet Interface card.
Table 18-1 describes the relationships between the three types of communication
performed by the DCM and the TSAP pairs.
TSAP Pair
Type of Initiator of the Type of Data
Communication Communication Siemens PLC Exchanged
Ethernet DCM
Interface
Solicited Writes/ FactoryLink Receive passive Send active (S5) Block and
Siemens Write (S5) Write active exception writes
Active/Passive Write passive (S505)
(S505)
where:
Active Describes the Siemens Interface co-processor jobs and denotes
the initiator or “master” of the link.
Passive Describes the Siemens Interface co-processor jobs and denotes
the receiver or “slave” of the link.
External Device
information to an external device. These are only Active.
Receive Describes the Siemens Interface co-processor jobs that receive
Interface
information from an external device. These are only Passive.
To define a TSAP pair, you must first obtain the following information:
• The DCM FactoryLink platform Ethernet adapter address
• The Siemens PLC Ethernet adapter address
• The Remote TSAP ID
• The Local TSAP ID
Note
You must program the Ethernet adapter address of the FactoryLink platform in
the Siemens Ethernet Interface. For further information about the Ethernet
address of the FactoryLink platform, refer to “Siemens H1 Adapter Display
Siemens H1
Utility (H1MPDISP)” on page 493.
____SSAA (COM535) or
___SS_AA (COM143)
where
“_” Is a space character in Siemens software programming displays
SS Is the SSNR (card) number if two-digits
_S Is the SSNR (card) number if one-digit
AA Is the ANR (job) number if two-digits
_A Is the ANR (card) number if one-digit
“1623” “^^^^1623”
“1623^” “^^^^1623”
“1623_” “^^^1623^”
“12_4” “^^^^12^4”
“12_4” “^^^^12^4”
“0^1” “^^^^^0^1”
External Device
Before completing the protocol-specific Siemens H1 configuration
panels, you must complete the External Device Definition panel.
Interface
See “Identifying Protocol Types and Defining Logical Ports” on
page 70 for details.
When you choose Siemens Sinec H1 from the Configuration Manager Main Menu,
the Siemens configuration panels are displayed.
Siemens H1
Complete a row for each logical port specified in the External Device Definition
panel you want to define as a communication path for read and write operations.
Logical Port Enter a number, defined in the External Device Definition panel
Logical Port column, to represent a particular communication path
to a device.
Valid Entry: previously defined logical port number
(default=0)
Ethernet Enter the Ethernet adapter installed in the FactoryLink system
Adapter for use with this logical port.
Number
Valid Entry: 0 or 1 (default=0)
At run time, the remaining fields of the Siemens H1 Logical
Station Control panel (except for the Status Message Tag field)
control the system resources used by the Device Control Module
(DCM) task. (The DCM task runs outside of FactoryLink and
provides the interface between the FactoryLink EDI task and the
external device. For more information about the DCM task, refer
to “Siemens H1 Communications” on page 441.)
External Device
Concurrent Requests. At startup, the DCM task allocates memory
Interface
for the number of solicited tables specified in this field. Each of
these solicited tables contains one or more solicited requests. If
you enter a number larger than the number specified in the
Maximum Concurrent Requests field, you are using memory
inefficiently.
Valid Entry: 5 - 100 (default=10)
Maximum Enter the number of solicited requests (individual read or write
Concurrent transactions) on which the DCM task can operate simultaneously.
Requests Each request requires slightly over 4 kilobytes of memory.
Valid Entry: 5 - 100 (default=10)
Number Enter the shared pool of memory available for all logical stations
Unsolicited with configured unsolicited operations. The DCM has a structure
Buffers similar to the solicited request for each concurrently active
unsolicited write command received from the PLC transaction.
Each buffer contains slightly over 4 kilobytes of memory.
Valid Entry: 5 - 100 (default=10)
Unsolicited Queue Enter the internal queue size of unsolicited write commands
Size (number of elements on queue) received from the PLC awaiting
formatting for the FactoryLink database.
Valid Entry: 5 - 100 (default=10)
Number Enter the shared pool of DCM allocated buffers used by all logical
Ethernet stations to transmit or receive Ethernet packets. Each buffer is
Buffers slightly over 1500 bytes in length.
Valid Entry: 5 - 250 (default=30) Siemens H1
Solicited Idle Enter the amount of time in seconds a logical station’s solicited
Disconnect connections remain active without solicited transactions
Timeout occurring.
(Seconds)
In the DCM, each connected logical station requires periodic
processing to maintain the connection while no actual solicited
transactions take place with the PLC. Solicited operations to
disconnected stations require additional overhead to reconnect
before a transaction can take place. Therefore, set this time
When the panel is complete, click on Enter to validate the information. Define the
data type (message) for any tag names displayed in the Tag Definition dialog.
Table 18-3 provides sample entries for the Siemens H1 Logical Station Control
panel:
Table 18-3 Sample Siemens H1 Logical Station Control Panel Entries (Continued)
18
Field Entry Description
External Device
Tables solicited tables at the same time.
Interface
Maximum Concurrent 10 The DCM can operate 10
Requests solicited requests at the same
time.
Number Unsolicited 10 Ten buffers will be used for
Buffers storage of data from unsolicited
requests for all the logical
stations.
Unsolicited Queue Size Ten elements will be on queue
from unsolicited requests
awaiting formatting in the
FactoryLink real-time database.
Number Ethernet 30 Thirty DCM allocated buffers
Buffers have been configured for use by
all logical stations for Ethernet
packets.
Solicited Idle 120 The logical station’s solicited
Disconnect Timeout connection remains active for 120
(Seconds) seconds without solicited
transactions occurring.
Unsolicited Idle 300 The logical station’s unsolicited
Disconnect Timeout connections remain active for 300
(Seconds) seconds without unsolicited
transactions occurring.
Status Msg Tag H1MP_LPORT0_ The EDI task writes errors for
Siemens H1
MSG this logical port 0 to this message
element.
Complete a row for each device to communicate through this logical port.
Error/Status Tag (Optional) Enter a tag name for an analog element in which to
Name store communications error codes associated with this device
(logical station).
You can animate output-text objects to display the codes stored in
an Error/Status Tag Name element on a graphics screen. Refer to
the Application Editor User Guide for more information.
Valid Entry: standard element tag name
Valid Data Type: analog
Logical Station Enter a number to identify the logical station to which the
information in this row pertains. A logical station represents the
combination of a logical port with a physical station. Assign a
unique number to each device communicating through this
logical port.
You will later enter this logical station number in a read or write
table to represent the device defined in this row. In a read or 18
write table, this number will identify the device to or from which
data is to be sent or received.
External Device
Valid Entry: previously defined logical station number
PLC Type Type of Siemens device associated with this logical station.
Interface
S5 (Default) Siemens S5 series PLC with either
CP-535 or CP-143
S505 Siemens 505 family stations with the following
Ethernet cards installed:
CP-1433
CP-1434
Remote Adapter Enter the 6-byte (12-nibble) Ethernet address of the Siemens H1
Address Ethernet defined on this line.
(hexadecimal)
Valid Entry: six address bytes (set by the Ethernet)
080006 01 0 000
------ -- - ---
Solicited Rd Enter the TSAP ID for the Fetch Passive TSAP on the Siemens
Remote FCHP Interface Card with which the Device Control Module
TSAP ID communicates for solicited read operations on this logical station.
Valid Entry: any 8-character ASCII string
External Device
Valid Data Type: digital
Interface
Comment (Optional) Enter reference information about this logical station.
Valid Entry: alphanumeric string of up to 21 characters
When the panel is complete, click on Enter to validate the information. Define the
data type (analog) for any tag names displayed in the Tag Definition dialog.
Table 18-4 provides sample entries for the Siemens H1 Logical Station
Information panel:
Error Status Tag Name H1MP_STATION0_ (Optional) Errors for this logical
STATUS station are written to this analog
element.
Logical Station 0 Communications path for the
communication.
Remote Adapter 0800006010001 Remote Ethernet address (in
Address (hexadecimal) hexadecimal).
Solicited Rd Remote 85 Fetch Passive TSAP SSNR 8,
FCHP TSAP ID ANR 5.
Solicited Rd Local 81 Fetch Active TSAP SSNR 8,
FCHA TSAP ID ANR 1. Siemens H1
Solicited Rd Station H1MP_LS0_R (Optional) Digital element
Status Tag Name containing the status of the
TSAP for solicited read
operations for logical station 1.
Has a value of 0 (OFF) when
disconnected and 1 (ON) when
connected.
External Device
Interface
Complete a row for each read or write table.
Tip
Table Name Give this read or write request a name. Define one request (table)
per line and do not include spaces in the name. You can define as
many tables in this panel as available memory allows. Try to
make the table name reflective of the operation it represents.
Siemens H1
If this is a triggered read or a block write table, when the trigger
element (Block Read Trigger for a read operation or Block Write
Trigger for a write operation) is forced to 1 (ON), the element
prompts FactoryLink to process this table and any other table in
which the same trigger is defined.
Valid Entry: alphanumeric string of up to 16 characters
Tip
Block Read If this is a block read operation, enter a number to indicate the
Priority priority of this table, relative to other read operations. The 18
highest priority is 1. This number influences the order in which
the EDI task handles the queuing of block read requests. If EDI
receives two requests at the same time, it processes the request
External Device
with the highest priority first. The default is 1.
Interface
If this is an unsolicited read or a write operation, accept the
default of 1. This field defaults to 1 regardless of whether the
operation being defined is a block read.
Valid Entry: 1 - 4 (default=1)
Note
The Block Read Trigger, Block Read Disable, Block Read Complete, and
Block Read State elements apply only to triggered read operations.
Do not define these elements for unsolicited read operations or for
write operations.
Block Read If this is an unsolicited read or a write operation, ignore this field.
Trigger
If this is a triggered read operation, this field is required. Enter a
tag name for a digital element to initiate a block read of the
addresses specified in the Read/Write Information panel. When
this element’s value is forced to 1 (ON), the addresses are read.
Valid Entry: standard element tag name
Valid Data Type: digital
Tip
The Block Read Disable element can be used to disable a block read
operation that is either part of a cascaded loop or is self-triggered.
The triggering cycle will cease upon disabling, however. To
re-enable a cascaded loop or a self-triggered read table, the Block
Siemens H1
Read Trigger element must be toggled or forced to 1. Refer to
Chapter 8, “Application Design Tips and Techniques,” for details.
External Device
Note
Interface
The Block Write Trigger, Block Write Disable, Block Write Complete, and
Block Write State elements apply only to write operations. Do not
define these elements for read operations.
Block Write Trigger If this is a read operation or an exception write operation you do
not plan to periodically disable, ignore this field.
If this is a block write table or an exception write table you plan
to periodically disable, this field is required. Enter a tag name for
a digital element to initiate a block write of the element values
specified in the Read/Write Information panel to the addresses
defined to receive the values. When this element’s value is forced
to 1 (ON), FactoryLink writes the values.
Valid Entry: standard element tag name
Valid Data Type: digital
Tip
When the panel is complete, click on Enter to validate the information. Define the
data type (digital) for any tag names displayed in the Tag Definition dialog.
Table 18-5 provides sample entries for the Siemens H1 Read/Write Control panel:
18
Table 18-5 Sample Siemens H1 Read/Write Control Panel Entries
External Device
Table READ The name of this table is READ.
Interface
Name
Block Write
Disable
Block Write
State
External Device
Interface
For a Read Table—Add a panel entry for each FactoryLink database element in
which data read from the device will be stored when the operation executes.
For a Write Table—Add a panel entry for each element to be written when the
operation executes.
Tip
Tag Name For a read table, specify a tag name for an element in which
FactoryLink will store the data read from the device.
For a write table, specify a tag name for an element containing a
value to be written to the device.
Valid Entry: standard element tag name
Valid Data Type: digital, analog, longana, float, message
External Device
FB Flags 1 0 255 BYTE No
Interface
IB Input Image 1 0 127 BYTE No
Note: Max Region Index values with an asterisk (*) indicate data regions that accept logical
station variables.
Note: Max Region Index values and Max Element Numbers with an asterisk (*) indicate
data regions that accept logical station variables.
Note: Max Region Index values and Max Element Numbers with an asterisk (*) indicate
data regions that accept logical station variables.
External Device
DSP Drum Step Preset 2 255* 255 INT2 No
Interface
G G (Local App global 2 0 65535 INT2 No
Variables)
Note: Max Region Index values and Max Element Numbers with an asterisk (*) indicate
data regions that accept logical station variables.
Note: Max Region Index values and Max Element Numbers with an asterisk (*) indicate
data regions that accept logical station variables.
External Device
LKD Derivative Gain Limiting 4 0 65535* FLT No
Interface
Coefficient
Note: Max Region Index values and Max Element Numbers with an asterisk (*) indicate
data regions that accept logical station variables.
Note: Max Region Index values and Max Element Numbers with an asterisk (*) indicate
data regions that accept logical station variables.
Bit or Length (Use with digital or message elements only) Enter the bit or
length in the PLC the Siemens H1 protocol module reads. 18
For digital elements: The bit to be read or written.
For message elements: The message length to be read or
External Device
written. The bit or length denotes the number of PLC elements to
place in the message.
Interface
0 - 15 (S5) Word regions: data block, counters, timers
1 - 16 (S505) Word regions: data block, counters, timers
1 - 32 (S505) Double word (4 byte) element regions
0-7 (S5) Byte regions: flags, input, output, peripheral
1 - 8 (S505) Byte regions
1 - 127 Word regions: message length in words
1 - 255 Byte regions: message length in bytes
1 - 63 (S505) Double word region message length
PLC Data Type Specify the type of data being read from or written to the device
for each element defined in the Tag Name field. For more
information about valid combinations of FactoryLink data types,
PLC regions, and PLC data types, refer to “Siemens H1 Data
Types” on page 489.
BIN Default conversion based on the type of
FactoryLink real-time database element.
BYTE (Use with PLC byte-regions only) 1-byte unsigned
integer.
INT2 2-byte signed integer.
INT4 4-byte signed integer.
BCD3 2-byte, 3-digit signed Binary Coded Decimal in the
high-order nibble.
Siemens H1
When the panel is complete, click on Enter to validate the information. Define the
data type (digital, analog, long analog, or floating-point) for any tag names
displayed in the Tag Definition dialog.
Table 18-8 provides sample entries for the Siemens H1 Read/Write Information
panel: 18
Table 18-8 Sample Siemens H1 Read/Write Information Panel Entries
External Device
Field Entry Description
Interface
Table Name READ The table name defined in the Read/Write
Control panel is displayed.
Tag Name H1MPDIG1 When the READ table is triggered by
H1MP_READ_TRIGGER (defined in the
Read/Write Control panel), FactoryLink
processes the table. The value read from
the device is stored in H1MPDIG1.
Logical Station 0 The value stored in this element is read
from the Siemens H1 device configured as
logical station 0.
PLC Region FB PLC region that is being read.
Region Index
Element 100
Bit or Length 3
PLC Data Type DIG The data being read from the device is
digital.
Siemens H1
External Device
PLC Data Type Not applicable
Interface
Active/inactive Status
At run time, the status of each logical station is either active or inactive. The
following conditions define the status of each logical station:
• Active logical stations (set at program initiation) respond to solicited or remote
station requests.
• Inactive logical stations abort solicited operations and reject any attempts by a
remote station to connect.
• During the transition between active and inactive, the logical station aborts any
new or pending solicited request, disconnects all TSAPs for that logical station,
and handles the transition from inactive to active in the same way as it handles
recovery from a disconnected station.
Note
Use the Set Remote Parameters command only when changing the
parameters of remote physical stations of the same device type. If
you change remote physical stations of different device types (such
Siemens H1
as redefining an S5 logical station as an S505 physical station or
an S505 logical station as an S5 physical station), undesirable
results may occur in your application. The EDI task does support
nor check for dissimilar device-type changes.
To set the logical station remote parameters, enter the following information in
the Siemens H1 Read/Write Information panel:
If a block write table with the Set Remote Parameters command contains any
other commands, a row error may occur. For information about row errors, refer to
“Set Logical Station Commands and Row Errors” on page 486.
Format
The message element you configured as a Set Remote Parameters command in the
Siemens H1 Read/Write Information panel contains an ASCII representation of
the Siemens Logical Station Information panel. This message element is used to
reconfigure the logical station at run time.
Each field in the Logical Station Information panel is represented in the message
element by an ASCII string. Each ASCII string in the message element is
separated by a semicolon. When reconfiguring the Logical Station Information
panel using the Set Remote Parameters command, you only specify the fields you
want to change. If one of the Logical Station Information fields is unchanged, a
semicolon place holder must be used in the Set Remote Parameters command
message element. When reconfiguring the Logical Station Information panel
using this message element, refer to “Siemens H1 Communications” on page 441.
You must always construct the message element to be the following ASCII
representation of the Siemens H1 Logical Station Information panel fields. 18
External Device
Remote Adapter Address Enter 12-hexadecimal digits
Interface
Solicited Rd Remote FCHP TSAP ID Any 8-character ASCII string
Solicited Rd Local FCHA TSAP ID Any 8-character ASCII string
Solicited Wr Remote RECV TSAP ID Any 8-character ASCII string
Solicited Wr Local SEND TSAP ID Any 8-character ASCII string
Unsolicited Rd Remote SEND TSAP ID Any 8-character ASCII string
Unsolicited Rd Local RECV TSAP ID Any 8-character ASCII string
Siemens H1
080006010005;RMT_FCHP;LCL_FCHA;RMT_RECV;LCL_SEND;RMT_SEND;LCL_REC;
where
080006010005; Is the hexadecimal remote adapter address of the Siemens H1
Ethernet
RMT_FCHP; Is the Solicited Rd Remote FCHP TSAP ID
LCL_FCH; Is the Solicited Rd Local FCHA ID TSAP ID
RMT_RECV; Is the Solicited Wr Remote RECV TSAP ID
LCL_SEND; Is the Solicited Wr Local SEND TSAP ID
RMT_SEND; Is the Unsolicited Rd Remote SEND TSAP ID
LCL_REC Is the Unsolicited Rd Local RECV TSAP ID
; (Semicolon) Terminates the message string
External Device
semicolon. When reconfiguring the Siemens Logical Station Information panel
using the Set Remote Parameters command, you only need to specify the fields
Interface
that change. If one of the Siemens Logical Station Information panel fields
remains unchanged, a semicolon place holder must be used in the Set Remote
Parameters command message element. You must always construct the message
element to be an ASCII representation of the Siemens Logical Station Information
panel.
For example, the following message element changes the Ethernet address of a
logical station but keeps the current TSAP ID (does not change the TSAP IDs):
80006010005;;;;;;;
where
080006010005 Is the hexadecimal remote adapter address of the Siemens H1
Ethernet
;;;;;; (Six semicolons) Are placeholders for the unchanged fields in the
Siemens Logical Station Information panel
; (Semicolon) Terminates the message string
The Siemens H1MP allows you to use logical station commands to change the
physical station address within the logical station at run time using the Set
Remote Parameters command.
In this example, read/write table 2 is configured to read ten 2-byte integers from
an external PLC. The logical station number is configured as 1. In Siemens
read/write table 1, the message element set_param_msg is configured to be logical
station command, Set Remote Parameters. This means you can construct
Siemens H1
set_param_msg to alter the physical station address inside logical station 1. Then,
before table 1 is triggered, you can trigger table 1 which will override the Siemens
Logical Station Information panel fields, allowing you access to different PLCs at
run time without configuring separate Read/Write and Logical Station tables.
Protocol
Module
Base
Module
set_param_msg
CML
External Device
Interface
Table 2 defines a read/write table to access ten 2-byte integers in logical station 1.
The set_param_msg element in table 1 is configured to change the physical
station configured as logical station 1 at run time. Therefore, you do not need to
configure any more read/write tables to read ten 2-byte integers. Table 2 alone can
be used to read ten 2-byte integers from any external device by setting
set_param_msg and triggering table 1 before you trigger table 2.
Siemens H1
Instead of hard-coding the index values into a line of the Siemens H1 Read/Write
Information panel, the Set Logical Station Variables command allows each logical
station to have eight variable index values called logical station variables. These
variables have the following characteristics:
• For both the S5 and S505 logical stations, they are unsigned-bytes with values
ranging from 0 - 255.
• For S5 logical stations with zero-based addressing (addresses begin with zero)
on the communications line, the variable index values equal the value specified.
(For example, for a specified value of 3, the variable value is 3.)
• For S505 stations with zero-based addressing on the communications line and
one-based addressing (addresses begin with one) in the address description, the
variable index values equal the specified value decremented by one. (For
example, for a specified value of 3, the variable value is 2.)
• At DCM startup, the S5 variable index values default to 0. The S505 variable
index values default to 1.
Format
18
The Set Logical Station Variables command is configured as a message element.
You change this element at run time to represent the new values for the logical
station variables. The value of each variable is separated by a semicolon. When
External Device
reconfiguring the logical station variables using the Set Logical Station Variables
command, you only need to specify the variables that change. If one of the logical
Interface
station variables is unchanged, a semicolon place holder must be used in the Set
Logical Station Variables command message element. You must always construct
the message element to be an ASCII representation of the logical station
variables.
For example, to set the logical station variables for an S5 logical station at start
up to:
1 2 3 4 5 6 7 8
5 0 0 0 0 12 0 15
You can use these variables for the element number in S505 Loop and Alarm
variables, or as the first index in double index regions in either S5 or S505 logical
stations.
Note
The Siemens H1MP allows you to use logical station variables to control the Siemens H1
Region Index in the Read/Write Information panel at run time. This provides the
flexibility to change the data blocks you access within the PLC at run time using a
Math and Logic procedure without having to configure a new read/write table.
In this example, read/write table 2 is configured to read ten 2-byte integers from
an external PLC. The Region Index value is configured to be logical station variable
number 3. This means when table 2 is triggered, it will look in the third logical
station variable for the Region Index value.
PLC
Protocol
Module
Base
Module
set_sta_msg
CML
External Device
Interface
You can use this element at run time to dynamically set Region Index 3 for table 2.
Once you set the value of set_sta_msg in an IML procedure and trigger the table,
the logical station variables take on the values as specified in the element
set_sta_msg. You then trigger table 2 and read the ten 2-byte integers. Notice in
table 2 the Region Index starts with a negative number. This indicates that logical
station variable 3 contains the actual Region Index table 2 will read.
Siemens H1
A block write table which contains logical station commands can only contain
logical station commands; otherwise row errors occur. Row errors may result from
any of the following conditions:
• If a table has a Set Parameters command as its first entry (by logical port), for
example, and a command other than a Set Parameters command is given.
• If a table does not contain a logical station command as its first entry (by logical
port) and a logical station command is given.
In a single block write table, the Siemens H1 protocol module can define multiple
logical station Set Parameters commands (instead of defining multiple logical
stations in multiple block write tables). However, no provisions are made in the
Siemens H1 to check for multiple commands to the same logical station.
Therefore, should multiple commands be made to the same logical station, the last
command processed defines the values for the logical station.
Note
C ABLE D IAGRAMS
18
This section contains information about connecting the Siemens H1 Ethernet
system using a thick net or thin net bus.
External Device
Thick Net Bus
Interface
Figure 18-3 illustrates two PCs running FactoryLink using a thick net bus. The
first PC uses a transceiver cable through a transceiver to connect to the Ethernet
bus. The second PC uses a thin net coax cable through a thick-to-thin transceiver
to connect with the Ethernet bus. A transceiver cable through a transceiver to the
Ethernet bus connects the Siemens S5 PLC with a CP535 or CP143 card.
Figure 18-3 Thick Net Bus
PC with FactoryLink
CP535/CP143
Siemens
S5 PLC
Transceiver Cable
(Thick to Thin)
Bus Cable Transceiver Cable Bus Cable
Siemens H1
Coax Cable
(Thin Net)
PC with FactoryLink
CP535/CP143
Siemens
S5 PLC
Thin Transceiver
Transceiver Cable
External Device
type.
Interface
This section lists the data conversions for FactoryLink real-time database
elements:
• Digital
• Analog
• Floating-point
• Floating long analog
• Message
BCD3 2-byte 3-digit Binary Coded Decimal with sign maximum: 999;
minimum: -999
BCD7 4-byte 7-digit Binary Coded Decimal with sign maximum: 32767;
minimum: -32768
18
Table 18-11 Floating Point Conversion
External Device
BIN Same as FLT
Interface
BCD3 2-byte 3-digit Binary Coded Decimal with sign maximum: 999;
minimum: -999
BCD3 2-byte 3-digit Binary Coded Decimal with sign maximum: 999;
Siemens H1
minimum: -999
For each FactoryLink platform, the Siemens H1 EDI package contains an adapter
External Device
display utility, H1MPDISP.EXE, that provides the following services:
Interface
• Verifies the configuration of the Ethernet adapter
• Provides the proper address to be programmed into the Siemens Ethernet
Interface card
where
Adapter# Is the LAN adapter number of the LAN adapter described in the
remainder of the line.
Accessible Indicates whether the adapter is properly configured and
accessible to the DCM task:
If YES, then the adapter can be accessed and is valid for the
Siemens H1.
If NO, then the adapter cannot be accessed and is either not
installed or improperly configured.
CP Address Is a 12-character hexadecimal address you must program into the
Siemens CP535/CP143 Ethernet Interface card. It is the remote
adapter address for each job (ANR) that communicates with this
adapter.
Siemens H1
For information about the messages displayed for the EDI task and the format in
which protocol module messages are generated, see Chapter 10, “Messages and
Codes.”
0001h
Cause: Internal protocol module error.
Action: Call Customer Support for assistance.
0002h
Cause: Communication error.
Action: Verify you have properly configured the External Device
Definitions and Logical Station Information tables and the
Ethernet installation and the Siemens CP535 programming
parameters are correct.
0003h
Cause: Communication error.
Action: Verify the Siemens CP535 and the PLC programming
parameters are correct.
0004h
Cause: Internal protocol module error.
Action: Call Customer Support for assistance.
XX05h
Cause: Received Siemens error code ’XX’h in response packet. 18
Action: For a list of error codes that correspond to the XX values in this
error message, consult the Siemens Communication Processor
External Device
CP535 with COM 535 Programming Package (S5 DOS Version),
Chapter 8, Order No. 6ES5998-6SA21, Release 04.
Interface
0006h
Cause: Invalid response packet length.
Action: Call Customer Support for assistance.
0007h
Cause: Internal protocol module error.
Action: Call Customer Support for assistance.
0008h
Cause: A “FLT” value in the PLC contains invalid floating-point data.
Action: Verify the value being read is an “FLT.”
0009h
Cause: Inactive station. A solicited (read or write) operation was
requested to an inactive station. This may occur at start up of
the protocol module.
Action: Allow sufficient time to establish communication before
initiating a solicited operation. If the error persists, ensure the
Siemens H1 Logical Station Information panel and Siemens CP
programming parameters match. Verify the station has not been
disabled through a logical station activate/deactivate command. Siemens H1
AXXXh
Cause: Invalid value was entered for the logical station commands (set
parameters or activate/deactivate station).
Action: For a list of the logical station command error codes, refer to
“Run-Time Logical Station Command Error Codes” on page 496.
Correct the value in the field that is specified by the error code.
For an invalid element value, the logical station generates the error code 0xAyXX
where
A Is an error from a logical station command
y Is the specific command
y=1 is the Activate/Deactivate Station command
y = 2 is the Set Remote Parameters command
y = 3 is the Set Logical Station Variables command
XX Is the error code for the specified field in error
When the protocol module detects an error, it puts the logical station in an
unknown configuration state, and the logical station becomes inactive. To free the
station from this unknown state, issue a set parameters command for that logical
station or restart the logical port.
For the Activate/Deactivate Station command, the logical station generates error
code 0xA101. Theoretically, the Activate/Deactivate command cannot produce
errors since it uses only digital elements whose values, set and reset, are both
valid. However, for consistency in error reporting, the logical station generates
this error code. The logical station generates error code 0xA2XX for the Set
Parameters command.
The following list defines the codes for both the Activate/Deactivate and Set
Parameters commands: 18
Table 18-14 Activate/Deactivate and Set Parliamentary Codes
External Device
Code Description
Interface
0xA101 Activate/Deactivate command
Siemens H1
•
•
•
•
Square D
19
External Device
Interface
This chapter contains information needed to set up and configure bidirectional
communications between the FactoryLink real-time database and Square D
SY/MAX devices using the IEEE 802.3 communications protocol or SY/MAX
point-to-point serial communications.
Note
When you Choose Square D from the Configuration Manager Main Menu, the
Square D
Square D configuration panels are displayed:
Complete a row for each logical port specified in the External Device Definition
panel you want to define as a communication path for read and write operations.
Note
Logical Port Enter a number, defined in the External Device Definition panel
Logical Port column, to represent a particular communication path
to a device.
Valid Entry: previously defined logical port number
Device Enter a tag name for a message element to which a text string
Message Tag will be written to indicate a communications error associated
with this logical port. For information about displaying the text
stored in a Device Message Tag element for an operator using this
application, see the Application Editor User Guide.
Valid Entry: standard element tag name
Valid Data Type: message
External Device
Source A text string that identifies the source route address defined in
Route the SR1 column is displayed.
Interface
Address
Valid Entry: leave blank (display only)
SR1 Enter the source route address or drop number of a network
interface module not being used on the Sylink network.
For serial communications, enter the source route address. If you
do not need additional routing, accept the system default of 255.
For Ethernet communications, enter the source drop number (see
the description for Source Drop Number).
Valid Entry: 0 - 255 (default=255)
Source Drop For Ethernet communications, enter the source drop number on
Number the Ethernet network. If you enter a number in this column,
enter the same number in the previous column, SR1.
Square D
For serial communications, accept the system default of 255.
Valid Entry: 0 - 255 (default=0)
Note
For the fields Baud Rate through Stop Bits, be sure to enter values
that correspond to the device hardware configuration for all
devices communicating through the specified logical port. To
determine the proper settings, refer to the device manufacturer’s
documentation.
Baud Rate Enter the speed at which the protocol module communicates with
the devices linked to FactoryLink via this logical port. This entry
must match the baud rate configuration of the devices. Refer to
the device manufacturer’s documentation for details.
Valid Entry: 110 - 115200 (default=9600)
Parity Enter the parity error correction during transmission via this
logical port.
Valid Entry: even
When the panel is complete, click Enter to validate the information. Define the
data type (message) for any tag names displayed in the Tag Definition dialog.
Table 19-1 provides sample entries for a row defining an Ethernet logical port (the
entry in the Function column in the External Device Definition panel is
ETHERNET):
Table 19-1 Sample Square D Logical Station Control Panel Entries (Continued)
19
Column Entry Description
Baud Rate 9600 This baud rate entry (the speed at which
External Device
the FactoryLink station communicates
with the device) of 9600 must match the
Interface
baud rate configuration of the Square D
devices communicating with
FactoryLink via logical port 0.
Parity EVEN The parity error correction for
transmission via logical port 0 is even
and must match the parity configuration
of the devices using this port.
Data Bits 8 The devices configured for
communications via logical port 0
require 8 data bits.
Stop Bits 1 The devices configured for
communications via logical port 0
Square D
require a stop bit of 1.
Complete a row for each device to communicate through this logical port.
Error/Status Tag Enter a tag name for an analog element in which to store
Name communications error codes associated with this device (logical
station). For information about displaying the codes stored in an
Error/Status Tag Name element for an operator using this
application, see the Application Editor User Guide.
Valid Entry: standard element tag name
Valid Data Type: analog
Logical Enter a number to identify the logical station to which the
Station information in this row pertains. A logical station represents the
combination of a logical port with a physical station. Assign a
unique number to each device communicating through this
logical port.
You will later enter this logical station number in a read or write
table to represent the device defined in this row. In a read or
write table, this number will identify the device to or from which
data is to be sent or received.
Valid Entry: 0 - 999
External Device
Destination Route A text string that identifies the destination route address defined
Interface
Address in the DRn column for this row is displayed.
Valid Entry: leave blank (display only)
DR1 Enter the destination route address or drop number of a network
interface module connecting to a separate Sylink network.
For serial communications, enter the destination route address. If
you do not need additional routing, accept the system default of
255.
For Ethernet communications, enter the destination drop number
(see the description for Destination Drop Number).
Valid Entry: 0 - 255 (default=255)
DR2 through DR7 If needed, define up to six additional destination route addresses.
If not needed, accept each field’s default of 255.
Square D
Valid Entry: 0 - 255 (default=255)
Destination Drop For Ethernet communications, enter the destination drop number
Number on the Ethernet network. If you enter a number in this column,
enter the same number in the DRn column for this row.
For serial communications, accept the system default of 255.
Valid Entry: 0 - 255 (default=255)
Maximum Define the maximum number of bytes the device defined in this
Packet row can transmit in one message. Most Square D devices can
size transmit 256 bytes, or 128 registers of data. The protocol being
used (point-to-point or IEEE 802.3) does not affect the maximum
packet size.
Valid Entry: 0 - 256 (default=256)
When the panel is complete, click Enter to validate the information. Define the
data type (analog) for any tag names displayed in the Tag Definition dialog.
Table 19-2 provides sample entries for a row defining a logical station
communicating via the logical port specified on the Logical Station Control panel.
DR3 255
DR4 255
DR5 255
DR6 255
DR7 255
Destination 54 The drop location of the device on the
Drop Number network path is 54.
Maximum 256 The device defined as logical station 0 can
Packet Size transmit up to 256 bytes in one message.
External Device
Interface
Square D
Complete a row for each read or write table.
Tip
Table Name Give this read or write request a name. Define one request (table)
per line and do not include spaces in the name. You can define as
many tables in this panel as available memory allows. Try to
make the table name reflective of the operation it represents.
If this is a triggered read or a block write table, when the trigger
element (Block Read Trigger for a read operation or Block Write
Trigger for a write operation) is forced to 1 (ON), the element
prompts FactoryLink to process this table and any other table in
which the same trigger is defined.
Valid Entry: alphanumeric string of up to 16 characters
Tip
Block Read If this is a block read operation, enter a number to indicate the
Priority priority of this table, relative to other read operations. The
highest priority is 1. This number influences the order in which
the EDI task handles the queuing of block read requests. If EDI
receives two requests at the same time, it processes the request
with the highest priority first. The default is 1.
External Device
Note
Interface
The Block Read Trigger, Block Read Disable, Block Read Complete, and
Block Read State elements apply only to triggered read operations.
Do not define these elements for unsolicited read operations or for
write operations.
Block Read If this is an unsolicited read or a write operation, ignore this field.
Trigger
If this is a triggered read operation, this field is required. Enter a
tag name for a digital element to initiate a block read of the
addresses specified in the Read/Write Information panel. When
this element’s value is forced to 1 (ON), the addresses are read.
Valid Entry: standard element tag name
Valid Data Type: digital
Square D
Block Read If this is an unsolicited read or a write operation, ignore this field.
Disable
If this is a triggered read operation, this field is optional. If you
need a digital element to disable a block read of the elements
specified in this table, enter a tag name. When this tag’s value is
forced to 1 (ON), the read operation is not executed, even when
the block read trigger is set to 1.
To re-enable a block read table that has been disabled, set this
element back to 0 (OFF).
Valid Entry: standard element tag name
Valid Data Type: digital
Tip
Note
The Block Write Trigger, Block Write Disable, Block Write Complete, and
Block Write State elements apply only to write operations. Do not
define these elements for read operations.
Block Write Trigger If this is a read operation or an exception write operation you do
not plan to periodically disable, ignore this field. 19
If this is a block write table or an exception write table you plan
to periodically disable, this field is required. Enter a tag name for
a digital element to initiate a block write of the element values
External Device
specified in the Read/Write Information panel to the addresses
Interface
defined to receive the values. When this element’s value is forced
to 1 (ON), FactoryLink writes the values.
Valid Entry: standard element tag name
Valid Data Type: digital
Block Write If this is a read operation or an exception write operation you do
Disable not plan to periodically disable, ignore this field.
If this is a block write table or an exception write table you plan
to periodically disable, this field is optional. Enter a tag name for
a digital element to disable a block write to the addresses
specified in this table. When this tag’s value is forced to 1 (ON),
the write operation is not executed, even when the block write
trigger is set to 1.
To re-enable a block write table that has been disabled, set this
Square D
element back to 0 (OFF).
Valid Entry: standard element tag name
Valid Data Type: digital
Tip
When the panel is complete, click Enter to validate the information. Define the
data type (digital) for any tag names displayed in the Tag Definition dialog.
Table 19-3 provides sample entries for a row defining a triggered read table:
19
Table 19-3 Sample Square D Read/Write Control Panel Entries
External Device
Table READ The name of this table is READ.
Interface
Name
Square D
FactoryLink reads the configured
address and writes its value to the
element configured for this table (in
the Read/Write Information panel).
Block Read SQRD_READ_DISABLE When the value of
Disable SQRD_READ_DISABLE is 1,
FactoryLink disregards the trigger
element, SQRD_READ_TRIGGER,
and does not process the READ table.
Block Read SQRD_READ_COMPLETE Once the data is read and stored in
Complete the database element defined (in the
Read/Write Information panel) to
receive it, FactoryLink forces a value
of 1 to SQRD_READ_COMPLETE.
Block Read SQRD_READ_STATE Once the data is read and stored in
State the database element defined to
receive it, FactoryLink forces a value
of 1 to SQRD_READ_STATE. During
the read operation,
SQRD_READ_STATE is set to 0.
Block Write
Disable
Block Write
State
External Device
Interface
Square D
For a Read Table—Add a panel entry for each FactoryLink database element in
which data read from the device will be stored when the operation executes.
For a Write Table—Add a panel entry for each element to be written when the
operation executes.
Tip
Tag Name For a read table, specify a tag name for an element in which
FactoryLink will store the data read from the device.
For a write table, specify a tag name for an element containing a
value to be written to the device.
Valid Entry: standard element tag name
Valid Data Type: digital, analog, longana, float
When the panel is complete, click Enter to validate the information. Define the
data type (digital, analog, long analog, or floating-point) for any tag names
displayed in the Tag Definition dialog.
Table 19-4 provides sample Read/Write Information panel entries for the triggered
read table defined in Table 19-3 on page 513. 19
Table 19-4 Sample Square D Read/Write Information Panel Entries
External Device
Field Entry Description
Interface
Table Name READ The table name defined in the Read/Write
Control panel is displayed.
Tag Name REG_DIG1 When the READ table is triggered by
SQRD_READ_TRIGGER (defined in the
Read/Write Control panel), FactoryLink
processes the table. The value read from the
device is stored in REG_DIG1.
Logical Station 0 The value stored in this element is read
from the Square D device configured as
logical station 0.
Data Type REGISTER A register address is being read.
Square D
Address 426 The address of the register is 426.
Bit Offset 12 The bit offset containing the value being
read is 12.
Priority NORMAL This read operation will be processed
according to the priority specified in the
Read/Write Control panel.
Pins 7 and 8
are jumped
together.
External Device
message tag, see “Configuring the Logical Station Control Panel” on page 500. For
information about configuring an analog tag, see “Configuring the Logical Station
Interface
Information Panel” on page 504.
For information about the messages displayed for the EDI task and the format in
which protocol module messages are generated, see Chapter 10, “Messages and
Codes,” of this guide.
SQRD8023 Messages
Square D
SQRD8023: Error sending connect command
Cause: Task was unsuccessful in sending the connect command. This
command is part of initialization and terminates with this error.
Action: Device address of drop may be incorrect.
These errors are associated with return data to the FactoryLink EDI task and the
logical port error message element. They appear in the format described in “EDI
Run-Time Manager Line Format” on page 186.
The following information is also returned to the Device Message Tag element
defined in the Logical Station Control panel:
SQRDDST: LSTA - yyy Error - xxx:sss
where:
yyy Is the logical station where the error occurred
External Device
Interface
Square D
6 Received too many NAKs Resent the packet the retry number
without receiving ACK.
•
•
•
•
Texas Instruments
20
External Device
Interface
This chapter contains information needed to set up and configure bidirectional
communications between the FactoryLink real-time database and various devices
in either of two ways:
• Directly (point-to-point mode) via a COM port on the system unit
• Over a TIWAY Serial Unilink network (TIWAY mode) via a COM port on the
system unit through the TIWAY Host Adapter module
The following table lists the supported device types for point-to-point and network
communications:
DIP Switches
Set the following switches on the Host Adapter. (See Dip Switch Settings for NITP
Protocol Table.)
DIP switch 1 switch 1 up
switch 2 up
switch 3 down
switch 4 down
switch 5 configurable (See Baud Rate Table.)
switch 6 configurable (See Baud Rate Table.)
switch 7 configurable (See Baud Rate Table.)
switch 8 configurable (See Baud Rate Table.)
switch 9 configurable (See Host Command Timeout Table.)
switch 10 configurable (See Host Command Timeout Table.)
DIP switch 2 switch 1 up
switch 2 down
switch 3 up
switch 4 down
switch 5 configurable (See Baud Rate Table.)
switch 6 configurable (See Baud Rate Table.)
switch 7 configurable (See Baud Rate Table.)
switch 8 configurable (See Baud Rate Table.)
switch 9 down
switch 10 down
1 2 3 4 5 6 7 8 9 10
External Device
U
P
Dipswitch 1
Interface
Host Command timeout
TIWAY I Baud Rate
Up Synchronous
Down Asynchronous
Up Full Duplex
Down Half Duplex
Up NRZI
Down NRZ
Up NITP
1 2 3 4 5 6 7 8 9 10
U
P
Dipswitch 2
Up Test Mode
Down Run Mode
Up HIU/EHA &
IO Loop Test
Down MHIU/EHA
Up Synchronous
Down Asynchronous
Up Even Parity
Down Odd Parity
Up Parity Enabled
Use Figure 20-2 to set the baud rate on DIP switches 1 and/or 2:
Figure 20-2 DIP Switch Baud Rates
0 1 0 0 110
0 1 0 1 150
0 1 1 0 300
0 1 1 1 600
1 0 0 0 1200
1 0 0 1 2400
1 0 1 0 4800
1 0 1 1 9600
1 1 0 0 19200
1 1 0 1 38400
1 1 1 0 57600*
1 1 1 1 115200*
0 = Down 1 = Up
Up Down
1 0
Timeout
20
Use Figure 20-3 to set the host PC’s command timeout:
Figure 20-3 Host Command Timeout Table
External Device
Interface
DIPSWITCH 1
Position
9 10 Description
Up Up 40 sec Timeout
Texas Instruments
KEYDELAY OFF
LCKBIT OFF
NRZI/NRZ NRZI
X.25/HDLC HDLC
FULL/HALF HALF
SYNC/ASYNC ASYNC
BAUD 115.2K
NETWORK ADDRESS 1-254 ARE VALID ADDRESSES
Note
External Device
Before completing the protocol-specific Texas Instruments
configuration panels, you must complete the External Device
Interface
Definition panel. See “Identifying Protocol Types and Defining
Logical Ports” on page 70 for details.
Texas Instruments
If you are communicating directly (point-to-point) with a single TI PLC, you do not
need to configure this table.
Table 20-2 provides sample entries for the Texas Instruments TIWAY Unilink
Setup panel: 20
Table 20-2 Sample Texas Instruments TIWAY Unilink Setup Panel Entries
External Device
Field Entry Description
Interface
Logical Port for 0 Specifies the logical
UNILINK communication path configured
by this table
Comment Port 1 as MHIU Port 1 communicates with a
TIWAY Host Adapter
From the Unilink Setup panel, select the row for the logical port you are
configuring and click on Next to bring the Unilink Setup Information panel to the
foreground.
Texas Instruments
Table 20-3 provides sample entries for the Texas Instruments TIWAY Unilink
Setup Information panel: 20
Table 20-3 Sample Texas Instruments TIWAY Unilink Setup Information Panel Entries
External Device
Field Entry Description
Interface
Adapter Mode MHIU Host Adapter is configured for
MHIU mode
Adapter Station 5 Address for Host Adapter on the
network
Adapter Max Station 1 The highest NIM address on the
Address network is 1
NM Option 1 - 9, A-E 1 Not configured because the Host
Adapter is configured in MHIU
mode
HIU Option 1-3 0
Texas Instruments
Complete a row for each logical port specified in the External Device Definition
panel you want to define as a communication path for read and write operations.
Logical Port Enter a number, defined in the External Device Definition panel
Logical Port column, to represent a particular communication path
to a TI device.
Valid Entry: previously defined logical port number
Baud Rate Enter the speed at which the protocol module communicates with
the devices linked to FactoryLink via this logical port. This entry
must match the baud rate configuration of the devices. Refer to
the device manufacturers documentation for details.
Valid Entry: 110, 150, 300, 600, 1200, 2400, 3600, 4800, 7200,
9600, 19200 (default=9600)
Recommended entry is 19200 if using a TI PLC on a TIWAY
network or 9600 if using a point-to-point TI PLC. However, if
using hardware requiring special parameters, you may need to
enter a different baud rate.
Parity Enter the parity error correction during transmission via this
logical port. This entry must match the configuration of the 20
devices communicating via this port. Refer to the device
manufacturers documentation for details.
Valid Entry: odd, even, none
External Device
Data Bits Enter the number of data bits used during transmission via this
Interface
logical port. This entry must match the configuration of the
devices communicating via this port. Refer to the device
manufacturers documentation for details.
Valid Entry: 5, 6, 7, 8
The recommended entry is 7. However, if using hardware
requiring special parameters, you may need to enter a different
data bit.
Stop Bits Enter the number of bits sent after a character to create a pause
before the start of the next character. This entry must match the
configuration of the devices communicating via this port. Refer to
the device manufacturers documentation for details.
Valid Entry: 1, 2
The recommended entry is 1. However, if using hardware
requiring special parameters, you may need to enter a different
stop bit.
Timeout Enter the length of time, in tenths of a second, the protocol
module will wait to receive a response to a read or write command
before timing out. You must enter a value greater than 0 for the
protocol module to timeout.
Valid Entry: 0 - 32000
Error Msg (Optional) Enter a tag name for a message element to which a
Tag Name text string will be written to indicate a communications error
associated with this logical port.
Valid Entry: standard element tag name Texas Instruments
Valid Data Type: message
When the panel is complete, click on Enter to validate the information. Define the
data type (message) for any tag names displayed in the Tag Definition dialog.
Table 20-4 Sample Texas Instruments Logical Station Control Panel Entries
External Device
Interface
Complete a row for each device to communicate through this logical port.
Error/Status Tag (Optional) Enter a tag name for an analog element in which to
Name store communications error codes associated with this device
(logical station).
You can animate output-text objects to display the codes stored in
an Error/Status Tag Name element on a graphics screen. Refer to
the Application Editor User Guide for more information. Texas Instruments
Valid Entry: standard element tag name
Valid Data Type: analog
Logical Station Enter a number to identify the logical station to which the
information in this row pertains. A logical station represents the
combination of a logical port with a physical station. Assign a
unique number to each device communicating through this
logical port.
TWY520C PLC525
TWY525 PLC530C
TWY530C PLC530T
TWY530T PLC535
TWY535 PLC540
TWY560 PLC565
TWY565
TWYRTU
TWY5TI
Physical Station Physical station address of the device with which the EDI task
communicates when using this logical station in a Read/Write
table.
Valid Entry: 1 - 254 (Normally, the physical station number is
the same as the logical station number.)
Comment (Optional) Enter reference information about this logical station.
Valid Entry: alphanumeric string of up to 31 characters
When the panel is complete, click on Enter to validate the information. Define the
data type (analog) for any tag names displayed in the Tag Definition dialog.
Table 20-5 provides sample entries for the Texas Instruments Logical Station
Information panel: 20
Table 20-5 Sample Texas Instruments Logical Station Information Panel Entries
External Device
Field Entry Description
Interface
Error/Status Tag Name TI_STATION0_ Contains information about
STATUS communication errors
Logical Station 0 Specifies the logical
communication paths.
Device Type TWY565 Specifies the type of device
connected to the communication
path.
Physical Station 1 Specifies the physical station
numbers associated with the
logical path.
Comment TI, PORT 0
Texas Instruments
Note
External Device
Refer to Chapter 8, “Application Design Tips and Techniques,” for
information about triggering schemes using elements defined in
Interface
this panel.
Table Name Give this read or write request a name. Define one request (table)
per line and do not include spaces in the name. You can define as
many tables in this panel as available memory allows. Try to
make the table name reflective of the operation it represents.
If this is a triggered read or a block write table, when the trigger
element (Block Read Trigger for a read operation or Block Write
Trigger for a write operation) is forced to 1 (ON), the element
prompts FactoryLink to process this table and any other table in
which the same trigger is defined.
Valid Entry: alphanumeric string of up to 16 characters
Exception For EDI to interpret this operation as a triggered block write or
Write as a read operation, accept the default of NO.
For EDI to interpret this operation as an exception write and
write element values to the device only when those values
change, enter YES. Do not specify elements expected to change at
frequent and unpredictable intervals in an exception write table.
Any element specified will be written to the device in its own
packet (message) each time it changes. Defining elements that
change value frequently as exception writes can slow down
communications or result in an error message.
In an exception write, an internal change-status indicator within
the element containing the data to be written prompts the write
operation. If an element is configured for an exception write and Texas Instruments
EDI recognizes this indicator has been set since the last scan of
the real-time database (indicating the value of the element has
changed), EDI writes this element’s value to the device.
Valid Entry: yes, no (default = no)
Note
The Block Read Trigger, Block Read Disable, Block Read Complete, and
Block Read State elements apply only to triggered read operations.
Do not define these elements for write operations.
Tip
The Block Read Disable element can be used to disable a block read
operation that is either part of a cascaded loop or is self-triggered.
The triggering cycle will cease upon disabling, however. To
re-enable a cascaded loop or a self-triggered read table, the Block
Read Trigger element must be toggled or forced to 1. Refer to
Chapter 8, “Application Design Tips and Techniques,” for details.
External Device
the block read trigger is set to 1.
Interface
To re-enable a block read table that has been disabled, set this
element back to 0 (OFF).
Valid Entry: standard element tag name
Valid Data Type: digital
Block Read If this is a write operation, ignore this field.
Complete
If this is a triggered read operation, this field is optional. If you
need a digital element to indicate when this operation is
complete, enter a tag name. This element is forced to 1 (ON) at
startup. After the elements defined in the Read/Write
Information panel have been updated in the FactoryLink
database, the complete element is forced to 1 again.
Do not use this element when more than one logical port is
specified in a single table.
Valid Entry: standard element tag name
Valid Data Type: digital
Block Read State If this is a write operation, ignore this field.
If this is a triggered read operation, this field is optional. If you
need a digital element to indicate the state of this operation (in
progress or complete), enter a tag name. This element is forced to
1 (ON) at startup. While the table is being processed, the element
is set to 0 (OFF). After the elements defined in the Read/Write
Information panel have been updated in the FactoryLink
database, the state element is forced back to 1.
Valid Entry: standard element tag name Texas Instruments
Valid Data Type: digital
Note
The Block Write Trigger, Block Write Disable, Block Write Complete, and
Block Write State elements apply only to write operations. Do not
define these elements for read operations.
Block Write Trigger If this is a read operation or an exception write operation you do
not plan to periodically disable, ignore this field.
If this is a block write table or an exception write table you plan
to periodically disable, this field is required. Enter a tag name for
a digital element to initiate a block write of the element values
specified in the Read/Write Information panel to the addresses
defined to receive the values. When this element’s value is forced
to 1 (ON), FactoryLink writes the values.
Valid Entry: standard element tag name
Valid Data Type: digital
Tip
The Block Write Disable element can be used to disable a block write
operation that is either part of a cascaded loop or is self-triggered.
The triggering cycle will cease upon disabling, however. To
re-enable a cascaded loop or a self-triggered write table, the Block
Write Trigger element must be toggled or forced to 1. Refer to
Chapter 8, “Application Design Tips and Techniques,” for details.
External Device
specified in this table. When this tag’s value is forced to 1 (ON),
Interface
the write operation is not executed, even when the block write
trigger is set to 1.
To re-enable a block write table that has been disabled, set this
element back to 0 (OFF).
Valid Entry: standard element tag name
Valid Data Type: digital
Block Write If this is a read or exception write operation, ignore this field.
Complete
If this is a block write table, this field is optional. If you need a
digital element to indicate when this operation is complete, enter
a tag name. This element is forced to 1 (ON) at startup. After the
data defined in this table’s Read/Write Information panel has
been written to the device, the complete element is forced to 1
again.
Do not use this element when more than one logical port is
specified in a single table.
Valid Entry: standard element tag name
Valid Data Type: digital
Block Write State If this is a read or exception write operation, ignore this field.
If this is a block write operation, this field is optional. If you need
a digital element to indicate the state of this operation (in
progress or complete), enter a tag name. This element is forced to
1 (ON) at startup. While the table is being processed, the element
is set to 0 (OFF). After the data defined in this table’s Read/Write
Information panel has been written to the device, the state Texas Instruments
element is forced back to 1.
Do not use this element when more than one logical port is
specified in a single table.
Valid Entry: standard element tag name
Valid Data Type: digital
When the panel is complete, click on Enter to validate the information. Define the
data type (digital) for any tag names displayed in the Tag Definition dialog.
External Device
Interface
For a Read Table—Add a panel entry for each FactoryLink database element in
which data read from the device will be stored when the operation executes.
For a Write Table—Add a panel entry for each element to be written when the
operation executes.
Tip
Texas Instruments
Alternatively, the elements you define in the Read/Write
Information panel can be configured in the tag definition dialog in
the Application Editor. Refer to the Application Editor User Guide
for details.
C - CR packed Digital
External Device
DCP - drum count preset Analog
Interface
STW - status word Analog
Valid FactoryLink
Description
Entry Type
Valid FactoryLink
Description
Entry Type
Valid FactoryLink 20
Description
Entry Type
External Device
deviation
Interface
AYDA Analog alarm yellow Floating-point
deviation
Note
Use the PORT data type only with an exception write element. A 1
(one) written to this element closes the port associated with the
logical station for this element. No further reads or writes occur. A
0 (zero) written to this element opens the port. Use of the TIWAY
Network reinitializes the Unilink Host Adapter before further
reads or writes occur. After the port is reopened, reads and writes
will operate normally.
Address Enter the address of the memory location (word) being read or
written to. The system reads the value at the address and
transfers it to the element specified in the Tag Name column. The
amount of memory assigned to each PLC data type depends on
several factors, including the PLC model and the amount of
memory installed in the system. If not using the loop indexing
feature, do not configure more than one Read/Write table to write
to the same address.
If using the loop indexing feature, the Address field may need to
be left blank. Refer to “Loop Indexing” on page 554 for
information about configuring tables for loop indexing.
DCP, LRDS, LRRC, LRST, and LSDB data types require you
employ additional parameters to determine the Address field
entry. Refer to “Additional Parameters for TI Data Types” on page
564 for information about these parameters.
Valid Entry: 1 - 32767, 1 - 64 (used with TI 545 or TI 565 PLCs
with s-memory; see additional data types listed
in the preceding table)
Loop Index If not using loop indexing, leave this field blank.
(Optional; use only with TI 545 or TI 565 PLCs having s-memory)
Alphanumeric string representing an analog element whose
value determines the loop element. The system reads the PLC
address specified in the Logical Station and Data Type fields and
writes the returned data to the loop element specified by the
value of the loop index variable. The value of this loop index
variable designates one of the elements specified in the Tag Name
field. The loop index variable is valid only for s-memory data
types such as loop variable and analog alarms.
Refer to the Data Type field description on page 548 for valid
s-memory data types. Refer to “Configuring Tables for Loop 20
Indexing” on page 554 for more information about loop indexing.
Valid Entry: NONE, LOOP1, LOOP2, LOOP3, LOOP4,
External Device
LOOP5, LOOP6, LOOP7, LOOP8, LOOP9,
LOOP10, LOOP11, LOOP12, LOOP13, LOOP14,
Interface
LOOP15, LOOP16 (default = NONE)
When the panel is complete, click on Enter to validate the information. Define the
data type (digital, analog, or floating-point) for any tag names displayed in the
Tag Definition dialog.
Table 20-7 provides sample entries for the Texas Instruments Read/Write
Information panel:
Up to 16 loop index variables can be defined. These loop index variables constitute
a loop index.
Next, to implement the loop indexing option, in the Texas Instruments Read/Write
Control panel, configure either a write trigger or enable the exception write.
The entries in the loop indexing Texas Instruments Read/Write Information panel
identify the analog loop index variables. The panel can include up to 16 loop index
variables. The value of each loop index variable specifies a different loop element
in the FactoryLink real-time database. Configure only one Texas Instruments
Read/Write Information panel to identify these loop index variables.
Logical Station Enter a number to identify the logical station to which the
information in this row pertains. A logical station represents the 20
combination of a logical port with a physical station. Assign a
unique number to each device communicating through this
logical port.
External Device
You will later enter this logical station number in a read or write
Interface
table to represent the device defined in this row. In a read or
write table, this number will identify the device to or from which
data is to be sent or received.
Valid Entry: 0 - 999
Data Type Specify the type of data being read from or written to the device
for each element defined in the Tag Name field.
Valid Entry: register, status
Address For a read table, enter the address in the device’s memory where
the value to be stored in this element is located.
For a write table, enter the address in the device’s memory to
which the element value will be written.
Valid Entry: 1 - 8192
Loop Index Enter an alphanumeric string representing a real-time database
analog element whose value determines the TI 545 or TI 565 loop
element. Loop index variable used only with TI 545 or TI 565
PLCs having s-memory.
Valid Entry: NONE, LOOP1, LOOP2, LOOP3, LOOP4,
LOOP5, LOOP6, LOOP7, LOOP8, LOOP9,
LOOP10, LOOP11, LOOP12, LOOP13, LOOP14,
LOOP15, LOOP16, (default = NONE)
Texas Instruments
In this example, table FB references the 16 loop elements (listed in the Tag Name
field) previously defined in the Graphics Mode Input task. The entries in the Loop
Index field reference the loop elements in the Tag Name field that are used by the
loop indexing Read/Write tables. For example, if a loop indexing Read/Write table
needs to reference the analog value contained in the element LOOPNDX1, you
must enter LOOP1 in its Loop Index field.
When the Texas Instruments Read/Write table is complete, choose Enter to accept
the information.
Next, configure one or more Read/Write tables for each loop index variable defined
in the initial Read/Write table.
The entries in the loop indexing Texas Instruments Read/Write Information panel
reference each loop index variable referenced in the initial Read/Write table and
the corresponding loop elements read by this variable. These entries also use the
loop index variable specified in the initial Read/Write table to identify loop
elements in the FactoryLink real-time database to be read or written to. The
panel can include up to 1,000 entries.
External Device
value to be written to the device.
Interface
Valid Entry: standard element tag name
Valid Data Type: digital, analog, floating-point
Logical Station Enter the number representing the device from which the data is
to be read or to which the element’s value will be written. This
number was originally defined in the Logical Station Information
panel for the logical port through which communications with
this device occurs.
Valid Entry: previously defined logical station number
Data Type Specify the type of data being read from or written to the device
for each element defined in the Tag Name field.
For valid data types for each channel, refer to the TIWAY 1
UNILINK Host Adapter User’s Manual.
FactoryLink
Valid Entry Description
Type
C CR packed Digital
Texas Instruments
WX Word input Analog
FactoryLink
Valid Entry Description
Type
FactoryLink
Valid Entry Description
Type
FactoryLink 20
Valid Entry Description
Type
External Device
LODA Loop orange deviation Floating-point
Interface
LYDA Loop yellow deviation Floating-point
FactoryLink
Valid Entry Description
Type
FactoryLink 20
Valid Entry Description
Type
External Device
ACFH Analog C flags high Analog
Interface
order
Note
Use the PORT data type only with an exception write element. A 1
(one) written to this element closes the port associated with the
logical station for this element. No further reads or writes occur. A
0 (zero) written to this element opens the port. Use of the TIWAY
Network reinitializes the Unlink Host Adapter before further
reads or writes occur. After the port is reopened, reads and writes
will operate normally.
Address For a read table, enter the address in the device’s memory where
the value to be stored in this element is located.
For a write table, enter the address in the device’s memory to Texas Instruments
which the element value will be written.
If no loop index variables have yet been specified, when used with
the loop indexing feature, this field acts as a default address for
the real-time database to write to at startup.
When all appropriate information has been specified, the panel should resemble
the following sample panel: 20
External Device
Interface
In this example, the value of LOOP1 designates which loop element, defined in
the Tag Name field, is to be read or written to. The system reads the PLC address
specified in the Logical Station, Data Type, and Loop Index fields and writes the
returned data to the appropriate loop element.
When FactoryLink initializes the database at startup, all elements’ values are set
to 0 and address 1 acts as a default loop element number because the loop write
element’s values have not yet been written. The protocol module reads or writes to
address 1 only if the loop index variable is 0. This prevents a meaningless read of
loop element 0.
When the table is complete, click on Enter to validate the information. Click on Exit
to return to the Main Menu. Texas Instruments
To determine the correct address field entry for each data type, follow the
corresponding procedure:
DCP
Determine which drum to use.
For information about drums, refer to the Programming Instruction Manual for
the appropriate TI PLC.
For information about steps, refer to the Programming Instruction Manual for the
appropriate TI PLC.
Append the converted drum and step numbers derived in Steps and to create a
four-digit hexadecimal value.
Note
External Device
Enter the decimal value in the Address field.
Interface
Example 1: Enter 2571 in the Address field in the Read/Write
tables.
Example 2: Enter 513 in the Address field in the Read/Write
tables.
For information about ramps, refer to the Programming Instruction Manual for
the appropriate TI PLC.
Append the converted loop and ramp numbers derived in Steps 2 and 5 to create a
four-digit hexadecimal value.
Note
External Device
This information was extracted from the 5TI2000 Programmer
Operator’s Manual.
Interface
The 5TI Sequencer has a 16-bit word which represents the ladder logic code. In
the 1010 series sequencer, 14 of these 16 bits are available for use, and in the 1020
series, 15 bits are available. The construction of the 16-bit word is described in
Diagram A. The binary weights for each bit are described in Diagram B. Sample
computations are given in Diagram C.
Use the following steps to update the ladder logic in the 5TI Sequencer:
Enter an L in the Data Type field of the Texas Instruments Read/Write Information
panel.
Use the element type LEDS, opcode LEDSD, and display digits on the 5TI
programmer to check the accuracy of the computation.
X 0 0 0 0 0 1 1024
7 0 0 0 0 1 0 2048
CR 0 0 0 0 1 1 3072
STR 0 0 0 1 0 0 4096
CTR 0 0 1 0 0 0 8192
OUT 0 0 1 1 0 0 12288
MCAR 0 1 0 0 0 0 16384
S TR NOT 0 1 0 1 0 0 20480
TMR 0 1 1 0 0 0 24576
External Device
configuring a message tag, see “Configuring the Logical Station Control Panel” on
page 534. For information about configuring an analog tag, see “Configuring the
Interface
Logical Station Information Panel” on page 537.
For information about the messages displayed for the EDI task and the format in
which protocol module messages are generated, see Chapter 10, “Messages and
Codes.”
Decoding ER:
Decode the ER: string by interpreting the least significant digit (LSD—rightmost
integer) and the most significant digit (MSD—leftmost integer)
of NN. For example:
err0043
If the MSD is less than eight, use Case 1 for decoding. If the MSD is eight or
higher, use Case 2 for decoding.
1
Cause: Invalid data returned.
Action: Verify device configuration and cabling. Check that FactoryLink
configuration tables contain the proper station addresses and
template parameters. Check that the Texas Instruments Logical
Station Control panel contains the proper baud rate, parity, and
data format parameters.
2
Cause: Turnaround error / timeout error.
Action: Refer to the action for Error Code 01.
3
Cause: Buffer overflow.
Action: Refer to the action for Error Code 01.
4
Cause: Checksum error on return data.
Action: Refer to the action for Error Code 01.
5
Cause: Transmit error.
Action: Refer to the action for Error Code 01.
LSD
1
Cause: Unknown error detected.
Action: Use the action specified for the error code’s MSD.
2
Cause: Receiver error. 20
Action: Use the action specified for the error code’s MSD.
External Device
3
Interface
Cause: Receiver abort.
Action: Use the action specified for the error code’s MSD.
4
Cause: Receiver CPT translation error.
Action: Use the action specified for the error code’s MSD.
5
Cause: Texas Instruments exception error.
Action: Use the action specified for the error code’s MSD.
6
Cause: Receive invalid read length.
Action: Use the action specified for the error code’s MSD.
7
Cause: Receive DSF translate error.
Action: Use the action specified for the error code’s MSD.
This error indicates cabling problems, incorrect DIP switch settings, or other
hardware-related problems.
err 0009
Cause: Read or write has been issued when the port has been closed.
Action: Force-write a 0 to the port on/off element defined to reopen the
port.
TIWAY Serial Unilink Network exception code errors are listed below.
For more information about TIWAY errors, locate the TI code in the list below and
refer to the TIWAY 1 UNILINK Host Adapter User’s Manual.
External Device
error continues.
Interface
86 (TIWAY code: 0009)
Cause: There is an incorrect HDLC checksum.
Action: Consult page 6-1 in the TIWAY 1 UNILINK Host Adapter User’s
Manual.
External Device
92 (TIWAY code: 008B)
Interface
Cause: The char count field value doesn’t match the received count.
Action: Contact Customer Support.
External Device
TI PLC Point-to-Point errors are as follows:
Interface
Note
For developer actions for each error, refer to the documentation for
the appropriate Texas Instruments PLC.
B1
Cause: Reset current transaction.
B2
Cause: Address out of range.
Action: Correct the address entered in the Read or Write table.
B3
Cause: Requested data not found.
B4
Cause: Illegal task code request.
B5
Cause: Request exceeds program memory size.
Texas Instruments
B6
Cause: Diagnostic fail upon power up.
B7
Cause: Fatal error detected.
B9
Cause: Incorrect amount of data with command.
BA
Cause: Illegal request in operational mode.
BB
Cause: Network not deleted.
BC
Cause: Write operation did not verify.
BD
Cause: Illegal number of ASCII characters received.
BE
Cause: Illegal write to program memory.
BF
Cause: Data not inserted.
C0
Cause: Data not written.
C1
Cause: Invalid data sent with command.
C2
Cause: Invalid op with NIM Local/Remote mode.
C3
Cause: Store and forward buffer is busy.
C4
Cause: No response from special function mode. 20
C5
External Device
Cause: Illegal instruction in program mem.
Interface
C6
Cause: Attempted write to protected variable.
C7
Cause: No response from Programmable Controller.
C8
Cause: Requested memory size exceeds total memory.
C9
Cause: Req. memory is not mult. of block sz.
CA
Cause: Req. memory < minimum defined value.
CB
Cause: Req. memory < maximum defined value.
CC
Cause: PLC busy - cannot perform operation.
CD Texas Instruments
Cause: Comm error in HOLD mode.
CE
Cause: Port lockout is active.
D1
Cause: I/O configuration error.
err 00B2
0 0 B 2
This error indicates the address specified in the Read/Write table is out of range.
Locate the error code next to the message string to determine the cause and
appropriate action for each message string. Then, use that code to refer to the
Case 1 or Case 2 Errors in this chapter.
Error message strings and their corresponding codes appear alphabetically, below:
93 Checksum mismatch
External Device
CD Comm error in HOLD mode
Interface
8F Command frame too short
Texas Instruments
D1 I/O configuration error
AB NM is not configured
External Device
CA Req. memory < minimum defined value
Interface
C9 Req. memory is not mult. of block sz
Texas Instruments
AF TIWAY 1 Ports RS232/Local Line mismatch
6. Install the FactoryLink ECS software and the KTDTL Installation Guide
or NetDTL device interface software if they are not
already installed.
11. Define the communication path to this device in the Chapter 23,
Logical Station table. “Configuring
Communication
Paths”
13. Check the Run-Time Manager or any configured error Chapter 26,
tags (specified in the Logical Station table) for “Messages and
messages indicating problems with the connection. If Codes”
errors are reported, troubleshoot the connection.
14. Once communications are successful on this single Steps 11 through 13
communication path, define a communication path for
each additional device in your configuration.
15. Configure the read and write operations the Chapter 24,
application will execute across these communication “Reading and
paths. Writing Data”
•
•
•
•
KTDTL and NetDTL
Overview
Note
Additionally, the tasks can run concurrently with software other than
FactoryLink that is also using INTERCHANGE or RSLinx.
NetDTL NetDTL
Task Task
Allen-Bradley
RSLinx or
INTERCHANGE FactoryLink
Real-Time
Database
NetDTL
Task
NetDTL
Task
21
D
at
a
H
ig
h
To the right of the main Data Highway
w Plus, a 1785-KA5 interface module
ay
Pl PLC-2 connects to a DH-485, which connects
us
to another 1785-KA5 interface module
57 and a Data Highway Plus.
178
5
-KA
D
at
178
a
3
H
D ig
at
a
hw 5-KA 46
H ay PLC 5/40
ig Pl
5
h w us
ay
13
177
178
5-K
A
21
PLC-2 1-K
A2
178
SLC 5/02
11
A5
PLC-3 177
5-K 26
A SLC 5/03
M
ai
To the left of the main Data n D
D at
Highway Plus, a 1785-KA at a
a H
H ig
interface module connects to ig hw
hw
a Data Highway. ay ay
Pl 48
48 5
us
to
178 Fa
PLC-2 5-K ct
A3 o ry
Devices on each network are Lin
indicated by “road signs” that k
PC
display the device node
addresses. 42
FactoryLink Station
D
at
a
H
ig To the right of the main Data Highway
hw
ay Plus, a 1785-KA5 interface module
Pl PLC-2
us connects to a DH-485, which connects
57 to another 1785-KA5 interface module
178
and a Data Highway Plus.
5-K
D
A3
at
178
a
H
D ig
5-K
at hw 46
a ay PLC 5/40
A5
H
ig Pl
hw us
ay
Devices on each network are
indicated by “road signs” that
display the device node
13
178 addresses.
5-K
A
PLC-2 177
1-K 22
A2
178
SLC 5/02
5
-KA
11 26
5
SLC 5/03
PLC-3 177
5-K D
A at
D a
To the left of the main Data at H
a ig
H hw
Highway Plus, a 1785-KA ig ay
hw
interface module connects to 48 ay 48
a Data Highway. 5
Pl
us
PLC-2 178
5 -KA
3
FactoryLink Station
KTDTL TOPOLOGY
The diagrams in this section provide examples of possible topologies for a KTDTL
task configuration.
KTDTL 21
Task
+
SLC 5/04
DH
PLC-5
wa
gh
Hi
ta
Da
PLC-5/250
PLC-5 with
1785-KA5
1785-KA5 module in a
PLC-5 I/O rack provides the
link from DH+ to DH-485
SLC-5/03
85
y4
wa
SLC-5/02
gh
Hi
ta
Da
SLC-5/01
FactoryLink
Station
1784-KTX 1784-KT
Card Card
PLC 5
DH+
SLC 5/04
DH-485 1785-KA5
1747-AIC 1747-AIC
1747-C11
Figure 21-7 Typical Link Between the FactoryLink Station and Various Devices
PLC-3
SLC 5/02
21
D
at
a
H
1785-KA3
KT Card
PLC-2 PLC-5/250
Figure 21-8 shows a basic physical link between the FactoryLink station and
devices on the Ethernet and DH+ networks communicating through a Pyramid
Integrator with an Ethernet interface module.
Figure 21-8 Typical Physical Link to Local Addresses
DH+ Link
Ethernet Link
PLC-3 PLC-5/xxE
PLC-5/xxE
Ethernet Card
FactoryLink Station
Figure 21-9 shows a typical physical link between the FactoryLink station and
devices at offlink addresses.
1775-KA
Data Highway 485 Offlink
The 1785-KA5 module serves as a bridge to let devices
1785-KA residing at offlink addresses communicate with the
computer running the device interface software.
21
D SLC 5/02
at
a
Ethernet Communications
The NetDTL task can
communicate directly to a device in
D PLC-5/xxE the PLC-5/xxE family over TCP/IP.
at
a
H
ig
hw
ay PI Et
Pl he
us rn
Data Highway Plus Ethernet Link et
The PLCs on the Data Highway Plus are
linked to the computer running the
device interface software through a
PLC-2/250 Pyramid Integrator with an
Ethernet interface module.
PLC-5 with
1785-KA5
1785-KA5 module in a
PLC-5 I/O rack provides the
SLC-5/03 link from DH+ to DH-485
5
48
SLC-5/02
y
wa
SLC-5/04
lu
gh
yP
Hi
wa
SLC-5/01
ta
h
Da
ig
H
ta
Da
PLC-5/250
Allen-Bradley
RSLinx or
INTERCHANGE FactoryLink
Real-Time
Database
PLC-5
NetDTL
Task
Communications through
an Ethernet card
PLC-5/250 with an
Ethernet interface
IP
P/
•
•
•
•
Getting Started
Before defining the communication paths and the read and write operations, you
must set up FactoryLink to recognize the KTDTL or NetDTL task and define
information that optimizes the performance of the task.
This chapter describes how to set up and optimize FactoryLink for KTDTL or
NetDTL task communications by filling out a row for the task in the FactoryLink
System Configuration table.
22
Choose System Configuration from the Main Menu. The System Configuration
Information panel is displayed:
Copy and paste the last row of the System Configuration Information panel into
the empty row just below it. (In the previous panel, you would copy the row for the
Real-time Monitor, RTMON.)
Edit the new row you just created as follows to identify the KTDTL or NetDTL
task to the system:
Enter FR in the Flags column to instruct the task to start automatically at run
time.
Enter FRS in the Flags column to instruct the task to start automatically and
to open a status window at run time where system messages from the KTDTL
or NetDTL task and the RSLinx or INTERCHANGE software will appear.
Enter either KTDTL or NetDTL in the Task Name column to identify the task to
the system.
Edit the columns beginning with Start Trigger and ending with Display
Description to identify specific information about the task at run time. Press
End on the keyboard at each of these columns to move the cursor to the end of
the entry. Edit the number to increase its value by one.
22
For example, in the sample panel, the complete entry in the Start Trigger
column in the row for RTMON is TASKSTART_S[15]. (The start trigger defined
Enter 1 in the Start Order column to ensure the task starts up appropriately at
run time.
Select the row for KTDTL or NetDTL to enter program arguments that will
improve system performance.
Press the Tab key several times to advance to the Program Arguments column.
Enter the
program
arguments
here
Enter the program parameter for the specific override, followed by the override
value, in the Program Arguments column using the list of IDs in the table on the
following pages.
-argumentvalue
where
- is the required prefix for any program parameter.
argument is the parameter ID chosen from the following table.
value is the override value for the parameter.
For example: -F12 where F is the ID of the major program control loop and 12
indicates the number of times the task passes through the loop before sleeping.
Note
-C 0 through 32767 To specify the number of seconds the task waits before
(Default is 30) it attempts to reconnect to a disconnected RSLinx or
INTERCHANGE software interface, enter the ID
followed by the number of seconds. If you do not want
the task to attempt reconnection, enter 0.
Example: -C30
1 Click Enter to validate the information. Next, click Exit to return to the Main Menu
after the System Configuration panel is complete.
While there are no standard guidelines for setting the control loop and sleep
period parameters, one of the following procedures might help you obtain the
desired results:
• Decrease the number of control loop passes and increase the sleep period until
task performance drops below an acceptable level.
or
• Increase the number of control loop passes and decrease the sleep period until
task performance reaches an acceptable level.
•
•
•
•
Configuring
Communication Paths
To configure the paths over which FactoryLink will communicate with the devices,
you create logical station definitions in which you identify sources and
destinations for read and write requests and define FactoryLink elements to
which system messages from the KTDTL or NetDTL task and the RSLinx
software will be written.
23
NetDTL
23
NetDTL—The card in Figure 23-2 is an Ethernet card and a link from Ethernet to
DH+ is provided by an Ethernet Interface module in a PLC-5/250 I/O rack.
1785-KA5 Module
FactoryLink Station
in a PLC-5
I/O Rack at
Address #4 DH-485
NetDTL—Ethernet interface
module in a PLC-5/250 I/O
rack provides the DH+ link DH+
SLC 5/03 at
Address #10
PLC-5/250 at
Address #10
Logical Station 1 consists of Logical Port 1
and a PLC-5/250 at DH+address #10.
Logical Station 2 consists of Logical Port 1
and a PLC-5 at DH+ address #4.
The following steps describe how to create logical station definitions in A-B
NetDTL driver for each device that communicates with FactoryLink.
Display the Logical Station Control panel by clicking its title bar in the display of
all panels..
NetDTL
23
Using the following field descriptions, complete a row in the panel for each logical
port to be included in the communication path. Sample entries are provided in
“Sample Logical Station Table Entries” on page 631.
Logical Port Enter a number to represent the communications path. Since the
task uses only one logical port, define only one port in this panel.
Click Enter to validate the data when the Logical Station Control panel is
complete.
If the tag names you defined on this panel are not defined elsewhere in
FactoryLink, a dialog for defining each tag is displayed. Choose MESSAGE for
Type and accept the default of SHARED for Domain for each tag name.
Select the row for the logical port you are configuring. Click Next to display the
Logical Station Information panel. The logical port number is displayed in the
Logical Port field on the lower left side of the panel.
23
Define the following information on the A-B Ethernet Address Information panel:
• Ethernet Address of a Pyramid Integrator or PLC-5/xxE that will process
read/write requests.
• Ethernet Interface number of the Pyramid Integrator or PLC-5/xxE as defined
in RSLINX Software.
Using the following field descriptions, complete a row in the panel for each device
(Pyramid Integrator or PLC-5/xxE) that will have a direct Ethernet connection
from the FactoryLink Station (i.e., each device that has a separate TCP/IP
address).
TCP/IP Address Enter each Ethernet TCP/IP address of a Pyramid Integrator or
Ethernet Interface PLC-5/xxE that will process read or write requests.
(ASCII)
Valid Entry: numeric string of up to 21 numbers and decimal
points in the format xxx.xxx.xxx.xxx
Select the row for the TCP/IP address of the device you are configuring. Click Next
to display A-B NetDTL Logical Station Information Panel. The TCP/IP address is
displayed in the TCP/IP Address field on the lower left side of the panel.
23
Using the following field descriptions, complete a row in the panel for each device
to communicate through this logical port. Sample entries are provided in the next
section titled “Sample Logical Station Table Entries”.
Err/Status Tag Optionally, enter a tag name for a long analog element to receive
Name: communication error codes associated with this device (logical
station). The high word value written to this element indicates
the type of error received. The low word value written to this
element is the specific error code. The high word values written to
23
this tag and the meaning of the error code in the low word are:
Tip
Logical Station Enter a number to identify the logical station to which the
(Decimal): information in this row pertains. A logical station represents the
combination of a Logical Port, and TCP/IP Address with a
physical station. Assign a unique number to each device
communicating through this logical port. You will enter this
logical station number later in a read or write table to represent
the device defined in his row. In a read or write table, this number
will identify the device to or from which data is to be sent or
received.
23
Click Prev to return to the Logical Station Control panel and return to step to
configure another logical port.
Refer to Chapter 24, “Reading and Writing Data” when you are ready to define the
read and write operations expected to occur between this logical port and the
devices configured as logical stations.
Display the Logical Station Control panel by clicking on its title bar in the display
of all panels.
Using the following field descriptions, complete a row in the panel for each device
to communicate through this logical port. Sample entries are provided in “Sample
Logical Station Table Entries” on page 631.
Logical Port Enter a number to represent the communications path. Since the
task uses only one logical port, define only one port in this panel.
Valid Entry: numeric value from 0 - 999
Response Timeout Enter the length of time, in tenths of a second, the task will wait
(0.1 Sec) to receive a response to a read or write command before timing
out. Be sure to enter a value greater than zero; otherwise, the
task immediately times out without waiting for a response. The
default is 55, or 5.5 seconds.
Valid Entry: numeric value from 0 - 99999
Status Msg Tag Optionally, enter a tag name for a message element to which a
text string will be written to indicate a communications error
associated with this logical port.
Valid Entry: standard element tag name
Valid Data Type: message
Click Enter to validate the data when the Logical Station Control panel is
complete.
6. If the tag names you defined on this panel are not defined elsewhere in 23
FactoryLink, a dialog for defining each tag is displayed. Choose MESSAGE for
Type and accept the default of SHARED for Domain for each tag name.
Using the following field descriptions, complete a row in the panel for each device
to communicate through this logical port. Sample entries are provided in the next
section titled “Sample Logical Station Table Entries”.
Err/Status Optionally, enter a tag name for a long analog element to receive
Tag Name communication error codes associated with this device (logical
station). The high word value written to this element indicates
the type of error received. The low word value written to this
element is the specific error code. The high word values written to
this tag and the meaning of the error code in the low word are:
0 KTDTL return code
1 Internal RSLinx code
Tip
KT Card 4
FactoryLink Station
If the tag names you defined on this panel are not defined elsewhere in
FactoryLink, a dialog box for defining each tag is displayed. Choose LONGANA for
Type and accept the default of SHARED for Domain for each tag name.
Click Prev to return to the Logical Station Control panel and return to step to
configure another logical port.
Refer to Chapter 24, “Reading and Writing Data” when you are ready to define the
read and write operations expected to occur between this logical port and the
devices configured as logical stations.
When all information on the Logical Station Control panel has been specified, the
panel should resemble one of the sample panels shown in Figure 23-3.
Figure 23-3 Sample Logical Station Control Panel 23
KTDTL
When all information on the Logical Station Information panel has been specified,
the panel should resemble the sample panel shown in Figure 23-4.
KTDTL
23
In this example, the element KT_ERR is configured to hold port errors for logical
In this example, the element NDTL_ERR is configured to hold port errors for
logical station 0, which communicates with a SLC 5/03 device at DH-485 address
For practical purposes, the initial entry in the A-B KT Card ID (ASCII) field is 1KT:0
throughout the following examples.
Unless otherwise indicated, all entries can be used for triggered and unsolicited operations.
FactoryLink Station
To communicate with Device A, To communicate with Device B,
you would make the following you would make the following
field entries: field entries:
A-B KT Card ID A-B KT Card ID
(ASCII) (ASCII)
1KT:0 1KT:0
Station Station
Address Link 1 Address
(Octal) (Octal)
Device A Device B
43 56
All of these entries can be used for triggered and unsolicited operations.
FactoryLink Station
To communicate with Device A, To communicate with Device B,
you would make the following you would make the following
field entries: field entries:
A-B KT Card ID A-B KT Card ID
(ASCII) (ASCII)
1KT:0 1KT:0
Station Station
Address Address
(Octal) Link 1 (Octal)
43
Device A Device B
56 23
To communicate with Device
1KT:0/B:42/KA 1KT:0/B:42/KA
(triggered only) (triggered only)
36 41
Unless otherwise indicated, all entries can be used for triggered and unsolicited operations.
All of these entries can be used for triggered and unsolicited operations.
0RM:2/B:42/KA 0RM:2/B:42/KA
(triggered only) (triggered only)
PLC 36 DH 41 PLC
Station Link 2 Station
Address Device C Device D Address
(Octal) (Octal)
36 41
Unless otherwise indicated, all entries can be used for triggered and unsolicited operations.
FactoryLink
Station
1KT:0
DH+ 036
Data Highway + Link 1
DH+ 010 DH+ 013 DH+ 023 DH+ 035 DH+ 045
Log. Sta. 0 Log. Sta. 1 KA5 Log. Sta. 2 Log. Sta. 3
PLC-5 PLC-3 DH-485 002 PLC-5/250 PLC-5
DH-485 Link 2
DH-485 003 DH-485 011 DH-485 012 DH-485 022 DH-485 031
Log. Sta. 4 Log. Sta. 5 KA5 Log. Sta. 6 Log. Sta. 7
SLC-5/03 SLC-5/03 DH+ 056 SLC-5/02 SLC-5/03
Data Highway + Link 3
FactoryLink
Station
1KT:0
DH+ 036
DH+ 010 DH+ 013 DH+ 023 DH+ 035 DH+ 045
Log. Sta. 0 Log. Sta. 1 KA Log. Sta. 2 Log. Sta. 3
PLC-5 PLC-3 PLC-5/250 PLC-5
Data Highway
DH 011 DH 013
Log. Sta. 4 Log. Sta. 5
PLC-3 PLC-3
0 55 lprt0_msg
Ethernet TCP/IP
DH+ 010 DH+ 013 DH+ 023 DH+ 035 DH+ 045
Log. Sta. 2 Log. Sta. 3 KA5 Log. Sta. 4 Log. Sta. 5
PLC-5 PLC-3 DH-485 002 PLC-5/250 PLC-5
DH-485 Link 2
DH-485 003 DH-485 011 DH-485 012 DH-485 022 DH-485 031 23
Log. Sta. 6 Log. Sta. 7 KA5 Log. Sta. 8 Log. Sta. 9
SLC-5/03 SLC-5/03 DH+ 056 SLC-5/02 SLC-5/03
DH+ 010 DH+ 013 DH+ 023 DH+ 035 DH+ 045
Log. Sta. 1 Log. Sta. 2 KA Log. Sta. 3 Log. Sta. 4
PLC-5 PLC-3 PLC-5/250 PLC-5
Data Highway
DH 011 DH 013
Log. Sta. 5 Log. Sta. 6
PLC-3 PLC-3
•
•
•
•
Reading and Writing
Data
Define read requests in either the Read/Write table or the Unsolicited Read table,
and write requests in the Read/Write table. Each table consists of two panels: a
control panel and an information panel.
Note: The data entry columns in the 24
KTDTL Read/Write table and the
NetDTL Read/Write table are
Triggered read operations occur based on either timed intervals or events. In both
types of operations, a change in value of a trigger element prompts FactoryLink to
read data in specific locations in a device.
• Timed-Interval Reads—A read operation based on a timed interval instructs
FactoryLink to collect data at defined intervals, such as several times a minute
or at a given time each day.
• Event-Driven Reads—A read operation based on an event instructs FactoryLink
to collect data only when a defined event occurs, such as when an operator
selects a new graphic window or when an alarm condition occurs.
When filling out a request for a read operation, you specify in which elements the
data read from the device during the operation will be stored. Among other things,
you specify: the tag name assigned to the FactoryLink database element storing
the data, the logical station from which the data will be read, and the address
containing the data to be read.
Triggered Read Request—In a triggered read request table, a digital element you
configure in the Read/Write Control panel as a trigger to initiate a block read
operation causes FactoryLink to read each device address specified in the
Read/Write Information panel whenever the value of the trigger element is forced
to 1 (ON). FactoryLink stores the value read from each address in a real-time
database element (digital, analog, long analog, floating-point, or message).
Figure 24-3 How a Triggered Read Operation Works
You can define two types of write operations: block and exception. 24
Block—In a block write operation, a change in value of a trigger element prompts
The difference in these two operations is the way in which each is triggered. Both
operations write data from FactoryLink to the device when a trigger is activated.
For a block write, the trigger is an element defined specifically for prompting a
write operation. For an exception write, the trigger is the change in status of the
element to be written.
Block Write Request—In a block write request table, a digital element you
configure in the Read/Write Control panel as a trigger to initiate a block write
operation causes the task to write element values specified in the Read/Write
Information panel to their associated device addresses each time the value of the
element is forced to 1 (ON).
Figure 24-6 How a Block Write Operation Works
Continued
Continued
Exception Write Request—When any of the values of the elements defined in the
Read/Write Information panel change in an exception write request table, the task
writes those values to the defined device addresses. Optionally, define a digital
element to disable and re-enable an exception write table and a trigger element to
update the equipment once the table is re-enabled. Each defined exception write
results in a separate write command.
Figure 24-7 How an Exception Write Operation Works
Continued
24
EXCEPTION
Configure two tables: a triggered read table and an exception write table. These
should look similar to the following ones.
TESTREAD NO 1 test_rtrig
TESTWRITE YES 1
TESTREAD
TESTWRITE
• An element (in the sample panel, value1) to hold the value read from a known
address in one of the devices in your configuration (in the sample panel, address
140 in the device configured as logical station 1). You will watch the activity of
this element in RTMON to verify it is being updated.
Define an element (in the sample panel, value2) in the write table to hold a value
that will be written to the same address configured in the read table. Change this
element’s value in RTMON to prompt the processing of this table.
Note
The next steps in the procedure involve the use of the FactoryLink
Real-Time Monitor. For detailed instructions on using RTMON,
refer to FactoryLink Fundamentals.
Create a watch list in RTMON containing the elements defined in the two tables 24
(test_rtrig, value1, and value2 in the sample panels). Use the Watch option on the
RTMON Options menu to create a watch list.
test_rtrig
Use RTMON to prompt FactoryLink to process the exception write table. Change
the value of the element to be written (value2 in the sample panel) using the same
option you used to trigger the read table, Tag Input. When you change the
element’s value in this way, the exception write table is processed and the value is
written to the specified register address.
value2
A triggered read operation is the best choice for reading data that changes
frequently and at regular intervals. Use the following types of triggered read
operations under the described circumstances.
Interval If an application does not require all data to be collected at the
same time, you can increase FactoryLink’s efficiency by
configuring several read tables, each reading at a different
interval and only as often as necessary. For example, configure a
table with timed reads that occur every five seconds for elements
with values that change frequently, and every thirty seconds for
elements with values that change less frequently.
Event If events occur infrequently, you can reduce the number of
requests sent between FactoryLink and the device and increase
overall efficiency by configuring several read tables, each
triggered by a different event. For example, if a graphic screen
contains a large number of variables useful only on that screen
(that is, they are not alarm points and are not being trended),
configure a separate read table containing only these variables.
FactoryLink will only read the elements on that screen when the
operator triggers this read table by selecting the graphic screen
for viewing. Using this technique can reduce traffic between
FactoryLink and the device when an application has a large
number of graphic screens.
As another example of an event-driven read operation, configure
FactoryLink to trigger a particular read table only if an alarm
condition occurs. The element that detects the alarm condition
can trigger FactoryLink to collect additional information from the
device about the status of related processes.
Write Operations
Use the following types of write operations under the described circumstances.
Block If an application writes values of real-time database elements
that change frequently to the device, use a block write operation
because FactoryLink sends the minimum number of write
commands necessary to write the specified data. A block write is
most efficient when your application writes a group of elements
at one time to the device (for example, when your application
requires a new recipe).
Exception If an application writes values of real-time database elements
that change infrequently to the device, or if the application only
needs to change one value at a time (for example, a new
user-entered setpoint), use an exception write operation. For each
exception write, one packet of data per tag is sent to a device.
For detailed descriptions of specific techniques you can use to enhance the
performance of your application, refer to “Techniques for Improving
Communication Performance” on page 688 of this guide.
READ_ANA
READ_ANA
If you define a write table as shown in Figure 24-9, however, each row will
generate a separate message and data will only be written to the four addresses
specified. To send a single message to write to addresses 32 through 41, you
would need to define each address separately as shown in Figure 24-8. Only
contiguous groups of data (up to the maximum allowed by the device) would be
put in one message for a write operation.
• Define Multiple Operations in a Single Table—Because the KTDTL and NetDTL
tasks can process multiple messages destined for a single device
simultaneously, you can define several read or write operations (within reason
and based on the architecture of the application) in a single table for maximum
throughput. Each additional table you define results in more messages the task
must generate thus reducing the efficiency of your application.
• Keep Disabled Messages Together—Put entries that might need to be disabled
periodically in their own table, separate from entries that will not be disabled.
• Prioritize Read and Write Operations—The priority of read and write operations
can affect the speed and performance of an application. Assign a priority to give
preference to the most critical data to be read or written should FactoryLink
receive more than one request to execute a read or write operation at a time.
If the Logical Station Information panel is currently displayed, click Next and go to
step . If another KTDTL or NetDTL panel is displayed, go to step .
Choose the appropriate option from the Main Menu. A cascaded view of all the
configuration panels is displayed. 24
KTDTL—For KTDTL, choose Allen-Bradley KTDTL.
Add a panel entry for each read or write request you want transmitted over a
communication path to a device. The information you provide depends on the type
of request you are defining. Refer to the appropriate section:
• “Triggered Read” on page 659
• “Block Write” on page 662
• “Exception Write” on page 665
Triggered Read
The following steps describe how to fill out a Read/Write Control panel for a
triggered read table.
Using the following field descriptions, add a panel entry for each triggered read
request you want to define. Leave all other fields blank. Sample entries are
provided in “Sample Triggered Read Request” on page 680.
Note
The element you use for the Block Read Trigger can also be defined
in another FactoryLink task. For example, you could define a
digital element in the Event or Interval Timer, Math and Logic,
or the Application Editor, and assign the same tag name to a
Block Read Trigger element. When the element’s value changes to
1 (as the result of a math operation or a defined event taking
place, for example), it prompts a read operation.
Tip
Tip
The Block Read Disable element can be used to disable a block read
operation that is either part of a cascaded loop or is self-triggered.
The triggering cycle will cease upon disabling, however. To
re-enable a cascaded loop or a self-triggered read table, the Block
Read Trigger element must be toggled or forced to 1. Refer to
“Techniques for Improving Communication Performance” on page
688 for further details.
Click Enter when you have finished filling out the information on this panel.
If the tag names you defined on this panel are not defined elsewhere in
FactoryLink, a dialog for defining each tag is displayed. Choose DIGITAL for Type
and accept the default of SHARED for Domain for each tag name.
Define the data to be read and the target addresses in the Read/Write Information
panel. Refer to “Filling Out the Read/Write Information Panel” on page 667 for
details.
Block Write
The following steps describe how to fill out a Read/Write Control panel for a block
write table.
Add a panel entry using the following field descriptions, for each block write
request you want to define. Leave all other fields blank. Sample entries are
provided in “Sample Block Write Request” on page 683.
Table Name Give this write request table a name. Define one table per line
and do not include spaces in the name. Define as many request
tables in this panel as available memory allows. Try to make the
table name reflective of the operation it represents.
When the Block Write Trigger element defined for this table is
forced on, the element prompts FactoryLink to process this write
table and any other write table with a Table Name entry
associated with the same trigger.
Valid Entry: alphanumeric string of up to 16 characters
Exception Write Accept the default of NO to indicate this is not an exception write.
Valid Entry: no
Block Write Priority Enter a number to indicate the priority of this table, relative to
other write operations. The highest priority is 1. This number
influences the order in which the KTDTL or NetDTL task
handles the queuing of this write request. If the task receives two
24
requests at the same time, it processes the request with the
Note
The element you use for the Block Write Trigger can also be defined
in another FactoryLink task. For example, you could define a
digital element in the Event or Interval Timer, Math and Logic,
or the Application Editor and assign the same tag name to a Block
Tip
Tip
The Block Write Disable element can be used to disable a block write
operation that is either part of a cascaded loop or is self-triggered.
The triggering cycle will cease upon disabling, however. To
re-enable a cascaded loop or a self-triggered write table, the Block
Write Trigger element must be toggled or forced to 1. For further
details, see “Techniques for Improving Communication
Performance” on page 688.
If the tag names you defined on this panel are not defined elsewhere in
FactoryLink, a dialog for defining each tag is displayed. Choose DIGITAL for Type
and accept the default of SHARED for Domain for each tag name.
Define the data to be written and the target addresses in the Read/Write
Information panel. Refer to “Filling Out the Read/Write Information Panel” on
page 667 for details.
Exception Write
The following steps describe how to fill out a Read/Write Control panel for an
exception write table.
Add a panel entry using the following field descriptions, for each exception write
request you want to define. Leave all other fields blank. Sample entries are
provided in “Sample Exception Write Request” on page 686.
Tip
Click Enter when you have finished filling out the information on this panel.
If the tag names for the elements you defined on this panel are not defined
elsewhere in FactoryLink, a dialog for defining each one is displayed. Choose
DIGITAL for Type and accept the default of SHARED for Domain for each tag name.
Define the data to be written and the target addresses in the Read/Write
Information panel. Refer to “Filling Out the Read/Write Information Panel” on
page 667 for details.
On the Read/Write Control panel, select the row for the table you are defining.
Click Next to display the Read/Write Information panel. The table name is
displayed in the Table Name field on the lower left side of the panel.
Define information using the following field descriptions, for each address to be
read or to which information is to be written:
• For a Read Table—Add a panel entry for each FactoryLink database element in
which data read from the device will be stored when the operation executes.
24
• For a Write Table—Add a panel entry for each element to be written when the
operation executes.
Sample entries are provided in “Sample Read and Write Table Entries” on page
680.
Tag Name For a Read Table—Specify a tag name for an element in which
FactoryLink will store the data read from the device.
For a Write Table—Specify a tag name for an element containing a
value to be written to the device.
Define a digital element and a corresponding Allen-Bradley data
type of BIN or DIG in the Data Type field to read or write to
bit-level addresses (B3:0/4 or N7:3/11, for example).
Valid Entry: standard element tag name
Valid Data Type: digital, analog, float, message, longana
For a Read Table—Click Enter to validate the data when you have finished defining
all the addresses to be read and all the elements to which the data is to be written.
For a Write Table—Click Enter to validate the data when you have finished defining
all the tag names for FactoryLink database elements and the addresses to which
their contents are to be written.
If the tag names for the elements you defined are not defined elsewhere in
FactoryLink, a dialog for defining each one is displayed. Choose the type of data to
be stored in the element for Type and accept the default of SHARED for Domain for
each tag name. Refer to the tag’s field description for the valid data types.
Click Prev to return to the Read/Write Control panel and refer to step on page 659
of this guide to configure another read or write request table.
Click Exit to return to the Main Menu when all read and write tables are complete.
24
After the task starts up, it processes block read and write and exception write
operations based on triggers and state changes configured as elements that have
been assigned tag names in read and write tables. As the task goes about its
normal operations, it is always ready to accept unsolicited data it is configured (in
an Unsolicited Read table) to receive.
The MSG instruction (or statement) in the PLC or SLC ladder logic, depending
upon how it has been programmed, sends a user-defined block of data based on a
particular time or event. If this block of data and the Unsolicited Read table
structure that was built do not match exactly in length and offset (starting
address), then the task will not receive the data.
Before configuring the Unsolicited Read table, you should be familiar with the
concepts discussed in the following pages related to data flow, data packet
processing, address range limitations, and (if SLC 5/03 and 5/04 devices are being
used) SLC 5/03 and 5/04 MSG instructions.
If you are not sure of when to use an unsolicited read operation, refer to “Choosing
Operation Type” on page 654 of this guide.
Note
Data Flow
KTDTL—In unsolicited read operations, Allen-Bradley devices send PLC-2 format
unprotected write command packets over each configured network to the
communications port in the FactoryLink computer. The card port, in turn, passes
these command packets to FactoryLink and the KTDTL task.
NetDTL—Unsolicited data flows from the devices in your configuration to
FactoryLink and NetDTL either directly, if the devices are PLC 5/xxEs, or
through a PLC 5/250 Pyramid Integrator (PI), in which case the data is first
sent to an alternate address in the PI and then to FactoryLink and NetDTL.
PLC 5/xxE devices are equipped with a built-in Ethernet interface and,
therefore, do not require a PLC 5/250 PI. In unsolicited read operations, data
flows from addresses in the specified PLC 5/xxE device as PLC-2 format
unprotected write command packets. These packets are sent directly to
FactoryLink and NetDTL.
For PLC and SLC devices connected to FactoryLink and NetDTL through a 24
PLC 5/250 PI, the devices send PLC-2 format unprotected write command
packets over each configured network to an alternate address in the PI
A data packet is an unprotected write command for unsolicited reads. The KTDTL
and NetDTL tasks process data elements as packets of data rather than as
individual addresses. Each packet has a unique definition that includes the
following information: path to the originating station, command length (number of
tags written), and the starting address (lowest address defined for a particular
logical station).
NetDTL—For NetDTL, the path to the originating station includes the PI DH+
port and the device’s network address on that port, or the Ethernet address of a
PLC 5/xxE device.
KTDTL—For KTDTL, the path to the originating station includes the
Allen-Bradley PC card port and the device’s network address.
The starting address of a data packet is flexible and can be assigned any value
ranging from 0 to 7777 (octal). The address of the originating station and the
command length, however, are less flexible. They define similar packets of data
from similar locations.
For unsolicited reads, it is only necessary to define the first and last addresses in
a packet. You can leave the middle addresses (everything other than the low and
high addresses) undefined or, most likely, assign them to single or multiple
FactoryLink tags as described in the following section.
When the KTDTL or NetDTL task maps unsolicited data to elements, it sorts the
data into packets based on the structure of PLC-2 write commands:
• For each defined Unsolicited Read table, the task sorts the entries in ascending
order by logical station and address. The lowest address for each logical station
determines the starting address of the packet.
• The task then determines the command length by first subtracting the starting
address from the highest referenced address, then by adding one. The highest
referenced address is the highest address plus the PLC-type length.
To Determine the PLC-Type Length—For the data types listed, add the specified
value:
INT2 Add 0.
INT4, FLT Add 1.
STRUC, ASC Add the length specifier (value of the Address field in the
Unsolicited Read Information panel) minus one.
When the KTDTL or NetDTL task receives a data packet, it searches its list of
defined packets for definitions that match the originating station, starting
address, and number of Allen-Bradley elements of the received packet. When it
finds matching definitions, the task reads the received information and writes all
of the data elements described in the definitions to the real-time database
according to the values of the data in the received packet. Any specific data tag
that is mapped to an address is only processed if that data tag and address are
24
present in the definition of the received packet.
If you need multiple definitions of the same data packet, define one packet in one
panel with multiple elements per address. Alternatively, you could define two
identical packets in two separate Unsolicited Read Information panels.
For SLC 5/03 and 5/04 processors, the maximum length is 41 elements (words).
If the range of addresses defined for a particular logical station exceeds this
maximum command length, send a second packet of addresses from the
Allen-Bradley device for this logical station. If FactoryLink elements are defined
for appropriate (border) addresses, then these packets will occupy contiguous
space.
For the most efficient performance of an unsolicited read operation, define only
one packet per logical station in a single configuration table. If you need to define
more than one packet per logical station, however, make the starting address
number of each subsequent packet greater than the highest address in the
address range of the previous packet.
All Allen-Bradley PLCs support the PLC-2 write command; however, some PLCs
limit the address ranges and data types that can be specified. Consult the
appropriate PLC programming guide for these restrictions.
In standard Allen-Bradley PLCs, certain Allen-Bradley PLC data types (FLT and
INT4, to name a few) cannot be sent in a PLC-2 unprotected write command. To
instruct the PLC to send such data types to FactoryLink:
Define the PLC type. For the task to convert the PLC type for the originating
logical station in the definition of the logical station number, specify the actual
PLC type (PLC-3, PLC-5, PLC-250) in the Station Type field of the Logical Station
Information panel for the logical station referenced in the Unsolicited Read
Information panel. The PLC type you enter in the Station Type field corresponds to
the PLC binary format for the data you specify in the Data Type field on the
Unsolicited Read Information panel.
Copy the data to a binary or integer file. Build the PLC-2 write data from the
PLC, sending the data in a binary or integer file by copying the long integer,
floating-point, or other data to the binary or integer file.
The SLC 5/03 and 5/04 processors, using the MSG instruction, can read and write
data to and from data table memory. To send and receive data from a user-defined
data table memory location, you specify information associated with the data for
the Target Node, Target Offset, and Message Length MSG instruction functions.
Note
• The entry fields for the SLC 5/03 and 5/04 MSG instruction only accept data in
decimal notation. Be sure to enter their octal equivalents into an unsolicited
read table.
• For the SLC 5/03 processor, when the target node is a DH+ network address
connected to the NetDTL task through a 1785-KA5 module, configure the
processor for remote communications. If the target node is another DH-485
network address, configure the processor for local communications.
• For the SLC 5/04 processor, when the target node is another DH+ network
address, configure the processor for local communications.
Click Next and go to step if the Logical Station Information panel is currently
displayed. Go to step if another KTDTL or NetDTL panel is displayed.
Choose the appropriate option from the Main Menu. A cascaded view of all the
configuration panels is displayed.
Display the Unsolicited Read Control panel by clicking its title bar.
Add a panel entry using the following field descriptions, for each unsolicited read
request you want to define. Sample entries are provided in “Sample Unsolicited
Read Request” on page 682 of this guide.
Table Name Give this unsolicited read request table a name. Define one table
per line and do not include spaces in the name. You can define as
many tables in this panel as available memory allows. Try to
make the table name reflective of the operation it represents.
Valid Entry: alphanumeric string of up to 16 characters
Unsolicited Read Enter YES or FORCE. The task will interpret this operation as
an unsolicited read and emulate the device’s addressing structure 24
based on entries you make in the Unsolicited Read Information
panel. The incoming data will be written to the real-time
Click Enter when you have finished filling out the information on this panel.
Define the data to be read and the target addresses in the Unsolicited Read
Information panel. Refer to “Filling Out the Unsolicited Read Information Panel”
on page 678 of this guide.
1 On the Unsolicited Read Control panel, select the row for the table you are
defining. Click Next to display the Unsolicited Read Information panel. The table
name is displayed in the Table Name field on the lower left side of the panel.
2 Using the following field descriptions, add a panel entry for each FactoryLink
database element in which data read from the device will be stored when
FactoryLink receives the data. Sample entries are provided in “Sample
Unsolicited Read Request” on page 682 of this guide.
Tip
Tag Name Specify a tag name for an element in which FactoryLink will store
the data read from the device. Be sure the message length defined
in the PLC or SLC MSG instruction is sufficient to handle the
number and types of elements you define in this table. Refer to
“SLC 5/03 and 5/04 MSG Instruction Considerations” on page 675
of this guide.
For data expected from bit-level addresses (B3:0/4 or N7:3/11, for
example), define a digital element and a corresponding
Allen-Bradley data type of BIN or DIG in the Data Type field.
Valid Entry: standard element tag name
Valid Data Type: digital, analog, float, message, longana
Logical Station Enter the number representing the device from which the
expected data is to be read. This number was originally defined in
the Logical Station Information panel for the logical port through
which communications with this device occurs.
Valid Entry: previously defined logical station number
Address Enter the address in the device’s memory where the value to be
stored in this element is located. You must use the PLC-2 format.
For address specification formats, refer to Chapter 25,
“Allen-Bradley Data Types and Addresses,” of this guide.
For special addressing requirements pertinent to unsolicited
reads, refer to “Unsolicited Read Operation Concepts” on page
670 of this guide. For offlink addressing considerations pertinent
to SLC 5/03 and 5/04 processors, refer to “SLC 5/03 and 5/04 MSG
Instruction Considerations” on page 675 of this guide.
Valid Entry: numeric value from 1 - 65535
Data Type Specify the type of data expected from the device for each element
defined in the Tag Name field. For descriptions of the supported
Allen-Bradley PLC and SLC data types and their corresponding
FactoryLink data types, refer to Chapter 25, “Allen-Bradley Data
Types and Addresses,” of this guide.
24
If you enter the data type BIN, the task automatically selects an
Allen-Bradley data type compatible with the FactoryLink data
Click Enter to validate the data when you have finished defining all the addresses
from which the expected data is to be read and all the elements to which the data
will be written.
If the tag names for the elements you defined are not defined elsewhere in
FactoryLink, a dialog for defining each one is displayed. Choose the type of data to
be stored in the element for Type and accept the default of SHARED for Domain for
each tag name. Refer to the tag’s field description for the valid data types.
Click Prev to return to the Unsolicited Read Control panel and refer to step on
page 677 to configure another unsolicited read request table.
Continued
Continued
READ is
illustrated in
this example.
READ
24
READ
UNSOL_READ is illustrated
in this example.
ANA_15 0 34 INT2
UNSOL_READ
ANA_15 0 34 INT2
UNSOL_READ
24
Continued
Continued
Continued
WRITE is
illustrated in
this example.
WRITE
24
Figure 24-18 illustrates how this block write operation works.
Continued
KTDTL_WRITE_TRIGGER is
1, FactoryLink processes the
table, WRITE.
Continued
Continued
EXCEPTION is
illustrated in
this example.
As shown in Figure 24-20, whenever the value of the digital element P240000
changes, FactoryLink processes the EXCEPTION table. This table writes the
value of P240000 to bit 12 in file type B, file number 3, element 1 in the device
configured as logical station 0. If the table is disabled then subsequently
re-enabled and NDTL_EXCEPTION_TRIGGER (Block Write Trigger) is set to 1, bit
12 is updated with the value of P240000 if the value has changed since the table
was disabled.
EXCEPTION
24
Figure 24-21 illustrates how this exception write operation works.
Continued
Because this is an
P240000 0 B3:1/12 DIG
exception write table,...
Specifying Priority
The Read/Write Control panel contains two columns for specifying the priority of
block reads and block or exception writes: Block Read Priority and Block Write Priority.
The priority of an operation can range from 1 to 4. These values correspond to four
first-in/first-out (FIFO) priority queues which are set up in order of importance.
Priority queue 1 has the highest priority.
When the Block Read Trigger or Block Write Trigger element for a table changes from
0 or is forced to 1, or when an element in an exception write table changes, that
table or exception element is placed into one of the four queues for processing by
the INTERCHANGE or RSLinx software. This queue placement depends on the
value specified in the Block Read Priority or Block Write Priority column for the table.
Each queue can hold up to 256 pending tables. When a table is triggered and the
priority queue to which it has been assigned is not full, the table is placed in that
queue. The Block Read State or Block Write State element for the table is reset to 1.
The queues are polled for tables (during each pass of the main loop of the KTDTL
or NetDTL task) according to the order of importance of the priority. The priority 1
queue is polled the most frequently and the priority 4 queue is polled the least
frequently. Every table is eventually processed but the ones in the priority 4 queue
can take more time to process.
Overtriggering
All tables are placed by default in the priority 1 queue, which is appropriate in
most cases. When an application contains a large number of tables, however, or
when an exception write table contains tag names for rapidly changing elements,
an overtriggering situation can arise with all tables going into the same queue.
Overtriggering occurs when tables are being placed in a priority queue faster than
the INTERCHANGE or RSLinx software can pull the tables out and process them.
Since the maximum number of pending tables a queue can hold is 256, the
maximum number of total pending tables is 1024 (256 · 4 queues = 1024). If you
accept the priority default of 1 for all tables, the total allowable number of pending
I/O transactions is only 256. To more evenly distribute tables across the four 24
priority queues (thus reducing the priority 1 queue’s burden of handling all the
pending I/O requests), you could assign priority 1 or 2 to tables containing more
Using this logic, you would assign a high priority to an exception write table for an
operation that acknowledges a loud annoying alarm and a low priority to a block
write table that downloads a batch recipe once a day.
Efficient Triggering
This section discusses triggering techniques to consider for optimum performance
of your application.
Timed
The easiest and most basic way to trigger a block read or write operation is with a
timed element. To define a timed trigger element, enter a tag name for a Block
Read Trigger or Block Write Trigger element in the Read/Write Control panel that
matches the tag name of an interval timer element (defined in the Interval Timer
Information panel). If you define this element to change once per second, the table
is placed in its assigned queue once every second.
Note
Cascaded
In the Read/Write Control panel, if either the complete or state element is defined
as the trigger element for the table in the row below the current table, that table
will not be triggered and placed into a queue until the preceding table is either
successfully placed in a queue or processed. If the table defined in the final row of
the Read/Write Control panel contains a tag name for a complete or state element
that matches the tag name of the trigger element for the table defined in the first
row, the completion of the final table triggers the first table. This endless loop
results in the sequential processing of tables at the fastest possible rate.
Figure 24-22 illustrates a series of read tables created using the cascading
technique. This type of table setup is also referred to as a daisy chain of tables.
Continued
READ1 NO 1 r5_state
READ2 NO 1 r1_state
READ3 NO 1 r2_state
READ4 NO 1 r3_state
READ5 NO 1 r4_state
If a table is to be placed into a queue that has become full, the value of the state
element for that table will not change. Consequently, the next table will not be
triggered until room is available in the queue for the current table.
If you use the Block Read Complete or Block Write Complete element to perform the
cascade, the next table in the loop is placed into its queue after the previous table
is successfully communicated through the INTERCHANGE or RSLinx software.
In this case, successful processing of the transaction is guaranteed. (A timeout
error occurring somewhere in the loop will slow the performance of the cascade.)
A parallel between timed and cascaded triggering further illustrates this method’s
effectiveness. When the same timed trigger element is used to trigger each of
several tables defined in the Read/Write Control panel, the tables are processed
sequentially (starting with the beginning row of the panel) on each occurrence of
the trigger. Essentially, this scenario represents a timer-initiated cascade. If each
instance of the timed element is replaced by an element that, when combined with
other elements, creates the cascaded triggering effect, the fastest rate at which
the tables can be placed into queues is naturally set by the tables themselves.
Self-Triggered
FactoryLink can process tables for read and write operations to Ethernet devices
more quickly than it can process tables going to devices not connected directly to
Ethernet. (The Ethernet connection and the I/O time for the NetDTL interface are
faster.) If you use the cascaded method for triggering tables going to devices that
will process the tables at different speeds, tables to the devices that process more
quickly (Ethernet devices) will idle in the loop waiting for the tables going to the
other devices that occur earlier in the cascade to finish processing.
Continued
R_AGAIN NO 1 selftrig
Continued
selftrig
When FactoryLink starts up, the complete or state element is automatically set
to 1. If you have defined this same element as the trigger element, the table is also
placed in its priority queue at startup. When the complete or state element is set
again as a result of the operation, the cycle starts over and the table is placed in
its priority queue again (because the complete or state element is also the trigger).
Overtriggering does not occur with a self-triggered table because a table destined
for a device is only placed into a queue or processed after the successful previous
processing or queue placement of the table.
Note
ó
Continued
As a trigger element, selftrig also places the
R_AGAIN NO 1 selftrig
R_AGAIN table into queue 1 at startup.
óú
ì During processing of the R_AGAIN table,
selftrig (as a state element) is set to 0.
ö
Continued
If the table completes successfully (the data
selftrig
is read then stored in the elements defined in
the Read/Write Information panel), selftrig ìö
(as a state element) is set to 1.
•
•
•
•
Allen-Bradley Data
Types and Addresses
Data Types—The KTDTL and NetDTL tasks can convert numerous Allen-Bradley
data types into compatible FactoryLink data types. “Supported Data Types” on
page 696 provides a cross reference list of each supported Allen-Bradley data type
and its FactoryLink data type after conversion.
Addresses—Enter the addresses of the PLC and SLC memory locations being 25
accessed in the Address field on the Read/Write Information and Unsolicited Read
Information panels. For information about valid address formats, refer to
For information about valid file types and subelements for specific device types,
refer to the appropriate section:
• “PLC-3 File Type Reference” on page 701
• “PLC-5 File Type Reference” on page 703
• “PLC-5/250 File Type Reference” on page 710
• “SLC 500 File Type Reference” on page 717
FactoryLink Allen-Bradley
Description/Conversion
Data Type Data Type
FactoryLink Allen-Bradley
Description/Conversion
Data Type Data Type
FactoryLink Allen-Bradley
Description/Conversion
Data Type Data Type
PLC-2 Format
Use the following formats to specify addresses for PLC-2 devices, and for PLC-3,
PLC-5, and PLC-5/250 devices configured for PLC-2 compatibility.
Note
word 25
word/bit
[module_id][filetype][filenumber][:;][element][/bit][,length][.subelement]
module_id (Valid for PLC-5/250 devices) Define the module ID (pushwheel)
number that specifies the thumbwheel value on the processor
module. (RM default is 0.)
filetype (Required) Specify the PLC file type. For valid entries for a
specific PLC type, refer to the appropriate PLC file types and
subelements table in this chapter.
filenumber (Optional) Enter the file number. The default is 0 for all PLC
types except PLC-5, where a default file number exists for some
file types.
: ; (Required) Enter either a colon (:) or semicolon (;).
element (Optional; assumed 0 if not entered) Enter the file element
number in octal for input/output files and in decimal for all other
PLC file types. Follow this number with an appropriate separator
and either the bit specifier, length in file elements, or appropriate
Subelement.
/bit (Optional) Enter a front slash (/) then the bit specifier in octal for
PLC-3 and input/output files and in decimal for all other PLC
types. If a back slash (\) is erroneously entered, the default value
will be used. The default is the least significant bit, 0.
,length (Enter for message elements) Enter a comma (,) then specify the
length, in file elements, to be read or written. The default is 1.
.subelement (Optional) Enter a period (.) then specify a subelement member of
the specified address file element. For valid entries for a specific
PLC type, refer to the appropriate file types and subelements
table in this chapter.
File Types
The following file types can be used in PLC-3 address specifications:
Element
Allen-Bradley
File Type Description Length
Data Type
in Words
O Outputs DIG/INT2 1 25
I Inputs DIG/INT2 1
C Counters STRUCT 3
N Integers DIG/INT2 1
F Floating-point FLT 2
B Binary DIG/INT2 1
A ASCII ASC 1
U Up enable DIG No
DN Done DIG No
OV Overflow DIG No
UF Underflow DIG No
TE Enabled DIG No
TT Timing DIG No
TD Done DIG No
File Types
The following file types are valid for PLC-5 address specifications. Note that some
file types are valid only on new generation PLC-5 devices.
Element
Allen-Bradley Default
File Type Description Length
Data Type File Number
in Words
S Status INT2 2 1
B Binary INT2 3 1
T Timers STRUCT 4 3
C Counters STRUCT 5 3
N Integer INT2 7 1
F Floating-point FLT 8 2
R Control STRUCT 6 3
EN Enable DIG No
ST Start DIG No
DN Done DIG No
ER Error DIG No
CO Continue DIG No
EW Enable waiting DIG No
NR No response DIG No
TO Time out DIG No
RW Read/write DIG No
RLEN Requested word INT2 Yes
count
DLEN Transmitted INT2 Yes
word count
FILE File-type number INT2 Yes
ELEM Word number INT2 Yes
RGS Rack/group/set INT2 Yes
CU Up enable DIG No
DN Done DIG No
OV Overflow DIG No
UN Underflow DIG No
NR No response DIG No
EN Enable DIG No
ST Start DIG No
transmission
DN Done DIG No
ER Error DIG No
CO Continuous DIG No
DO Derivative of DIG No
EN Enable DIG No
DN Done DIG No
EM Empty DIG No
ER Error DIG No
UL Unload DIG No
IN Inhibit DIG No
comparisons
FD Found DIG No
DN Done DIG No
EN Enable DIG No
TT Timing DIG No
DN Done DIG No
File Types
The following file types can be used for PLC-5/250 address specifications:
Element
Allen-Bradley
File Types Description Length
Data Type
in Words
O Outputs DIG/INT2 1
I Inputs DIG/INT2 1
ST String ST 42
PD PID STRUCT 82
B Binary DIG/INT2 1
T Timer STRUCT 6
C Counter STRUCT 3
Element
Allen-Bradley
File Types Description Length
Data Type
in Words
R Control STRUCT 3
N Integer DIG/INT2 1
F Floating-point FLT 2
Subelements
The following subelements are valid for the specified file types in PLC-5/250
address specifications:
25
Table 25-15 File Type AS
CF Fault DIG No
CU Up enable DIG No
DN Done DIG No
OV Overflow DIG No
UN Underflow DIG No
EN Enable DIG No
ST Start DIG No
transmission
AD Asynchronous DIG No
done
AE Asynchronous DIG No
error
CO Continuous DIG No
DN Done DIG No
ER Error DIG No
EN Enable DIG No
DO Derivative of DIG No
MO Mode DIG No
EN Enable DIG No
ER Error DIG No
UL Unload DIG No
IN Inhibit DIG No
comparisons
FD Found DIG No
EN Enable DIG No
TT Timing DIG No
DN Done DIG No
File Types
The following file types can be used for SLC 500 address specifications. Note that
some file types are only valid on later model SLC processors.
Element
Allen-Bradley Default
File Type Description Length
Data Type File Number
in Words
O Output DIG/INT2 0 1
25
S Status DIG/INT2 2 1
T Timers STRUCT 4 3
C Counters STRUCT 5 3
R Control STRUCT 6 3
N Integer INT2 7 1
F Floating-point FLT 8 2
CU Up enable DIG No
DN Done DIG No
OV Overflow DIG No
UN Underflow DIG No
UA Update DIG No
accumulated
value
EN Enable DIG No
DN Done DIG No
ER Error DIG No
UL Unload DIG No
IN Inhibit DIG No
25
FD Found DIG No
EN Enable DIG No
TT Timing DIG No
DN Done DIG No
•
•
•
•
Messages and Codes
This chapter contains information about deciphering run-time status and error
messages that appear on the Run-Time Manager screen and about how
Allen-Bradley INTERCHANGE and RSLinx return codes function with the
KTDTL and NetDTL tasks.
Messages and error codes appear at run time on the Run-Time Manager screen
opposite the Shared Task description for the KTDTL or NetDTL task in the
message area under Last Message. These messages can also be written to a
real-time database message element for display on a custom graphics screen.
Refer to Chapter 23, “Configuring Communication Paths,” of this guide. 26
Also, if you configured your application to create a run-time status window for
Startup
The following status messages appear in the order they are listed every time the
task is started by the Run-Time Manager.
Shutdown
The following message appears at task shutdown:
Normal Termination
Cause: The task has shut down normally.
E RROR M ESSAGES
Error messages for the KTDTL and NetDTL tasks can be generated and displayed
by FactoryLink at task startup, during communications attempts, and at
shutdown. These messages require corrective steps to be taken; the action
required is described following the description of the cause of each message.
Startup
The following messages can be generated and displayed by FactoryLink if errors
occur at task startup:
Cause: The device configuration table files were not properly built,
possibly because the tables contain incorrect entries.
Action: Verify the configuration table entries and correct as needed.
Check the FLAPP\DCT directory to verify the .DCT files were
built. Restart FactoryLink to regenerate these files, if necessary.
Cause: The task does not recognize any read or write operations because
it is unable to read the FLAPP\DCT directory.
Action: Verify the FLAPP\DCT directory has read and write privileges.
Grant these privileges if necessary.
Communications
The following messages can be generated and displayed during a communications
attempt by the KTDTL or NetDTL task:
Tot (# of errors since startup) (Table Name) Lsta: (Logical Station #) (A-B
return-code message)
Cause: This message indicates the total number of communication
errors that have occurred for the specified logical station since
task start up. The return code indicates the status of a read or
write operation for the specified table name.
Action: Take the appropriate action indicated in the message to correct
the error.
Shutdown
When the KTDTL or NetDTL task is terminated by the Run-Time Manager, the
following messages appear in the order they are listed:
Termination In Progress
Cause: The termination procedure was started because of either an
internal run-time error or a normal FactoryLink termination
request.
Action: Check the log file or the status window for other messages
displayed after this one. If the termination is not the result of a
normal termination request and another system message was
generated, make a note of this message. Contact Customer
Support for assistance if you cannot determine the source of the
error based on the subsequent message. 26
Disconnect (A-B KT card #/EI #): (A-B return-code message)
•
•
•
•
Telemecanique PLC
A single FactoryLink system can run more than one driver for simultaneous
communication with various external devices.
Principles of Operation
The PLC interface reads/writes data to/from external devices via a specific driver
and one or more communication ports located on one or more communication
cards. The read/write operations can be run periodically or be controlled by
triggers, operator actions, or system events.
The PLC interface task controls communication using data entered by the user in
the various configuration tables.
27
When the PLC interface task receives a response to a command from an external
device, it checks the response and acknowledges it, if it is correct.
The PLC interface task also checks the response is received within a set time-out.
Telemecanique
If the response time is exceeded or if an incorrect response is received, the task
repeats the command. If the retransmission counter reaches the maximum
number of sends allowed, the task considers the interface as having failed and
displays an error code in the Task Manager screen. The error code identifies the
device causing the communication problems.
When a read operation is requested, the PLC interface task sends a command to
the device driver for it to read the objects specified by the user in a Read/Write
Configuration table. There can be two types of read operations:
Read block (triggered): Reads the values of all PLC objects specified in the
Read/Write Configuration table and writes them to the real-time database.
For a triggered read block, the user specifies a “trigger” element in the real-time
database that will be used to initiate read operations. When the trigger value is 1
(ON) and has changed state since it was last sampled, the PLC interface task
reads the addresses specified in the read/write table.
The block read operations ensure maximum performance levels for the PLC
interface task. This type of operation means a minimum number of block read
requests lets the user collect the data specified in the configuration table. The
PLC interface task sends these requests as “packets” separated by type of data
and groups of packets separated by logical station. The packet size depends on the
protocol used by the peripheral. The read process continues until the last block
read activated by the current trigger is performed.
Unsolicited read (unsolicited data): The PLC interface task can await data
sent by an external device for better operation with some external devices. In this
case the exchange is initiated by the external device, independently of
FactoryLink, so it can write data to the real-time database. These write
commands are treated as read actions as the data is received by the FactoryLink
real-time database in the same way as when objects are read from a PLC.
In order to receive unsolicited data, the PLC interface task emulates the
addressing structure of PLC objects to write to the real-time database. For this
reason, the write command from the PLC must apply to a specified type of data
object; otherwise, the task will not write its contents to the FactoryLink real-time
database.
Write
When a write operation is requested, the PLC interface task sends a command for
the driver program to write the data objects specified by the user in a Read/Write
Configuration table to the appropriate peripheral. Two write operations are
possible:
Block writes (triggered): Writes the values of all of the elements in the
database specified in a Read/Write Configuration table to a PLC.
When a block write is performed, the user specifies a trigger element taken from
the FactoryLink real-time database. The trigger starts the write operations. When
the trigger value is 1 (ON) and has changed state since it was last sampled, the
PLC interface task sends a command to the driver program to write to the PLC
the data objects specified by the user in the Read/Write Configuration table.
The block write operations ensure maximum performance levels for the PLC
interface task. This type of operation means a minimum number of block read
requests lets the user collect the data specified in the configuration table. The
PLC interface task sends these requests as packets separated by type of data and
groups of packets separated by logical station. The packet size depends on the
protocol used by the peripheral. The read process continues until the last block
read activated by the current trigger is performed.
Write on change of state (not triggered): Write on change of state is used only
to write elements whose value has changed (or elements that have a change of
state indicator set) since the last time the database was sampled by the task.
Configuration Tables
The user configures the FactoryLink PLC interface option by entering the
required information in a number of configuration tables that let the system read 27
and write data to/from an external device and initialize the communication
parameters.
Although various types of external devices may be used, the PLC interface task Telemecanique
normally uses five types of configuration tables:
External Device Definition table: This table lets the user specify up to 1000
logical port numbers. These numbers simplify the configuration of communication
access paths by grouping communication co-processors, their physical interface
ports, and the external devices in various combinations.
Read/Write Control and Information tables: These two tables let the user
specify the PLC data objects to be read and transferred to the FactoryLink
real-time database and the PLC data objects to be written from the FactoryLink
real-time database.
The number of read/write control information and configuration tables the user
can configure is limited by the amount of memory available. The number of
read/write tables is limited to 200 tables per type (200 block read tables, 200 block
write tables, 200 exception write tables). The number of entries in each read/write
table cannot exceed 1309 elements.
To access this table, choose Define External Devices from the Configuration
Manager Main Menu. The following screen is displayed:
27
This table lets the user define up to 1000 logical ports. A single logical port is
usually adequate for most applications. If an application uses a large number of Telemecanique
different devices, multiple logical port numbers can be useful so data can be sent
from the FactoryLink real-time database to a number of devices on one or more
networks.
When the information has been entered, choose Exit or press [F3] to validate the
entries and return to the Main Menu.
27
Telemecanique
•
•
•
•
Telemecanique
Configuration Tables
The PLC Interface task allows the user to configure two-way communication
between the FactoryLink real-time database and one or more Telemecanique
drivers via a network interface card.
After completing the External Device Definition table, complete the following
Telemecanique configuration tables:
• Logical Station Control table
• Logical Station Information table
• Read/Write Control table
• Read/Write Information table
28
Telemecanique
To select a screen, place the cursor on a visible part of the screen and click on it
with the left mouse button.
Logical Port The logical port number specified in the External Device
Definition table corresponding to a specific communication
channel.
Valid Entry: 0 to 999
Baud Rate Communication transmission speed in Baud.
Valid Entry: 4800, 9600, 19200 (default=9600)
Use only 4800 or 19200 settings if the TSX SCM module is
28
programmed for these values.
Parity Type of parity used by the transmission. Telemecanique
Valid Entry: odd, even, none (default=odd)
Use only EVEN or NONE if the TSX SCM module is programmed
for these settings.
Data Bits Number of data bits used in the transmission.
Valid Entry: 7, 8 (default=8)
Use only 7 if the TSX SCM module is programmed for this
setting.
MSG Tag Name (Optional) Tag of the database element that contains the report
on communication status on this logical port.
Valid Entry: standard element tag name
Valid Data Type: message
When the information has been entered, place the cursor on the logical port to be
configured, then place the cursor on the visible part of the Logical Station
Information table and click on the left mouse button.
28
Telemecanique
The information entered in this table is assigned to the logical port whose number
is displayed in the Logical Port field. If this number is incorrect, return to the
Logical Station Control screen, and move the cursor to the logical port to be
configured, then once again call-up the display of the Logical Station Information
table.
Logical Port Reminds the user of the number of the logical port to which the
information displayed in this table is assigned.
The next five fields define the five level XWAYaddress. Refer to the corresponding
documentation for more information.
The driver waits up to 10 seconds for a response to a read or write request before
declaring an error condition. The logical station is linked to station group 1 (drop
1) and data exchange does not transit via a Telway network.
28
Telemecanique
Note
If message type elements are used for block read or write operations, it is
recommended no more than 16 message type elements be entered in the same
table.
Table Name The user defined name of the read/write table to configure or
modify.
Valid Entry: alphanumeric string of up to 16 characters
Unsolicited Read (Optional) Indicates reading unsolicited data from the logical
stations specified in this table must be interpreted by the PLC
Interface task. When an unsolicited data read is performed, the
PLC Interface task emulates the addressing structure of the PLC
objects to write to the real-time database. An unsolicited data
table must only contain Message type tags and only read Text
type PLC objects. Refer to “FactoryLink and TSX/PMX PLC Data
Objects” on page 768. FactoryLink listens for unsolicited data on
the First Slave Address. In addition, the user must define a
logical station whose address corresponds to the target address of
the text block used by the PLC for this transmission.
Y A normal write to the real-time database
F A forced write to the real-time database
N Unsolicited data is not interpreted
Exception Write This indicator shows whether writing is required each time the
value of one of the elements specified in the Read/Write
Information table changes.
Y A change of state of any element generates a write
request of its value, regardless of the specified
triggers or of other values.
N No exception writes. Write operations are only
generated when the value of the write trigger and
its change of state bit are forced to 1. All of the
values are written, regardless of the status of their 28
change of state bit.
It is possible to configure both exception write and block write
actions in the same table. Telemecanique
Block Read Priority (Optional) Not used.
Block Write Trigger A FactoryLink real-time database digital element that, when
forced to 1 (ON), triggers a block write of the values specified in
the Telemecanique Read/Write Information table. The block write
trigger is normally defined in another FactoryLink task such as
the Event and Interval Timer, Math and Logic, or Application
Editor.
Valid Entry: standard element tag name
Valid Data Type: digital
Block Write A digital database element that, when set to 1 (ON), disables the
Disable block write action on the elements specified in this table.
Valid Entry: standard element tag name
Valid Data Type: digital
Block Write A digital element of the database forced to 1 (ON) by the PLC
Complete Interface task once the block write of this table is complete. If this
element is defined when the PLC Interface task is initialized, the
value of this element is forced to 1 (ON).
The Block Write Complete elements are valid only if a different
table is used for each logical port.
Valid Entry: standard element tag name
Valid Data Type: digital
Write State A digital element of the database with a value set to 0 (OFF)
when a block write operation on the elements specified in the
table are in progress. Once the block write operations on this
table are complete, the value of this element is set to 1 (ON). If
this element is defined when the PLC Interface task is initialized,
the value of this element is forced to 1 (ON).
The Block Write State elements are valid only if a different table 28
is used for each logical port.
Valid Entry: standard element tag name
Valid Data Type: digital Telemecanique
The block read and write priority levels are set to the highest value, 1. When the
value of database element te_read equals 1 (ON), a block read of the values
specified in the Read/Write Information table is performed. When the value of
database element te_rdisable equals 1 (ON), block reading of table te_rwtable1 is
disabled. Once all of the block read operations for this table are complete, the PLC
Interface task forces the value of the te_rcomp database element to 1. The value of
the te_rstate database element changes to 0 while table te_rwtable1 is being read.
When the value of database element te_write equals 1 (ON), a block write of the 28
values specified in the corresponding Read/Write Information table is enabled.
When the value of database element te_wdisable equals 1, block writing of the
values specified in table te_rwtable1 is disabled. Once all block write operations Telemecanique
for this table are complete, the PLC Interface task force the te_wcomp database
element to 1. The value of the te_wstate database element is 0 when the table
te_rwtable1 is being written.
The values entered in this table identify Telemecanique PLC objects that are:
• Read and transferred to the real-time database when the block read trigger
requests a block read of the table specified in the Table Name field
• Written from the real-time database when the block write trigger requests a
block write of the table specified in the Table Name field.
The data entered in this table is assigned to the table whose name is specified in
the Table Name field. If this name is incorrect, the user must return to the
Read/Write Control screen, and place the cursor on the name of the table to be
filled in, then display the Read/Write Information screen once again.
Specify the following data for each PLC object to read or write:
Station Name Comment field to associate the logical station number to the
corresponding XTEL station name.
Logical Station A number (defined in the Logical Station Configuration table)
that identifies the physical attributes required by the read and
write operations on the real-time database element.
Valid Entry: 0 to 999 (default=0)
All logical station numbers entered must first be defined in the
Logical Station Information table.
Tag Name The name of the real-time database element whose value is
updated when a block read action is performed or which is sent to
the PLC when a block write action is performed.
PLC Object Symbolic representation of the PLC object to read or write.
Valid Entry: Refer to “FactoryLink and TSX/PMX PLC Data
Objects” on page 768.
In this example, the database element te_pl1 is updated when a block read or a
block write operation is performed in relation to logical station 2 (the symbolic
name of the X-TEL station is LSTA2). The Telemecanique object to read or write is
word W0.
Once all data has been entered, click on Exit to validate it. Click on Exit or press
28
[F3] to return to the Configuration Manager.
Telemecanique
•
•
•
•
System Configuration
Table
These tables allow the user to configure executable files to run, depending on the
type of configuration requested.
To open the System Configuration table, choose System Configuration from the
Configuration Manager Main Menu. The following panel is displayed.
Executable File This field must be filled in with BIN/TECOM for the task to start.
29
Telemecanique
•
•
•
•
Reference
It also lets the user determine the appropriate entries for the value of the first
slave address, last slave address, and the TW7 fields in the Telemecanique Logical
Station Configuration table described previously.
The communication devices use the first slave address only for unsolicited
messages and the successive addresses (from the first address + 1 to the last
address) for message data.
To make use of this characteristic, assign the slave numbers, 4 to 18, to the
communication device. To do this, specify the value 4 in the First Slave Address
Field and the value 18 in the Last Slave Address Field in the Telemecanique Logical
Station Control Information table. This allows FactoryLink to send/receive up to
15 messages at a time to/from the network.
These settings must be compatible with “the number of addresses” declared in the
CONFIG.SYS configuration file. Note the TSX 37.xx PLCs can only poll 8
addresses if connected through the TER port.
For other XWAY protocols, the first slave/cost slave addresses are used to define 30
the number of communication sockets to be used. For example, 5-15 on ETHWAY
asks for 10 communication sockets.
It's recommended to declare the exact number of slaves in the master PLC. In
fact, any slave declared and missing will have slow down the pool cycle. The
For best performences, install a PLC with two UNI-TE networks; one to collect the
data and another where FactoryLink will be the only slave.
Click on "Properties"
Exit the Network Configuration Pannel. The new settings are now active.
For Windows 95
Click Properties>Advanced.
For Windows NT
Click "Properties"
For UNI-TELWAY
For versions later than 2.1, refer to the procedure for UNI-TELWAY.
N ETWORK E XAMPLES
FactoryLink communicates directly with the PLCs via UNI-TELWAY or
MAPWAY/ETHWAY/FIPWAY (refer to example 1). Each PLC can, in turn, control
a lower level network of interconnected PLCs via UNI-TELWAY, MAPWAY,
ETHWAY, FIPWAY, ISAWAY, XWAYIP, or TELWAY (refer to Example 2).
FactoryLink communicates with the PLCs on these lower level networks via the
PLC common to both networks.
Each PLC on a network must be assigned the same drop number as the group of
stations to which it belongs. The drop number specifies which group of stations
the messages are sent to.
A UNI-TELWAY bus has one master. All other logical devices (LSTAx) are slaves.
FactoryLink
X-WAY Network
30
A lower level UNI-TELWAY bus is connected to LSTA4 and a lower level TELWAY
network is connected to LSTA0.
Figure 30-2 Network Example 2
Monitor 77/2
Device Device
LSTA4 Master
LSTAO
(Drop0) (Drop1)
Device Device
TELWAY (sta1)
Network LSTA1 LSTA5 Slave 16
(net = 2) (Drop0) (Drop1) UNI-TELWAY
Network
Device Device
(sta3)
LSTA2 LSTA6 Slave 17
(Drop0) (Drop1)
Device Device
(sta5) Slave 18
LSTA3 LSTA7
(Drop0) (Drop1)
The configuration of these networks and of the lower level networks is set in the
Telemecanique Logical Stations Configuration table:
1 TEMAP1
0 1 1 0 0 0 NO 0
1 2 1 0 0 0 YES 0
2 2 3 0 0 0 YES 0
3 2 5 0 0 0 YES 0
4 1 2 0 0 0 NO 1
5 1 2 5 3 74 NO 1
6 1 2 5 3 75 NO 1
7 1 2 5 3 76 NO 1
30
Telemecanique
It also provides instructions for filling in the PL7 Object field in the Read/Write
Configuration table.
The data types supported by FactoryLink are different from those supported by
the PLCs. However, when writing to a FactoryLink data element from its
corresponding memory location in the PLC (PL7 Object), the software interface
converts the type of data from a PLC data object to a FactoryLink data object type.
In the same way, when writing to a PLC memory location (PL7 Object) from a
FactoryLink data element, the software interface converts the type of data from a
FactoryLink data object to a PLC data object type.
Conversion Process
Bit, single-length word, and double-length word data objects can be converted
respectively to/from FactoryLink digital, analog and floating-point elements.
The FactoryLink communication system converts PLC data object types: bits,
single-length words, and double-length words respectively into FactoryLink
digital, analog and floating-point data objects.
The task places the PLC data object to convert in the LSBs of a 32-bit word and
assigns the value 0 to non-significant bits.
The task then converts the complete 32-bit unsigned word into a FactoryLink data
element value.
If a digital type data object is required, the task performs the following
conversion: data value equal to 0, then the element takes the value 0 (OFF).
Data value not 0, then the element takes the value 1 (ON).
If an analog data object is required, the task performs the following conversion:
the 32-bit word is reduced to a 16-bit length word, then copied to the analog
data element. If the data object is a DWORD, the 16-bit MSB data is lost.
The PLC text type elements and the FactoryLink message type elements do
not require conversion. The sign extension is not implemented.
The task places the FactoryLink data object to convert in the LSBs of a 32-bit word
and assigns the value 0 to non-significant bits.
The task then converts the complete 32-bit unsigned word into a PLC data object
value.
If a bit type data object is required, the task performs the following conversion:
data value equal to 0, then the bit is set to 0. Data value not 0, then the bit is
If a word type data object is required, the task performs the following
conversion: the 32-bit word is reduced to a 16-bit length word, then copied to a
PLC single-length word. If a floating-point data object is selected, the sign and
the decimal part are lost. In addition, if the integer part exceeds 216-1, it is
cropped.
The names of PLC objects are specified in the PL7 Object field in the
Telemecanique Read/Write Configuration table in symbolic language, depending
on the type, function, and address of the data object.
Refer to the following tables to determine the symbolic representations valid for
PLC objects. Entry of the corresponding symbol in the PL7 Object field is not case
sensitive. Space characters are not allowed.
The floating point numbers are stored with IEEE single precision format (32 bits)
inside the PLC and with IEEE double precision format (64 bits) inside
FactoryLink. This may induce a lost of precision when exchanging data between
the PLC and FactoryLink.
Num Objects
30
Telemecanique
Symbolic
representatio Addressing
Object
n Num range
syntax
Saved Variables
Word Read/Write %Mi.W i=< 77FE
Double Word Read/Write %Mi.L i=< 77FC
Bit from Word Read %Mi.j i=< 77FE, j<8
Non-Saved Variables
Word Read/Write %Vi.W i=< 77FE
Double Word Read/Write %Vi.L i=<= 77FC
Bit from Word Read %Vi.j i=< 77FE, j<8
Common Word
Word Read/Write %Si.W i=< 3F7E *
* For this object, only addresses where the low byte is lower or equal to H7E are
allowed.
Table 30-7
As a result...
To take avantage of the algorithm which minimizes the number of requests, it’s
recommended to write odd word series or even word series. For long word write
series of long word equal modulo 4.
Examples :
For NUM only the bits from 0 to 7 are available and are coded with the high byte
of the word.
Table 30-8
Wi = H’network number/00’
Wi + 3 = Data to send
Example:
Address of Buffer Wi :
Wi + 3 = data to send
On a MAPWAY/FIPWAY/ETHWAY network:
Configure the TXT type NET function block for OUTPUT with to send unsolicited
data from a network station to the FactoryLink system:
Wi + 1 = data to send
0 FE 5 FE 74
0 FE 5 FE 74
1 7 11 0 0
In this example, the first station is configured to receive unsolicited data sent
from slave 17.
The second station is configured to receive unsolicited data sent by text block 3 of
the master PLC application.
The third station is configured to receive unsolicited data from text block 1 of a
PLC application connected to the network as station 7.
Logical
Tag Name PL7 Object
Station
1 Unsol1 TXT
2 Unsol2 TXT
3 Unsol3 TXT
•
•
•
•
Telemecanique Error
Messages
This chapter describes the messages reporting operations and error conditions
that can be generated and displayed for the Telemecanique protocol module.
Link is spurious
Cause: (UNI-TELWAY only) An unexpected, unsolicited message has
been received.
Action: Ensure the PLC is sending unsolicited messages to the first
UNI-TELWAY slave number reserved for this purpose.
Cause: The Telemecanique panel does not define a logical port on the
invoked XWAY network.
Action: Define the logical port on the Telemecanique panel.
31
Telemecanique
The manual for the I/O Translator task, AB RSLINX protocol driver, and the
MBUSTCP protocol driver are included in this section. Other RAPD protocol
driver manuals are included on the documentation CD. If you need more
information about rapid drivers, refer to the I/O Translator Guide.
Chapter 32
•
•
•
•
External Device
Interface for AB_RAPD 32
External Device
Interface
This chapter introduces you to the AB__RAPD (Allen Bradley_Rapid Application
Protocol Driver) interface and tells you how to start the associated protocol
module.
O VERVIEW
RAPD drivers depart from USDATA’s External Device Interface (EDI) technology.
RAPD drivers are based on the Intertask Mail Exchange architecture. This
architecture defines the task message handling between a protocol driver task
and IOX.
The IOX task issues commands to the protocol driver to access an external device.
The protocol driver, in turn, communicates to the external device(s). IOX might
call on a driver to send data to, or to retrieve data from, an external device.
A driver, on the other hand, can send unsolicited data to the IOX. Any required
conversions on the data going to and received from the protocol driver is handled
by the IOX task.
The FactoryLink AB__RAPD task, the IOXLATOR task, and the Allen-Bradley
RSLinx™ task provides a device interface with which a programmable logic
controller (PLC) and a small logic controller (SLC) can communicate with
FactoryLink, across one or more Allen-Bradley proprietary networks.
Note
Additionally, the tasks can run concurrently with software other than
FactoryLink that is also using RSLinx.
H OW TO U SE T HIS C HAPTER
Use this chapter in conjunction with the I/O Translator Guide to configure the
FactoryLink tags into datasets and read/write triggers. The IOXLATOR also
handles the type conversion between the Allen-Bradley and FactoryLink data
types.
In addition, the FactoryLink ECS Device Interface Guide section for the KTDTL
and NetDTL interface can be referenced for Allen-Bradley data types and
addresses.
AB__RAPD AT A G LANCE
32
This section provides a quick cross-reference to the IOXLATOR and indicates
where to find specific information in this supplement.
External Device
Interface
I/O Translator Dataset You create the dataset definitions by filling out the I/O
Definition Translator Dataset Definition panel of the IOXLATOR
definition panels. This includes read/write triggers and
completion and status tags.
For descriptions of the specific entries you make in this
panel, refer to this supplement. See “Configuring the I/O
Translator Definition Panel” on page 798.
I/O Translator Tag For each dataset, define the tags that make up the dataset
Definition using the I/O Translator Tag Definition panel of the
IOXLATOR definition panels.
For descriptions of the specific entries you make in this
panel, refer to this supplement. See “Configuring the I/O
Translator Definition Panel” on page 798.
AB RSLinx Port Definition For each logical port, define a specific hardware interface
(KT card, Ethernet) in the AB RSLinx Port Definition panel
of the AB__RAPD definition panels.
For descriptions of the specific entries you make in this
panel, refer to this supplement. See“Configuring the AB
RSLinx Port Definition Panel” on page 800.
AB RSLinx Station For each logical port, define the Allen-Bradley devices
Definition connected to the port in the AB RSLinx Station Definition
panel of the AB__RAPD definition panels.
For descriptions of the specific entries you make in this
panel, refer to this supplement. See “Configuring the AB
RSLinx Station Definition Panel” on page 802.
AB RSLinx Dataset For each station, list one or more datasets, previously
Definition defined in the IOXLATOR definition panels, and the
address of the data in the station.
For descriptions of the specific entries you make in this
panel, refer to this supplement. See “Configuring the AB
RSLinx Dataset Definition Panel” on page 807.
External Device
Interface
B
e
f
o
r
e
c
o
m
p
l
e
t
i
n
g
t
h
e
A
Before completing the AB__RAPD configuration panels, you must complete the
I/O Translator Definition panels.
Specify the mailbox of the AB RSLinx driver. The IOX communicates with the AB
RSLinx driver by writing to this mailbox.
AB RSLinx Driver Mailbox This mailbox belongs to the AB RSLinx driver task. Any
Tag task that wants to communicate with the AB RSLinx driver
must write to this mailbox.
Valid Entry: standard tag name
Valid Data Type: mailbox
When the panel is complete, click on Enter to validate the information. Define the
data type (mailbox) for any tag names displayed in the Tag Definition dialog.
Table 32-1 provides sample entries for a row defining a AB RSLinx Driver
Mailbox: 32
Table 32-1 Table 1 Sample AB RSLinx Driver Mailbox Panel Entries
External Device
Column
Interface
AB RSLinx Driver DRVMBX The IOX communicates with the AB
Mailbox Tag RSLinx driver by writing to this mailbox.
Description
Complete a row for each IOX with which the AB RSLinx driver communicates.
The AB RSLinx driver communicates with the IOX by writing to this mailbox. The
AB RSLinx driver communicates with multiple IOXs.
I/O Translator Mailbox Tag This mailbox belongs to the IOX task. Any task that wants
to communicate with the IOX must write to this mailbox.
This must be the same tag defined in the IOX Mailbox
Definition table.
Valid Entry: standard tag name
Valid Data Type: mailbox
Max MSG Maximum number of messages that can reside in the IOX’s
mailbox.
Valid Entry: 1 - 9999 (default = 100)
When the panel is complete, click on Enter to validate the information. Define the
data type (mailbox) for any tag names displayed in the Tag Definition dialog.
Table 32-2 provides sample entries for a row defining a I/O Translator.
32
Table 32-2 Sample I/O Translator Definition Panel Entries
External Device
Column Entry Description
Interface
I/O Translator IOXMBX IOX mailbox tag.
Mailbox Tag
Description
Complete a row for each port used by the driver in this application. A port can be a
serial port, an Ethernet network connection, a KT, or KTC card.
Port Name Give this port a name. Define one port per line and do not
include spaces in the name. You can define as many ports in
this panel as are available on the system.
Valid Entry: alphanumeric string of up to 16
characters
Response Timeout Enter the length of time (in tenths of seconds) the protocol
module waits to receive a response to a read or write
command.
External Device
Valid Entry: 1 - 200 (default = 1)
Interface
Port Status Optional Analog tag to show port status. -1 indicates the
port is not active. A positive value indicates the driver
ID of the RSLinx driver active for that port.
Valid Entry: standard tag name
Valid Data Type: analog
When the panel is complete, click on Enter to validate the information. Define the
data type (analog) for any tag names displayed in the Tag Definition dialog.
Port Status port1_status Tag name of analog tag to hold the port status
value.
Station Name Give this station a name. Define one station per line and do
not include spaces in the name. You can define as many
stations in this panel as are available on this port.
Valid Entry: alphanumeric string of up to 16
characters
Station Status Tag Optional name of a analog element to which any error code
for this logical station is written.
Valid Entry: standard tag name
Valid Data Type: analog
Pyramid EI # (Decimal) Enter the number that corresponds to the station number
specified with the TCP/IP address in the Allen-Bradley
RSLinx configuration software.
Valid Entry: 0 - 999 (default = 0)
External Device
Formats
0RM:[2,3] Resource Manager module, channel 2
Interface
or 3 (for example, 0RM:2)
[1-4]KA:[2,3] Card number, KA module, channel 2
or 3 (for example, 1KA:2)
If you are defining the Pyramid Integrator (PLC5/250)
itself, leave this field blank.
If you are defining a PLC-5/xxe connected directly to
Ethernet, leave this field blank.
For applications using off-link addressing, enter the
location of the off-link station.
Valid Entry: alphanumeric string of up to 22
characters
Note
Do not use 1KT:0. The card number is defined using the interface
number in the port definition table.
Station Address (Octal) Enter the physical DH+, DH, or DH-485 address of the
Allen-Bradley device.
Address Limits
DH+ networks 0 - 77 (octal)
DH networks 0 - 377 (octal)
DH-485 networks 0 - 37 (octal)
Be sure to also complete the PYRAMID CHANNEL ID
(ASCII) field associated with each device if the port is an
Ethernet port.
Valid Entry: 0 - 377 (Octal)
Station Type Enter the type of Allen-Bradley device from which data is
read or to which data is written.
Valid Entry:
PLC Same as PLC-2U.
PLC-2 Same as PLC-2U.
PLC-2P A-B PLC that is accessed by using the
A-B basic (PLC-2) unprotected-read
and protected-write commands.
PLC-2U A-B PLC that is accessed by using the
A-B basic (PLC-2) unprotected-read
and unprotected-write commands.
PLC-3 A-B PLC-3; same as PLC3-KA.
PLC-3KA A-B PLC-3 that is not a PLC-3SR.
PLC-3SR A-B PLC-3 that uses a 1775-S5 or
1775-SR5 scanner for DH+
communications. This scanner allows
faster bit write operations.
PLC-4 Same as PLC-2U.
PLC-5 A-B PLC-5 new or old generation.
PLC-250 A-B PLC5/250 Pyramid Integrator.
SLC-500 SLC 500 series processor.
32
Tip
To enter a station type, go back to the field and press Ctrl+K. From
External Device
the list of valid entries that appear, double-click the station type or
highlight your choice and press Enter.
Interface
Encode Register Define the PLC register to use for an encoded exception
write. Currently not used.
Valid Entry: 1 - 9999
Read Disable Digital tag to enable or disable the read function for the
device. Function is enabled if no tag is specified or the tag
value is OFF. Function is disabled if the tag value is ON.
Valid Entry: standard tag name
Valid Data Type: digital
Write Disable Digital tag to enable or disable the write function for the
device. Function is enabled if no tag is specified or the tag
value is OFF. Function is disabled if the tag value is ON.
Valid Entry: standard tag name
Valid Data Type: digital
When the panel is complete, click on Enter to validate the information. Define the
data type (digital) for any tag names displayed in the Tag Definition dialog.
Table 32-4 provides sample AB RSLinx Station Definition panel entries for AB
RSLinx Port Definition table entries, which are defined in the table on page 801.
Station Status station1_status Tag name of analog tag to hold the port
Tag status value.
External Device
Interface
This table links datasets to the physical PLC addresses. Complete a row for each
dataset associated with the device.
I/O Translator Mailbox Tag IOX mailbox associated with this dataset.
Valid Entry: standard tag name
Valid Data Type: mailbox
Data Set Dataset control tag (digital) which is associated with the
dataset specified by the IOX task.
Valid Entry: standard tag name
Valid Data Type: digital
Note
Read Completion This trigger is set when the dataset is read from the
external device.
Valid Entry: standard tag name
Valid Data Type: digital
Write Completion This trigger is set when the dataset is written to the
external device.
Valid Entry: standard tag name
Valid Data Type: digital
Rcv Completion This trigger is set when the dataset is received from the
external device with the unsolicited receive function.
Valid Entry: standard tag name
Valid Data Type: digital
When the panel is complete, click on Enter to validate the information. Define the
data type (digital) for any tag names displayed in the Tag Definition dialog.
Table 32-5 provides sample AB RSLinx Dataset Definition panel entries for AB
RSLinx Port Definition table entries which are defined in the table on page 801.
External Device
Station Name Station1 The table name defined in the Station
Interface
Definition panel is displayed.
I/O Translator IOXMBX Tag name of the I/O Translator for this
Mailbox Tag dataset.
WORD WORD
PLC3_LONG LONG
LONG RLNG
3BCD BCD
4BCD BCD
PLC3_FLT IEEE
SLC_FLT IEEE
SLC_FLT IEEE
FLT RFLT
BIT BIT
The following command line arguments are used in the System Configuration
panel:
External Device
elements in the AB RSLinx Station Definition table. See “Configuring the AB
RSLinx Driver Mailbox Panel” on page Configuring the AB RSLinx Driver
Interface
Mailbox Panel for information about configuring a message tag. See “Configuring
the I/O Translator Definition Panel” on page 798 for information about
configuring an analog tag.
Error Messages
The following messages might be displayed at startup.
NOCT
Cause: There is no AB__RAPD CT file.
Action: Check CTLIST for the correct AB__RAPD entry.
NOCTRECS
Cause: There are records missing in the AB__RAPD CT file.
Action: Check CTLIST for the correct AB__RAPD entry.
NOCTCLOSE
Cause: There is no AB__RAPD CT file.
Action: Check CTLIST for the correct AB__RAPD entry.
ABSTOP
Cause: There is a problem initializing the IOXLATOR.
Action: Verify the IOXLATOR is running.
ABSTOP1
Cause: There is a problem registering the datasets with the IOXLATOR.
Action: Verify the datasets defined by AB__RAPD are defined by the
IOXLATOR.
E RROR C ODES
32
The following errors are returned to the IOXLATOR at run time.
External Device
Table 32-7 IOXLATOR Errors
Interface
Error Code Description
1002 Cause: The station read disable tag is set for the dataset being
triggered for a read by the IOXLATOR.
Action: Reset the disable tag.
1003 Cause: The station write disable tag is set for the dataset being
triggered for a write by the IOXLATOR.
Action: Reset the disable tag.
•
•
•
•
MODBUS Ethernet
Driver 33
External Device
Interface
PURPOSE
This chapter provides information about a collection of software tools used in
conjunction with Modicon’s Quantum line of Programmable Logic Controllers
(PLCs) and network operating equipment (NOE) ethernet modules.
The following guidelines help focus our purpose and goals to meet customer
requirements:
• Accuracy is paramount—This FactoryLink documentation must provide accurate and
reliable information and procedures.
• Time is valuable—This FactoryLink documentation must guide the programmer through
what he needs to know quickly and efficiently.
AUDIENCE
The major audience of this chapter is the individual familiar with both the
FactoryLink software and the Modicon’s Quantum line of PLCs.
. . . at a Glance
Included in this chapter is a section named . . . at a Glance. This section provides a
quick key to locations for information to perform the procedures detailed in each
section with hypertext links to those locations.
CONVENTIONS
The material in the Documentation Set adheres to the guidelines published in The
Digital Technical Documentation Handbook by Schultz, Darrow, Kavanagh, and
Morse; Developing International User Information by Jones, Kennelly, Mueller,
Sweezy, Thomas, and Velez; and corporate style guidelines.
Documentation Conventions
Convention Description
External Device
command examples. Italic type also sets off references
to specific documents.
Interface
monospace type Monospace type is used to denote command names and
code examples or example output.
press nnnnn Press is used to denote a key on the keyboard. The key
name will display in a sans serif type.
Convention Description
Command Syntax
Example Syntax
command input_file [input_file…] {a|b} output_file
where
command is typed as it is displayed in the syntax.
input_file indicates a variable the user supplies.
[input_file…] indicates the user can optionally supply multiple input file
names, each name separated by a space.
{a|b} indicates either the a or b must be specified as an argument.
output_file indicates the user must specify an output file.
External Device
Interface
2 Read about I/O Translator and “I/O Translator and Protocol Driver
Protocol Driver communications, Communications” on page 823
including datasets, read and block
write, unsolicited receive, exception
write, encoded write, and domain
selection.
4 Read about error codes and error “Error Codes and Messages” on page
messages. 838
O VERVIEW
33
The FactoryLink ECS Modbus Ethernet driver is used in conjunction with
Modicon’s Quantum line of PLCs and network operating equipment (NOE)
ethernet modules. The software enables data exchange between a Quantum PLC
External Device
and a FactoryLink application on a 10 BaseT TCP/IP network.This driver
software,
Interface
This section includes information on how to install Modbus Ethernet Driver
Software.
CAUTION
External Device
The driver task communicates directly with the PLC devices and, therefore,
Interface
understands the required communications protocol. The IOX, on the other hand,
requests the protocol driver to send/get data from the device(s). The IOX provides
necessary data conversions for the protocol driver and handles the FactoryLink
tag data storage. The two tasks communicate with one another via datasets and
mailbox tags.
DATASETS
A dataset is a contiguous area of data (registers, memory locations) in an external
device, such as a PLC. The protocol driver is responsible for defining the complete
dataset area. The dataset area is the area in the device the driver accesses. Access
may be Read or Write, depending on access restrictions the device manufacturer
set.
Datasets are always assumed to be contiguous. The protocol driver must provide a
start and length value to delimit the start and end values of the contiguous area.
The contiguous area is also associated with a data type. The data type refers to
the element type of the area in the device.
UNSOLICITED RECEIVE
The external device sends protocol messages to the FactoryLink workstation for
an unsolicited receive. This means the action is initiated in the external device.
The protocol driver checks if the received data is defined in one of its locally
defined datasets. If it is, the data received from the external device is sent with
the corresponding dataset information to the IOX. The IOX provides any
necessary data conversion. The message is discarded if the message received from
Events, such as alarms, are usually unsolicited. Some extra programming effort
has to be done in the external device (ladder logic is required in a PLC) because
the external device originates the messages.
EXCEPTION WRITE
An exception write is initiated by the FactoryLink workstation and writes data to
the external device. Exception writes are write requests for an element within a
dataset that has changed in value. Since only an element is written, the entire
dataset is not written as a block. The protocol driver receives a request for
exception write from the IOX. The first action the driver takes is to check if the
write can be accomplished with one write message.
If the exception data element size is smaller than the size of the external device
data type element, the data must be read first, patched with exception data, and
written back. An example is a bit that must be written to in a word area. If this is
not done, some data bits within the word may be overwritten in the external
device. The data type of the dataset determines if this event occurs.
For example, if a left byte (BL) in a Holding Register (HREG) has to be written,
then the specific data word must first be read because the size of a Holding
Register is a word (16 bits). The BL has to be patched into the word just read and
then written back to the external device.
The reading of data before writing slows down performance since message traffic
is increased. Some devices provide a function to accomplish the write in the
message. If your device does not have this feature, the encoded write is an
alternative option.
ENCODED WRITE
The encoded write function is almost similar to the exception write in that both
functions write single data elements. The difference is the exception write is an
actual direct (block) write of data to register addresses whereas the encoded write
achieves this end result indirectly. The encoded write is a block write of some
register values to a external device. The data is written to registers that are part
of some internal program, such as ladder logic. The ladder logic may be some
programmed logic that manipulates specifies bits within a specified word. The
information comes down in a block write message for the ladder logic to know
what bits to change within a word.
One advantage of this method is for every element to be written, only one Modbus
Ethernet write command is needed because the external device program does the 33
actual operation on the data element (no reading before writing). A second
advantage is the external device program can control all encoded writes because
they are all written to one location in the external device.
External Device
The encoded write is defined by specifying a starting holding register address in
Interface
the Encode Address field of the Modbus Ethernet Device Definition panel.
Note
The encoded write function is an optional feature the application may or may
not use. This driver does not currently use this feature.
The standard domain for the Modbus Ethernet protocol driver is the SHARED domain, but it
can also be used in the USER domain. The protocol driver communicates with a dedicated
piece of hardware; therefore, only one task should be able to access the hardware. The task
should be started by the SHARED Run-Time Manager if only one program accesses
the hardware.
Note
The protocol driver and the IOX must be in the same domain (SHARED).
You access these panels by opening the Configuration Manager and selecting
Modbus Ethernet Protocol Driver. Four panels are displayed with the titles of all
visible for direct access. To access a specific panel, either
• Position the cursor on a visible area of that panel and click the left mouse
button
• Click on the Next/Previous buttons of the panel in full view
MAILBOX PANEL
The Modbus Ethernet Mailbox panel allows the user to define and initialize one
mailbox tag for the Modbus Ethernet protocol driver for full operation of MCI.
1 Open the Configuration Manager Main Menu > Modbus Ethernet Protocol
Driver.
DEFINITION PANEL
33
The Ioxlator Mailbox Definition panel allows the user to specify the IOX task.
Only one mailbox tag is needed.
External Device
The Ioxlator Mailbox Definition screen shot goes here.
Interface
Perform the following steps to define the fields on this panel:
1 With the Configuration Manager>I/O Translator open, click on any visible part of the
Modbus Ethernet IOX Definition panel.
Max MSG Maximum number of requests for the protocol driver that can be
queued in the mailbox tag. We recommend a value of 100
messages. The number of messages is limited by the size of an
integer value (9999) and/or by the amount of available memory.
The memory needed for a request depends on the size of the
configured datasets. This entry is required.
1 With the Configuration Manager>I/O Translator open, click on any visible part of the
Modbus Ethernet Device Definition panel.
External Device
Valid Entry standard element tag name
Interface
Valid Data Type digital
Write Real-time database element used to enable/disable write commands for the
Disable device. Write commands are enabled if no tag is defined or the status of the
tag is OFF. Write commands are disabled if the status of the tag is ON.
1 With the Configuration Manager>I/O Translator open, click on any visible part of the
Modbus Ethernet Dataset Definition panel.
Data Set Tag name representing a unique logical name for a data set. The
name of the logical device is displayed in the Device Name field.
Type Type definition of the data type in the logical device (PLC). The data types
can be of type Coil, Digital Input, Input Registers, Holding Registers,
Extended Memory, and Statistics.
Place the cursor in the Type field and press Ctrl>K to access the entries for
this field. The table on the next page lists the data types you can enter into
this field.
External Device
C Digital Output 0x reference READ/WRITE
Interface
CO Digital Output 0x reference READ/WRITE
ST Statistics READ/WRITE
The following table describes the statistics information layout in the Quantum
PLC.
Word Meaning
03 Board status.
External Device
24 & 25 Receive buffer error.
Interface
26 & 27 Transmit buffer error.
36 & 37 IP address.
In driver:
When used to read, reads in 38 words of stats stored as 16 bit
words. Use start value of 1 and len of 38 in the Data Set field in
the Driver table.
When used for a write use start of 1 and Len of 1. The statistics
are cleared for a write (block or exception).
In Ioxlator:
READ/WRITE capable
When used to read, use the following configuration
recommendations to read in data. The addressing defines the
location of the various statistics words.
Statistics are cleared when used for a write (block or exception).
ip_addr[0] (analog) 1 38 BL
ip_addr[1] (analog) 1 38 BR
ip_addr[2] (analog) 1 37 BL
ip_addr[3] (analog) 1 37 BR
External Device
Interface
Start Start address number of the dataset.
A holding register is a 16 bit storage area in the Quantum PLC. The driver allows
for bit & byte manipulations on a holding register. This is the only data type
(register type) within the PLC that can be addressed by the driver on a word, byte
or bit level (other register types are excluded from this feature).
For access to a holding register on the word level, simply specify WORD in the Conv column of
the tag definition panel of the I/O Translator. No conversions will occur in the driver since the
driver understands that holding registers are natively stored as 16 bit values.
If a manipulation on the bit level is to be performed, the bit number must be specified in the
Bit/Length column of the I/O Translator Tag Definition panel. Bits are designated from right
to left with the right most bit designated as bit 1 and the left most bit designated as bit 15.
Under the CONV column, specify BIT. For example, to manipulate bit 2 of a holding register,
specify 2 in the Bit/Length column and BIT in the Conv column. You can specify a digital
tag associated with the entry. When the digital tag is set to 1, bit 2 of the holding register will
be set to 1. If the tag is set to 0, bit 2 will be cleared in the holding register. To further illustrate,
if the holding register currently has a value of 5 (binary equivalent is 0000 0000 0000 0101)
and the tag is set to 1, then the holding register’s value will be changed to 7 (binary equivalent
is 0000 0000 0000 0111).
For byte manipulations, do not define a value in the Bit/Length column but do set the Conv
column to either BR (right byte) or BL (left byte). The value of the associated tag will be
reflected in the designated byte (left or right) of the holding register.
UNSOLITICTED DATA
Unsolicited data is expected by the driver to be composed of only holding registers.
This limitation is due to the PLC using the MSTR block to facilitate a write
command to the FactoryLink station. MSTR blocks can only use holding registers
as source registers.
In defining a dataset for unsolicited data, you must know the length (number of
registers) of the dataset (exact number of registers you expect to receive in an 33
unsolicited message from the PLC). If you expect to get varying numbers of
registers being reported back, then define separate datasets for each case. An
unsolicited message will be rejected if no matching dataset can be found for it.
External Device
Datasets are matched against an unsolicited message by comparing the start and
length specifiers and by the data type definition for the dataset which must be set
Interface
to HREG.
The following error codes will be reflected in the device status tag. This tag is
defined in the Device Definition panel of the driver.
Code Meaning
507 Modbus exception response was received (see exception error codes)
Error Messages
Error messages are logged either to a file or the console. To view or capture error
messages, use the following program switch setting under Program Arguments in
the System Configuration option of the FactoryLink configuration manager:
-dn for posting messages to the console
-ln for logging messages to a file, file will be automatically stored as:
%FLAPP%%DOMAIN%%FLUSER%/mbustcp.log
External Device
Interface
CAUTION
Abnormal shutdown
The driver task has shutdown due to a fatal error
No datasets defined
No datasets were configured in the driver’s dataset definition
panel.
External Device
01 ILLEGAL FUNCTION Function code sent in the query is not allowed
Interface
in the slave. The PLC does not support this
function.
•
•
•
•
External Device
Interface for Gem80 34
External Device
Interface
G ETTING STARTED
This section introduces the External Device Interface for Gem80 and points you to
specific sections in this chapter and in the FactoryLink ECS Device Interface
Guide (Device Interface Guide) that will help you get the Gem80 protocol module
running.
While this chapter provides all the protocol-specific data entry requirements for
Gem80, the Device Interface Guide gives you the conceptual information you need
to get started as well as procedural guidelines for entering the protocol-specific
data. If you are a first-time user of a FactoryLink device interface protocol
module, the Device Interface Guide will prove especially helpful.
Overview
This chapter, which is a supplement to the FactoryLink ECS Device Interface
Guide, contains information needed to set up and configure bi-directional
communications between the FactoryLink real-time database and one or more
Gem80 PLCs.
You can use the “External Device Interface at a Glance” section throughout the
entire configuration of the Gem80 protocol module. When the Device Interface
Guide instructs you to go to a protocol-specific chapter or section, however, go to
this chapter instead and return to the Device Interface Guide when necessary.
Gem80 at a Glance
This section provides a quick cross-reference to the Device Interface Guide and
indicates where to find specific information in this chapter.
External Device You create the logical port definitions by filling out the
Definition External Device Definition panel. See Chapter 5,
“Configuring Communication Paths,” in the Device Interface
Guide for descriptions of the entries you make on this panel.
Enter the information as specified with one exception: in the
Device Name column, enter GEM_.
External Device
messages displayed by FactoryLink for the EDI task and the
Interface
protocol module. For information about messages unique to
Gem80, see “Run-Time Application Messages” on page 870.
Before completing the Gem80 configuration panels, you must complete the
External Device Definition panel. See Chapter 5, “Configuring Communication
Paths,” in the Device Interface Guide for details. Enter the information as
specified with one exception: in the Device Name column, enter GEM_.
External Device
Interface
Complete a row for each logical port specified in the External Device Definition
panel you want to define as a communication path for read and write operations.
Table 34-1 provides sample entries for a row defining a Gem80 logical port (the entry in
the Function column in the External Device Definition panel is SYSCOM): 34
Table 34-1 Sample Logical Station Control Panel Entries
External Device
Column Entry Description
Interface
Logical Port 0 The communication path to be used for read and
write operations between FactoryLink and devices
communicating via this port is represented as 0.
Retry Timeout 0.1 100 The driver waits 10 seconds after any read or write
seconds error to the device before attempting to retry or
attempting further reads or writes to the same
device.
Complete a row for each device to communicate through this logical port.
Logical Station Enter a number to identify the logical station to which the
(Decimal) information in this row pertains. A logical station 34
represents the combination of a logical port with a physical
station. Assign a unique number to each device
External Device
communicating through this logical port. This number must
be unique among all Gem80 devices across all ports.
Interface
You will later enter this logical station number in a read or
write table to represent the device defined in this row. In a
read or write table, this number identifies the device to or
from which data is sent or received.
Valid Entry: unique numeric value from 0 - 999
(default = 0)
When the panel is complete, click on Enter to validate the information. Define the data
type (analog) for any tag names displayed in the Tag Definition dialog.
Table 34-2 provides sample entries for a row defining a logical station communicating via the
logical port specified on the Logical Station Control panel: 34
Table 34-2 Sample Logical Station Information Panel Entries
External Device
Column Entry Description
Interface
Logical Port 0 The logical port number defined in
the Logical Station Control panel is
displayed.
Complete a row for each read or write table. Refer to Chapter 6, “Reading Data
from a Device,” and Chapter 7, “Writing Data to a Device,” in the Device Interface
Guide for specific instructions on configuring each type of read and write
operation. Additionally, refer to Chapter 8, “Application Design Tips and
Techniques,” for information about triggering schemes using elements defined in
this panel.
Table Name Name this read or write request. Define one request (table)
per line and do not include spaces in the name. You can
define as many tables in this panel as available memory
allows. Try to make the table name reflective of the
operation it represents.
If this is a triggered read or a block write table, when the
trigger element (Block Read Trigger for a read operation or Block
Write Trigger for a write operation) is forced to 1 (ON), the element
prompts FactoryLink to process this table and any other table in which
the same trigger is defined.
Valid Entry: alphanumeric string of up to 16
characters
External Device
enter YES.
Interface
In an exception write, an internal change-status indicator
within the element containing the data to be written
prompts the write operation. If an element is configured for
an exception write and EDI recognizes this indicator has
been set since the last scan of the real-time database
(indicating the value of the element has changed), EDI
writes this element’s value to the device.
Valid Entry: no, yes (default = no)
Tip
Note
The Block Read Trigger, Block Read Disable, Block Read Complete, and
Block Read State elements apply only to triggered read operations. Of these
elements, only Block Read Trigger is required; the others are optional. Do not
define these block read elements for unsolicited read operations or for write
operations.
34
Tip
The Block Read Disable element can disable a block read operation that is
External Device
either part of a cascaded loop or is self-triggered. The triggering cycle ceases
upon disabling, however. To re-enable a cascaded loop or a self-triggered
Interface
read table, the Block Read Disable element must be changed to 0 and the
Block Read Trigger element must be forced to 1. Refer to Chapter 8,
“Application Design Tips and Techniques,” in the Device Interface Guide
for details about cascaded and self-triggered tables.
Note
The Block Write Trigger, Block Write Disable, Block Write Complete, and
Block Write State elements apply only to write operations. Of these elements,
only Block Write Trigger is required for a block write table; the others are
optional. Do not define these block write elements for read operations.
External Device
for a digital element to initiate a block write of the element
Interface
values represented by the tag names specified in the
Read/Write Information panel to the addresses defined to
receive the values. When the value of the block write trigger
is forced to 1 (ON), the element values are written.
Valid Entry: standard tag name
Valid Data Type: digital
Block Write If this is a read operation or an exception write operation
Disable you do not plan to periodically disable, ignore this column.
If this is a block write operation or an exception write
operation you plan to periodically disable, enter a tag name
for a digital element to disable a block write to the
addresses specified in this table. When the value of the
element represented by this tag name is forced to 1 (ON),
the write operation is not executed, even when the block
write trigger is set to 1.
To re-enable a block write table that has been disabled, set
this element back to 0 (OFF).
Valid Entry: standard tag name
Valid Data Type: digital
Tip
The Block Write Disable element can disable a block write operation that is
either part of a cascaded loop or is self-triggered. The triggering cycle ceases
upon disabling, however. To re-enable a cascaded loop or a self-triggered
read table, the Block Write Disable element must be changed to 0 and the
Block Write Trigger element must be forced to 1. Refer to Chapter 8,
“Application Design Tips and Techniques,” in the Device Interface Guide
for details.
When the panel is complete, click on Enter to validate the information. Define the data
type (digital) for any tag names displayed in the Tag Definition dialog.
Table 34-3 provides sample entries for a row defining a triggered read table:
34
Table 34-3 Sample Read/Write Control Panel Entries
External Device
Column Entry Description
Interface
Table Name READ The name of this table is READ.
Block Write
Disable
Block Write
Complete
Block Write
State
External Device
Interface
For a Read Table—Add a panel entry for each FactoryLink database element in
which data read from the device will be stored when the operation executes.
For a Write Table—Add a panel entry for each FactoryLink database element to be
written when the operation executes.
Tag Name For a read table, specify a tag name for an element in which
FactoryLink stores the data read from the device.
For a write table, specify a tag name for an element
containing a value to be written to the device.
Valid Entry: standard tag name
Valid Data Type: digital, analog, longana, float, message
Logical Station Enter the number representing the device from which the
data is read or to which the element’s value is written. This
number was originally defined in the Logical Station
Information panel for the logical port through which
communications with this device occurs.
Valid Entry: previously defined logical station
number
For reading and writing digital tags, this field is the bit
number within the specified table. For reading and writing
Bit/Length
message tags, this field is the length of the string in
characters.
Valid Entry: 0 - 99 (default = 0)
Base Address Tag name of a FactoryLink real-time database element that
Tag Name holds a Gem80 table address which is added at runtime to
the contents of the Address field to form the table address
accessed. Note that if a Base Address tag is specified, then
the contents of that tag must be read by the driver at
runtime for every read/write. This may impact on the
overall communications performance, and this impact may
be significant in high-throughput applications. See also the
Technical Notes at the end of the chapter which describe the
Read/Write blocking actions of the driver.
Valid Entry: standard tag name
Valid Data Type: analog
When the panel is complete, click on Enter to validate the information. Define the tag type
for any tag names displayed in the Tag Definition dialog.
Table 34-4 provides sample Read/Write Information panel entries for the triggered read table
defined on page Table 34-3. 34
Table 34-4 Sample Read/Write Information Panel Entries
External Device
Interface
Table Name READ The table name defined in the
Read/Write Control panel is displayed.
Reads
1 For Block Mode NO, each tag results in a separate read command. Note that this
also applies to JK and STARNET connection types, as well as to programming
port messages. So to optimize JK or STARNET communications, it is beneficial to
set Block Mode to YES.
3 All CF requests for the same logical station and tag type are grouped into a single
read. Similarly, this is also true for all CQ requests.
4 If Block Mode is YES, entries for different tag types, different logical stations, or
different Base Address Tag Names are grouped into separate reads. For example,
Digital and Analog tags are not mixed within a single read, even for the same logical station.
5 For Block Mode YES, within a single tag type and logical station, successive
addresses are blocked into a single read provided the number of PLC tables in the
read does not exceed the maximum block size for the connection type. These block
sizes are as listed in the section Block Sizes below.
Writes
1 Every exception write results in a separate write command.
2 All following points refer to Block Writes, such as Exception Write set to N in the
configuration table.
3 For Block Mode NO, each tag results in a separate write command. Note that this
also applies to JK and STARNET connection types, as well as to programming
port messages. So to optimize JK or STARNET communications, it is beneficial to
set Block Mode to YES.
5 If Block Mode is YES, entries for different tag types or different logical stations or
different Base Address Tag Names are grouped into separate writes. For example,
Float and Analog tags are not mixed within a single write, even for the same logical station.
6 For Block Mode YES, within a single non-digital tag type and the same logical
station, successive addresses are blocked into a single write provided the number 34
of PLC tables in the write does not exceed the maximum block size for the
connection type. Maximum block sizes are specified in the following table.
(Remember that QF float tables use two table addresses for each value).
External Device
7 For Block Mode YES, bit writes into the same PLC table address are grouped into
Interface
a single write. Digital writes into successive addresses are not blocked into a single write. For
example, bit writes into G100 bit 1, bit 5, and bit 12 are carried out as a single write to the PLC.
Bit writes into G100 bit 1 and G101 bit 2 are processed as two separate PLC writes.
Block Sizes
Table 34-5
PRGPORT 32
JK_STD 32
JK_ENH 128
STARNET 111
See Chapter 10, “Messages and Codes,” in the Device Interface Guide for
information about the messages displayed for the EDI task and the format in
which protocol module messages are generated.
External Device
configured timeout.
Interface
Action: Verify the device configuration and cabling is
correct. The FactoryLink configuration tables
must contain the proper tributary addresses
and parameters. The Logical Station Control
panel must contain the proper baud rate, parity,
data bits, and stop bits settings.
ER:xxx8 Cause: The PLC reply did not contain the expected
number of tables.
Action: Verify the PLC configuration is correct. This
error usually occurs because the requested
tables are not configured within the PLC.
•
•
•
•
External Device
Interface for SECS 35
External Device
Interface
G ETTING STARTED
This chapter introduces the Device Interface for SDRV Communications and
points you to specific sections that will help you get the SDRV Communications
protocol module up and running.
This chapter provides all the protocol-specific data entry requirements for SDRV
Communications, as well as procedural guidelines for entering the
protocol-specific data.
Overview
This chapter contains information needed to set up and configure bidirectional
communications between the FactoryLink real-time database and one or more
SEMI Equipment Communication Standard (SECS) Protocol devices. SDRV
Communications will support the SECS-I and SECS-II serial RS-232 protocol as
well as the HSMS TCP/IP protocol.
External Device
Interface
Complete a row for each logical port you want to define as a communication path
for read and write operations.
Logical Port
Required
Valid Entry: 0 - 999
SECS/HSMS
Required
Valid Entry: HSMS
SECS
Specify whether to use the SECS RS232 or HSMS protocol for communiction.
Com Port
Required for SECS
35
Valid Entry: 1 - 8
External Device
Specify COM port for SECS protocol.
Interface
Baud Rate
Required for SECS
Valid Entry: 150 4800
300 9600 (default)
1200 19200
2400
T3 Timeout 1 sec
Required
Valid Entry: 1 - 120 seconds
10 as default
T5 Timeout 1 sec
T6 Timeout 1 sec
T7 Timeout 1 sec
T8 Timeout 1 sec
Retry Limit
35
Required SECS ONLY
Valid Entry: 0 - 31
External Device
3 as default
Interface
SECS retry limit
ACTIVE/PASSIVE
HOST/EQUIP
Required
Valid Entry: HOST
EQUIP
Protocol
Required
Valid Entry: SMS-SS94 for HSMS
SMS-94 for HSMS
SMS93 for HSMS
ECS for SECS
EM for BOTH
TCP Port
Specify the TCP Port Number at which the Passive Entity waits for
connection.
Specify the frequency at which control messages will be sent to verify the link
is still functional.
TGRACE 1 sec
35
Required HSMS ONLY
Valid Entry: 1 - 120 seconds
External Device
10 as default
Interface
Specify the time during which send operations will be accepted while
attempting to establish a connection.
Specify time limit to allow the other end of the link to attempt to send
messages while all buffers are full.
Optional
Valid Entry: Standard FactoryLink tag name
Valid Data Type: Analog
Tag name of a FactoryLink real-time database analog tag to which the status
for the last send operation is written.
Optional
Valid Entry: Standard FactoryLink tag name
Valid Data Type: Analog
Tag name of a FactoryLink real-time database analog tag to which the count
of messages sent is written.
Optional
Valid Entry: Standard FactoryLink tag name
Valid Data Type: Analog
Tag name of a FactoryLink real-time database analog tag to which the count
of messages received is written.
Optional
Valid Entry: Standard FactoryLink tag name
Valid Data Type: Analog
Tag name of a FactoryLink real-time database analog tag to which the count
of timeout errors is written.
Optional
Valid Entry: Standard FactoryLink tag name
Valid Data Type: Analog
Tag name of a FactoryLink real-time database analog tag to which the count
of retries is written.
External Device
Valid Data Type: Valid Data Type:Message
Tag name of a FactoryLink real-time database message tag to which status for
Interface
this logical port is written.
When the panel is complete, click on Enter to validate the information. Define the
data type for any tag names displayed in the Tag Definition dialog.
Complete a row for each device to communicate through this logical port.
Optional
Valid Entry: Standard FactoryLink tag name
Valid Data Type: Analog
Tag name of a FactoryLink real-time database analog element to which any errors
for this logical station are written
Required
Valid Entry: 0 - 63
0 as default
Number that you assign to represent the combination of a logical port and
physical station. A logical station number can be used only once.
Device ID
35
Required
Valid Entry: 0 - 32767
External Device
0 as default
Interface
Number to identify a physical device.
Required
Valid Entry: ON_LINE
OFF_LINE
Comment
Optional
Valid Entry: Alphanumeric string of up to 30 characters
When the panel is complete, click on Enter to validate the information. Define the
data type for any tag names displayed in the Tag Definition dialog.
Complete a row for each read or write table. Refer to Chapter 6, “Reading Data
from a Device,” and Chapter 7, “Writing Data to a Device,” in the Device Interface
Guide for specific instructions on configuring each type of read and write
operation. Additionally, refer to Chapter 8, “Application Design Tips and
Techniques,” for information about triggering schemes using elements defined in
this panel.
Required
Valid Entry: 0 - 63
o as default
SECS-II Table ID
Required
Valid Entry: 0 - 32767
0 as default
Number of the table defined in the SDRV-II Message Definition Control Table
to be processed for this logical device.
External Device
Valid Data Type: Analog
Interface
the stream number of the message to be sent.
Optional
Valid Entry: Standard FactoryLink tag name
Valid Data Type: Analog
Send Message ID
Optional
Valid Entry: Standard FactoryLink tag name
Valid Data Type: Analog
Send Trigger
Optional
Valid Entry: Standard FactoryLink tag name
Valid Data Type: Digital
Digital element whose value, when forced to 1 (ON), initiates a send of the
message defined by the stream, function and message ID tags.
Optional
Valid Entry: Standard FactoryLink tag name
Valid Data Type: Digital
Digital element whose value, when 1 (ON), disables a triggered send of the
device(s) message specified in this table.
Send State
Optional
Valid Entry: Standard FactoryLink tag name
Valid Data Type: Digital
Send Status
Optional
Valid Entry: Standard FactoryLink tag name
Valid Data Type: Analog
Tag name of a FactoryLink real-time database analog tag to which the status
for the last send operation for this table is written.
Read Disable
Optional
Valid Entry: Standard FactoryLink tag name
Valid Data Type: Digital
Digital element whose value, when 1 (ON), prevents the logical device from
being polled for received messages.
Command Trigger
35
Optional
Valid Entry: Standard FactoryLink tag name
External Device
Valid Data Type: Analog
Interface
command to the SDRV task. Used to set the On Line/Off Line state of the
SDRV task.
Command Value
Optional
Valid Entry: Standard FactoryLink tag name
Valid Data Type: Analog
Analog element whose value is used in conjunction ith the Command Trigger
to build the command sent to the SDRV task.
Command Status
Optional
Valid Entry: Standard FactoryLink tag name
Valid Data Type: Analog
Analog element whose value is used in conjunction with the Command Trigger
to build the command sent to the SDRV task.
Optional
Valid Entry: Standard FactoryLink tag name
Valid Data Type: Analog
Optional
Valid Entry: Standard FactoryLink tag name
Valid Data Type: Analog
Receive Message ID
Optional
Valid Entry: Standard FactoryLink tag name
Valid Data Type: Analog
Receive Status
Optional
Valid Entry: Standard FactoryLink tag name
Valid Data Type: Analog
Tag name of a FactoryLink real-time database analog tag to which the status
for the last command for this table is written.
When the panel is complete, click on Enter to validate the information. Define the
data type for any tag names displayed in the Tag Definition dialog.
External Device
Interface
SECS-II Table ID
Required
Valid Entry: 0 - 32767,,az
0 as default
Comment
Optional
Valid Entry: Alphanumeric string of up to 30 characters
When the panel is complete, click on Enter to validate the information. Define the
data type for any tag names displayed in the Tag Definition dialog.
Tag Name
Optional
Valid Entry: Standard FactoryLink tag name
Valid Data Type: DIGITAL
ANALOG
FLOAT
MESSAGE
Read/Write
35
Required on the first line of a message definition.
Valid Entry: READ
External Device
WRITE
BOTH
Interface
INQGN (Inquire/Grant)
Specify the message type. BOTH defines the message for both READ and
WRITE activity. INQGN will result in an Inquire/Grant transaction. The
value in ‘Constant’ specifies the function number of the data message. The
stream and message ID will be same for the data message.
Stream Decimal
Optional
Valid Entry: 0 - 255
Stream number for the message to be sent or received. Required on the line
which specifies READ, WRITE, BOTH or INQGN.
Function Decimal
Optional
Valid Entry: 0 - 255
Function number for the message to be sent or received. Required on the line
which specifies READ , WRITE, BOTH or INQGN.
Message ID
Optional
Valid Entry: 0 - 999
Message number for the message to be sent or received. Required on the line
which specifies READ , WRITE, BOTH or INQGN.
Required
Valid Entry: LIST
BNARY
BOOLN
AXCII
JIS8
SINT8
SINT1
SINT2
SINT4
FLOT8
FLOT4
UINT8
UINT1
UINT2
UINT4
FNAME
NOBDY
FSIZE
FN_B - File Name, send data as bytes
FN_A - File Name, send data as ASCII
FN_I1 - File Name, send data as SINT1
FN_I2 - File Name, send data as SINT2
FN_I4 - File Name, send data as SINT4
FN_I8 - File Name, send data as SINT8
FN_U1 - File Name, send data as UINT1
FN_U2 - File Name, send data as UINT2
FN_U4 - File Name, send data as UINT4
FN_U8 - File Name, send data as UINT8
External Device
CONAS- Conditional item type ASCII
Interface
Specify the data item. For additional details of FN_XX and CONXX item types
see the Technical Notes section.
Number
Optional
Valid Entry: 0 - 32767
Number used in conjunction with some data items. For specific usage see the
Technical Notes section.
Constant
Optional
Valid Entry: Alphanumeric string of up to 15 characters
Character string used in conjunction with some data items. For specific usage
see the Technical Notes section.
Parse Position
Optional
Valid Entry: Alphanumeric string of up to 15 characters
Character string used to identify the position of a data item in a message. For
specific usage see the Technical Notes section.
Reply
Optional
Valid Entry: NO
YES
If ‘YES’ and a Read Disable Tag is specified for this Logical Device, it will be
set to ‘ON’ upon receiving this message. This will prevent receiving messages
for this Logical Device until the Read Diasble Tag is set to ‘OFF’.
Parse
Optional
Valid Entry: NO
YES
Specify whether to process all data items or parse out data items to be
processed in a READ message. If ‘YES’, it must appear on the same line with
the READ.
TECHNICAL N OTES
35
Application Specific
External Device
INT8
Interface
For UINT8 and SINT8 the data can be stored into 2 LANA or 4 ANA by specifying
a tag array and a count in the ’Constant’ column.
Parsing
If the ’Parse’ field of a ’READ’ Message Definition Line is ’Yes’, the incoming
message will be parsed. The parsing term for each tag is entered in the ’Parse
Position’ field.
The following example illustrates ‘Parse Position’ terms for a sample message
(similar to S6,F3):
Message Structure ParsePosition String
L, 3 1
UINT4 1.1:
UINT4 1.2:
L, 1 1.3
L, 2 1.3.1
UINT4 1.3.1.1:
L, 7 1.3.1.2
ASCII, 40 1.3.1.2.1:10,20 Start with character 10, store 20
ASCII, 40 1.3.1.2.2:,40 Store first 40 characters
ASCII, 40 1.3.1.2.3:10 Start at character 10, store rest of string
ASCII, 40 1.3.1.2.4: Store whole string
UINT4 1.3.1.2.5:
INT4 1.3.1.2.6:
UINT4 1.3.1.2.7:
The term after the ':' in the form 'X,Y' is used for strings to determine the start
position (X) and the number of bytes (Y) to be stored. If 'X' is omitted (:,Y) the start
position is 0. If 'Y' is omitted (:X,) the string starting at X to the end of the end of
the string is stored. If neither X nor Y is specified, the whole string is stored. In
the case of UINT8 and SINT8 the 'X' value is used to store into 2 LANA or 4 ANA
tag array.
Command Trigger and Command Value are analog tags. The Command Trigger
defines the Command Type and the Command Value contains an optional
argument for the Command. Right now the only Command defined is ’1’ which
sets the On Line/Off Line status. The desired status is stored in Command Value:
1 for On Line and 0 for Off Line.
Repeat Blocks
Repeat Blocks - A list block can be repeated if an entry is made in the ’Constant’
field for a ’LIST’ entry.
For example:
LIST 3 2
tag1 UINT4
tag2 UINT2
tag3 UINT2
LIST 6
tag1 UINT4
tag2 UINT2
tag3 UINT2
tag1+1 UINT4
tag2+1 UINT2
tag3+1 UINT2
For example:
LIST 1 2
LIST 3
tag1 UINT4
35
tag2 UINT2
tag3 UINT2
External Device
will result in the following message:
Interface
LIST 2
LIST 3
tag1 UINT4
tag2 UINT2
tag3 UINT2
LIST 3
tag1+1 UINT4
tag2+1 UINT2
tag3+1 UINT2
For example:
LIST 3 2
tag1 UINT2
tag2 UINT2
LIST 2 2
tag3 SINT2
tag4 SINT2
LIST 6
tag1 UINT2
tag2 UINT2
LIST 4
tag3 SINT2
tag4 SINT2
tag3+1 SINT2
tag4+1 SINT2
tag1+1 UINT2
tag2+1 UINT2
LIST 4
tag3+2 SINT2
tag4+2 SINT2
tag3+3 SINT2
tag4+3 SINT2
The message structures are expanded at start up to reduce the processing at run
time. If logging (command line ’d’ or ’D’) is enabled, the message structures will be
stored in the file ’sdrv_log.dat
Conditionals
Item types are CONI2, CONU2, CONI4, CONU4 and CONAS for SINT2, UINT2,
SINT4, UINT4 and ASCII data types respectively. Entries in the ’Constant’ field
will be used to match the incoming data. These item types can be used in normal
or parsed READ messages. The conditional fields may or may not have tags
associated with them. If there are any conditionals in a message definition, the
message will first be processed to see if the data received in the conditional fields
matches the ’Constant’ data for the conditional field before any data is stored into
tags. For ’CONAS’ fields, the ’:X,Y’ parsing conditions apply to the conditional
matching, but if the conditions are met, and a tag is specified for the field, the 35
whole string will be stored.
File Transfers
External Device
FNAME, FN_XX and FSIZE require a message tag containing a file name. FSIZE
Interface
will send a SINT4 with the file size.
FNAME will require a message tag containing the file name for READ functions.
To WRITE files, use the following item types: FN_B(BYTE), FN_A(ASCII),
FN_I1(SINT1), FN_U1(UINT1), FN_I2(SINT2), FN_U2(UINT2), FN_I4(SINT4),
FN_U4(UINT4), FN_I8(SINT8) and FN_U8(UINT8). Each of those item requires
a message tag containing the file name of the file to be sent. The particular item
type used determines the data type used to send the file. On a READ the data type
is determined from the messsage.
Multiple Items
A READ message such as S1F10 where a data item may consist of multiple items,
can be handled by using a tag array and specifying the size of the array in
’Number’.
System Specific
bXXX, BXXX - XXX is the number of SDR buffer allocated by the SDR task. If
missing or less than 10, 200 buffers will be allocated.
fYYYYY, FYYYYY - YYYYY is the path SDR files. Stores the ’sdrconf.cfg’ file. If
not defined, default is ’<FLAPP>/procs’.
l, L - additional data for repeat blocks and parsing will be displayed on the screen
or written to the file specified by d:f.
Miscellaneous
On READ, the ’Item Type’ is ignored. The data is processed according to the
’mesg.next’ type.
External Device
for these elements in the Logical Station table. See “Configuring the Logical
Device Control Panel” on page Configuring the Logical Device Control Panel for
Interface
information about configurng a tag name for a message element. See “Configuring
the Logical Device Information Panel” on page Configuring the Logical Device
Information Panel for information about configuring a tag name for an analog
element.
See Chapter 10, “Messages and Codes,” in the Device Interface Guide for
information about the messages displayed for the EDI task and the format in
which protocol module messages are generated.
Index I-905
analog 213 checksum
data type 668, 678, 696, 698 in error checking schemes 284
digital 213 limitations of GPI 261
floating point 214 non-printable characters 299
long analog 215 clear to send 56
message 216 clearing change-status indicators 607
bit-level addresses 667, 678 codes 580, 582–583
block read and write 823 coil register
Block Sizes 869 see also read coil or input status register
block write write digital element to 147
block write request 124, 127 column entries
control panel entries 662–665 AB RSLinx Driver Mailbox Tag 796
defined 649 Address 807, 866
how it works 650, 685 Address, sample entry 867
when to use 655 Base Address Tag Name 866
bridge identifier 621 Base Address Tag Name, sample entry 867
bytes Baud Rate 849
basic concept 289 Baud Rate, sample entry 851
in design flexibility 283 Bit/Length 866
Bit/Length, sample entry 867
C Block Mode 853
cable connections Block Mode, sample entry 855
description and diagrams 59 Block Read Complete 859
Modbus Plus diagram 383 Block Read Complete, sample entry 863
overview 50 Block Read Disable 858
Siemens H1 diagram 487 Block Read Disable, sample entry 863
Square D diagram 518 Block Read Priority 857
types of 59 Block Read Priority, sample entry 863
worksheet 62 Block Read State 860
capabilities, limitations, and trade-offs for Block Read State, sample entry 864
General Purpose Interface 261 Block Read Trigger 858
carrier detect 56 Block Read Trigger, sample entry 863
cascaded loop 172–174, 690–692 Block Write Complete 862
cascaded loop tables 859, 861 Block Write Disable 861
cascading tables 172 Block Write Priority 860
change-status indicator 857 Block Write State 862
Index I-907
identifying 73 sample entries 797
combination read request 97 AB RSLinx Port Definition 793, 800
combination write request 132, 159 sample entries 801
command line arguments AB RSLinx Station Definition 793, 802
for System Configuration panel 810 sample entries 806
command protocols, GPI 328 accessing 826
command response timeout 613 display of all 795, 848, 875
Command/Response Control panel External Device Definition 846, 848, 851,
General Purpose Interface 271 873, 875, 884
Command/Response Information panel I/O Translator Dataset Definition 793
General Purpose Interface 275 I/O Translator Definition 798
Command/Response table sample entries 799
General Purpose Interface 269 I/O Translator Tag Definition 793
commands, logical station 474 Ioxlator Mailbox Definition panel 827
common errors 180 Logical Station Control 846, 849, 870, 873,
see also messages and codes 876, 903
communications Logical Station Control, sample entries
Allen-Bradley card port 589, 595–597 851
errors 77 Logical Station Information 846, 852, 865,
Ethernet card port 590, 598–600 870, 873, 884, 903
KTDTL and NetDTL error tag 613 Logical Station Information, sample en-
logical port error tag 613 tries 855
methodology 20 Modbus Ethernet Mailbox panel 826
multiple devices 22 Modbus TCP/IP Dataset Definition panel
path 69–85 830
protocol 77 Modbus TCP/IP Driver Device Definition
Siemens H1 link 441 panel 828
with multiple protocol modules 23 Read/Write Control 846, 856, 874, 886
with offlink addresses 592–594 Read/Write Control, sample entries 863
computations for 5TI sequencer ladder logic Read/Write Information 846, 865, 874,
code 567 891–892
conceptual information 843, 845, 873 Read/Write Information, sample entries
configuration panels 867
AB RSLinx Dataset Definition 793, 807 configuring
sample entries 809 communication paths 69
AB RSLinx Driver Mailbox 796 communication paths for KTDTL and Net-
Index I-909
block read disable trigger 661 parameter addresses 98, 133
block read priority 659 path to offlink station ??–621634–644
block read state trigger 163, 175, 661, 688, PLC-5/250 TCP/IP address 613
693 PLC-5/xxE 628
block read trigger 163, 175, 659, 688, 693 PLC-5/xxE TCP/IP address 613
block write complete trigger 665 protocol module to EDI 73
block write disable trigger 663 pushwheel number 627
block write priority 662 Pyramid Integrator 628
block write request 124–130, 153 read and write operations 856, 886
block write state trigger 163, 175, 665, 688, read request 89–122
693 re-enabled exception write trigger 666
block write trigger 163, 175, 663, 688, 693 self-triggered tables 175, 692–693
card number 627 stations ??–623, ??–630
cascaded loop 172–174, 690–692 status window 603
channel number 627 table type and triggers 126
combination write request 132 table type and triggers for read requests
communication path 849, 876 92
communication paths 69 TSAP pair for Siemens H1 443
data type 668, 696, 698 unsolicited data type 678
device addresses 621, 634–644 unsolicited read table 676
device type 623, 629 delimiters
devices ??–623, ??–630 in expected response 295
element for storing data read 667, 678 NUMERIC 292
element to write to device 667 TAGVALUE 292
exception write disable trigger 666 device addresses
exception write priority 666 defining 98–99, 133–134
exception write request 97, 130–132 device communications
log file 606 cable diagrams 59
logical port 613 configuring. testing, troubleshooting 587
logical port error tag 613 device control module (DCM)
logical ports 69 definition 441, 446
logical station 626 device topologies
logical station error tag 626 combination 29
logical stations 77, 83 overview 27
module type 627 devices
network address of device 621, 634–644 Allen-Bradley types 791
Index I-911
sample 156 FLT8
when to use 655 analog 214
Exclusive-or 303 floating point 215
External Device Interface, see EDI in Allen-Bradley 219
long analog 216
F
Field G
Breakdown of outgoing message 284 gateway identifier 621
Definition of 283 General Electric
Length 284 Logical Station Control panel 238
Modifying a previously defined 304 Logical Station Information panel 241
Field Position messages 255
Definition 292 overview 237
In GPI design 283 Read/Write Control panel 244
Field Type 294–295, 302–304 Read/Write Information panel 251
For status 300 General Purpose Interface
In GPI design 283 basic concepts 289
In outgoing message 292 capabilities, limitations, and trade-offs
List of delimiters 292 261
flexibility of GPI 283 command protocols 328
floating point Command/Response Control panel 271
Allen-Bradley conversions 214, 218 Command/Response Information panel
BCD3 218 275
BCD4 218–219 Command/Response table 269
BIN 218 configuration 305
FLT4 219 conversion functions 323
INT2 218 debugging tools 288
floating point element 214, 218 flexibility and design 283
data conversion 491 functions of 291
read holding register 106 incoming response 294
write to holding register 143 Logical Station Control panel 263
flowcharts, problem solving 178 Logical Station Information panel 267
FLT4 messages 334
analog 214 network command protocols 332
floating point 215 network response protocols 330
long analog 216 outgoing message 284
Index I-913
logical station concepts 611 creating definitions 73
Logical Station Information panel 634 defining 70
messages and codes 721 errors associated with 77
NetDTL topology 598 logical station 853, 855, 886
offlink addressing 592 and activate deactive command 497
optimizing task performance 607 associating with logical port 77
overview 589 commands supported by Siemens H1 474
PLC-3 file type reference 701 creating definitions 77
PLC-5 file type reference 703 error tag 626
PLC-5/250 file type reference 710 errors associated with 77
program arguments for 604–607 identifying in read and write operations
reading and writing data 645 667
reading data from a device 646 identifying in unsolicited read operation
sample Logical Station table entries 631 678
sample read and write table entries 680 KTDTL and NetDTL concepts 611
see also Allen-Bradley table sample entries 85
SLC 500 file type reference 717 worksheet 71
unsolicited reads 670 Logical Station Control panel
writing data to a device 649 Allen-Bradley 196
General Electric 238
L General Purpose Interface 263
ladder logic code 567 Modicon Modbus 342
LAN adapter number 493 Modicon Modbus Plus 364
LANALOG 280 OMRON 390
Conversion function 325 Siemens CP525 418
Language 291 Siemens H1 446
least significant digit 569 Square D 500
LEN Telemecanique PLC 739
Process function 321 Texas Instruments 534
link identifier 621, 628 Logical Station Information panel
Local TSAP 443 Allen-Bradley 200
log file 606 General Electric 241
logical port 846, 849, 855, 873, 886 General Purpose Interface 267
logical ports KTDTL and NetDTL 634
associating with EDI definition 77–84 Modicon Modbus 344
associating with logical stations 77–85 Modicon Modbus Plus 366
Index I-915
network 822 naming considerations for EDI tags 39
purpose 815 NetDTL, see KTDTL and NetDTL
Rapid Application Protocol Driver network command protocols, GPI 332
components 823 network response protocols, GPI 330
description 823 NM Option 1 through NM Option E 532
two-task system 823 No response
Modbus Ethernet task Type of packet response 294
Configuration Manager 821 NO_RSP 300
modem interface control signals 56 non-printable characters 298
Modicon Modbus nonstandard unsolicited messages 674
Logical Station Control panel 342
Logical Station Information panel 344 O
messages 358 octal addressing format 671, 675
overview 341 OCTASC
Read/Write Control panel 346 Conversion function 324
Read/Write Information panel 353 Odd-numbered error codes
Modicon Modbus Plus List of for logical port 338
cable diagram 383 Odd-numbered error codes to build/transmit
Logical Station Control panel 364 List of 335–336
Logical Station Information panel 366 offlink addressing with KTDTL and NetDTL
messages 384 592
overview 363 OM
Read/Write Control panel 369 Process function 321
Read/Write Information panel 376 OMRON
Modifying previously defined field data types and PLC data areas 408
In list of functions 275 Logical Station Control panel 390
monitor mode, OMRON PLC 407 Logical Station Information panel 393
MSG instruction 670–671 messages 409
for SLC 5/03 and SLC 5/04 675 overview 389
MULT_RSP 300 PLC monitor mode 407
multiple devices, communicating with 22 Read/Write Control panel 396
Multiple logical station parameters Read/Write Information panel 403
Logical station commands 486 operating systems
setting parameters 53
N Windows NT Ethernet 53
NAK Retry Count 198 optimization guidelines 48
Index I-917
ONESCOMP 321 source and destination for 77
OR 321 testing 182
SL 321 read coil or input status register
SR 322 store in digital element 110
SUB 322 read complete trigger 95
SWAP 322 read disable trigger 95
TWOSCOMP 321 read holding or input register
XOR 322 store in analog element 102
processing differences in read and write oper- store in digital element 104
ations 166 store in floating-point or long analog ele-
program arguments ment 106
format for entering 604 store in message element 108
protocol driver communications 823 read memory register
block read and write 823 store in analog element 112, 114, 116, 151
datasets 823 read operations
encoded write 824 combination 97
exception write 824 configuring using the Tag Definition dia-
unsolicited receive 823 log 51
protocol modules 291 diagram 90
communicating with multiple 23 differences in processing 166
for communication with GPI 269 disabling 858
identifying types 70 indicating completion of 859
Pyramid Integrator indicating state of 860
alternate address in 671 overview 89
as server 590 priority of 94, 96, 857
data flow through 670 processing of 166
read priority 658
Q samples 118
quick reference 846, 873 trigger 175
triggered 90, 93
triggering 163, 858
R unsolicited 91, 96
RAW VALUE Read/Write Control panel
definition and size of in GPI 288 Allen-Bradley 202
read and write requests General Electric 244
device response time 77 Modicon Modbus 346
error detection 77
Index I-919
Station Address (Octal) 634–640 Read/Write Information panel 430
Sample Driver Error 571 switches 434
sample panel entries Siemens H1
control, combination write 159 Adapter display utility (H1MPDISP) 493
control, exception write 156 cable diagrams 487
control, unsolicited read 121 data types 489
definition, for COM ports 75 logical station commands 474
definition, for DigiBoard ports 76 Logical Station Control panel 446
information, triggered block write 154 Logical Station Information panel 450
information, triggered read 119 messages 494
information, unsolicited read 122 overview 441
sample point-to-point error 580 Read/Write Control panel 455
sample protocols for GPI 326 Read/Write Information panel 463
sample write requests 153 setting the Logical Station Variables com-
self-triggered table 859, 861 mand 482
self-triggered tables 174–175, 692–693 types of communication 441
serial communications single-packet response 293
port communications 27 SL
see also COM ports Process function 321
setting up 55 slaves and the TW7 data fields, configuring in
set bits in holding register using mask write Telemecanique PLC 761
141 SLC 500 file type reference for KTDTL and
setting operating system parameters 53 NetDTL 717
setting the Logical Station Variables com- SLC 500 file types 717
mand in Siemens H1 482 sleep period 605–607
setting up communications 845 SNG_RSP
shared memory PMD 300 318
filling up 44 SNGL_RSP 294, 300
overview 41 solicited reads/writes
Siemens CP525 pending requests 606
data types 435 specifying priority of block reads and block or
Logical Station Control panel 418 exception writes 171
Logical Station Information panel 421 Square D
messages 438 cable diagram 518
overview 417 Logical Station Control panel 500
Read/Write Control panel 423 Logical Station Information panel 504
Index I-921
unsolicited data configuration example block write request sample 153
778 cascaded tables 172
testing and troubleshooting 177 considerations 40
testing communication path 652, 654 defining 126
testing your application 181 frequency 656
Texas Instruments guidelines 47
computations for 5TI sequencer ladder overtriggering 172
logic code 567 read control panel entries 659–662
data types 564 read operations considerations 45
DIP switches 524 read operations overview 35
DIP switches for TIWAY NIM 528 read request 90, 93
Logical Station Control panel 534 read request sample 118
Logical Station Information panel 537 read, block write, or exception write for
loop indexing 554 KTDTL and NetDTL 659
messages 569 read, defined 646
overview 523 read, how it works 647, 681
Read/Write Control panel 540 read, when to use 654
Read/Write Information panel 547 self-triggered tables 174
setup 524 timed 172
TIWAY Ser.Unilink Network or TSAP
Point-to-Point exception code errors 572 and ASCII strings 444
Unlink Setup Information panel 531 and Device Control Module 441
Unlink Setup table 530 defining pair 443
thick net bus 487 definition 441
thin net bus 488 Local 443
TI PLC point-to-point errors 577 Needed to define 443
timed triggering 172 Remote 443
timed-interval read 646, 654 TSAP pair 443
tips and techniques 163 see also Siemens H1
KTDTL and NetDTL 652 TSPRINTF
transferring data 35, 89–119, 123–154 Conversion function 325
transferring FactoryLink data to device 865, TSX/PMX PLC data objects in Telemecanique
891–892 PLC 768
Transport Service Access Points TWOSCOMP
TSAPs 441 Process function 321
triggers
Index I-923
definition 302
in PROCESS 292
process function 322
XWAY networks, see Telemecanique PLC