Professional Documents
Culture Documents
Doc ID TUNE-UM001C-EN-P
Technical Support Telephone 440-646-5800 Technical Support Fax 440-646-5801 World Wide Web www.software.rockwell.com 2003 Rockwell Software Inc. All rights reserved. Printed in the United States of America This manual and any accompanying Rockwell Software products are copyrighted by Rockwell Software Inc. Any reproduction and/or distribution without prior written consent from Rockwell Software Inc. is strictly prohibited. Please refer to the license agreement for details.
Copyright Notice
Trademark Notices
The Rockwell Software and RSBizWare logos, RSBizWare Batch, RSBizWare BatchERP, RSBizWare eProcedure, RSBizWare MaterialTrack, RSBatch, RSBatch eProcedure, RSBatch Production Manager, RSBizWare BatchCampaign, RSBizWare Historian, RSBizWare BatchHistorian, RSBizWare Batch Archiver, RSBizWare Scheduler, RSTune, and RSLoop Optimizer are registered trademarks of Rockwell Software Inc. All other trademarks are the property of their respective holders and are hereby acknowledged. This Rockwell Software product is warranted in accord with the product license. The products performance will be affected by system configuration, the application being performed, operator control, and other related factors. This products implementation may vary among users. This manual is as up-to-date as possible at the time of printing; however, the accompanying software may have changed since that time. Rockwell Software reserves the right to change any information contained in this manual or the software at anytime without prior notice. The instructions in this manual do not claim to cover all the details or variations in the equipment, procedure, or process described, nor to provide directions for meeting every possible contingency during installation, operation, or maintenance. v13.0
Warranty
ii
Contents
1 Introduction 1
What is RSTune? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1 RSTune Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1 System and Software Requirements. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
2 Quick Start
3 Installation
Setting up RSLinx for RSTune . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7 Installing RSTune. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8 Starting the RSTune Software . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9 Configuring a Loop to Communicate with a Processor . . . . . . . . . . . . . . . . . . . . . . . . . 9 Browsing OPC item names. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 Editing and Deleting Loops . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14 Editing an existing loop . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14 Deleting a loop . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15 Testing Communications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15 Troubleshooting Installation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
4 Tuning Theory
Description of Proportional, Integral, and Derivative Control . . . . . . . . . . . . . . . . . . PID Loop Example. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Proportional only control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Proportional plus integral (PI) control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Proportional plus integral plus derivative (PID) control . . . . . . . . . . . . . . . . . . . RSTune Theory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Tuning types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
17
17 18 19 20 20 21 22
5 Using RSTune
25
iii
Changing the Display of the Faceplate and Trend Window . . . . . . . . . . . . . . . . . . . . Changing the Trend Display. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Changing the Span, Colors, and Decimal Places . . . . . . . . . . . . . . . . . . . . . . . . . Changing the value of the left and right axes . . . . . . . . . . . . . . . . . . . . . . . . . . . . Changing the display of the Faceplate and Trend window . . . . . . . . . . . . . . . . . Changing Controller Settings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Changing the set point and controller output . . . . . . . . . . . . . . . . . . . . . . . . . . . . Changing the controller mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Debugging Communications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Menus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Faceplate and Trend window Options menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . Faceplate buttons . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Simulate window . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Using the Off-Line Analysis & PID Tuning Screen . . . . . . . . . . . . . . . . . . . . . . . . . . Creating a Report for a Control Loop . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . About the Report . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Setting Up an Extra Trend . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Extra Trends Communications Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
27 27 29 31 31 33 33 33 34 34 35 35 36 39 39 40 41 43
45
45 45 48 48 49 49 50 50 51 51 52 52 54
57
58 58 58 58 59 60
iv
CONTENTS
Editing Data in the Time Data Window. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Zooming . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Averaging Data. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Changing Data Points to a Line . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Filtering Data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Saving Changes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Verifying Data Using the Time Data Window . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Statistical Analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Hysteresis Check . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Adding Data from the Time Data Window to the Report . . . . . . . . . . . . . . . . . . . . . .
61 62 63 64 65 65 66 66 68 71
73
73 74 75 76 76 76 78 79 79 79 80 81
9 OPC Topics
83
What is an OPC Topic? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 83 Single processor example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 84 Setting Up an OPC Topic in RSLinx . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 85
10 DDE Topics
87
What is a DDE Topic? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 87 Single Processor Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 88 Setting Up a DDE Topic in RSLinx. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 89
11 Application Notes
Data Collection Methods . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Controller in Manual (Open Loop). . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Controller in Auto (Closed Loop) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Controller in Auto (Using a Manual Step Test) . . . . . . . . . . . . . . . . . . . . . . . . . . Controller in Manual (Fast Plant Test) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
91
91 91 92 92 93
v
Examples of Data Editing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Example of Noisy Data. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Example of Data That is Cycling and Has Noise Spikes . . . . . . . . . . . . . . . . . . . Example of a Process That Responds Faster in One Direction . . . . . . . . . . . . . . Integrating (Non-Self-Regulating) Loops . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Temperature Control of Extruders . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Cascading Loops . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Collecting Data for Cascading Loops. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
94 94 95 96 96 97 98 99
101
101 101 101 102 102 102 102 103 104 104
A Activation
How Activation Works . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Protecting Your Activation Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Activating Your RSBizWare Batch Module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Running the Activation Utilities. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Finding More Information About Activation. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Some Common Questions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
105
105 105 106 106 107 107
109
109 109 110 110 110
C Glossary Index
111 vii
vi
Introduction
Welcome to RSTune, the application that makes tuning your control loops fast, easy, and accurate. RSTune also provides methods of analyzing your loops to help ensure optimal tuning parameters. This chapter covers: What is RSTune? RSTune Features System and Software Requirements
What is RSTune?
RSTune is Rockwell Softwares Windows-based software for analyzing and tuning PID control loops in Allen-Bradley PLC-5, SLC 500, MicroLogix 1200/1500, and ControlLogix Programmable Logic Controllers.
RSTune Features
Tools on the time plot: Make zooming, editing, averaging, or filtering your real-time
data a snap
OPC support: RSTune is an OPC client (RSLinx 2.1 and above only). ControlLogix 5550 support
Support for MicroLogix 1200 and MicroLogix 1500 Support for Logix 5000 PID function block Extra trend: An extra trend can be added to allow you to watch another variable in the
same trend.
Viewing of real-time trend values: Real-time trend values can be viewed as ToolTips
Archiving: Manual archiving of multiple sets of data allows easy before and after
analysis.
Performance increase displays: The performance increase from tuning your loop is
communications, which allows you to browse the network for OPC items such as PID instruction addresses and control block tag names.
Remotely connect to RSLinx (version 2.3 or later): If you are using OPC communications, you now have the option of connecting to a remote computer that is running the RSLinx Gateway.
Quick Start
This chapter gives you a step-by-step approach to get you started using RSTune. More detailed explanations about the tuning process and how you can edit, verify, and analyze your data can be found in the remaining chapters of this Users Guide. This chapter covers: Tuning a Loop Guidelines for Optimizing Loops
Tuning a Loop
1. Establish and test communications as shown in Testing Communications. 2. Click Faceplate to communicate with your PID loop or software simulation. The Faceplate window opens.
3. Click AutoTune.
You can cancel the AutoTune sequence and return to normal operation at any time by clicking the End Sequence button.
4. Follow the instructions on the screen to tune the loop. For each question in the Performing AutoTune Sequence area, help is available by clicking the Help button. Detailed information on AutoTune is provided in Using AutoTune to Collect Data.
5. When you have completed the AutoTune sequence, RSTune displays suggested PID tuning parameters, the Time Data Window for the loop, and the safety factor, derivative, and filter information. Click Download to send PID parameters to the processor or simulation. 6. A sample of the screen after AutoTune has completed is shown here:
2 Quick Start
5. Perform an open loop step test (Manual mode) at several different locations in the controller output span, for example, at 20%, 40%, 60%, and 80%. (See Controller in Manual (Open Loop) for more information.) Check the new tuning parameters and the model identified in the Process Model window. (See Options in the Process Model Window.) Are the models (or PID tuning parameters) at each step significantly different? If the parameters are more than a factor of two different, consider trying to linearize the loop. If you cannot linearize the loop, use the most conservative tuning values. 6. Perform an open loop step test in the opposite direction as in step 5. Compare PID tuning parameters or the models identified in the Process Model window. Does the process respond differently in the up direction versus the down? If so, can you reduce or eliminate the discrepancy? If not, use the more conservative tuning values. When tuning a loop, it is important to keep in mind other factors that can affect the control loop. For example, sensors must be properly located, calibrated correctly, and able to respond quickly enough to expected process changes. Valves must be sized correctly. The entire design of the control system affects how well the system can be tuned. For more information on optimizing your loop, select Help > Optimization Steps on the Faceplate or the first window in RSTune.
Installation
This chapter provides information on installing RSTune and setting up the communications package. You must have communication software installed and configured for RSTune to communicate with your control loop. RSTune works with: RSLinx 2.3 (or higher)
The Lite version of the communications software is not sufficient for communication with RSTune. You must have at least the OEM version of the communications software to communicate via OPC or the Professional version to communicate via DDE.
You can simulate a control loop using built-in DDE communications without the use of RSLinx. (See Using RSTune for more information.) This chapter covers: Setting up RSLinx for RSTune Installing RSTune Starting the RSTune Software Configuring a Loop to Communicate with a Processor Editing and Deleting Loops Testing Communications Troubleshooting Installation
These steps are not needed if you are using the control loop simulator.
To configure an RSTune loop to communicate with your processor: 1. Install RSLinx. 2. Configure RSLinx to communicate with your processor. 3. Define an RSLinx topic that RSTune can use to communicate with your PLC.
Installing RSTune
Your RSTune package contains a CD-ROM and a Master Disk. RSTune is copy protected, and the Master Disk activates the software. To install the RSTune software on Windows XP, 98, NT 4.0, or 2000 operating systems: 1. Close all open programs in Windows. 2. Insert the RSTune CD-ROM into the drive. If you have AutoRun enabled on the computer, continue with step 3. Otherwise: Click Start, then click Run. The Run dialog box opens. In the Open edit box, type drive:\setup, where drive is the letter of the drive containing the CD-ROM. Click OK. 3. Follow the directions on the screen. 4. When prompted for the products serial number, enter the last six digits of the serial number (found on the label of the Master Disk). 5. When asked if you want to move activation now, click Yes. Insert the Master Disk into the disk drive. 6. The utility for moving activation, EvMove, runs. Use the EvMove dialog boxes to move activation from the Master Disk to your root directory (usually C:). For help using EvMove, see How Activation Works, or the EvMove online help. 7. Remove the Master Disk and follow the directions on the screen. When the setup utility finishes, an entry for the RSTune application program is displayed in the program list in the Rockwell Software group. 8. Store the CD-ROM and the Master Disk in a safe place. For more information on product activation, see Activation.
3 Installation
From this window you can define a new loop, choose an existing loop to either tune or edit, or delete a loop. Loops that have already been created are listed in the Choose a Loop box in the main window. For more information, see Editing and Deleting Loops.
4. Type a name for the loop in the File name box. The file extension .tun is added automatically. 5. Click Save. The RSTune Setup dialog box opens, as shown here.
6. Choose the Processor Type. The information on the dialog box changes to show the available options for the selected processor. 7. Under Communications Via, select the type of communications you want to use OPC or DDE.
10
3 Installation
8. If you selected: a. DDE: Continue with step 10. b. OPC: The Remote computer field is enabled. Double-click the empty field or click the browse button to the right of the box. The Browse Network Computers dialog box opens.
If you are talking to the local computer, please leave this field blank.
3. Navigate through the network to locate the remote computer to which you want to establish communications. Either double-click the computer name or select the computer name and click OK. 4. Complete the remaining areas on the dialog box as described in the following table:
If you selected processor: PLC-5 PD file PLC-5 integer file SLC 5/03, 5/04 SLC 5/02, 5/05 ControlLogix MicroLogix 1200/1500 (All processors) (All processors) Topic Sample Interval The RSLinx Topic. You can select the topic from the drop-down list. The sample interval of your controller or to an interval at least four to 10 times less than the equivalent dead time of your process. Equivalent dead time is the time it takes for your process variable to change appreciably after the controller output changes. RSTune uses the sample interval time to: Collect data to analyze Update the faceplate trend and bar graphs The sample intervale you select should be at least as long as the processor scan time. It should also match the sampling time set in RSLinx.
Set these parameters: Parameter descriptions PV Engineering units The engineering units displayed by the AutoTune sequence when it requests a set point change. These units are for display only.
11
If you selected processor: PLC-5 PD file PLC-5 integer file SLC 5/03, 5/04 SLC 5/02, 5/05 ControlLogix MicroLogix 1200/1500
Set these parameters: Parameter descriptions Loop Update Time (view-only) The Loop Update Time is a parameter that is held inside the PDI control block. It must be set when you are programming the block. When the PID control block executes, it uses the Loop Update Tim in the PID calculation. It is important that the Loop Update Time in the control block corresponds exactly to the actual sample period of the loop. The PID control block should be activated by a timer. The timer preset value should therefore be the same as the Loop Update Time. If this is not the case, the PID calculation will be incorrect. The SLC PID instruction can operate in Timed mode or STI mode. In Timed mode, the instruction executes every Update Time Period. In STI mode, the instruction should be placed in an STI interrupt subroutine. It will then execute every time the STI subroutine is scanned. When using STI, also apply the Loop Update Time to the PLC-5 PD file.
PLC-5 PD file PLC-5 integer file SLC 5/03, 5/04 SLC 5/02, 5/05 MicroLogix 1500 ControlLogix
The addresses used in the PID instruction in your ladder logic file.* The Processor Type determines how many addresses are required.
Tags in ControlLogix can be scoped to either controllers or program files. If your tags are scoped to program files, select the check box. If you select the check box, the Program file box opens. Type the name of the program where your PID control block loop tag resides. Type it in the same format as it was entered when you programmed the PID instruction.
(All processors)
*.
Tag Name
If using OPC communications, you can select from a list of available PID instruction addresses and tag names. (See Browsing OPC item names for more information.)
12
3 Installation
Add trends or loops: See Setting Up an Extra Trend. Go to the Faceplate and Trend window: Click Faceplate.
Scroll bar
Scroll arrows
1. To navigate in the dialog box, scroll down the hierarchy of OPC Item names until you reach the item name that you wish to use. 2. Click the item name to select it and click OK. The selected item name is transferred to the Edit Setup dialog box. The topic name appears in brackets next to the item name. Or, you can double-click the item to simultaneously select it and apply it to the Edit Setup dialog box.
Browsing is only available with OPC communications, not with DDE.
13
2. Click Edit Setup. The RSTune Setup dialog box opens. See Configuring a Loop to Communicate with a Processor for detail on the options in this dialog box.
When you are editing an existing control loop, options in the RSTune Setup dialog box are grayed out if there is archived data stored for that loop.
Archives are created: By RSTune when you run the AutoTune sequence When you select Archive>Archive On When you turn archiving on by clicking the Tape Recorder icon. To select a new PID loop or change the location, do one of the following: 1. Click Save As to create a new loop. 2. Click Close to go to the main window. Click New to create a new loop.
If you want to configure a new loop that is similar to another (same PLC), first select the loop in the Choose a Loop list, then click New Loop. The new loop will be a copy of the original. Now you can change addresses to complete the setup of the new loop.
14
3 Installation
Deleting a loop
To delete a loop (a .tun file and all associated data files): 1. In the main window, click the loop to delete in the Choose a Loop list. 2. Select File > Delete Loop. 3. To:
Delete archived data for this loop: Select Yes in the dialog box. Keep archived data for this loop: Select No in the dialog box. Data can be
Testing Communications
The link between RSTune and the server can be either DDE or OPC. RSTune automatically determines the available communications methods. If there is a choice, you can choose between DDE or OPC in the Edit Setup dialog box.
When you have a choice, OPC is the preferred method of communications.
You can test the communications through the Setup dialog box to see if the server is responding correctly. To test communications, click Test. RSTune attempts to read the process variable for the loop from the server. RSTune displays either an error message or the current process variable of the loop.
Troubleshooting Installation
If RSTune does not start up or run properly, check that the communication software is installed. RSTune works with RSLinx version 2.3 or later. The communication software provides communication between the programmable controller and a personal computer in the Microsoft Windows NT, Windows XP, Windows 98, or Windows 2000 environment. If you get a LINX Initialization error message in RSTune when you try to call up the Control Loop Setup window, check these items. Check to see if RSLinx is running. If not, did you install it? Can you run RSLinx by itself? Check the configuration of the RSLinx topic for proper station address and communications device.
15
Make sure your cable or card is plugged in. Check the RSLinx topic to be sure that the Station number is set to the node address of the processor with which you want to communicate. If you get the error Foreign application wont perform DDE method or operation, you might have tried to access the faceplate before all of the RSLinx drivers have fully initialized. Wait and then try again. Check to see if your Control Block address is pointing to a PID controller.
16
Tuning Theory
This chapter provides a basic explanation of PID control, including an example of a simple control loop. Explanations are also provided for the various tuning types that you can select when using RSTune. This chapter includes: Description of Proportional, Integral, and Derivative Control PID Loop Example RSTune Theory Tuning types: Load tuning Safety Factor Setpoint Tuning
error.
Integral gain: The change in controller output is proportional to the amount of time
17
PID loop tuning is the procedure you perform to determine the best possible value for each gain factor given the process you are controlling. Determining if a system is well tuned is application-dependent; but in general, a welltuned system is one that: Responds with little or no overshoot Runs at maximum efficiency, closely tracking the setpoint Provides the fastest response to an upset Compromises between the above three factors Reaches stability More control of when PID tuning is calculated; de-selecting the tuning button causes timeplot to not re-tune while zooming. In some systems, one factor might be more desirable than another. For example, some overshoot might be tolerable to get a faster response.
In
PID Equation
Temperature Sensor
Heating Valve
This system might control the heating to a room in a building. The people occupying the room can adjust the desired temperature by changing the setting (setpoint) on a thermostat. The temperature sensor sends the actual room temperature (process variable) to the controller.
18
4 Tuning Theory
Room temperature could be affected by load changes the outside air temperature might get colder, causing the room to get colder, or many people could come into the room and turn on computers or copy machines, causing the room to get warmer. The difference between the setpoint and the actual temperature is called the error. The error signal is fed to the PID equation and a new output value (controller output) is calculated and sent to the heating valve to try and bring the temperature back to setpoint. If the room gets colder, the difference between the current setpoint and the room temperature increases. The heating control loop would have to respond to this increased error. If the control loop is tuned properly, the system can respond quickly and efficiently. If the system is not tuned properly, problems could occur. If the room is heated too fast, for example, the room temperature might exceed or overshoot the setpoint. The control loop must back down on the heating, but if it does this too fast, the room temperature would go below the setpoint. The system might oscillate like this for a long period of time before it settles down, if it ever settles down. Heating the room too slowly would also cause problems. The occupants would be uncomfortable, and keep changing the setpoint to make the system respond, causing the system to keep chasing the new setpoint. In either case, an improperly tuned system is inefficient, can cause equipment problems, and will not achieve the desired goals of the system.
Offset
The process variable in the graph does settle out, but it does not reach setpoint. The amount of offset from setpoint depends on the amount of proportional gain and the conditions affecting the control loop.
19
The proportional gain can be increased in order to decrease the amount of offset. However, too much proportional gain can cause the controller to respond too aggressively, and the process variable could overshoot the setpoint and then continue to oscillate. An example of this is shown here.
Offset
Set point
Process variable
With integral action, the change in controller output is proportional to the amount of time the error is present. In the example above, the proportional gain responds to the setpoint change, and as time passes, the integral action works to eliminate the offset and bring the process variable back to setpoint. The proper amount of integral action must be used. If there is too little integral action, the system will be sluggish and take too long to get to setpoint. If there is too much integral action, the system could end up oscillating and never settle down.
20
4 Tuning Theory
Sometimes derivative action is thought of as a brake on the controller output. It is often used to prevent overshoot. When a load or setpoint change occurs to the system, derivative action causes the controller output to move in the wrong direction as it approaches setpoint. This prevents or limits overshooting the setpoint and can make the system settle in to the setpoint faster. Generally, you can use more proportional and integral gain if you are using derivative action. Since derivative works off the rate-of-change, it can cause the controller output to be very jittery if there is noise in the measurement. Because of this, use caution when applying derivative action on noisy loops. Unfortunately, most loops are noisy. Use derivative action carefully. Here is an example of PID control:
The same amount of proportional and integral action was used in this example as was used in the example of PI control. A small amount of derivative action was added to limit the overshoot and cause the process variable to settle in to the setpoint a bit faster.
RSTune Theory
RSTune uses an advanced frequency response method coupled with an expert system to determine the best tuning parameters for your control loops. RSTune can tune the loop from data collected from only one "bump" or pulse (like a setpoint change) in auto or manual mode. RSTune converts the data to frequency response. Note that the calculated PID settings are only as good as the data collected to build the frequency response. The frequency response uniquely represents a process signature that identifies that particular process. RSTune runs an expert system to find the best tuning parameters and also to create a model of the process. The modeling allows powerful analysis to be done on the process.
21
Tuning types
Various types or methods of tuning exist to allow a system to be tuned optimally, depending on the application and the type of changes to which the system might need to respond. RSTune allows you to choose between two types of tuning. Load tuning Setpoint (Lambda) tuning For most loops, we recommend that you use PI or PID fastest load tuning. Load tuning gives better response to load upsets. If, however, you need tuning that gives no overshoot, use setpoint tuning. The various methods RSTune uses for analysis are discussed in Control Loop Analysis. LOAD
TUNING
Load tuning gives PI and PID tuning parameters optimized for load changes at the controller output. Load changes are the most difficult disturbances for the system to control. They are also the most common. There is always a trade-off between fast response and sensitivity to changing process conditions. RSTune lets you further specify the type of load tuning you want to use, as well as a safety factor to control the sensitivity of load tuning. LOAD
TUNING TYPES
With RSTune you can specify the type of Load Tuning you want to use. The three types of Load Tuning (with Safety Factor = 1) are:
Fastest: Optimal (minimum absolute error to load step) Fast: Quarter amplitude damping Slow: 10% overshoot
The fastest tuning with the lowest safety factor is the most sensitive to a changing process. Conversely, the slowest tuning with the highest safety factor is the least sensitive. The sensitivity of the loop can be analyzed using the Robustness plot, which is discussed in Control Loop Analysis. LOAD
TUNING WITH NO OVERSHOOT
For load tuning with no overshoot, decrease integral action in the fastest category by a factor of 3. For example, if your controller uses integral in time/rep, multiply the integral setting by 3. If integral is in rep/time, divide by 3. Setpoint tuning also gives you no overshoot.
22
4 Tuning Theory
SAFETY
FACTOR
RSTune uses a safety factor to control the sensitivity of load tuning. The safety factor setting can be between 1.0 and 5.0. A setting of 1 means the tuning is very sensitive to small changes in the process but could become unstable if subjected to large or sudden load changes. A safety factor of 5.0 gives you conservative tuning; the loop will respond somewhat more slowly but is more stable when subjected to large or sudden load changes. More conservative tuning is appropriate in most situations, and 2.5 is the default setting. For faster response decrease the safety factor.
Most control loops are somewhat non-linear. To be stable when the process changes, most loops require tuning with a safety factor larger (more conservative) than 1.
If you enter a Safety Factor that might cause the system to be too sensitive, the message Warning: Safety factor makes the loop dangerously sensitive to process changes is displayed. You might then want to change the safety factor to a more conservative number, but this is only a warning. You can still download the more sensitive value. SETPOINT
TUNING
setpoint (or Lambda) tuning matches the setpoint response to a first order time constant (or lag time) that you enter. System response is first delayed by the process dead time. This method is popular in certain applications, such as paper machines, where overshoot is not acceptable. With setpoint tuning the closed loop response should be the identified process dead time plus the target first order time constant (lambda time) you enter. The loop will achieve setpoint in roughly 4 lambdas.
23
24
Using RSTune
This chapter provides you with information on the use of the basic windows of RSTune, including the menu commands, displays, display options, and button functions. This chapter covers: Faceplate and Trend Window Changing the Display of the Faceplate and Trend Window Changing Controller Settings Debugging Communications Menus Using the Off-Line Analysis & PID Tuning Screen Creating a Report for a Control Loop Setting Up an Extra Trend Step-by-step procedures are also provided in the online help system of the software. The details of control loop tuning using the methods available in RSTune are covered in Tuning Control Loops.
RSTune comes with a control loop simulation program that can be used to help you learn how RSTune works without being connected to a process. To use the control loop simulation: 1. In the Choose a loop box in the Main window, click Simulate.tun. 2. Click Faceplate. 3. See Faceplate and Trend Window below.
25
Or
From the Setup window: Click Faceplate.
The Faceplate for ... window opens. The example here is based on the simulate.tun loop.
of this button.
Real-time trend display: Displays real-time data from your processor PV, CO, or SP display: If you hold the cursor over any point in the real-time trend display, the PV, CO, or SP values at that time are displayed. The values that are
26
5 Using RSTune
displayed depend on the Span settings. See Changing the value of the left and right axes.
Buttons: Perform various commands PID parameter values: The current processor PID values and the new values that will
Turn On Archiving
To collect and archive data in RSTune, you must be sure to turn the archiving function on. To do so, click the Tape Recorder icon (shown at left). Only data that is collected after archiving is turned on will be recorded.
27
To change how ticks and trend length are displayed: 1. Select Options > Trend Options in the Faceplate and Trend window. 2. The Trend Options dialog box opens.
4. Click OK to save the information from the Trend Options window to your setup file.
28
5 Using RSTune
3. Select the tab for the parameter whose variable display characteristics you want to change (PV, CO, SP). The following options are available on each tab:
29
Engineering span: These values are for information only. They show the full
engineering range of the selected variable. The PV and CO engineering spans are the spans used by your controller.
Display span: These spans are for the bar graphs and trend display only. Adjust these to view the range of data you want displayed on the bar and trend displays. The smaller the span, the higher the resolution on the display.
The display spans for the variable you select in the Use XX for right/left axis box are shown in that variables color at the top and bottom of the trend graph. (See Changing the value of the left and right axes for more information.) These spans are for the Faceplate display only. The display spans should be within the engineering span. SP and PV display spans must be the same. If you change either the PV or SP display span, RSTune prompts you and automatically changes the other. On a new loop, RSTune automatically sets the display spans to a 25% range around the current PV and CO values. If you set any span, RSTune will no longer automatically set any display span for that loop.
Current value: This value is for information only. The current value is shown in it's appropriate color. Line Color: Allows you to change the line color of the selected variable. Click the Line Color button or the current value for the variable whose color you wish to change. Select a new color and click OK. The new color displays in the Current value box on the dialog box. If you change the PV, CO or SP colors, your color selections take effect for all of your loops. Decimal places: This option changes the number of places shown after the decimal point. The number of decimal places is for the Faceplate window only. It has no effect on the accuracy of the value stored in the archive files. Use the Current value window to see the visual effect of changing the number of decimal places. The number of decimal places must be in the range 0 to 5. Line width: This option lets you define the width of the lines in the trend display. When you select OK, your width selections for PV, CO and SP take effect for all your loops (the width selections are saved in EXPERTUN.INI). The line width must be in the range 1 to 4. Display on graph: Check or uncheck the box to hide or show the variable on the
real time trend display. If the variable is hidden on the trend display it is still read and displayed in the digital value window, and archived to disk. 4. Click OK to exit this window and save your changes.
30
5 Using RSTune
31
32
5 Using RSTune
33
Debugging Communications
Data Spy allows you to display raw data before scaling, formatting, or adjusting decimal points. Data Spy is available through the Faceplate and Trend window. To use Data Spy, select Options > Data Spy. The Spy dialog box opens.
The Mode as ASCII chars box displays each character of the mode string as its ASCII value. The type of communications being used (DDE or OPC) is shown at the bottom of the dialog box. This window can remain open while other RSTune windows are active. It always stays on top.
Menus
The RSTune Faceplate and Trend window has four menu options: Archive View Options Help
34
5 Using RSTune
Faceplate buttons
The buttons underneath the Trend window on the Faceplate allow you to choose to tune from previously archived data, use the AutoTune sequence, or close the Faceplate and Trend window. Descriptions of each of the buttons are included below. Detailed use of the buttons in various tuning functions is described in Tuning Control Loops. TUNE
FROM ARCHIVED DATA BUTTON
The Tune from archived data button brings up a list of archived data files. (See Tuning Control Loops for more information.) This is similar to the window that appears when using Offline Analysis.
Name of the original file (added by RSTune) Yes indicates that the file has been edited
The list shows the name of the archive file, the date and time when the data was collected, and whether the file is an edited version of an archived file. To work with an archived file, click the filename. The buttons below the archived file list are:
Tune: This button displays the Time data window. From this window, you can have
RSTune determine tuning parameters and perform analysis on the data. See Tuning Control Loops for details on using the Time data window.
35
Copy to ASCII: This button allows you to save your data to an ASCII file (extension .asc). The file can be named and placed in any folder. You can also save the data as a print file (.prn) or as a data file in comma separated value format (.csv). Time Plot: The Time data window displays the process variable and controller output
data. Use this window to verify that your data meets tuning requirements, or to edit data to optimize it before calculating new parameters.
Delete: This button deletes the selected archived data file from your hard disk.
Delete removes the selected archived data file for the control loop, not the actual control loop. To delete the control loop file, see Editing and Deleting Loops.
Back: This button closes the archive data file list window and returns you to the
good idea to make a small set of notes here for each archive file. The Loop Notes box to the right of the archive list displays notes that have been entered concerning the loop. RSTune automatically adds notes to the Loop Notes when a file is edited. You can also enter notes manually by clicking Change Notes. 1. To edit the Loop Notes for a data set, select the data set. 2. Click Change Notes. 3. Type your changes in the Edit Notes window. To start a new line in the Edit Notes window, press CTRL + ENTER. 4. Click OK to save your changes or Cancel to abandon them. AUTOTUNE
BUTTON
AutoTune starts the AutoTune sequence. This is a sequence of questions that you can follow to have RSTune automatically calculate new PID tuning parameters for your control loop. The AutoTune sequence is described in Using AutoTune to Collect Data. CLOSE
BUTTON
The Close button closes the Faceplate and Trend window and takes you back to the RSTune main window. It does not close RSTune.
Simulate window
When you open the faceplate for a loop with a processor type of Software simulation, the Simulate window opens minimized. This simulated control loop allows you to gain
36
5 Using RSTune
experience with RSTune without being connected to a processor. The simulator lets you simulate flow, level, temperature and pH loops; also typical loop control problems such as hysteresis, stiction and non-linearity.
The information in the Simulate window is the same as the information on the Faceplate and Trend window, except for the Advanced button. Any changes to information in the Simulate window will also be changed in the Faceplate and Trend window.
The functions you can do from the basic Simulate window are listed here. For information on the Advanced button features, see Advanced Simulate window.
To: Change the set point, controller output, or PID values Do these steps: Note: The controller output value can only be changed in Manual mode. Double-click the box. Delete the old value and type the new value. Click Enter. Switch between Auto and Manual modes Restore the initial tuning parameters Click the drop-down and select Manual or Auto. Click Initial PID. This option returns the initial tuning values, regardless of how many settings you have downloaded. This is different than the Bring back Previous PID settings to New option on the Faceplate and Trend window Options menu. The Bring back option restores only the previous PID values, not the initial values.
37
ADVANCED SIMULATE
WINDOW
The Advanced simulate window allows you to select one of seven process types and change the load.
38
5 Using RSTune
39
RSTune creates reports in Microsoft Word (version 97 SR-1 or higher). Word must be installed in order to use the reporting feature. You can create a report while tuning or from archived data. To create a report: 1. Select tuning for the loop. 2. On the Faceplate and Trend window, select Options > Tuning Report. 3. Wait while the report is being prepared. Doing other work on your computer could interfere with the insertion of graphics in your report. 4. Maximize Word to see the report. 5. To save the report, select File > Save in Word. RSTune automatically names the file for you.
When you open the report in Word, you will see a message that tells you the document contains macros and asks what you want to do. If you disable macros, the document will open as readonly and you will be unable to edit it. Select Enable Macros to open the report for editing.
40
5 Using RSTune
EDITING
A REPORT
Once created, you can edit your report to be specific to your company. Replace all occurrences of Company Name with your companys name. You can double-click on text in the headers or footers to edit it. Change the letter on the cover page to suit your needs. Delete any blank graphs or data that you do not want to use. Edit or add notes about the graphics in the report. Summarize your findings in the Conclusions and Recommendations section.
When you open the report, you will see a message warning that the document contains macros and asking what you want to do. If you disable macros, the document will open as read-only and you will be unable to edit it. Select Enable Macros to open the report for editing.
PRINTING
A REPORT
From within Microsoft Word: 1. Update the report information by pressing CTRL + A, then pressing F9. 2. Select File > Print.
To create a new trend: 1. In the main window, click the loop to contain the extra trend. 2. Click Edit Setup. The RSTune Setup window opens.
41
3. Click Advanced. The Extra Trends and Advanced Loop Setup dialog box opens.
4. Click Extra Trends. 5. The blank Setup Extra Trends window opens. 6. Click Add Trend. The Trend 1 tab is added, as shown here.
7. Set Eng span to the full engineering range of the trend variable. 8. Set Inst span to the instrument range of the trend variable. This is the range of the value reported to RSTune by the server. When gathering data from a PLC, you may need to set the Inst span to the Numeric range (0 to 40%, for example).
When RSTune reads an Extra Trend value, it scales the values from the instrument span to the engineering span. If the value is not scaled, set Inst span to the same value as Eng span.
42
5 Using RSTune
10. Click Test to determine if your server is responding correctly to the address information. RSTune reads the variable from the server and displays the variable or an error message. Both the raw instrument value and the scaled engineering value are shown. The raw instrument value is the value that is actually reported by the server. The scaled value is in engineering units and will appear on the Faceplate window. You can change its color or enter a different number of decimal places. To change the color click the engineering value.
43
44
Collecting Data
With RSTune, you can follow the AutoTune sequence to determine PID tuning parameters, or you can manually gather data and tune using that information. (See Data Collection Methods for more information.)
When gathering data: Collect the process variable and controller output data from a step or pulse test. You can make a set point change (in Auto) or a controller output change (in Manual). Both the process variable and controller output must start and end at a steady state condition and include the complete response to the set point or controller output change. When steady state settles out, both the process variable and controller output
45
are relatively flat horizontal lines in the Trend display, moving within the range of normal process noise. RSTune analyzes process variable and controller output data pairs. All process variable filtering must be removed from the signal.
The data must not be from a load or process upset. Loads must not change during the test and the range of test data should be as linear as possible. If a load change occurs during the test, click End Sequence and begin the test again.
1. From the main window, click the loop to tune. 2. Click Faceplate. 3. Click AutoTune. The Performing Auto-Tune Sequence area changes, as shown here.
If your loop is erratic or cycling, try: Putting the loop in Manual mode and waiting for it to settle out. Putting it in Auto mode and entering a low proportional gain and a low integral gain. Wait for the loop to settle out.
You should allow for a least 30 samples of flat-line data before continuing.
4. When your process data is steady state, click Yes. The Performing Auto-Tune Sequence area notifies you of the selected set point, as shown here.
46
5. RSTune needs to produce a bump in your process by making a set point or controller output change. The default is 7. To use a different value, click Different. You are prompted for a value. You can use negative numbers if needed. Click Enter.
If you are using the Simulate.tun file that comes with RSTune, you might want to use a larger value. The default is not much larger than the process noise, so you will get better data if you use 10 or 15.
6. Click OK. 7. If the loop is in Auto mode or you are tuning a simulated loop, go to step 10. a. If the loop is in Manual mode, the following prompt displays:
To get good data for tuning, RSTune needs to see the process variable respond to the controller output. The amount of process variable response needs to be at least 4 to 6 times larger than the normal peak-to-peak noise in your process. c. After the process variable moves by this amount, click Yes. RSTune changes the controller output back to its original value. 4. The Performing Auto-Tune Sequence area prompts Is the process settled out?
47
5. When the process has steady state, click Yes. 6. The name of the archive file for this data is displayed. Click OK. 7. The Time data window for the data opens (see Calculating Tuning Parameters). You can start verifying or editing your data and determining new PID tuning values.
Collecting Data
In some cases, you might want to collect data manually instead of using the AutoTune sequence. This is a basic procedure to collect data manually. This is a closed loop test with the controller in the Auto mode. Examples of other methods of collecting data manually are provided in Application Notes.
The data must not be from a load or process upset. Loads must not change during the test and the range of test data should be as linear as possible. If a load change occurs during the test, stop collecting data and start over.
1. Make sure the controller output is not at 0%, 100%, or saturated into a limit. If it is, change the controller output to between 5% and 95% (or not at a limit). Valves are usually non-linear at their limits. 2. Let the loop settle out (reach steady state). 3. Select Archive > Archive On (or click the Tape Recorder icon). 4. Change the controller set point by about 10%. 5. Wait for the process variable to respond an appreciable amount, then change the set point back to its original value. Skip this step if your process can tolerate a new operating point. 6. Let the loop settle out (reach steady state). 7. Select Archive > Archive Off.
48
49
Archiving Data
Data collected with the AutoTune sequence is automatically archived. You can also manually archive data: 1. Select Archive > Archive On. 2. RSTune starts archiving data to a file with the same root as the .tun file. For example, if the .tun file is FIC100.tun, the first archive file will be FIC100.001, the next archive will be FIC100.002, and so on. 3. When you are done collecting data, select Archive > Archive Off. When you turn archiving on, RSTune displays the name of the file where the data is archived in the title bar of the Faceplate and Trend window:
The list of files looks like this in the Faceplate and Trend window:
50
It looks like this in the Off Line Analysis and PID Tuning window:
The Time and Date shown in the Collected column indicate the time and date the archive was started, based on the computers clock.
51
52
Current F: 0 Channel 1 Description: PV Channel 1 Eng. Min. Span: 0 Channel 1 Eng. Max Span: 100 Channel 2 Description: CO Channel 2 Eng. Min. Span: 0 Channel 2 Eng. Max Span: 100 Channel 3 Description: SP Channel 3 Eng. Min. Span: 0 Channel 3 Eng. Max Span: 100 Response Direction: up Controller Algorithm: Allen Bradley PLC-5 PD file ISA, D on PV Controller Type: ideal PB Or Gain: gain Integral Units: min/rep PB Multiplier: 1 Integral Multiplier: 1 Derivative Multiplier: 1 Mode: 1 PID: 4 TimePlot AutoScale PV: 0 TimePlot AutoScale CO: 0 TimePlot PV Min: 41.63655 TimePlot PV Max: 49.87732 TimePlot CO Min: 39.31247 TimePlot CO Max: 55.48609 TimePlot Number of Lines: 0 TimePlot Line Position1: 0 Timeplot Line Position2: 0 Timeplot Line Position3: 0 Timeplot Line Position4: 0 Timeplot Line Position5: 0 Timeplot Line Position6: 0 Timeplot Line Position7: 0 Timeplot Line Position8: 0 Timeplot Line Position9: 0 Timeplot Line Position10: 0 Timeplot Line Position Hyst1: 0 Timeplot Line Position Hyst2: 0 Timeplot Line Position Hyst3: 0 Timeplot Line Position Hyst4: 0 Characterizer Fit Type: 0 Characterizer Language: 0 Characterizer Lines: 0 Characterizer Blue Y1: 0 Number Of Points: 192 ArchiveNotes: Data collected manually with the controller in Auto mode. Data Section ============
53
PV ----------41.46768 41.30512 41.62125 41.5027 41.64124 41.89695 42.13604 42.30678 42.32682 42.26803 41.42966 39.54797
CO ----------39.78901 40.99653 41.36135 39.8148 40.96721 38.49328 31.08119 25.70074 24.43569 23.97164 23.6704 25.02115
54
TO THE
CONTROLLER
Downloading different gain values while the processor is in the Run or Remote Run mode might cause unexpected machine operation, which can result in injury, loss of life, or machine damage.
To download the new PID parameters to the controller or the software simulator: 1. Click Download on the Faceplate and Trend window.
3. Click Yes. After the values are downloaded, the Current and New parameters should be identical. RETRIEVING PREVIOUS PID SETTINGS To check what the PID settings were before the download, you can use the Bring Back Previous PID Settings to New option. When you select this option, the New settings are replaced with the settings that had been in the Current column before the download. To retrieve the previous values, select Options > Bring back Previous PID settings to New. The values under New are changed to the values that were in Current before the download. These values can be downloaded.
55
56
The Time data window displays the process variable and controller output data. Use this window to verify that your data meets tuning requirements, or to edit data to optimize it before calculating new parameters. This window opens when: The AutoTune sequence is complete You select an archived data file and click Tune You are in the Off-Line Analysis and PID Tuning dialog box and click Time Plot or Tune This window can be moved anywhere on your screen and remains on top of other RSTune windows. A sample Time data window is shown here.
57
58
New PID parameters and probable performance increase or Are current settings stable? message
The PID parameters are based on the data collected for your loop. More specifically, the data shown in the Time data window is used for all calculations. If you modify or zoom in this window, the results will change. Before the loop is tuned, the New column displays N/A (not applicable) for each parameter. The parameters in the New column are recalculated as you make changes in
59
the Controller Tuning section of the Faceplate and Trend window and as you make changes to data in the Time data window. You can also change any of the New tuning parameters yourself. Click the box of the parameter you want to change, edit the value, and press Enter. The Probable Performance Increase is updated as the PID parameters change and tells you how much better the controller will respond to a load upset with the new PID parameters. It is the percent probable performance increase in integrated absolute error (IAE) to a load upset assuming the controller does not overshoot to a load upset with either the current or new parameters. If the controller overshoots, the performance increase is an approximation that is roughly proportional to the IAE improvement. It is still a good predictor of performance. This box says None if the Probable Performance Increase is insignificant. Adding derivative might increase the performance in these cases. (Click the Use derivative if possible box.) To determine the optimal tuning parameters for your loop: Verify and edit your data using the Time data window (below). Select the desired tuning factors in the Controller Tuning section of the Faceplate and Trend window (below). Analyze the effects of the new PID parameters using the Analysis windows. (See Control Loop Analysis for more information.)
Controller Tuning
When the Time data window opens, you can select the controller tuning factors that you want to use for this loop.
See Tuning Theory for definitions of load tuning, set point tuning, safety factor, and other RSTune parameters.
click Tune.
Off-line window: Click Tune. Time data window: Click the Tuning Fork icon.
60
The Time data window opens and the Controller Tuning section is added to the Faceplate and Trend window, as shown here.
regulation.
To see what the PID settings would be for each type of tuning, click PID Grid, where you will be able to change the settings and see the effects in one window.
3. For:
Load Tuning: Type a Safety Factor between 1 and 5, with 1 being the most
sensitive.
Set Point Tuning: Type a Response time (in seconds). For a faster response, use a smaller response time. For slower response, use a larger response time. The default value that RSTune sets is conservative to prevent overshoot on set point change.
4. To use derivative gain, select Use derivative if possible. 5. Click Done tuning. The Time data window closes. If you are using the Off-line Analysis and PID Tuning window, the PID parameter display is also closed.
61
Zooming
After collecting data, you might want to zoom in on the data you want to use for tuning. This is typically the smallest window of data that starts at a steady state condition and ends within about 5% of steady state. You can zoom manually or use Auto Zoom. When Auto Zoom is used, RSTune automatically tries to zoom in on the data that offers the best tuning. ZOOMING MANUALLY To zoom in on your data: 1. Select Zoom > Zoom in or click the Zoom In button, shown at left. 2. Click the graph where you want to begin zooming. 3. Click again where you want to end zooming. The portion of the graph you selected is highlighted.
4. To change the zoomed area, click a new spot. You can do this as many times as needed. Clicking the graph anywhere to the right of the midpoint moves the right edge of the highlighted area. Clicking to the left of the midpoint moves the left edge. To include all of the data points to the left, click just outside the left side of the graph. To include all of the data points to the right, click just outside the right side of the graph. To stop zooming, click Cancel Zoom. 5. Click Zoom Now or click the Zoom In button. You can zoom in as many times as needed.
62
To return to the previous view, select Zoom > Zoom Back to Previous. To return to the view of all data, select Zoom > Zoom Out or click the Zoom Out button. USING AUTO ZOOM To use Auto Zoom: 1. Select Zoom > Auto Zoom. The data is highlighted. 2. Click Zoom Now to accept the data. Auto Zoom attempts to zoom based on the current data. If RSTune does not have the proper data to perform Auto Zoom, the error message Cannot automatically find a zoom location in the data is displayed. You can then either zoom manually, or recollect data and retry Auto Zoom. (See Data Collection Methods for methods of collecting data.)
Averaging Data
RSTune uses your initial data as the steady state basis for all tuning and modeling. Ideally, this data should start and end at steady state. However, if your initial data is noisy or cycling, averaging might improve your tuning results. Average the controller output and the process variable data to just where it starts changing due to the bump introduced as part of the test. To average a portion of your data: 1. Select Edit > Average or click the Average button. 2. Click the beginning point of the data you want to average. 3. Click the end point of data you want to average. That section of data is highlighted.
63
4. To change the area, click at the new spot. You can do this as many times as needed. Clicking the graph anywhere to the right of the midpoint moves the right edge of the highlighted area. Clicking to the left of the midpoint moves the left edge. To include all of the data points to the left, click just outside the left side of the graph. To include all of the data points to the right, click just outside the right side of the graph. To stop averaging, click Cancel Avg. 5. To modify your data, click on the graph at the new beginning or end point of the data you wish to average. 6. To accept the change click Avg now. You can undo the last averaging operation by selecting Edit > Undo or clicking the Undo button.
5. Click OK. To undo the line editing session, select Edit > Undo or click the Undo button. You can edit both the PV and OP data.
64
Filtering Data
1. Select Edit > Filter (or click the Filter button). The Process Variable Filtering dialog box opens.
2. Select the Filter type from the list. For filter descriptions, see the online help. 3. Type the Filter time constant in seconds. Pick a filter time large enough to eliminate as much noise as possible without degrading loop performance. If the filter time constant is too large, it can hurt loop performance, because the control system will try to control the filter.
Filtering modifies your plant data. If you use a PV filter, subsequent tuning will be based on the filtered process variable.
4. Click Test to test the effects of filtering. The graph in the Time data window is redrawn with the filter values applied. 5. Click OK to accept the filter values or Cancel to ignore the changes. To undo the filtering change, select Edit > Undo or click the Undo button.
Saving Changes
After making editing changing in the Time data window, you can save the changes by selecting Edit > Save changes. The edited data is automatically saved in a new archive data file. RSTune keeps both the original and the edited data file or files. The edited file is indicated by Yes in the Edited column. RSTune automatically adds a note that identifies the original file.
The file that the edited file was created from. Yes indicates that data in this file was edited.
65
Statistical Analysis
Statistical analysis can be used to check the improvement in control with the new tuning parameters. Before tuning, collect the normal operating data (with no set point changes) with the controller in Auto. Download the new tuning parameters and collect normal operating data again. Compare the statistics for both sets of data. Statistical analysis looks at steady state.
Be sure to turn Archiving on when collecting data so you can save and compare the two sets of data. Select Archive > On to start archiving. Select Archive > Off when data collection is complete.
After you gather data for statistical analysis: 1. On the faceplate, select Tune from archived data. 2. Select the file to analyze. 3. Click Time Plot. The Time data window opens. 4. Use the zoom tools to zoom in on the portion of the data you wish to analyze. 5. Select Options > Statistical Analysis. The RSTune Statistical Analysis dialog box opens
66
The Time data window also changes to show the statistics as mean, standard deviation, and 2x standard deviation lines on the process variable graph.
2x Standard deviation (green lines) Mean (red line) Standard deviation (blue lines)
The statistical information can be added to the loop report by selecting Options > Add to Report.You will be given the option to add the data to the Before Statistics or the After Statistics section of the report. Definitions of the statistics are:
Sample (raw): The data collection sample interval in the archive. Mean (): The average of your data.
standard deviation =
sample variance 2
67
IAE - Integrated Absolute Error: Performance of a loop is judged by how closely the
controlled variable is held to the set point, both for set point changes and load changes. There are many mathematical ways of judging this, and IAE is one type. IAE is a measure of controller error defined by the integral of the absolute value of a time dependent error function.
Hysteresis Check
RSTune can perform a hysteresis check on your data. Hysteresis is a dead band in the movement of a device upon a change of direction. For example, if a valve is moving in one direction, it continues to move if the air signal keeps moving in the same direction. But when the air signal changes direction, the valve has to stop and reverse motion. Conditions like static friction and lost motion in linkages take time to overcome. This time, or hysteresis, must be compensated for by the air signal increasing to an amount equal to the hysteresis before the valve will move in the other direction. If RSTune cannot calculate hysteresis from your data, an error message is displayed. Click Yes to this message to display information on how to properly gather data to perform a hysteresis check. If your hysteresis is more than 1% for valves with positioners or 3% for valves without positioners, consider repairing or changing equipment to try to reduce the hysteresis. COLLECTING DATA
FOR A
HYSTERESIS CHECK
The hysteresis check requires several controller output changes while the controller is in Manual mode: two steps in one direction and one step in the other. To collect data for a hysteresis check: 1. In the Faceplate and Trend window, select Manual mode. 2. Select Archive > On or click the Tape Recorder button. 3. Wait for the process variable to settle out and collect a little more data to get normal process noise. 4. Increase the controller output by 5%. 5. Wait for the process variable to settle out. 6. Increase the controller output by another 5%. 7. Wait until the process variable settles out. 8. Decrease the controller output by 10%.
68
9. Wait until the process variable is at steady state. 10. Click Archive > Off. (See Data Collection Methods for additional methods of collecting data.) PERFORMING
THE
HYSTERESIS CHECK
Once the data has been collected, you can do the Hysteresis check: 1. Click Tune from archived data. 2. Select the archive file collected above. 3. Click Tune. You might see a message indicating that the data is questionable for tuning. You can ignore this, as it does not reflect on the datas suitability for a hysteresis check. Click OK. 4. To check:
Automatically: Select Options > Hysteresis check > Automatic or click the Hysteresis button.
6. The areas RSTune used to calculate hysteresis are indicated on the graph. RSTune finds each of the three areas where steady state occurred in the process variable after a step change. The areas are:
p2: From the first steady state area to the second p3: From the second steady state area to the third
69
7. The controller output graph is labeled at each step change (C1, C2, and C3). If the controller output data is noisy, average the data to make it clean between steps (see Averaging Data). 8. Hysteresis data can be recorded in the report by selecting Options > Copy to Clipboard and adding to the appropriate section of the report. NOTES
ON THE
HYSTERESIS CHECK
During the hysteresis check, information is displayed on valve sizing and transmitter span. Process gain that is too high could be an indication of incorrect valve sizing, incorrect valve characteristic, or a transmitter span that is not correct for the loop. If any of these items are incorrect, the loop can be difficult to control, and usually results in a cycling loop.
Valve Oversized
An oversized valve cannot provide very fine control. Any valve has a rangeability factor that determines how precisely it regulates. A good control valve might have a rangeability of 100 to 1, which means you can make 1% adjustments in the output. The valve can also be referred to as having a resolution of 1%. This allows finer control with less chance of inducing hunting or cycling. If a valve is oversized, the usable operating range of the valve gets smaller. For example, a valve with a rangeability of 100 to 1 could be oversized for an application to the point that its effective usable operating range is only 50 to 1 (process gain of 2). This translates to a resolution of 2%. The oversized valve can only be adjusted within 2% instead of 1%. It no longer has tight control, and the process might be hunting within the valve resolution. The oversized valve could also be operating on its seat. A command could be sent to the valve, but it might not move off its seat since control isnt precise. The solution to an oversized valve is to change the valve trim or replace the valve with one of the appropriate size.
Valve Undersized
An undersized valve can be a safety problem since it might not have the range to control the process. The solution to an undersized valve is to change the valve trim or replace the valve with one of the appropriate size.
Transmitter Span Too Large
The most likely reason for the process gain to be too small is if the process variable transmitter span is larger than it needs to be. The resolution of the measurement improves with a smaller transmitter span.
70
The resolution of your measurement is the smallest change that your system can detect. For example, you have a choice of two transmitters connected to a controller. The controller has a 12-bit analog to digital converter with a resolution of 1 in 4096 (212 = 4096). Converted to percentage: 1/4096 = 0.0002441 0.024%.
Controller A/D
Resolution of 0.024%
You are measuring temperature and one of the transmitters has a span of 0 to 4096. With the 12-bit converter described above, you are only able to measure and control within 1 degree: 4096 * 0.024% 1 The other transmitter has a span of 100 to 500 degrees. Your resolution would improve approximately 0.1 degrees: 500 100 = 400 400 * 0.024% 0.1 Now your system could detect a change of 0.1 degrees instead of 1 degree. If you only need to detect and control a measurement within a certain range, choose a transmitter span that represents what you need.
Transmitter Span Too Small
The process gain of the loop might be large if the transmitter span is too small or too narrow. The solution is to widen the span. This will result in small movements to the control valve, causing large changes to the PV. Since small valve movements are subject to valve problems, a large process gain will have the effect of amplifying any valve problems.
pasted into the appropriate section of the report. See Creating a Report for a Control Loop for more information on reporting.
71
72
73
You must work with an archive file that contains at least one valid bump. The bump can be from data collected in Manual or Auto mode.
6. Begin working with the plots by selecting a model from the Process Model window.
74
To select a process model: 1. Adjust the plot windows so that you can see the Process Model, Process Frequency Response, and Robustness Plot. 2. Check the data on the Process Frequency Response and Robustness Plots. 3. In the Process Model window, select a different Model type from the list (Force steady state gain or Allow gain to float). The plots change to reflect the new model. 4. Check the data on the Process Frequency Response and Robustness Plots. 5. In the Process Model window, select the Model type that fits your data the best. 6. Once youve determined the best Process Model, you can use the Process Simulation window and the Robustness Plot to analyze the calculated and current PID parameters.
The Process Frequency Response plots both the actual and the model data. Choose the model that is closest to the actual data of Amplitude Ratio and phase. The most important frequencies are where the phase is between about 90 and 180 degrees (phase lead) or 90 and 180 degrees (phase lag). The Robustness Plot shows the trade-off between tight tuning and sensitivity to process changes. If you have two sets of tuning with about the same robustness, you can generally choose the faster response.
RSTune identifies a process model using advanced frequency response methods. The software develops a high-fidelity model from a variety of data here are examples of data sets used to identify the model: Open loop step Closed loop step (controller in automatic) Open loop pulse Closed loop pulse (controller in automatic) Psudeo random data Open loop doublet pulse
75
integrator process is discussed more in Application Notes) If the model is second order and the roots are imaginary, the time constant displays the word imaginary.
Model Type
All of the analysis windows depend on the model type chosen. Two models are available. When you choose a different model, all the analysis windows update. The model types are:
Allow gain to float: Causes RSTune to ignore steady state information and fit the
model based on higher frequencies. These higher frequencies are more important to optimal and stable closed loop control.
Force steady state gain: Forces the steady state gain to be equal to the amplitude ratio at the lowest frequency. The model is fit using the remaining good frequencies. The lowest (or zero) frequency values for amplitude ratio and phase are not plotted on the frequency plot, so at the lowest plotted frequency, the model frequency response might not appear to match the process.
If you selected the Inverse Response option in the Advanced window during loop setup, the model will also show a lead time and integrator.
76
determine which process model is best. In general, you want the closest fit at frequencies where the phase is between about -90 and -180 degrees. RSTune uses the data in this plot to calculate new PID tuning parameters.
The left vertical axis is the scale for the amplitude ratio in decibels. Two plots of amplitude ratio are provided, one based on actual data and the other based on the Model type. The right vertical axis is the scale for phase angle in degrees. Two plots of the phase angle are provided, one based on actual data and the other based on the Model type. The amplitude ratio and phase angle are plotted against frequency in radians/time (logarithmic scale) on the horizontal axis. The lines are color coded. The process frequencies most important to process control are those between about minus 90 and minus 180 degrees of phase. In Process Frequency Response plots for first order time constants, the corner frequency (or cut-off frequency) is where the amplitude ratio starts to turn and the phase lag equals 45 degrees. Consider a sine wave input to a process at this corner frequency. The output of a first order process has half the input power at the corner frequency. A lag time or first order time constant of 10 has a corner frequency of 1/10. A PID controller with an integral time of 10 also has a corner frequency of 1/10. A PID controller with a derivative time of 10 has a corner frequency of 1/10; however, for derivative, this represents a phase lead of 45 degrees rather than phase lag.
77
To find these frequencies: 1. Look at the red scale on the right of the plot. Locate 90 and 180. 2. Find the stretch of the red phase angle line between 90 and 180. These are the most important phases. 3. See where the 90 and 180 phase points line up vertically with the blue amplitude ratio line. These are the most important amplitude ratios. The Process Frequency Response plot is based on process data only, and therefore does not update if the PID tuning changes. It only updates when the Model changes. This can happen if you change the model type, or if you zoom in to a different bump in the Time data window. The Options menu on the Process Frequency Response window allows you to: Display the plot in Radians/sec. This is the default. Display the plot in Cycles/sec. Show High Frequencies. With this option checked, RSTune shows amplitude ratio and phases for frequencies with phases lower than 270 degrees.
Load Plot
The Load plot shows a simulation of a process upset. RSTune applies a step load change to the simulation. This is the first plot displayed if you selected Load Tuning on the Faceplate. If it is not displayed, you can select it using Options > Load plot.
79
This example shows the response to a process upset. The upper portion of the window shows the process variable response and the lower portion shows the controller output response.
Robustness Plot
The RSTune Robustness plot shows how sensitive your loop is to process gain or process deadtime changes. The Robustness plot graphically shows the tradeoff between tight tuning and stability. If you have two sets of tuning parameters with about the same robustness, you can generally choose the faster response. An example Robustness plot is shown here.
New Current
Safety factor area. The plots should be outside of this region (above and to the right)
The two axes of the plot are process gain and dead time. The plot has a region of stability and a region of instability. The red (new tuning parameters) and blue (current tuning parameters) lines on the robustness plot are the limit
80
of stability. To the right and above the lines, the closed loop process is unstable. To the left and below the lines, the closed loop system is stable. The crosshairs in the safety factor area are at the actual process gain and deadtime. Generally, a safety factor or divisor of 2 is reasonable for a control loop. For practical system stability, keep the limit of stability line outside the safety factor area. For example, in the Robustness plot shown above, the line for the current tuning parameters is inside the safety factor area. These parameters offer very tight tuning, but if the system encounters a high gain ratio, it will be in the region of instability. The line representing the new tuning parameters is well outside the safety factor area, offering more stability. Robustness plots are calculated using the Process Model and controller tuning values. The accuracy of the plot depends on the accuracy of the model. Whenever you choose a different model in the Process Model window, the Robustness plot refreshes. This plot also updates when a new Safety Factor value is entered on the faceplate. RSTune conservatively estimates process dead time when dead time gets close to the sample interval. If your plant has very small dead time, the model appears less stable and the verge of stability lines is lower. The simulations (which use the model) also appear less stable than your plant.
DEAD TIME
You can display the Robustness plot with axes of gain and deadtime. To display this plot, right-click the plot and select Actual Gain and Dead Time. This plot is displayed by default. GAIN
AND
This changes the plot to show Dead Time Ratio and Gain Ratio. To display this plot, rightclick the plot and select Use Gain and Dead Time Ratio.
81
At the cross, where both ratios are 1, the process gain and deadtime are at the process values you tuned for. ROBUSTNESS INCREASE
AND
CLOSEST DISTANCE
These options assign a numerical value to the robustness. They are displayed at the top right of the plot. Closest Distance is only available if Gain and Dead Time Ratio is selected. This allows you to scroll through the values for Robustness Increase and the Closest Distance for the new and current parameters. The Robustness Increase is the percent that the robustness improves with the new tuning. It is based on comparing the Closest Distance of the new and current tuning. If the loop is less robust with the new tuning, the Robustness Increase will be negative. The Closest Distance is the closest that the robustness line comes to the crosshairs in the safety factor area. This gives a conservative relative measure of the robustness of the loop.
82
OPC Topics
RSTune requires an OPC or a DDE topic for each control loop you need to communicate with. See DDE Topics for information on working with DDE topics.
83
1784-KT 10
PLC-5 50
In this process, you might want to monitor: Various addresses in the processor every five seconds to update a Microsoft Excel chart PID addresses in the processor every one second for use with RSTune In both cases, you could be reading data from several different data files or a single large data file. It might be helpful to concentrate your data in a single data file, since this improves the efficiency of the communications and lowers overall network traffic. To monitor these addresses, you would create two topics: 1. One that polls the processor once every five seconds to read data from the PLC-5 every five seconds (for Excel). 2. Another to poll data from the processor once every second to read data from the PLC-5 every second (for RSTune). Usually, when working with RSTune, you will just set up one topic for each PLC. To keep things simple, use the PLC name as the topic name.
84
9 OPC Topics
85
86
10 DDE Topics
RSTune requires a DDE or OPC topic for each control loop you need to communicate with. See OPC Topics for information on using OPC topics.
87
1784-KT 10
PLC-5 50
In this process, you might want to monitor: Various addresses in the processor every five seconds to update a Microsoft Excel chart PID addresses in the processor every one second for use with RSTune In both cases, you could be reading data from several different data files or a single large data file. It might be helpful to concentrate your data in a single data file, since this improves the efficiency of the communications and lowers overall network traffic. To monitor these addresses, you would create two topics: 1. One that polls the processor once every five seconds to read data from the PLC-5 every five seconds (for Excel). 2. Another to poll data from the processor once every second to read data from the PLC5 every second (for RSTune). Usually, when working with RSTune, you will just set up one topic for each PLC. To keep things simple, use the PLC name as the topic name.
88
10 DDE Topics
89
90
11 Application Notes
This chapter contains examples of data collection, diagnostics for various types of conditions, and explanations of handling problem loops when using RSTune. Data Collection Methods Examples of Data Editing Integrating (Non-Self-Regulating) Loops Temperature Control of Extruders Cascading Loops See also Guidelines for Optimizing Loops.
91
3. Let the loop settle out (reach steady state). You should allow for at least 30 samples of steady state before continuing. 4. Select Archive > Archive On. 5. Change the controller output by about 10%. 6. Wait for the process variable to respond an appreciable amount. Change the output to its original value. Skip this step if your plant can tolerate a new operating point. 7. Let the loop settle out (reach steady state). You should allow for at least 30 samples of steady state before continuing. 8. Select Archive > Archive off.
92
11 Application Notes
The data collected in these two graphs was collected from the same loop, except the one on the right included a step change. In this case, the doublet pulse saved 25 minutes.
93
For information on the Average function, see Averaging Data. Sometimes data requires multiple editing steps to have optimal data for tuning. The next example demonstrates this situation.
94
11 Application Notes
To optimize the data, you should: 1. Zoom in on the data as shown in the highlighted area. 2. Use Edit > Line Edit to edit out noise spikes. The zooming, editing and averaging in this example would look like:
When you edit out the noise spikes, the actual range of movement for the process variable and the controller output can now be seen more easily on the Time data window graphs. This data allows RSTune to calculate optimal tuning parameters.
95
This process responds faster in the positive (increasing) direction than it does in the negative (decreasing) direction. To find the optimal tuning parameters for this data: 1. Zoom in on the data when it is increasing. 2. Make your desired controller tuning selections. 3. Note the new tuning parameters calculated by RSTune. 4. Zoom out on the data to return it to its original form. 5. Zoom in on the data when it is decreasing. 6. Make your desired controller tuning selections. 7. Note the new tuning parameters calculated by RSTune. 8. Compare the two sets of tuning parameters, and use the more conservative values. The more conservative values will have the smaller gain, smaller derivative, and smaller integral (if rep/time) or larger integral if sec/repeat.
96
11 Application Notes
Composition and temperature on distillation columns Composition and temperature on stirred tank chemical reactors Temperature on extruders Some gas pressure loops Digital blending systems that are controlling volume RSTune provides optimal tuning for integrating loops. Collect data for an integrating loop in: Manual mode using the method described in Controller in Manual (Fast Plant Test). The loop must start and end with PV and CO at steady state. Auto mode using any of the methods described. The loop must start and end with PV and CO at steady state. The Fast Plant Test in Auto works quite well on integrating processes. If you are approaching a new loop or the loop is cycling, we suggest using proportional only control when you collect data. Set the proportional gain to a value such as 0.5 to give stable control. Use no integral action. The loop settles faster when performing the test if no integral action is used. If your controller uses integral in time/rep, set the integral to a large number. If your controller uses integral in rep/time, set the integral to zero.
To omit integral action, if your controller uses integral in: Time/rep: Set the integral to a large number. Rep/time: Set the integral to zero.
97
To collect data for this type of loop in Auto mode: Possible initial setting: Proportional value of about 80, or gain of 1.25 Possible initial setting: Derivative value of about 1 min Do the step test with no integral action in the controller. The loop settles faster. Leave derivative action in.
To omit integral action, if your controller uses integral in: Time/rep: Set the integral to a large number. Rep/time: Set the integral to zero.
Cascading Loops
In cascading loops, the output of one control loop (or controller) manipulates the set point of another. Using a cascade design can greatly improve performance of the control system when the process can be split into separate control levels. A typical application of a cascading loop is trying to control the level of a liquid in a vessel. The master loop measures the liquid level in the vessel, compares it to a set point, and calculates a new output command. This output command becomes the new set point for the slave controller, which measures the flow, compares it to the set point sent by the master, and then adjusts the flow rate, maintaining the desired level in the vessel.
Level Transmitter
FT
98
11 Application Notes
99
100
101
DEAD
BAND
PLC-5 processors allow you to set a dead band range in which the controller output will not respond to the error. We recommend that you do not use a dead band as it can cause cycling. DERIVATIVE
GAIN
If you are using a PLC-5 processor with firmware Series/Rev earlier than B/M, C/L, D/C, or E/A and derivative gain, be aware that switching from manual to auto might cause a spike in the output of the controller. To avoid the spike, set D (derivative gain) to zero, switch to auto mode, then set D to the desired value. The following equations describe the output spike (D is the derivative value and T is the loop update time). If D is on error:
D Output spike = [ ( error now ) ( error when you switched mode ) ] --T
If D is on PV:
ControlLogix Processors
We recommend you use PID with the dependent gains and derivative calculation on PV.
102
Enter the Control Block (CB) address of the PID instruction in the same format as when you programmed the PID instruction. The Control Block is a file that stores PID status and control bits, constants, variables, and internally used parameters. The Control Block type (integer or PD) affects how you should program the logic to execute the PID instruction. See the Allen-Bradley PLC -5 Instruction Set Reference Manual for examples. INTEGER
CONTROL
Integer control requires a false to true rung transition to execute. This Integer PID operation is called a rung transitional execution. Integer control uses 23 consecutive elements of data table memory per PID instruction. One integer element equals one word of data table memory. For example, if you use N10:0 as your control address, elements N10:0 through N10:22 are reserved for the PID instruction.
Use caution to avoid accidentally overwriting these reserved addresses.
If the PV goes from 4095 to 4096, the instruction sees zero for the PV. If the PV goes from 0 to 1, the PID instruction sees 4095 for the PV.
PD
CONTROL
PD control executes as long as the rung is true. PD control does not require a false to true transition. This PD PID operation is called a rung conditional execution. PD control uses one element of data table memory per PID instruction. One PD element equals 82 words of data table memory. For example, if you use PD10:0 as your control address, your next available address is PD10:1. Use the done bit of a timer to execute the PID block; do not use a block transfer.
103
instruction. Enter the address in the same format as when you programmed the PID instruction. Sample ladder logic shown below.
This is the value to enter.
PV or SP Engineering Units
These are the units displayed by the AutoTune sequence when it asks for a set point change. These are for your display purposes only. The suggested PV engineering units are:
PLC-5 PD file type: The PV Engineering units should match the Engineering Units min/max boxes in the PID instruction. PLC-5 integer file type: If set point scaling is on, the PV Engineering units should
match the scaled engineering units. If set point scaling is off, the PV Engineering units should be unscaled units.
SLC 500: If set point scaling is on, the PV Engineering units should match the scaled engineering units. If set point scaling is off, they should be unscaled units. ControlLogix 5550 PID type: The PV Engineering units should match the
104
Activation
Rockwell Software products are copy-protected. Only a computer with access to the activation key can run the software. The key is located in an activation file, which is located on the master disk supplied with the program. The activation file contains one activation key per product. Each key contains one or more licenses, depending on how many copies of the product you purchased.
Store your master disk in a safe place. If your activation becomes damaged, the master disk might be the only means to run your software in an emergency.
To avoid damaging your activation files, do not perform the following operations with activation files on the hard drive: Restore from backup Upgrade the operating system Reinstall the same version of the operating system Uninstall the operating system Compress or uncompress the hard drive
105
Turn off Windows for Workgroups 32-bit file access. If activation files were moved to a hard drive with 32-bit file access on, turning off 32-bit file access results in activation files being lost. You can turn on 32-bit disk access and 32-bit file access in Windows for Workgroups without harming the activation file. Defragmentation utilities will not harm activation files. Before running any type of utility that might modify the structure or organization of the hard drive, remove activation from the hard drive. 1. Use the Move Activation utility (EvMove) to move activation files from the hard drive to an activation disk. You can run EvMove.exe from your Master Disk or your hard drive (EvMove.exe is typically located in c:\Program Files\Rockwell Software\Rsutil). 2. Perform the hard disk operation. 3. Move the activation files back to the hard drive.
You must use the move utility, EvMove, to move activation files. Attempts to copy, move or email an activation file by other means will damage the file.
106
A Activation
files are typically in c:\Program Files\Rockwell Software\Rsutil). You can run these programs with one of these methods: Start > Run Start > Programs > Rockwell Software > Utilities > Move Activation or Reset Activation
107
I accidentally deleted the software directory on my hard disk. Do I need to call Rockwell Software for replacement activation files? No. Deleting the program files does not delete your activation. The activation files are not stored in the program directory; they are located in the root directory. Your activation files wont be lost unless you format the hard disk, tamper with hidden files in the root directory, or perform certain other hard disk operations (see Protecting Your Activation Files). To get the software running again, reinstall the software but do not move the activation when given the opportunity. Why cant I move activation to a floppy disk on a Windows NT system? It has to do with a disk modification that NT does not allow. If you have access to a Windows 95, 98 or 2000 computer, you can create a disk that will work under NT. Format a floppy disk and move any activation file to it under Windows 95, 98 or 2000. (You can move the activation back off the disk if you want to keep it where it was.) Use that disk with your Windows NT computer and move the activation to it.
108
Supplemental Reading
These Rockwell Software materials might be useful when setting up and using RSTune.
For more information on: RSLinx See: RSLinx Getting Results Guide or online help
Online Help
RSTune includes online help, a tutorial, and optimization steps that provide general overview information, comprehensive step-by-step procedures, and context-sensitive control definitions. To view online help while using RSTune: Choose Help > Contents or Help > Search for Help on from the main window or Faceplate and Trend window Click the Help button in dialog boxes Move the cursor to the box, button, or item you want help with and press F1 The tutorial guides you through the basics of using RSTune. It is available from the main RSTune window. To use the Tutorial, select Tutorial > Tutorial. The optimization steps provide detailed information on optimizing your loop. It is available through the Faceplate and Trend window. To use the optimization steps, select Help > Optimization Steps.
109
Online Books
In RSTune, the Online Books feature allows you to immediately access and search the product documentation for RSTune from the Help menu. This feature contains the Users Guide in electronic book format. From the main window, open the Users Guide by selecting Help > Online Books.
110
Glossary
Activation disk
Any disk (floppy or hard) containing an activation file. An activation disk can be used to activate the software. This is different than a key disk (Master Disk) in that at least one license of the software must be available on the activation disk to activate the software.
Activation file
A hidden read-only system file that activates a Rockwell Software product. The software will run properly only if your system can find the correct activation file.
Activation key
Activation files contain a database of activation keys. Each key is particular to a certain product and must be accessible on a local or remote drive for that product to run.
Archiving
The action of saving data collected from a particular control loop to the hard drive. This data file is saved to the same directory as your control loop (.tun) file.
Auto mode
In Auto mode, the controller or processor automatically controls the output commands based on its program. This is a closed loop.
AutoTune
The RSTune AutoTune sequence automates the process of collecting data for PID tuning. Answer the questions to the RSTune AutoTune sequence and RSTune finds optimal tuning for your loop.
Averaging filter
The averaging filter is a moving average filter every sample interval it gives the average of the previous time constant of values. The effect of the time constant is about half that of the first order filter. To get the equivalent first order time, use an averaging filter with an averaging window length of twice a first order constant. The averaging filter is a good filter for reducing frequencies of noise occurring at the filter time. If you have a specific frequency you want to remove, setting the average filter time equal to the period of that noise should completely remove it (period is the inverse of frequency). In general, it is not as good as the butterworth at higher frequencies.
Butterworth filter
111
Cascading loops
The output of one control loop manipulates the set point of another control loop. Includes a master loop and a slave loop(s).
Closed loop
A control loop with feedback. The process variable is compared to a set point and a new output command is sent. This occurs with the controller in the Auto mode.
Control Block
A file that stores PID status and control bits, constants, variables, and internally used parameters. The Control Block type affects how you should program the logic to execute the PID instruction.
Controller gain
The ratio of a change in the output to a change in either the controlled variable or the set point.
Controller output
The current output command of the controller. It is sometimes referred to as the Controlled Variable.
Cycling (oscillating)
A condition in a control loop where the process variable does not settle out at set point, but continues to change, often going both above and below set point.
DDE
Dynamic Data Exchange. A method of transferring data from one Windows application to another. For example, RSLinx uses DDE to provide PLC data to RSTune.
Dead band
A user-specified range above and below the set point where controller output does not respond to the error. The dead band lets you control how closely the process variable matches the set point without changing the output. We recommend that you refrain from using dead band as it can cause cycling.
Dead time
The amount of time that occurs before the process variable moves appreciably after the controller output changes.
Derivative gain
Causes the change in controller output to be proportional to the change in the rate-ofchange of the error; also called rate.
Disturbance
An undesired change in a variable applied to a system which tends to affect adversely the value of a controlled variable.
112
C Glossary
Disturbance, cyclic
In a control loop, the difference between the set point and the process variable.
Filtering
The most commonly used filter. Also called a first order lag. You can implement it with the equation:
A process whose describing differential equation is a first order equation. The time constant for a first order process is called lag time.
Frequency response plot
If you introduce a sine wave into a linear process, the output of the process is also a sine wave. However, the output might not be the same size and might be shifted in time relative to the input. The relative size of the output sine wave compared to the input is called the dynamic process gain or amplitude ratio and the amount of time shift is called the phase. A different sine wave frequency introduced in your process might give a different amplitude ratio and phase. If you tried this for a broad range of different sine wave frequencies, you would get a spectrum of amplitude ratio and phase data at each frequency from which a frequency plot like the one in RSTune could be made.
Gain
See Controller gain, Derivative gain, Integral gain, Process gain, Proportional gain.
Hysteresis
Performance of a loop is judged by how closely the controlled variable is held to the set point, both for set point changes and load changes. There are many mathematical ways of judging this, and IAE is one type. IAE is a measure of controller error defined by the integral of the absolute value of a time dependent error function.
Improvement Indices
See valve travel index, valve reversal index and Robustness Increase.
113
Integral gain
Causes the change in controller output to be proportional to the amount of time the error is present; also called reset.
Integrator
If a process settles out after being given a step change it is called self-regulating. If it does not, it is called non-self-regulating or integrating. This is much like the integral action of a controller, which keeps going if the error remains. An integrating process can take a long time to (or might never) reach steady state (settle out) after a manual step change in the controller output.
Interval (sample interval)
The time in seconds that RSTune uses to collect data. This sample interval is also used to update the trend and bar graphs.
Key disk
A floppy disk that can be used to activate the software even if that disk contains zero licenses. The Master Disk is the only key disk. This differs from an activation disk in that an activation disk must contain at least one license.
Lag
The effect of something happening after a change occurs. For example, the valve moves after the command is sent. The amount of lag time varies depending on the system equipment and design.
Lag time
The amount of time after the dead time that the process variable takes to move 63.3% of its final value after a step change in valve position. Lag time is the time constant for a first order process.
Lambda
Authorization to use a specified number of instances of software. A products activation key contains a license for each copy of the software you have purchased. For example, if you bought seven copies of RSLogix 5, the RSLogix 5 key on the Master Disk contains seven licenses of RSLogix 5. You can move the activation file for RSLogix 5 to seven different computers.
Linear
The type of relationship that exists between two variables when the ratio of one variable to the corresponding value of the other is constant over the entire range of possible values.
114
C Glossary
Load change
In a control loop, a change occurring other than a set point change, that causes a disturbance in the system. For example, in a temperature loop, more people coming into a room would raise the room temperature causing the loop to respond.
Load tuning
Provides PI and PID tuning parameters optimized for load changes at the controller output. Load changes are the most difficult disturbances for the system to control, but they are also the most common.
Load upset
The mode of the controller where the output command is under the control of the operator, and not the control loop. This is an open loop.
Master Disk
This disk is supplied with the software. It contains a database of keys in an activation file that enables the software to run. Be sure to store your Master Disk in a safe place. If your activation file becomes damaged, the only way you can run your software (until the activation is reset) is with your Master Disk.
Modeling
A mathematical approximation of the control loop. It is based on actual data and loop response. The model can then be used for testing the response of the loop with different tuning parameters and under different conditions.
Noise
Unwanted spikes or disturbances in the system. Noise could be seen on an active transmitter measuring temperature, if for example, the transmitter was subjected to electrical noise from nearby contactors or similar equipment. Noise should be edited out of data that is to be used to calculate tuning parameters. See also Normal process noise.
Noiseband
When performing a hysteresis check, the amount of noise as a percent of the process variable range. More than 2% might be an indication that filtering should be used.
Normal process noise
Minor variations in the process variable (PV) that are not caused by the loops control. Normal process noise can come from sources such as electrical interference, magnetic fields, turbulence in flow loops, or waves in a tank in level loops.
115
Offset
In a proportional only control loop, the difference between the set point and the settled out value of the process variable.
Open loop
A control loop without feedback. The controller does not send new output commands. The operator can change the output command. Occurs with the controller in the Manual mode.
Overshoot
If a process variable is responding to a new set point or to a load change, and initially goes beyond (above or below) the goal, it is known as overshoot.
Power Spectral Density
Useful for seeing the potential improvement from better tuning. Shows the relative power in the signal at various frequencies ranging from twice the sample time to twice the data collection period.
Process gain
The steady state ratio of the output of a process to a change in its input.
Process upset
An upset that is not from changing the set point. A process upset is something that causes your process variable to deviate from set point when you were running at steady state. An example in a flow loop would be a change in downstream pressure. In a level loop controlled by outflow, an increase in inflow would be an upset.
Process variable
The variable that the control loop is trying to control. It is used as feedback for the loop.
Proportional gain
A control loop response in which the size (amplitude) of the overshoot or undershoot of each successive cycle is one fourth the size of the previous cycle is called quarter amplitude damping.
Rangeability
Any valve has a rangeability factor that determines how precisely it will regulate. A good control valve might have a rangeability of 100 to 1, which means that you can make 1% adjustments in the output. The valve can also be referred to as having a resolution of 1%.
Rate
116
C Glossary
A relative indicator of the speed of the control loop. The smaller the relative response, the faster the loop. The higher the relative response value, the slower the loop. Use this number for comparison purposes. The Relative Response Time is dependant on the speed of response: you can change it by adjusting the safety factor or lambda time.
Remote Computer
The remote computer name is only visible when RSTune is using OPC communications with the Server. The computer name is not entered when RSTune is using DDE communications. Remote connection requires RSLinx or ProcessLogix Gateway.
Reset
The number of times the valve has changed direction in CO showing in the time graph.
Robustness
An indication of how sensitive your loop is to process gain or process deadtime changes. A very robust loop tends to remain stable under most conditions. It is not very sensitive, however, and might respond slowly or not hold control tightly to normal changes. The Robustness plot graphically shows the tradeoff between tight tuning and stability. See also Sensitivity.
Safety factor
Controls sensitivity when using Load type tuning. The setting can be between 1 and 5. A setting of 1 means the tuning is very sensitive to small changes in the process but could become unstable if subjected to large or sudden load changes. A safety factor of 2.5 gives you moderate tuning; the loop will respond somewhat slower but is more stable when subjected to large or sudden load changes. A safety factor of 5 gives you very conservative tuning.
117
This is a high performance second order filter. It is a good filter to eliminate noise, since it causes the least amount of phase addition for the most amount of noise reduction compared to other filters. You can implement it with this equation:
v1 + SampleInterval ( PV PVf1 ) v = ------------------------------------------------------------------------------Tau + SampleInterval PVf1 + 2 SampleInterval ( v PVf1 ) PVf = ----------------------------------------------------------------------------------------Tau + 2 SampleInterval
Second order filter
The second order filter uses half your time constant in each of two cascaded first order filters. This results in an overall time constant equivalent to a first order one.
Sensitivity
An indication of how quickly a control loop can respond to load or set point changes. A loop that can respond very quickly or hold control very tightly is less robust. If it is subjected to sudden large changes it might not be able to react without going unstable.
Server
RSTune uses RSLinx or the ProcessLogix OPC server as the server for communications to the controller. The link between RSTune and the server can be either DDE or OPC. RSLinx version 1 use a DDE link. RSLinx version 2 or later and ProcessLogix use an OPC link.
Set point
Used to match the set point response to a first order time constant (or lag time) that you enter. System response is first delayed by the process dead time. This method is popular in the paper industry on some loops when operators want no overshoot. A variation of this tuning is known as lambda tuning.
Settled out
Simulation of a control loop is accomplished by using a model of the loop based on actual data collected from the loop. The model can be used to simulate how the loop will react under different tuning parameters or conditions.
118
C Glossary
Steady state
The condition when both the process variable and controller output are relatively flat horizontal lines in the Trend display, moving within the range of normal process noise. A process variable or controller output that is ramping or in a transient condition is not steady state. The process variable does not have to be at set point.
Step change
A change of the set point or controller output from one steady state value to another.
Step test
A change made to the set point or controller output in order to analyze the response of the control loop.
Stiction
The word stiction is derived from the words stick and friction. It is the resistance to the start of motion. Stiction or stick-slip occurs because of tight packing, undersized actuators, or corroded stems. Sticking at the seat is very common especially for valves designed for tight shutoff.
Time constant
For a first order lag filter, the time constant is the time to reach 63.2% of the final value in response to a step change.
Travel
The total distance the valve has traveled in the CO showing in the time graph.
Valve characteristic
The type of response a valve has to a command is its characteristic. It is a function of the valve plug design. The correct characteristic should be chosen for the specific application.
Valve sizing
Choosing a valve to have the proper range and flow characteristics for a specific application.
Valve travel index
The percent improvement in the controller output travel from the current to new. If the new PID tuning parameters (and filter) result in more travel than the current ones, the Valve Travel index will be negative.
Valve reversal Index
The percent improvement in controller output reversals from the current to new. If the new PID tuning parameters (and filter) result in more reversals than the current ones, the Valve Reversal Index will be negative.
Verify
The process of using the Time data window to confirm that the control loop data collected is optimal for calculating tuning parameters.
119
120
Index
A
activate archiving 27 activation damaged 107 different computers 106 disk 111 trouble creating 108 file 105, 111 from disk drive 106 from hard drive 106 key 105, 111 moving 106 online help 107 over network 107 protecting 105 reset 106, 107 searching drives for 107 troubleshooting 107 analysis windows 73 Process Frequency Response Plot 76 Process Model 74 robustness plot 80 archive 35, 50, 111 accessing 51 creating 14 delete 51 deleting 51 notes 52 run from 51 tune from 35 archiving turning on 27 ASCII, copy to 52 Auto mode 45, 48, 111 auto zoom 62 AutoTune 36, 45, 111 average 63, 94 filter 111 Bode plot 76 Bring Back Previous PID Settings to New 55 bump test see step test 111 Butterworth filter (second order) 118
C
calculating tuning parameters 59 cascade loop 98, 112 collect data 99 change PID parameters 54 CHECKDRIVES 105, 107 closed loop see auto mode test 48, 92 collect data 45 cascade loop 99 manual 48, 91 color, trend line 29 communications debugging 34 testing 15 configure DDE topic 14 loop 9, 10 control block 112 address 102 control loop 112 setup window 10 simulation 78 simulation plot load 79 load upset 80 setpoint 79 control, PI 20 controlled variable 25, 103 controller change mode 33 gain 112 in auto
B
bargraph display 27
vii
Closed Loop 92 Manual Step Test 92 in manual fast plant test 93 Open Loop 91 output 19, 112 changing on faceplate 33 tuning 22, 60, 61 offline 61 optimal parameters 60 ControlLogix 5550 processor 1, 102 copy protection see activation 105 copy to ASCII 52 corner frequency 77 cut-off frequency 77 CV address 103 cycling 63, 112 example 95
DDE Topic 14 loop 15 derivative 20 gain 17, 20, 61, 102, 112 selecting 61 display spans 29 disturbance 112 download 55 PID parameters 54
E
edit, data 94 engineering span 29 engineering units 11, 104 environment variable CHECKDRIVES 105 KEYDISK 107 equivalent dead time 49 error 17, 113 example cycling and noisy data 95 noisy data 94 PID loop 18 plant test 94 process responds faster in one direction 96 expand control loop simulation 79 extra trend 41 setting up 41 extruders 97 temperature control 97
D
damaged activation 107 data 63 archive 35, 50, 51 accessing 51 archive, deleting 51 collecting 45, 91 manually 91 edit 61, 94 pairs 49 points 49 requirements 45, 48, 49 verify 66 viewing 62 Data Spy 34 DDE 87, 112 topic 7, 8 create 14 topic configuration 14 dead band 102, 112 dead time 112 debug, communications 34 decimal places 29 delete archive 51
F
faceplate 3, 25, 35 and trend window 25 bargraph display 27 features 1 files, delete archive 51 filter 113 average 111 first order 113 second order 118 Butterworth 118 time constant 65
viii
INDEX
first order 74, 113 filter 113 frequency response 21, 76, 113
G
gain 20 controller 112 derivative 17, 61, 102, 112 integral 17, 20, 114 process 70, 74, 116 proportional 17, 19, 116 graph changing type (Time data window) 58
H
hysteresis 68, 113 notes 70 performing check 68
I
IAE 68 see integrated absolute error 113 information, additional 109 initialization error, RSLinx 15 installation 7, 8 integer control 103 integral gain 17, 20, 114 integrated absolute error. 113 integrating loops 76, 96 integrator 114 interval 114 sample 49
license 105, 114 line color 29 line edit 64 load changes 19, 115 plot 79 tuning 22, 115 no overshoot 22 selecting 61 types 22 loop adding 9 cascade 98 configure 9 creating 9 edit 14 integrating 76, 96 new 9 notes 36, 52 problem 4 setup parameters 10, 102 editing 14 PID instruction addresses 12, 102 processor type 101, 102 PV engineering units 11 RSLinx topic 11, 83, 87 sample interval 11
M
main window 9 manual mode 115 manual step test controller in auto 92 master disk 115 activating with 107 mode changing controller 33 modeling 115 moving activation 106 RSBizWare Batch modules 106
K
key disk 107, 114 KEYDISK environment variable 107
L
ladder logic 101 lag 114 time 114 lambda tuning 23, 118
N
new loop 9 New Platform PLC-5 9, 101
ix
noise 115 spikes 64 noiseband 115 noisy data 63 example 94, 95 normal process noise 115 note archive 52 loop 52
O
Off Line Analysis and PID Tuning window 45, 51 Off-line Analysis and PID Tuning window 39 Offline button 50 off-line tuning 39 offline tuning 45, 61 offset 116 online books 110 online help 109 activation 107 OPC 83 open loop 116 see manual mode step test 91 test 91 operating system requirements 2 optimize loops 4 order first 74 second 74 overshoot 19, 22, 116
P
parameter calculating tuning 59 displays 29 PD control 103 PD file type 9, 101 PID 17, 20 change parameters manually 54 download parameters 54 grid 61 instruction addresses 12
instruction reference 101 loop example 18 tuning 51 plant test 91 examples 94 PLC-5, New Platform 9, 101 plot load 79 robustness 80 Power Spectral Density 116 probable performance increase 60 problem loops 4 process gain 70, 74 noise, normal 115 upset 46, 48, 116 variable 18, 116 variable address 104 Process Frequency Response Plot 76 process gain 116 Process Model 74 Start Simulator 37 types 76 window 74 ProcessLogix set up 10 proportional gain 17, 19, 116 only control 19 plus integral control 20 plus integral plus derivative 20 PV address 104 engineering units 11 PV engineering units 11
Q
quarter amplitude damping 116 quick start procedure 3
R
range, see span rangeability 116 real time trend display 26
INDEX
report add to 71 create 39 edit 40, 41 macros 40 open 40 print 41 save 40 tuning 39 requirements, operating system 2 reset activation 106, 107 resolution 117 Reversals 117 robustness 117 plot 80 Rockwell Software, contacting 110 RSBizWare Batch modules moving 106 RSLINX initialization error 15 RSLinx 2, 7, 11, 83, 87 topic 10, 11 setup 11 RSTune installing 8 setup window 10 starting 9 theory 21 run RSTune 9
S
safety factor 61, 81, 117 sample interval 11, 49, 114 Save As (setup window) 14 saving changes, Time data window 65 scale Y-axis, Time data window 58 second order 74 Butterworth filter 118 filter 118 sensitivity 118 see robustness plot 80 set up ProcessLogix 10 setpoint 18, 118 changing on faceplate 33 plot 79
tuning 23, 118 selecting 61 settled out see steady state 45 setup parameters editing 14 setup PV engineering units 11 setup window control loop 10 opening 14 options gray 14 RSTune 10 shrink control loop simulation 79 Simulate window 36 simulation 118 sample loop 25 simulator 37 span display 29 engineering 29 spikes 64 stability, checking with robustness plot 80 start RSTune 9 statistical analysis 66 steady state 45, 119 step change 119 step test 119 open loop (manual) 91 stiction 119 supplemental reading 109 support, technical 110
T
technical support services 110 temperature control of extruders 97 test communications 15 plant 91 step, open loop 91 theory, RSTune 21 thick lines (Time data window) 58 time constant 119 filter 65 Time data window 48, 57 add data to report 71
xi
auto zoom 62 changing graph type 58 saving changes 65 scale Y-axis 58 zoom 62 topic configuration 14 create 14 DDE 7, 8 delete 14 edit 14 RSLinx 10 transmitter span too large 70 too small 71 Travel 119 trend 25, 35 adding 41 display 26 display, changing 29 extra 41 options 28, 29 troubleshooting 110 activation 107, 108 communications 15 tuning 3, 22, 60, 61 automatically 36 controller 60 determine optimal parameters 60 from archived data 35, 51
lambda 23 off-line 39 offline 45, 61 parameters, calculating 59 report 39 setpoint 23 turn on archiving 27
U
use derivative if possible 61
V
valve characteristics 119 oversized 70 sizing 119 undersized 70 Valve reversal Index 119 Valve travel index 119 View menu 31
W
WINtelligent LINX see also RSLinx 11
Z
zoom 62
xii
INDEX
xiii