Because of the variety of uses for the products described in this
publication, those responsible for the application and use of this control
equipment must satisfy themselves that all necessary steps have been taken
to assure that each application and use meets all performance and safety
requirements, including any applicable laws, regulations, codes and
standards.
The illustrations, charts, sample programs and layout examples shown in
this guide are intended solely for purposes of example. Since there are
many variables and requirements associated with any particular
installation, Allen-Bradley does not assume responsibility or liability
(to include intellectual property liability) for actual use based upon the
examples shown in this publication.
Allen-Bradley publication SGI-1.1, Safety Guidelines for the Application,Installation, and Maintenance of Solid State Control (available from your
local Allen-Bradley office), describes some important differences between
solid-state equipment and electromechanical devices that should be taken
into consideration when applying products such as those described in this
publication.
Reproduction of the contents of this copyrighted publication, in whole or
in part, without written permission of Allen-Bradley Company, Inc., is
prohibited.
Throughout this manual we use notes to make you aware of safety
considerations:
ATTENTION: Identifies information about practices or
circumstances that can lead to personal injury or death, property
damage or economic loss.
Attention statements help you to:
identify a hazard
avoid the hazard
recognize the consequences
Important: Identifies information that is critical for successful application
and understanding of the product.
Table of Contents
Using This Manual
What's In This Preface
Purpose of This Manual
Who Should Use This Manual
How To Use This Manual
What's The Smart Transmitter Toolkit 11
What You Get With The STT Subroutine 12
What You Need to Use The STT Subroutine 13
Why You Should Use The STT Subroutine 13
How a PLC5 Processor Communicates With a HART Field Device 14
How You Use The STT Subroutine 16. . . . . . . . . . . . . . . . . . . . . . .
This preface describes how to properly and efficiently use this manual.
Smart T
User
ransmitter T
Manual
oolkit
It tells you about:
the purpose of this manual
who should use this manual
how to use this manual
terms
abbreviations
conventions
related publications
publication 17706.5.21
Use this manual to install and use the Smart Transmitter Toolkit.
Throughout this manual we refer to this utility as the STT subroutine.
Who Should Use
This Manual
This manual is intended for use by:
persons who install Smart Transmitter Interface products, in connection
with Allen-Bradley PLC controllers or other intelligent controllers
system integrators who design and establish network systems that
involve plant floor machinery, programmable controllers, HART field
devices, Smart Transmitter Interface products, and host computers
We assume that you have:
a strong working knowledge of your plant’s process and equipment
a familiarity with personal computers, MS-DOS or PC-DOS,
ControlView, and 6200 programming software
i
Preface
Using This Manual
How To Use This Manual
Read about the
STT subroutine
chapter 1
Terms
Start by reading about the STT subroutine. Then, follow the instructions in
chapter 2 to install the STT subroutine. Finally, use chapter 3 and the
appendices to help you incorporate the STT subroutine into your ladder
logic.
See
HART Command
Data Table Layouts
appendix A
Install the STT
subroutine
chapter 2
Use the STT
subroutine
chapter 3
See
Codes
appendix B
Some of the tasks described in this manual assume that you have an
acquaintance with basic computer terminology.
Abbreviations
For a glossary of terms related to Smart Transmitter Interface products, see
the Smart Transmitter Interface Products (HART Protocol) User Manual,
publication 1770-6.5.19.
In this manual, we use these abbreviations.
This abbreviation:is for:
BTR
BTWBlocktransfer Write
HARTHighway Addressable Remote Transducer
JSRJump to Subroutine
STTSmart Transmitter Toolkit
Blocktransfer Read
ii
Preface
Using This Manual
Conventions
Related
Publications
We use these conventions in this manual:
In this manual, we show:Like this:
prompts and messages
literal text that you type
variable text that you type
keys that you press
screens that you see
that there is more information about the
topic in another manual
Press a function key
STT_SUB
filename
F1
Program
Directory
AllenBradley Publications
PublicationPublication Number
Smart Transmitter Interface Products (HART Protocol) User Manual
PLC5 Programming Software Programming Manual
17706.5.19
62006.4.7
STT Software License
For a list of publications for Allen-Bradley programmable controller
products, see the Automation Group Publication Index, publication SD499.
STT is not a licensed software product. It is provided to help you quickly
communicate with HART field devices. Please feel free to use this
software on any and all machines that you have.
Revision 5.1, January 4, 1991
Rosemount, Inc. Document No. D9000047, Revision A
iii
Chapter
1
Introducing The Smart Transmitter Toolkit
What's
What'
In This Chapter
s The Smart
Transmitter Toolkit
HART Universal Commands
The functions performed by these commands
are performed by all HART devices.
HART Commonpractice Commands
The functions performed by these commands
may not be possible for all HART devices.
HART Transmitterspecific Commands
Only one or at most a few HART devices
implement these functions. The functions
performed by these commands allow each
device type to implement their own
commands for special functions, calibration,
and special data handling.
Refer to the product manual for your HART
field device for a list of supported commands.
This chapter gives you an overview of the Smart Transmitter Toolkit
that you received with your Smart Transmitter Interface (cat. no. 1770-HT1).
The Smart Transmitter Toolkit (STT) is a PLC-5 ladder logic subroutine
utility that saves development time by simplifying the communication
among Allen-Bradley PLC-5 processors, Allen-Bradley Smart Transmitter
Interfaces, and HART-compliant field devices, such as a smart transmitter
or actuator.
✔ The STT subroutine provides a shell that lets you use a PLC processor
to communicate with a HART field device, without having detailed
knowledge of the HART protocol.
✔ The STT subroutine supports the HART commands that are most
commonly used with PLC processors. The STT subroutine does not
support vendor-specific HART commands, such as totalization.
✔ STT focuses on digital data that is associated with the HART protocol.
Use Allen-Bradley Analog I/O modules to acquire 4-20mA analog data.
✔ STT does not include faceplates or operator interface screens. However,
you can configure operator interface software, such as ControlView
software, to display/modify data that is received/sent to the STT
subroutine.
✔ STT supports:
HART Universal Commands 0, 1, and 3
HART Common Practice Commands 35, 38, 43, and 44
Both long- and short-frame addressing
Both point-to-point and multi-drop configurations
Allen-Bradley PLC-5 processors
Important: Do not view STT as a configuration tool. We assume you take
the appropriate steps to configure and calibrate the HART field device
using either Cornerstone software or a hand-held terminal.
1-1
Chapter 1
Introducing The Smart Transmitter Toolkit
What You Get W
Subroutine
6200 Programming Software
ith The STT
You
Provide
The STT subroutine transfers this digital data between the PLC-5
processor and HART field devices:
Read
- primary variable and unit
- primary variable current
- dynamic variables and unit
- status information
Write/modify primary variable range values
Write primary variable unit
Reset configuration change flag
Set primary variable to zero
STT Provides
Workstation
Data Highway Plus
PLCresident Control Functions
Your Application Program
STT Data Tables and
Subroutine Call
PLC5 ladder logic subroutine
that simplifies the communication
between a PLC5 processor and
a HART field device.
PLC5 Processor
Smart Transmitter Interface
1770HT1
RIO
1770HT16
HART
Field
Devices
4-20 mA Loop
1-2
Chapter 1
Introducing The Smart Transmitter Toolkit
What You Need to Use The
STT Subroutine
Why Y
ou Should Use The
STT Subroutine
You need these hardware and software components to integrate STT with
your new or existing PLC-5 processor:
Hardware
(1 or more) 1770-HT1 Smart Communications Controller(s)
(1 or more) 1770-HT8 or 177-HT16 Terminal Block(s)
(1 or more) HART-compliant field device(s)
Software
PLC-5 6200 Programming Software
(2 or more) PLC-5 data table files
(1 or more ) PLC-5 programming file(s)
PLC-5 integer data table file locations N90:0, N90:1, and N90:2
The STT subroutine greatly simplifies sending and receiving data to and
from HART field devices.
Without STT, the ladder developer must:
✔ Format each command from the HART specification using the Smart
Transmitter Interface protocol.
✔ Understand HART protocol internals, such as long frame addressing vs.
short frame addressing, and byte swapping for word alignment.
✔ Parse HART command responses for data.
✔ Convert IEEE-754 data to floating-point data.
✔ Synchronize BTWs with BTRs.
With STT, the ladder developer must only:
✔ Configure a data block.
✔ Make the appropriate call to the STT subroutine.
1-3
Chapter 1
Introducing The Smart Transmitter Toolkit
How
a PLC5 Processor
Communicates With a HART
Field Device
To help explain what the STT subroutine can do for you, let’s examine how
communication occurs between a PLC processor and a HART field device.
➊The PLC-5 processor sends a Smart Transmitter Interface packet to
the 1770-HT1 as block-transfer write (BTW) data.
➋The 1770-HT1 forwards the Smart Transmitter Interface packet as a
HART packet to the HART field device.
❸The HART field device receives the HART packet and then responds
back to the 1770-HT1 with a HART packet that contains the
appropriate HART digital data.
➍The 1770-HT1 routes the response back to the PLC-5 processor in a
Smart Transmitter Interface packet as block-transfer read (BTR) data.
PLC5
Processor
BTW Data
➊
Smart T
ransmitter
Interface packet
BTR Data
➍
RIO
Smart Transmitter Interface
1770HT1
1770HT16
HART Poll
➋
HART
packet
HART Response
❸
420
HART
Field
Device
mA Loop
90065
1-4
The PLC-5 processor sends and receives data from the 1770-HT1 as Smart
Transmitter Interface Packets. The HART field device sends and receives
data from the 1770-HT1 as HART packets. The 1770-HT1 converts the
packets that it receives to the required format before transmitting the
packets to their destination.
This diagram illustrates the relationship between the two packets.
Smart Transmitter
Interface packet
Smart Transmitter Interface Command
Channel Number
Control
Parameter
Chapter 1
Introducing The Smart Transmitter Toolkit
HART
packet
Preamble
Delimiter
Address
HART Command
Byte Count
Data
Check Byte
90066
Using a few pieces of data, the STT subroutine creates a Smart Transmitter
Interface packet and sends it to the 1770-HT1. The STT subroutine then
takes the response from the 1770-HT1 and decodes the Smart Transmitter
Interface packet to provide you with useful data.
For more information about communications with Smart Transmitter
Interface products, see the Smart Transmitter Interface Products (HARTProtocol) User Manual, publication 1770-6.5.19.
1-5
Chapter 1
Introducing The Smart Transmitter Toolkit
How You Use The STT
Subroutine
Read chapter 2, then
Chapter 2
install the software.
Installing The Smart
Transmitter Toolkit
Chapter 3
Using The Smart
Transmitter Toolkit
We developed the STT Subroutine so that you can easily use a PLC-5
processor to communicate with a HART field device. Here’s how easy it is
to use STT:
1.Install the STT subroutine into your workstation and PLC-5
processor.
STT
Subroutine
2.Customize your PLC-5 ladder logic to use the STT subroutine.
a. Allocate data blocks in your PLC5 processor
for each HART field device in your system.
b. Enter a JSR instruction in your ladder logic
program for each 1770HT1 in your system.
What to Do Next
When you’ve completed these steps, you’re ready to use the STT
subroutine.
Go to chapter 2 to begin installing the Smart Transmitter Toolkit.
1-6
Chapter
2
Installing The Smart Transmitter Toolkit
What's
In This Chapter
This chapter provides instructions for installing the Smart Transmitter
Toolkit (STT).
Important: Use 6200 programming software to install the STT subroutine
into your PLC-5 processor. Before you begin, make sure your current
program is loaded.
To install the STT subroutine, you will:
1.Copy the STT subroutine file to the hard drive.
2.Create and name a new program file in your PLC-5 processor.
3.Paste the STT subroutine file into the new program file.
4.Save your work (optional).
5.Change the data table defaults (optional)
Important: The STT subroutine uses three fixed word addresses:
N90:0 through N90:2. When you paste the STT subroutine, these
three addresses are created. If these addresses are already in use and
cannot be freed up for the STT Subroutine, you need to change the
data table defaults. If you need to make these changes, do step 5.
The rest of this chapter contains the instructions for completing these steps.
Before You Begin
You need this diskette to install the STT subroutine:
Allen-Bradley
Software
Smart T
ransmitter T
Disk 1 of 1
Since you install the STT subroutine using 6200 programming software,
you may want to obtain a copy of the PLC-5 Programming SoftwareProgramming Manual, publication 6200-6.4.7.
oolkit
This diskette contains these paste files:
• STT100.CR5 - the STT subroutine
• STT100E1.CR5 - programming example 1
• STT100E2.CR5 - programming example 2
• STT100E3.CR5 - programming example 3
See chapter 3 for an explanation of the programming
examples.
2-1
Chapter 2
Installing The Smart Transmitter Toolkit
1. Copy STT Subroutine
File to the Hard Drive
A.Insert the STT disk into a floppy drive.
B.Start at the 6200 Main Menu and press these keys:
To/From
Floppy
F9F2F7
From Floppy
6200
Main Menu
File
Utils
F7
You see:
Processor
Memory: Cut Rungs
C.Use the cursor keys to highlight the STT100 file.
D.To select the STT100 file as the source of the copy,
press
F3 Select
E.To begin the copy, press
Source
.
F1 Begin
Oper
.
The operation is completed.
F.To return to the 6200 Main Menu, press
Esc Esc .
2-2
Chapter 2
Installing The Smart Transmitter Toolkit
2. Create
Program File
and Name a New
A.Start at the 6200 Main Menu and press these keys:
6200
Main Menu
Online ProgF3Offline Prog
F1
or
Proc Func
F1
You see:
B.To create a program file, press F6 Create
file number.
C.To name the file, press
F10
Change Fl Name
name. We recommend that you use the filename
D.To go to the Program Directory, press
Esc .
Lad Fl
and then enter a
and then enter a file
STT_SUB.
2-3
Chapter 2
Installing The Smart Transmitter Toolkit
3. Paste
The STT
Subroutine File
A.Start at the Program Directory and press these keys:
Monitor
Program
Directory
File
F8
Edit
F10
Advanced
F8
Edit
You see:
Paste From Disk
F8
B.Use the cursor keys to highlight the STT100 file.
C.To begin the paste, press
F1 Begin
Paste
.
The paste operation takes about 3 minutes. Since the STT subroutine
uses indirect addressing, you may hear beeps during the paste
operation. This is normal.
D.To return to the Program Directory, press Esc Esc .
2-4
Chapter 2
Installing The Smart Transmitter Toolkit
4. Save Your W
ork
(optional)
A.Start at the Program Directory and press these keys:
Save
Program
F2
Program
Directory
Save
Restore
F2
You see:
B.If you want to change the name of the file, enter a new name. If you
don’t enter a new name, the file is saved using the name that you see
on the screen.
C.To save the file, press
F1 Begin
Oper
.
2-5
Chapter 2
Installing The Smart Transmitter Toolkit
5. Change The STT Default
Data File
(optional)
You can move the STT subroutine data table file from its default location
of N90.
Important: Moving this file increases the chance of making errors while
setting up your system and complicates the technical support of the STT
subroutine because the file is not in its default location. We recommend
that you only attempt this procedure if you are experienced in ladder-logic
programming and using 6200 programming software.
The STT subroutine uses indirect addresses in block-transfer instructions.
You cannot use 6200 programming software to edit/cut/copy/paste
block-transfer instructions that use indirect addressing or to search for file
references that use indirect addressing. To move the file, follow these
steps:
A.Use the 6200 file utilities to export the processor memory file and
comments/symbols. Make sure that you export all the different types
of comments (address, rung, instruction, etc.).
The exported program file has a .PC5 extension.
The exported comments/symbols file has a .TXT extension.
For more information about using 6200 file utilities, see PLC-5Programming Software Programming Manual, publication 6200-6.4.7.
What'
s Next
B.Use an ASCII text editor to make the changes as described below.
Moving
a.Edit the .PC5 file
b.Search for all occurrences of integer file number N90 and change
c.Save the changes and close the file.
d.Edit the .TXT file.
e.Search for all occurrences of integer file number N90 and change
f.Save the changes and close the file.
C.Import the modified processor memory file and comments/symbols
file. Use a different name for the imported files to distinguish them
from the original files.
You are finished installing the STT subroutine. Proceed to the next chapter
for instructions on using the STT subroutine in your ladder logic.
the STT Data Table File From N90
to the new integer file number.
to the new integer file number.
2-6
Chapter
3
Using The Smart Transmitter Toolkit
What's
1.
In This Chapter
Create Data T
Integer word = 16 bits
Floatingpoint word = 32bits
able Files
Follow the instructions in this chapter to incorporate the STT subroutine
into your ladder code and use the HART commands.
1.Create data table files.
2.Provide the STT subroutine inputs
3.Use the STT subroutine status word.
4.Call the STT subroutine.
5.Interpret the STT subroutine outputs.
At the end of this chapter, you’ll find some programming examples.
In your PLC-5 processor, create one integer and one floating-point file for
each HART field device.
Each integer file must be 150 integer words minimum (0 through 149)
Each floating-point file must be 20 floating-point words minimum
(0 through 19)
In addition, the floating point file must be the data file that immediately
follows the integer data file. For example, if the integer file is N10, the
floating point file must be F11.
Important: The STT utility uses integer data file N90 for indirect
addressing. Do not use this data file for a HART field device data
table file.
Since the STT subroutine uses N90:0 and N90:1 for indirect addressing,
you must place valid file numbers in N90:0 and N90:1. For example, if
you created N10 and F11, you need to place a 10 in data table location
N90:0 and an 11 in data table location N90:1.
Following is an explanation of how the data tables are used by the STT
subroutine.
3-1
Chapter 3
Using The Smart Tranmsitter Toolkit
Data Table Report PLC–5/25 Addr 31 Data Table File N10:0
Floatingpoint words 10 through 19 = STT Subroutine Output Area
3-2
Floatingpoint words 0 through 9 = User Input Area
Chapter 3
Using The Smart Transmitter Toolkit
2. Provide
The STT
Subroutine Inputs
Standard
IntegerWord 0I/O Rack Number of
Inputs
1770HT1
Word 1I/O Group Number of
1770HT1
Word 2Channel Number of HART
field device
Word 3Polling Address of HART
field device
Word 4Smart Transmitter Interface
Command Number 16
decimal (10 Hex)
Word 5HART CommandThis integer word contains the number of the HART command that the STT subroutine
All data that is used by the STT subroutine is obtained from the integer and
floating point data files that you create for each HART field device.
Before you make a call in your ladder logic to the STT, you must put the
required data into these data files.
There are two types of input data:
Command-specific inputs are specific for each HART command.
See appendix A.
Standard inputs are required for every HART command. This table
explains each of the six standard inputs.
This integer word contains the I/O rack number of the 1770-HT1 that is connected to the HART
field device. Valid values are 1 through 7.
This integer word contains the I/O group number of the 1770-HT1 that is connected to the
HART field device. Valid values are 0, 2, 4, and 6.
This integer word contains the channel on the 1770-HT8 or the 1770-HT16 that is wired to the
HART field device. Valid values are 1 through 32.
This integer word contains the polling address of the HART field device. Use a Rosemount 268
Handheld terminal or Cornerstone software to configure this address.
If you are wired:
• pointtopoint, the polling address is 0 (zero).
• multidrop, the polling address is 1 through 15.
Note: Most HART field devices come from the factory with a default polling address of zero.
This integer word contains the number of the Smart Transmitter Interface command. Currently,
the only supported command is 16. This command indicates that you want to send a HART
command to a HART field device. Always place a 16 in word 4 of the integer data file.
generates and processes. Valid values are 0, 1, 3, 35, 38, 43, and 44.
Every HART command, except 0, requires the HART address returned by HART command 0.
Example: Inputs for HART Command 0
Data Table Report PLC–5/25 Addr 31 Data Table File N10:0
• N10:0 indicates that the 1770-HT1 is located at I/O rack 4.
• N10:1 indicates that the 1770-HT1 is located at I/O group 6.
• N10:2 indicates that the HART field device is wired to channel 3.
• N10:3 indicates that the HART field device has a polling address of 0.
• N10:4 indicates that the Smart Transmitter Interface command is 16 (for STT release 1.00, it is always 16).
• N10:5 indicates that this example is using HART command 0.
3-3
Chapter 3
Using The Smart Tranmsitter Toolkit
3. Use The STT Subroutine
Status W
ord
STT
Subroutine Status W
Bit 0STT Enter/Exit BitUse bit 0 to debug your program. When called, the STT subroutine sets bit 0 to 1. When
Bit 1
Bit 2
Bit 3STT Trigger BitBit 3 is the STT subroutine trigger bit. Use bit 3 to tell the STT subroutine to process the
Bit 4STT Error BitBit 4 is the STT subroutine error bit. This bit is set if either the BTW or the BTR has
Bits 57ReservedReserved for future use.
Bit 8STT BTW Retry Bit Bit 8 indicates that the BTW has returned an error and is being retried by the STT
Bit 9STT BTR Retry BitBit 9 indicates that the BTR has returned an error and is being retried by the STT
Bits 1015ReservedReserved for future use.
STT Enable Bit
STT Done Bit
The STT subroutine status word handshakes with your PLC ladder logic.
The STT subroutine status word:
tells you when the STT subroutine is entered and exited
tells you when the STT subroutine is enabled and done
lets you trigger the STT subroutine
tells you when the STT subroutine errors
The STT status word is integer word 30 of the integer file that is passed in
with your JSR instruction. This table shows the bits that are used in the
STT subroutine status word.
ord 30
the STT subroutine exits, the subroutine sets bit 0 to 0. This lets you know when the STT
subroutine is entered and exited.
Bit 1 indicates that the STT subroutine is in the middle of processing a HART command.
Bit 2 indicates that the STT subroutine is done processing a command.
When you make an unconditional call to the STT subroutine, if the subroutine is not
already enabled, it sets bit 1 to 1 and bit 2 to 0. When the STT subroutine is done
processing a Hart command (successful or not), it sets bit 2 to 1 and bit 1 to 0. When bit
2 is set to 1, you can process the output data that is returned by the STT subroutine.
requested command. Even though you call the STT subroutine with an unconditional
JSR, it does not process the HART command unless bit 3 is set to 1. When the STT
subroutine sees bit 3 set to 1, it processes the request. When the request is first
detected, the STT subroutine is enabled and it sets bit 3 to 0.
failed. Any data, except words 30 and 31, in the output area is invalid if this bit is set.
subroutine.
subroutine.
3-4
Example
In this example, the STT trigger bit is set to 1 if the STT enable bit is set to 0.
N10:60
01
N10:60
L
03
Chapter 3
Using The Smart Transmitter Toolkit
4. Call The STT Subroutine
Insert a JSR on an unconditional rung to call the STT subroutine.
The JSR instruction includes one program file number and one input
parameter. There are no return parameters.
The program file number is the program file number where you installed
the STT subroutine. For example, if you installed the STT subroutine
into program file number 5, the JSR must call program file number 5.
The input parameter is the integer file number for the current HART
field device. For example, if you created N10 and F11 for your HART
field device, the input parameter would be 10.
When the STT routine is called by your ladder logic, it generates the
specified HART command from the data that you provided in the integer
and floating-point data files.
After generating a properly formatted HART command, the STT
subroutine executes a BTW followed by a BTR to execute the command
just generated. It then reformats the returned data and places the outputs in
the locations specific to that HART command. See appendix A for more
detail on the command-specific outputs.
Because of the nature of enabling and finishing BTWs and BTRs, it takes
three calls minimum to the STT subroutine to obtain the outputs from the
HART command. This is a description of the steps that occur in each of
the three passes through the STT subroutine.
1st Pass
• sets the enter/exit bit to 1
• sets the trigger bit to 0
• sets the enable bit to 1
• generates the HART command
specified in integer word 5
• initiates a BTW
• sets the enter/exit bit to 0 and returns
Example
In this example, the JSR calls the STT subroutine unconditionally. The
STT subroutine looks for input data in files N10 and F11. However, since
this example is using HART command 0, there is no input data in the
floating-point file.
2nd Pass
• sets the enter/exit bit to 1
• finishes the BTW
• initiates a BTR
• sets the enter/exit bit to 0 and returns
JSR
JUMP TO SUBROUTINE
Prog file number5
Input par10
Return par
3rd Pass
• sets the enter/exit bit to 1
• finishes the BTR
• produces outputs
• sets the done or error bit to 1
• sets the enable bit to 0
• sets the enter/exit bit to 0 and returns
3-5
Chapter 3
Using The Smart Tranmsitter Toolkit
5.Interpret
The STT
Subroutine Outputs
Each HART command returns these outputs:
Command-specific outputs returned for a specific HART command.
See appendix A for more detail on the command specific outputs.
Standard Outputs that are returned for every HART command.
This table explains each of the seven standard outputs.
Standard
IntegerWord 30STT Subroutine Status Word
➀
Outputs
(see page 34)
Word 31STT Subroutine Error Code➀This word contains any error code returned by the STT subroutine.
Word 32Smart Transmitter Interface
Status Word
Word 33Smart Transmitter Interface
Error Code
Word 34HART
ProtocolCommunication Error
Code
Word 35HART Command Response
Summary Error Code
Word 36HART Field Device Error
Code
See appendix B for a list of error codes.
➀
➀
➀
➀
All handshaking with the STT subroutine is done with the STT status word.
On powerup, the Smart Transmitter Interface sets bit 7 to a 1. All other bits are set to 0.
Therefore, the value for word 32 is 128 decimal.
The STT utility does not provide any way to reset bit 7 to a zero. Therefore, bit 7 is
always set to 1 in word 32.
This word contains any error code returned by the 1770HT1.
This word contains information that pertains to the reception of a message by a device.
An error in this word indicates that the HART transmitter detected a communications
error and the message was not accepted.
The response data is not returned when errors are reported.
This word contains information relative to the execution of a HART command. This error
code is command dependent.
This word contains information that pertains to the operating status of the HART device
as a whole and is not associated with the completion of any HART command.
3-6
Example: Outputs for HART Command 0
Data Table Report PLC–5/25 Addr 31 Data Table File N10:0
Important: We used this example because every ladder program must
have a JSR instruction and all HART communications must start with
HART command 0. Every HART command (except HART command 0)
requires the HART address.
These seven integer words contain the status of
the STT subroutine and the communications
with the HART field device.
Chapter 3
Using The Smart Transmitter Toolkit
Programming
Example 1:
Single HART Device W
Single 1770HT1
ith
In this example, the primary variable is being read continuously from a
single HART field device.
PLC5
Processor
Smart Transmitter Interface
1770HT1
RIO
HART
Field
Device
1770HT16
4-20 mA Loop
Because we’re dealing with one device we can execute the JSR with a
fixed device data file number. In the course of operation if the device does
not respond, we reissue HART command 0 to try and get a new HART
address for the device.
Important: This example assumes that data table files N10 and F11 exist,
and N10 is populated with the standard inputs for HART command 0 prior
to the execution of this logic. The primary variable value is placed in
F11:10 and the primary variable unit code is placed in N10:40.
3-7
Chapter 3
Using The Smart Tranmsitter Toolkit
Rung 2:0
STT 1.00 Programming Example 1.
This example reads the primary variable from 1 HART field device wired to 1
1770-HT1.
When the STT subroutine is not enabled, set the STT subroutine trigger bit.
| STT enable STT trigger |
| N10:30 N10:30 |
+––––]/[–––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––(L)–––––+
| 1 3 |
Rung 2:1
Call the STT subroutine unconditionally.
| STT |
| Subroutine |
| +JSR–––––––––––––––+ |
+–––––––––––––––––––––––––––––––––––––––––––––––––––––––––+JUMP TO SUBROUTINE+–+
| |Prog file number 5| |
| |Input par 10| |
| |Return par | |
| +––––––––––––––––––+ |
Example 1 (continued)
Rung 2:2
Only process when the STT subroutine is done. If the Hart command is 0, copy
the Hart address to the input area and request Hart command 1. If the device
does not respond (error 33), try getting a new Hart address for the device by
requesting Hart command 0.
| Hart Hart |
| STT Done Command # Address |
| N10:30 +EQU–––––––––––––––+ +COP–––––––––––––––+ |
+––––] [––––––––––––––––––––––––––++EQUAL +++COPY FILE +++–+
| 2 ||Source A N10:5|||Source #N10:40||| |
| || 1|||Dest #N10:6||| |
| ||Source B 0|||Length 3||| |
| || ||+––––––––––––––––––+|| |
| |+––––––––––––––––––+| Hart || |
| | | Command # || |
| | |+MOV–––––––––––––––+|| |
| | ++MOVE ++| |
| | |Source 1| | |
| | | | | |
| | |Dest N10:5| | |
| | | 1| | |
| | +––––––––––––––––––+ | |
| | Device Not Hart | |
| | Responding Command # | |
| |+EQU–––––––––––––––+ +MOV–––––––––––––––+| |
| ++EQUAL +––+MOVE ++ |
| |Source A N10:33| |Source 0| |
| | 0| | | |
| |Source B 33| |Dest N10:5| |
| | | | 1| |
| +––––––––––––––––––+ +––––––––––––––––––+ |
3-8
Rung 2:3
| |
+––––––––––––––––––––––––––––––––[END OF FILE]–––––––––––––––––––––––––––––––––+
| |
Chapter 3
Using The Smart Transmitter Toolkit
Programming
Example 2:
Multiple HART Devices W
Single 1770HT1
ith
In this example, the primary variable is read continuously from two HART
field devices that are associated with one 1770–HT1 Communications
Controller. You will notice that the example reads the primary variable
from device 1 and then from device 2. If you want to talk to two HART
field devices at the same time, you must use two 1770-HT1s. Example 3
demonstrates reading the primary variable from two HART field devices
using two 1770-HT1s.
PLC5
Processor
Smart Transmitter Interface
1770HT1
RIO
HART
Field
Device
HART
Field
Device
1770HT16
4-20 mA Loop
4-20 mA Loop
In this example, we used separate data areas for each device. This forced
us to load the device data file number into the JSR input variable prior to
making the call to the STT subroutine.
In the course of operation, if either HART field device does not respond,
we reissue command 0 to try and get a new HART address for the field
device. This example assumes that each device data area is setup with the
standard inputs for command 0, prior to the execution of this logic.
Device 1 uses N10 and F11
Device 2 uses N12 and F13
N14 is the JSR variable
F15 contains both primary variable values
3-9
Chapter 3
Using The Smart Tranmsitter Toolkit
Rung 2:0
STT 1.00 Programming Example 2
This example reads the primary variable from 2 HART field devices wired to 1
1770-HT1.
If neither device is current, make device 1 the current device.
| Doing |Doing Doing |
| Device 1 |Device 2 Device 1 |
| B3 B3 B3 |
+––––]/[––––––––]/[––––––––––––––––––––––––––––––––––––––––––––––––––––(L)–––––+
| 1 2 1 |
Rung 2:6
| |
+––––––––––––––––––––––––––––––––[END OF FILE]–––––––––––––––––––––––––––––––––+
| |
Chapter 3
Using The Smart Transmitter Toolkit
Programming
Example 3:
Multiple HART Devices W
Multiple 1770HT1s
ith
In this example, the primary variable is read continuously from two HART
field devices that are wired to separate 1770-HT1s. Communication with
multiple 1770-HT1s can occur asynchronously when calling the STT
subroutine.
PLC5
Processor
Smart Transmitter Interface
1770HT1
RIO
HART
Field
Device
1770HT16
4-20 mA Loop
Smart Transmitter Interface
1770HT1
RIO
HART
Field
Device
1770HT16
4-20 mA Loop
In the course of operation, if the field device does not respond, we reissue
HART command 0 to get the HART address. This example assumes that
each device data area is setup with the standard inputs for HART command
0 prior to the execution of this logic.
Device 1 uses N10 and F11
Device 2 uses N12 and F13
F15 contains both primary variable values
3-13
Chapter 3
Using The Smart Tranmsitter Toolkit
Rung 2:0
STT 1.00 Programming Example 3.
This example reads the primary variable from 2 HART field devices wired to 2
1770-HT1s.
When the STT subroutine is not enabled, set the STT subroutine trigger bit.
| Device 1 |
| Device 1 STT |
| STT enable trigger |
| N10:30 N10:30 |
+––––]/[–––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––(L)–––––+
| 1 3 |
Rung 2:1
Call the STT subroutine unconditionally.
| STT |
| Subroutine |
| +JSR–––––––––––––––+ |
+–––––––––––––––––––––––––––––––––––––––––––––––––––––––––+JUMP TO SUBROUTINE+–+
| |Prog file number 5| |
| |Input par 10| |
| |Return par | |
| +––––––––––––––––––+ |
Example 3 (continued)
3-14
Chapter 3
Using The Smart Transmitter Toolkit
Example 3 (continued)
Rung 2:2
Only process when the STT subroutine is done. If the Hart command is 1, copy
the primary variable to file F15. If the Hart command is 0, copy the Hart
address to the input area and request Hart command 1. If device 1 does not
respond (error 33), try getting a new Hart address for device 1 by requesting
Hart command 0.
| Device 1 Device 1 |
| Device 1 Hart Process |
| STT Done Command # Variable |
| N10:30 +EQU–––––––––––––––+ +MOV–––––––––––––––+ |
+––––] [––––––––––––––––––––––––––++EQUAL +––+MOVE ++–+
| 2 ||Source A N10:5| |Source F11:10|| |
| || 0| | 0.000000|| |
| ||Source B 1| |Dest F15:1|| |
| || | | 0.000000|| |
| |+––––––––––––––––––+ +––––––––––––––––––+| |
| | Device 1 Device 1 | |
| | Hart Hart | |
| | Command # Address | |
| |+EQU–––––––––––––––+ +COP–––––––––––––––+ | |
| ++EQUAL +++COPY FILE +++ |
| ||Source A N10:5|||Source #N10:40||| |
| || 0|||Dest #N10:6||| |
| ||Source B 0|||Length 3||| |
| || ||+––––––––––––––––––+|| |
| |+––––––––––––––––––+| Device 1 || |
| | | Hart || |
| | | Command # || |
| | |+MOV–––––––––––––––+|| |
| | ++MOVE ++| |
| | |Source 1| | |
| | | | | |
| | |Dest N10:5| | |
| | | 0| | |
| | +––––––––––––––––––+ | |
| | Device 1 Device 1 | |
| | Not Hart | |
| | Responding Command # | |
| |+EQU–––––––––––––––+ +MOV–––––––––––––––+| |
| ++EQUAL +––+MOVE ++ |
| |Source A N10:33| |Source 0| |
| | 33| | | |
| |Source B 33| |Dest N10:5| |
| | | | 0| |
| +––––––––––––––––––+ +––––––––––––––––––+ |
Rung 2:3
This rung is identical to 2:0, except it uses device 2.
| Device 2 |
| Device 2 STT |
| STT enable trigger |
| N12:30 N12:30 |
+––––]/[–––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––(L)–––––+
| 1 3 |
3-15
Chapter 3
Using The Smart Tranmsitter Toolkit
Rung 2:4
Call the STT subroutine unconditionally.
| STT |
| Subroutine |
| +JSR–––––––––––––––+ |
+–––––––––––––––––––––––––––––––––––––––––––––––––––––––––+JUMP TO SUBROUTINE+–+
| |Prog file number 5| |
| |Input par 12| |
| |Return par | |
| +––––––––––––––––––+ |
Important: All data table layout examples in this appendix are shown
assuming that these conditions exist:
The 1770-HT1 is located at I/O rack 4 and I/O group 6.
The HART field device is wired:
-to channel 3 of a 1770-HT8 or 1770-HT16
-point-to-point (polling address is 0)
0A2
The HART field device uses a long-frame address.
A-1
Appendix A
HART Command Data Table Layouts
HART Command 0
Read HART Address
Use this command to read the HART address from a HART field device.
Important: To use STT, you must include this command at least once in
your program prior to any calls with other HART commands. This
command returns the HART address of the HART field device. The
HART address is used in all other HART commands.
Standard
IntegerWord 0I/O Rack Number of 1770HT1
Data Table Report PLC-5/25 Addr 31 Data Table File N10:0
This is the HART address that is needed
as an input to the other HART commands.
These seven integer words are the standard outputs
that contain the status of the communications with
the HART field device (see page 36).
A-3
Appendix A
HART Command Data Table Layouts
HART Command 1
Read Primary Variable
Use this command to read the primary variable and unit code from a
HART field device. The primary variable is returned in floating-point
format and the unit code is returned as an integer.
Standard
IntegerWord 0I/O Rack Number of 1770HT1
Commandspecific
IntegerWords 6 8HART Address of HART field device
Data Table Report PLC-5/25 Addr 31 Data Table File N10:0
This floatingpoint word is a commandspecific
output that contains the primary variable current.
These seven integer words are the standard outputs
that contain the status of the communications with
the HART field device. (see page 36).
These four floatingpoint words are commandspecific outputs
that contain the variables from the HART field device.
A-7
Appendix A
HART Command Data Table Layouts
HART Command 35
Write Primary V
Values
ariable Range
Use this command to write new upper and lower primary variable range
values to the data memory of the HART field device. This command then
outputs the actual upper and lower primary range values from the data
memory of the HART field device.
If the write operation was successful, you should see the same values
that you entered.
If the write operation was unsuccessful, you will see the original values
from the data memory of the field device. These values may or may not
be the same as the values that you entered. Check the status and error
codes.
Standard
IntegerWord 0I/O Rack Number of 1770HT1g
Commandspecific
IntegerWords 6 8HART Address from HART Command 0g
FloatingpointWord 0Primary Variable Upper Range Valuegp
Inputs
Word 1I/O Group Number of 1770HT1
Word 2Channel Number of HART field device
Word 3Polling Address of HART field device
Word 4Smart Transmitter Interface Command Number 16 (decimal)
Word 5HART Command Number 35
Inputs
Word 10Primary Variable Range Values Unit Code
Word 1Primary Variable Lower Range Value
Data Table Report PLC-5/25 Addr 31 Data Table File N10:0
These seven integer words are the standard outputs
that contain the status of the communications with
the HART field device. (see page 36).
These two floatingpoint words are commandspecific
outputs that should contain the new upper and lower
range values that you entered for the primary variable.
A-9
Appendix A
HART Command Data Table Layouts
HART Command 38
Reset Configuration Change Flag
Data Table Report PLC-5/25 Addr 31 Data Table File N10:0
These seven integer words are the standard outputs
that contain the status of the communications with
the HART field device (see page 36).
A-11
Appendix A
HART Command Data Table Layouts
HART Command 43
Set Primary V
ariable Zero
Use this command to trim the primary variable so that it reads zero with
the existing process applied to the HART field device. The resulting offset
must be within the limits defined by each device.
Standard
IntegerWord 0I/O Rack Number of 1770HT1
Commandspecific
IntegerWords 6 8HART Address from HART Command 0
Data Table Report PLC-5/25 Addr 31 Data Table File N10:0
These seven integer words are the standard outputs
that contain the status of the communications with
the HART field device (see page 36).
A-13
Appendix A
HART Command Data Table Layouts
HART Command 44
Write Primary V
ariable Units
Use this command to select the units in which the primary variable and the
primary variable range will be returned by the HART field device. This
command also selects the units for sensor limits and minimum span.
Standard
IntegerWord 0I/O Rack Number of 1770HT1
Commandspecific
IntegerWords 6 8HART Address from HART Command 0
Data Table Report PLC-5/25 Addr 31 Data Table File N10:0
This integer word is the commandspecific
output that should contain the unit code that
you entered for the primary variable.
These seven integer words are the standard outputs
that contain the status of the communications with the
HART field device (see page 36).
A-15
Codes
Appendix
B
What's In This Appendix
STT Subroutine Error Codes
Integer Word 31
CodeDefinition
1Blocktransfer write (BTW) error
2Blocktransfer read (BTR) error
This appendix contains the codes that you need to use the STT subroutine.
For
this list:
STT Subroutine Error Codes
Smart Transmitter Interface Error Codes33B2
HART ProtocolCommunication Error Codes34B3
HART Command Response Summary Error Codes35B3
HART Field Device Error Codes36B4
Unit Codes10, 40B5
Integer Word See page:
31B1
B-1
Appendix B
Codes
Smart Transmitter Interface Error Codes
Integer Word 33
General Errors
Code (decimal)
000No ErrorThe Smart Transmitter Interface processed the last received command, and
101Downloading FirmwareThe Smart Transmitter Interface firmware is being upgraded over the
202No Corresponding BTWThe Smart Transmitter Interface received a BTR but does not know what data
303Command Still in
Command Errors
Code (decimal)
1610Invalid CommandThe Smart Transmitter Interface command is invalid and cannot be
1711Invalid Channel NumberThe Smart Transmitter Interface channel number is invalid. The command
1812Invalid HART MessageThe HART packet encapsulated within a Smart Transmitter Interface packet is
1913Invalid Channel ListThe channel list provided with the Enable Burst Monitor Mode command
2014Invalid ParameterAn invalid parameter is provided with the Smart Transmitter Interface
2115Invalid ControlAn invalid control byte is included with the Smart transmitter Interface
2216Invalid DF1 Packet Length The length of the DF1 packet is not consistent with the length specification in
Code (hex)DefinitionDescription
Progress
Code (hex)DefinitionDescription
no errors were detected.
RS232C port. The last received command cannot be processed.
is being requested. All BTRs must be preceded by a BTW indicating what
response to return in a BTR.
The Smart Transmitter Interface is still obtaining the HART Response from a
field device and cannot respond with the requested data. The programmable
controller should reissue the BTR request to obtain the response.
processed.
cannot be processed.
invalid and cannot be forwarded to a field device.
contains an invalid entry or is incorrectly terminated. The command cannot be
processed.
command and so it cannot be processed.
command. The command cannot be processed.
that packet. The command cannot be processed.
Device Errors
Code (decimal)
3220Burst Mode Device Not
3321No Response Received
3422No Valid Burst DataThe Smart Transmitter Interface does not have data in its Burst Monitor Table
B-2
Code (hex)DefinitionDescription
The Smart Transmitter Interface is not receiving burst data from a field device
Communicating
From Device
in burst mode. Either Burst mode has been turned off in the field device or it is
too busy to send burst table data. The error code is cleared once the Smart
Transmitter Interface receives new burst data from the device.
The Smart Transmitter Interface has not received a response from a field
device after exhausting all retry attempts.
for the requested channel. Either the Smart Transmitter Interface was not
commanded to monitor the channel for burst data, or the field device is not in
burst mode.
Appendix B
Codes
HART Protocol Communication Error Codes
Integer Word 34
BitError CodeDescription
7
6Vertical Parity ErrorThe parity of one or more of the bytes received by the HART field device is incorrect.
5Overrun ErrorAt least one byte of data in the receive buffer of the HART field device was overwritten before it
4Framing ErrorThe stop bit of one or more bytes received by the HART field device was not detected.
3Longitudinal Parity ErrorThe longitudinal parity calculated by the HART field device does not match the longitudinal parity
2ReservedSet to 0.
1Buffer OverflowThe packet is too long for the receive buffer of the HART field device.
0UndefinedNot defined at this time.
Communications ErrorIf set, the field device has detected a communications error. Bits 0 6 indicate the type of error.
was read.
byte at the end of the packet.
HART Command Response Summary Error Codes
CodeHART CommandCode Definition
0
2
5
6
7
8
935Lower Range Value too HighThe Lower Range Value was above the Upper Sensor Limit.
1035Applied Process too LowThe process applied to the field device was too low.
11
12
13
14
16
32
64
➀
This
code applies to all HAR
All
All
All
➀
➀
➀
No commandspecific errorsNo errors were found in verifying the parameters for this command.
Invalid SelectionThe code or index was not allowed in this command or for this field device.
Too Few Data Bytes Received The message syntax was proper but the number of bytes contained in the message
was less than required to execute the command.
All
➀
TransmitterSpecific
Command Error
An error occurred in a HART command for which a CommandSpecific Response
Code is not defined. Further information on this response code is available in each
TransmitterSpecific document.
All
All
➀
➀
In Write Protect ModeThe field device is Write Protected and cannot accept this write command.
Warning: Update FailureThe realtime data returned from the field device has not changed since the last time
it was read.
43Applied Process too HighThe process applied to the field device was too high.
43Lower Range Value too LowThe Lower Range Value was below the Lower Sensor Limit.
All
All
All
➀
➀
➀
Upper Range Value too HighThe Upper Range Value was above the Upper Sensor Limit.
Upper Range Value too LowThe Upper Range Value was below the Lower Sensor Limit.
Upper and Lower Range
Both the Upper and Lower Range Values are beyond their limits.
Values Out of Limits
All
➀
Span too SmallThe Span, as determined from the Upper and Lower Range Values, was below the
Minimum Span.
All
➀
Access RestrictedThe command was rejected due to a condition within the Field Device which would
prevent proper execution.
All
All
➀
➀
BusyThe device is performing a function that cannot be interrupted by this command.
Command not implementedThe command was not defined for this device.
T commands that are supported by this release of the Smart T
ransmitter Toolkit: 0, 1, 3, 35, 38, 43, and 44.
Integer Word 35
B-3
Appendix B
Codes
HART Field Device Error Codes
Integer Word 36
BitError CodeDescription
7
6Configuration ChangedA write or set command has been executed on the HART field device.
5Cold StartPower has been removed and reapplied resulting in the reinstallation of the setup
4More Status AvailableMore status information is available and can be read using HART command 48,
3Primary Variable Analog Output FixedThe analog and digital outputs for the primary variable are held at their requested
2Primary Variable Analog Output SaturatedThe analog and digital outputs for the primary variables are beyond their limits and no
1NonPrimary Variable Out of LimitsThe process applied to a sensor, other than that of the Primary Variable, is beyond
0Primary Variable Out of LimitsThe process applied to the sensor for the primary variable is beyond the operating
Field Device MalfunctionAn internal hardware error or failure has been detected by the HART field device.
information. The first HART command to recognize this condition automatically resets
this flag. This flag may also be set following a master reset or self test.
Read Additional Status Information.
Note: HART command 48 is not supported by the STT subroutine.
value. They will not respond to the applied process.
longer represent the true applied process.
the operating limits of the device. To identify the variable, use command #48, Read
Additional Status Information.
AllenBradley has been helping its customers improve productivity and quality for 90 years.
AB designs, manufactures and supports a broad range of control and automation products
worldwide. They include logic processors, power and motion control devices, manmachine
interfaces and sensors. AllenBradley is a subsidiary of Rockwell International, one of the
world's leading technology companies.
With major offices worldwide.
Algeria •
Argentina • Australia • Austria • Bahrain
Republic • Denmark • Ecuador
Indonesia • Israel
Poland • Portugal • Puerto Rico • Qatar • Romania • Russia-CIS • Saudi Arabia • Singapore
•
aiwan
• Thailand •
T
W
orld Headquarters, AllenBradley
• Italy • Jamaica •
The Netherlands
• Egypt • El Salvador • Finland • France •
Japan • Jordan • Korea • Kuwait • Lebanon
• T
, 1201 South Second Street, Milwaukee, WI 53204 USA, T
• Belgium • Brazil •
urkey • United Arab Emirates • United Kingdom • United States • Uruguay
Bulgaria • Canada
Germany • Greece • Guatemala • Honduras • Hong Kong • Hungary
• Malaysia • Mexico •
• Chile •
China, PRC • Colombia
New Zealand • Norway
• Slovakia • Slovenia •
el: (1) 414 3822000 Fax: (1) 414 3824444
• Costa Rica •
South Africa, Republic
• V
enezuela
• Yugoslavia
Croatia • Cyprus
• Iceland •
• Oman • Pakistan •
• Spain •
• Czech
India
Peru
• Philippines
Switzerland
•
•
Publication
17706.5.21 March 1994
Copyright
1994 AllenBradley Company
PN 9551
1697
, Inc. Printed in USA
Loading...
+ hidden pages
You need points to download manuals.
1 point = 1 manual.
You can buy points or you can get point for every manual you upload.