Endress+Hauser ControlCare - Application Designer Operating Instruction
Pubblicità
Pubblicità
Operating Instructions
ControlCare Application Designer
Function Blocks
8
9
BA022S/04/en/06.10
Software Version 2.05.xx
56004886
ControlCare Application Designer: Function Blocks Table of Contents
Table of Contents
Revision History . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
Product Version . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
Registered Trademarks . . . . . . . . . . . . . . . . . . . . . . 6
1 Safety . . . . . . . . . . . . . . . . . . . . . . . . . . 7
1.1
Designated use . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
1.2
Installation, commissioning and operation . . . . . . . . 7
1.3
Operational safety . . . . . . . . . . . . . . . . . . . . . . . . . . 7
1.4
Conventions and icons . . . . . . . . . . . . . . . . . . . . . . 8
1.5
ControlCare documents . . . . . . . . . . . . . . . . . . . . . . 9
1.6
About this manual . . . . . . . . . . . . . . . . . . . . . . . . . 10
2 Function Block Application Process . 11
2.1
Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
2.2
Block objects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
2.3
Block parameters . . . . . . . . . . . . . . . . . . . . . . . . . . 13
2.3.1
Parameter types . . . . . . . . . . . . . . . . . . . . . 13
2.3.2
Parameter identifiers . . . . . . . . . . . . . . . . . 14
2.3.3
Universal parameters . . . . . . . . . . . . . . . . . 15
2.3.4
Parameters in Application Designer . . . . . 16
2.4
Block operation . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
2.4.1
Block mode parameter MODE_BLK . . . . 18
2.4.2
Block modes . . . . . . . . . . . . . . . . . . . . . . . 18
2.4.3
Mode priority . . . . . . . . . . . . . . . . . . . . . . . 20
2.4.4
Mode shedding . . . . . . . . . . . . . . . . . . . . . 22
2.5
Parameter calculation . . . . . . . . . . . . . . . . . . . . . . 23
2.5.1
Process variable PV . . . . . . . . . . . . . . . . . . 23
2.5.2
Scaling parameters XD_SCALE, PV_SCALE,
OUT_SCALE . . . . . . . . . . . . . . . . . . . . . . 24
2.5.3
Setpoint SP . . . . . . . . . . . . . . . . . . . . . . . . 26
2.5.4
Ouput variable, OUT . . . . . . . . . . . . . . . . . 27
2.5.5
Back calculation . . . . . . . . . . . . . . . . . . . . 27
2.6
Status handling . . . . . . . . . . . . . . . . . . . . . . . . . . . 28
2.6.1
Status propagation . . . . . . . . . . . . . . . . . . . 28
2.6.2
Status message . . . . . . . . . . . . . . . . . . . . . . 28
2.6.3
Substatus and limit propagation . . . . . . . . 30
2.6.4
Control loop integrity . . . . . . . . . . . . . . . . 31
2.7
Fault state handling . . . . . . . . . . . . . . . . . . . . . . . . 34
2.7.1
Control blocks . . . . . . . . . . . . . . . . . . . . . . 34
2.7.2
Output blocks . . . . . . . . . . . . . . . . . . . . . . 34
2.7.3
Forcing fault state . . . . . . . . . . . . . . . . . . . 35
2.8
Function block options . . . . . . . . . . . . . . . . . . . . . 36
2.8.1
GRANT_DENY . . . . . . . . . . . . . . . . . . . . 36
2.8.2
IO_OPTS . . . . . . . . . . . . . . . . . . . . . . . . . . 37
2.8.3
CONTROL_OPTS . . . . . . . . . . . . . . . . . . 38
2.9
Alert handling . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39
2.9.1
Events and alarms . . . . . . . . . . . . . . . . . . . 39
2.9.2
Reporting, priority and acknowledgement 40
2.9.3
Limit alarms . . . . . . . . . . . . . . . . . . . . . . . 41
2.9.4
Event update and alarm summaries . . . . . . 42
2.9.5
Alarm display parameters . . . . . . . . . . . . . 43
2.9.6
Example . . . . . . . . . . . . . . . . . . . . . . . . . . . 44
2.10
Simulation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45
2.11
Changing function block parameters . . . . . . . . . . . 46
2.11.1 Off-line characterization . . . . . . . . . . . . . . 46
2.11.2 On-line characterization . . . . . . . . . . . . . . 47
3 Resource Block . . . . . . . . . . . . . . . . . 48
3.1
Informative parameters . . . . . . . . . . . . . . . . . . . . . 48
3.1.1
Device software . . . . . . . . . . . . . . . . . . . . . 48
3.1.2
Device hardware . . . . . . . . . . . . . . . . . . . . 49
3.1.3
Hardware write lock . . . . . . . . . . . . . . . . . 49
3.1.4
Simulation . . . . . . . . . . . . . . . . . . . . . . . . . 49
3.2
Operational parameters . . . . . . . . . . . . . . . . . . . . . 50
3.2.1
Block operation . . . . . . . . . . . . . . . . . . . . . 50
3.2.2
Resource state . . . . . . . . . . . . . . . . . . . . . . 50
3.2.3
Resource restart . . . . . . . . . . . . . . . . . . . . . 51
3.2.4
Resource options . . . . . . . . . . . . . . . . . . . . 51
3.2.5
Alert reporting . . . . . . . . . . . . . . . . . . . . . . 52
3.2.6
Software write lock . . . . . . . . . . . . . . . . . . 53
3.2.7
Block errors . . . . . . . . . . . . . . . . . . . . . . . . 53
3.3
Block parameters . . . . . . . . . . . . . . . . . . . . . . . . . . 54
4 Transducer Blocks . . . . . . . . . . . . . . 56
4.1
Hardware Configuration block . . . . . . . . . . . . . . . . 57
4.1.1
Block configuration . . . . . . . . . . . . . . . . . . 57
4.1.2
Block errors . . . . . . . . . . . . . . . . . . . . . . . . 58
4.1.3
Block parameters . . . . . . . . . . . . . . . . . . . . 58
4.2
Temperature Transducer block . . . . . . . . . . . . . . . . 59
4.2.1
Block configuration . . . . . . . . . . . . . . . . . . 59
4.2.2
Block errors . . . . . . . . . . . . . . . . . . . . . . . . 59
4.2.3
Block parameters . . . . . . . . . . . . . . . . . . . . 60
4.3
Device transducer blocks (Endress+Hauser) . . . . . . 61
4.3.1
Block configuration . . . . . . . . . . . . . . . . . . 62
4.3.2
Block parameters . . . . . . . . . . . . . . . . . . . . 62
4.4
Display block (DISP) . . . . . . . . . . . . . . . . . . . . . . . 63
4.4.1
Block configuration . . . . . . . . . . . . . . . . . . 63
4.4.2
Block parameters . . . . . . . . . . . . . . . . . . . . 63
4.5
Diagnosis block (DIAG) . . . . . . . . . . . . . . . . . . . . . 64
4.5.1
Block configuration . . . . . . . . . . . . . . . . . . 64
4.5.2
Block parameters . . . . . . . . . . . . . . . . . . . . 64
5 Input Blocks . . . . . . . . . . . . . . . . . . . 65
5.1
CHANNEL parameter . . . . . . . . . . . . . . . . . . . . . . 65
5.2
Analog Input (AI) . . . . . . . . . . . . . . . . . . . . . . . . . . 66
5.2.1
Functional description . . . . . . . . . . . . . . . . 66
5.2.2
Block Configuration . . . . . . . . . . . . . . . . . 68
5.2.3
Block operation . . . . . . . . . . . . . . . . . . . . . 69
5.2.4
SFC445 temperature ranges (XD_SCALE) 70
5.2.5
Block parameters . . . . . . . . . . . . . . . . . . . . 71
5.3
Discrete Input (DI) . . . . . . . . . . . . . . . . . . . . . . . . . 72
5.3.1
Functional description . . . . . . . . . . . . . . . . 72
5.3.2
Block configuration . . . . . . . . . . . . . . . . . . 73
5.3.3
Block operation . . . . . . . . . . . . . . . . . . . . . 73
5.3.4
Block parameters . . . . . . . . . . . . . . . . . . . . 74
Endress+Hauser 1
Table of Contents ControlCare Application Designer: Function Blocks
5.4
Pulse Input (PULS) . . . . . . . . . . . . . . . . . . . . . . . . 75
5.4.1
Functional description . . . . . . . . . . . . . . . . 75
5.4.2
Block configuration . . . . . . . . . . . . . . . . . 76
5.4.3
Block operation . . . . . . . . . . . . . . . . . . . . . 76
5.4.4
Block parameters . . . . . . . . . . . . . . . . . . . 78
5.5
Multiple Analog Input (MAI) . . . . . . . . . . . . . . . . 79
5.5.1
Functional description . . . . . . . . . . . . . . . . 79
5.5.2
Block configuration . . . . . . . . . . . . . . . . . 79
5.5.3
Block operation . . . . . . . . . . . . . . . . . . . . . 80
5.5.4
Block parameters . . . . . . . . . . . . . . . . . . . 80
5.6
Multiple Discrete Input (MDI) . . . . . . . . . . . . . . . 81
5.6.1
Functional description . . . . . . . . . . . . . . . . 81
5.6.2
Block configuration . . . . . . . . . . . . . . . . . 81
5.6.3
Block operation . . . . . . . . . . . . . . . . . . . . . 82
5.6.4
Block parameters . . . . . . . . . . . . . . . . . . . 82
6 Control Blocks . . . . . . . . . . . . . . . . . . 83
6.1
PID Control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 83
6.1.1
Functional description . . . . . . . . . . . . . . . . 84
6.1.2
Closed-loop control . . . . . . . . . . . . . . . . . . 87
6.1.3
Feedforward control . . . . . . . . . . . . . . . . . 88
6.1.4
Cascade control . . . . . . . . . . . . . . . . . . . . . 90
6.1.5
Output tracking . . . . . . . . . . . . . . . . . . . . . 92
6.1.6
Remote cascade . . . . . . . . . . . . . . . . . . . . . 93
6.1.7
Remote output . . . . . . . . . . . . . . . . . . . . . . 95
6.1.8
Block operation . . . . . . . . . . . . . . . . . . . . . 97
6.1.9
Block parameters . . . . . . . . . . . . . . . . . . . 98
6.2
Enhanced PID Control . . . . . . . . . . . . . . . . . . . . 100
6.2.1
Bumpless transfer . . . . . . . . . . . . . . . . . . 100
6.2.2
Enhanced output tracking . . . . . . . . . . . . 101
6.2.3
Additional parameters . . . . . . . . . . . . . . . 102
6.3
Advanced PID Control . . . . . . . . . . . . . . . . . . . . 103
6.3.1
PID algorithm . . . . . . . . . . . . . . . . . . . . . 104
6.3.2
PI sampling . . . . . . . . . . . . . . . . . . . . . . . 104
6.3.3
Adaptive gain . . . . . . . . . . . . . . . . . . . . . 105
6.3.4
Anti-reset wind-up . . . . . . . . . . . . . . . . . 105
6.3.5
Special treatment for error . . . . . . . . . . . 106
6.3.6
Mode indication . . . . . . . . . . . . . . . . . . . 107
6.3.7
Additional parameters . . . . . . . . . . . . . . . 107
6.4
Step Output PID . . . . . . . . . . . . . . . . . . . . . . . . . 108
6.4.1
Functional description . . . . . . . . . . . . . . . 108
6.4.2
Block configuration . . . . . . . . . . . . . . . . 111
6.4.3
Block operation . . . . . . . . . . . . . . . . . . . . 113
6.4.4
Block parameters . . . . . . . . . . . . . . . . . . 114
7 Calculation and Logic Blocks . . . . . . 116
7.1
Arithmetic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 116
7.1.1
Range extension . . . . . . . . . . . . . . . . . . . 117
7.1.2
Calculated variables . . . . . . . . . . . . . . . . 119
7.1.3
Block operation . . . . . . . . . . . . . . . . . . . . 122
7.1.4
Block parameters . . . . . . . . . . . . . . . . . . 123
7.2
Output Splitter . . . . . . . . . . . . . . . . . . . . . . . . . . 124
7.2.1
Functional description . . . . . . . . . . . . . . . 125
7.2.2
Block configuration . . . . . . . . . . . . . . . . 127
7.2.3
Block operation . . . . . . . . . . . . . . . . . . . . 128
7.2.4
Block parameters . . . . . . . . . . . . . . . . . . 129
7.3
Signal Characterizer . . . . . . . . . . . . . . . . . . . . . . 130
7.3.1
Functional Description . . . . . . . . . . . . . . 130
7.3.2
Block configuration . . . . . . . . . . . . . . . . . 131
7.3.3
Block operation . . . . . . . . . . . . . . . . . . . . 132
7.3.4
Block parameters . . . . . . . . . . . . . . . . . . . 133
7.4
Cascade Signal Characterizer . . . . . . . . . . . . . . . 134
7.4.1
Functional Description . . . . . . . . . . . . . . 135
7.4.2
Block configuration . . . . . . . . . . . . . . . . . 136
7.4.3
Block operation . . . . . . . . . . . . . . . . . . . . 138
7.4.4
Block Errors . . . . . . . . . . . . . . . . . . . . . . 138
7.4.5
Block parameters . . . . . . . . . . . . . . . . . . . 139
7.5
Integrator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 140
7.5.1
Functional description . . . . . . . . . . . . . . . 140
7.5.2
Block configuration . . . . . . . . . . . . . . . . . 144
7.5.3
Block operation . . . . . . . . . . . . . . . . . . . . 145
7.5.4
Block parameters . . . . . . . . . . . . . . . . . . . 146
7.6
Analog Alarm . . . . . . . . . . . . . . . . . . . . . . . . . . . 148
7.6.1
Functional description . . . . . . . . . . . . . . . 148
7.6.2
Block configuration . . . . . . . . . . . . . . . . . 151
7.6.3
Block operation . . . . . . . . . . . . . . . . . . . . 153
7.6.4
Block parameters . . . . . . . . . . . . . . . . . . . 154
7.7
Enhanced Analog Alarm . . . . . . . . . . . . . . . . . . . 155
7.8
Input Selector . . . . . . . . . . . . . . . . . . . . . . . . . . . 156
7.8.1
Functional description . . . . . . . . . . . . . . . 156
7.8.2
Block configuration . . . . . . . . . . . . . . . . . 158
7.8.3
Block operation . . . . . . . . . . . . . . . . . . . . 159
7.8.4
Block parameters . . . . . . . . . . . . . . . . . . . 160
7.9
Setpoint Ramp Generator (SPG) . . . . . . . . . . . . . 161
7.9.1
Functional description . . . . . . . . . . . . . . . 161
7.9.2
Block configuration . . . . . . . . . . . . . . . . . 164
7.9.3
Block operation . . . . . . . . . . . . . . . . . . . . 166
7.9.4
Block parameters . . . . . . . . . . . . . . . . . . . 166
7.10
Enhanced Setpoint Ramp Generator . . . . . . . . . . 168
7.11
Timer and Logic . . . . . . . . . . . . . . . . . . . . . . . . . 169
7.11.1 Functional description . . . . . . . . . . . . . . . 169
7.11.2 Block configuration . . . . . . . . . . . . . . . . . 176
7.11.3 Block operation . . . . . . . . . . . . . . . . . . . . 177
7.11.4 Block parameters . . . . . . . . . . . . . . . . . . . 177
7.12
Lead-Lag . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 179
7.12.1 Functional description . . . . . . . . . . . . . . . 179
7.12.2 Block configuration . . . . . . . . . . . . . . . . . 182
7.12.3 Block operation . . . . . . . . . . . . . . . . . . . . 183
7.12.4 Block parameters . . . . . . . . . . . . . . . . . . . 183
7.13
Output Signal Selector and Dynamic Limiter . . . . 184
7.13.1 Functional description . . . . . . . . . . . . . . . 184
7.13.2 Block configuration . . . . . . . . . . . . . . . . . 186
7.13.3 Block operation . . . . . . . . . . . . . . . . . . . . 190
7.13.4 Block parameters . . . . . . . . . . . . . . . . . . . 191
7.14
Constant . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 192
7.14.1 Functional description . . . . . . . . . . . . . . . 192
7.14.2 Block configuration . . . . . . . . . . . . . . . . . 192
7.14.3 Block operation . . . . . . . . . . . . . . . . . . . . 193
7.14.4 Block parameters . . . . . . . . . . . . . . . . . . . 193
7.15
Constant and Contained RW . . . . . . . . . . . . . . . . 194
7.15.1 Functional description . . . . . . . . . . . . . . . 194
7.15.2 Block configuration . . . . . . . . . . . . . . . . . 196
7.15.3 Block operation . . . . . . . . . . . . . . . . . . . . 198
7.15.4 Block parameters . . . . . . . . . . . . . . . . . . . 199
2 Endress+Hauser
ControlCare Application Designer: Function Blocks Table of Contents
7.16
Flip-flop and Edge Trigger . . . . . . . . . . . . . . . . . . 201
7.16.1 Functional description . . . . . . . . . . . . . . . 201
7.16.2 Block configuration . . . . . . . . . . . . . . . . . 205
7.16.3 Block operation . . . . . . . . . . . . . . . . . . . . 207
7.16.4 Block parameters . . . . . . . . . . . . . . . . . . . 208
7.17
Advanced Equations . . . . . . . . . . . . . . . . . . . . . . 209
7.17.1 Functional description . . . . . . . . . . . . . . . 209
7.17.2 Block configuration . . . . . . . . . . . . . . . . . 209
7.17.3 Block operation . . . . . . . . . . . . . . . . . . . . 210
7.17.4 Block parameters . . . . . . . . . . . . . . . . . . . 210
7.18
Density . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 211
7.18.1 Functional description . . . . . . . . . . . . . . . 211
7.18.2 Block configuration . . . . . . . . . . . . . . . . . 213
7.18.3 Block operation . . . . . . . . . . . . . . . . . . . . 214
7.18.4 Block parameters . . . . . . . . . . . . . . . . . . . 215
7.19
Hybrid with Analog I/O . . . . . . . . . . . . . . . . . . . 216
7.19.1 Functional description . . . . . . . . . . . . . . . 217
7.19.2 Block operation . . . . . . . . . . . . . . . . . . . . 218
7.19.3 Block parameters . . . . . . . . . . . . . . . . . . . 218
7.20
Hybrid with Discrete I/O . . . . . . . . . . . . . . . . . . 219
7.20.1 Functional description . . . . . . . . . . . . . . . 220
7.20.2 Block operation . . . . . . . . . . . . . . . . . . . . 221
7.20.3 Block parameters . . . . . . . . . . . . . . . . . . . 221
7.21
Hybrid with Embedded I/O . . . . . . . . . . . . . . . . . 222
7.21.1 Functional description . . . . . . . . . . . . . . . 223
7.21.2 Block operation . . . . . . . . . . . . . . . . . . . . 224
7.21.3 Block parameters . . . . . . . . . . . . . . . . . . . 225
8 Output Blocks . . . . . . . . . . . . . . . . . 226
8.1
Analog Output . . . . . . . . . . . . . . . . . . . . . . . . . . 226
8.1.1
Functional description . . . . . . . . . . . . . . . 226
8.1.2
Output configuration for SFC446 . . . . . . 228
8.1.3
Block configuration . . . . . . . . . . . . . . . . . 229
8.1.4
Block operation . . . . . . . . . . . . . . . . . . . . 230
8.1.5
Block parameters . . . . . . . . . . . . . . . . . . . 231
8.2
Discrete Output . . . . . . . . . . . . . . . . . . . . . . . . . . 232
8.2.1
Functional description . . . . . . . . . . . . . . . 232
8.2.2
Output configuration for SFC428, SFC432,
SFC435, SFC438 . . . . . . . . . . . . . . . . . . . 233
8.2.3
Block configuration . . . . . . . . . . . . . . . . . 234
8.2.4
Block operation . . . . . . . . . . . . . . . . . . . . 235
8.2.5
Block parameters . . . . . . . . . . . . . . . . . . . 236
8.3
Multiple Analog Output . . . . . . . . . . . . . . . . . . . . 237
8.3.1
Functional description . . . . . . . . . . . . . . . 237
8.3.2
Block configuration . . . . . . . . . . . . . . . . . 238
8.3.3
Block operation . . . . . . . . . . . . . . . . . . . . 239
8.3.4
Block parameters . . . . . . . . . . . . . . . . . . . 240
8.4
Multiple Discrete Output . . . . . . . . . . . . . . . . . . . 241
8.4.1
Functional description . . . . . . . . . . . . . . . 241
8.4.2
Block configuration . . . . . . . . . . . . . . . . . 242
8.4.3
Block operation . . . . . . . . . . . . . . . . . . . . 242
8.4.4
Block parameters . . . . . . . . . . . . . . . . . . . 243
9 PROFIBUS Blocks . . . . . . . . . . . . . . 244
9.1
General description . . . . . . . . . . . . . . . . . . . . . . . 245
9.1.1
Accessing cyclic PROFIBUS I/O data . . 245
9.1.2
Failsafe/Fault state mechanism . . . . . . . . 246
9.1.3
Configuring PROFIBUS input and output values . . . . . . . . . . . . . . . . . . . . . . . . . . . . 247
9.2
PROFIBUS Transducer . . . . . . . . . . . . . . . . . . . . . 248
9.3
PROFIBUS Analog Input . . . . . . . . . . . . . . . . . . . 252
9.3.1
Functional description . . . . . . . . . . . . . . . 252
9.3.2
Block operation . . . . . . . . . . . . . . . . . . . . 252
9.3.3
Block parameters . . . . . . . . . . . . . . . . . . . 252
9.4
PROFIBUS Multiple Analog Input . . . . . . . . . . . . 253
9.4.1
Functional description . . . . . . . . . . . . . . . 253
9.4.2
Block Configuration . . . . . . . . . . . . . . . . 254
9.4.3
Block operation . . . . . . . . . . . . . . . . . . . . 254
9.4.4
Block parameters . . . . . . . . . . . . . . . . . . . 255
9.5
PROFIBUS Digital Input . . . . . . . . . . . . . . . . . . . . 257
9.5.1
Functional description . . . . . . . . . . . . . . . 257
9.5.2
Block operation . . . . . . . . . . . . . . . . . . . . 257
9.5.3
Block parameters . . . . . . . . . . . . . . . . . . . 257
9.6
PROFIBUS Multiple Discrete Input . . . . . . . . . . . 258
9.6.1
Functional description . . . . . . . . . . . . . . . 258
9.6.2
Block operation . . . . . . . . . . . . . . . . . . . . 258
9.6.3
Block parameters . . . . . . . . . . . . . . . . . . . 259
9.7
PROFIBUS Totalizer . . . . . . . . . . . . . . . . . . . . . . . 260
9.7.1
Functional description . . . . . . . . . . . . . . . 260
9.7.2
Block operation . . . . . . . . . . . . . . . . . . . . 261
9.7.3
Block parameters . . . . . . . . . . . . . . . . . . . 261
9.8
PROFIBUS Analog Output . . . . . . . . . . . . . . . . . . 262
9.8.1
Functional Description . . . . . . . . . . . . . . 262
9.8.2
Block configuration . . . . . . . . . . . . . . . . . 263
9.8.3
Block operation . . . . . . . . . . . . . . . . . . . . 267
9.8.4
Block parameters . . . . . . . . . . . . . . . . . . . 267
9.9
PROFIBUS Multiple Analog Output . . . . . . . . . . . 269
9.9.1
Functional description . . . . . . . . . . . . . . . 269
9.9.2
Block operation . . . . . . . . . . . . . . . . . . . . 270
9.9.3
Block Configuration . . . . . . . . . . . . . . . . 270
9.9.4
Block parameters . . . . . . . . . . . . . . . . . . . 271
9.10
PROFIBUS Discrete Output . . . . . . . . . . . . . . . . . 273
9.10.1 Functional description . . . . . . . . . . . . . . . 273
9.10.2 Block configuration . . . . . . . . . . . . . . . . . 274
9.10.3 Block operation . . . . . . . . . . . . . . . . . . . . 275
9.10.4 Block parameters . . . . . . . . . . . . . . . . . . . 275
9.11
PROFIBUS Multiple Discrete Output . . . . . . . . . . 276
9.11.1 Functional description . . . . . . . . . . . . . . . 276
9.11.2 Block configuration . . . . . . . . . . . . . . . . . 276
9.11.3 Block operation . . . . . . . . . . . . . . . . . . . . 277
9.11.4 Block parameters . . . . . . . . . . . . . . . . . . . 278
Endress+Hauser 3
Table of Contents
10 Modbus Blocks . . . . . . . . . . . . . . . . 279
10.1
ControlCare Implementation . . . . . . . . . . . . . . . 279
10.1.1 Register access . . . . . . . . . . . . . . . . . . . . 280
10.1.2 Data types . . . . . . . . . . . . . . . . . . . . . . . . 281
10.2
MBCF Modbus Configuration Block . . . . . . . . . . 282
10.2.1 Configuration as TCP/IP master . . . . . . . 283
10.2.2 Configuration as TCP/IP slave . . . . . . . . 283
10.2.3 Configuration as serial master . . . . . . . . 284
10.2.4 Configuration as serial slave . . . . . . . . . . 284
10.2.5 Configuration as master and slave . . . . . 284
10.3
Modbus Control Master . . . . . . . . . . . . . . . . . . . 286
10.3.1 Block description . . . . . . . . . . . . . . . . . . 286
10.3.2 Block configuration . . . . . . . . . . . . . . . . 288
10.3.3 Block operation . . . . . . . . . . . . . . . . . . . . 291
10.3.4 Block parameters . . . . . . . . . . . . . . . . . . 292
10.4
Modbus Control Slave . . . . . . . . . . . . . . . . . . . . 293
10.4.1 Block description . . . . . . . . . . . . . . . . . . 293
10.4.2 Block configuration . . . . . . . . . . . . . . . . 296
10.4.3 Block operation . . . . . . . . . . . . . . . . . . . . 298
10.4.4 Block parameters . . . . . . . . . . . . . . . . . . 299
ControlCare Application Designer: Function Blocks
Appendix A:
Interpreting parameter status . . . . . . 300
Appendix B:
Standard data types and structures . . 302
Appendix C:
Manufacturer-specific data structures 306
Index . . . . . . . . . . . . . . . . . . . . . . . . 309
4 Endress+Hauser
ControlCare Application Designer: Function Blocks
Endress+Hauser 5
6
ControlCare Application Designer: Function Blocks
Revision History
Product version
Manual Changes
1.00.xx
BA022S/04/en/07.02
Original manual
2.01.xx
BA022S/04/en/01.06
Editorial
Remarks
• In new Corporate design
• SFC151 updated to SFC162 and SFC173.
• Configuration Tool now named Application
Designer
• The descriptions of the function blocks have not changed and remain valid over the Product
Versions.
• The use of special blocks for PROFIBUS in control strategy creation are described in BA036S/04/en:
Application Designer: PROFIBUS Tutorial
2.02.xx
BA022S/04/en/07.06
Editorial • Note on Field Controller DIP-switch added to
Simulation (Chap. 1.2)
• Pulse Input description improved (Chap 5.5)
• Enhanced Signal Characterizer (50 points, cascade) described (Chap 7.4)
• Restructuring of manual
• Parameter, block descriptions updated
2.03.xx
BA022S/04/en/06.07
(Not released)
Editorial
2.04.xx
BA022S/04/en/12.08
Function Blocks • Additional Enhanced Blocks
• Hybrid Function blocks offer more parameters
• Modbus blocks reduced and restructured
2.05.xx
BA022S/04/en/06.10
Modbus MBCF Block • Addition of master+slave option(Chapter 10.2.5)
Input Selector ISEL Bliock • Description OP_SELECT corrected, p157
Product Version
Details of product version and the individual components of Application Designer Suite can be seen in the About ControlCare dialog:
Start=>Programs=>Endress+Hauser=>ControlCare=>Tools=>About ControlCare
Registered Trademarks
PROFIBUS
®
Registered trademark of the PROFIBUS User Organisation, Karlsruhe Germany.
FOUNDATION
TM
Fieldbus
Trademark of the Fieldbus Foundation, Austin, TX 78759, USA
HART
®
Registered trademark of the HART Communication Foundation, Houston, USA
Microsoft
®
, Windows
®
, Windows 2000
2008 Server
®
,Windows 7
®
®
,Windows XP
®
, Windows 2003 Server
®
, Windows
, Windows Vista
®
and the Microsoft logo are registered trademarks of the Microsoft Corporation.
Acrobat Reader
®
is a registered trade mark of the Adobe Systems Incorporated.
All other brand and product names are trademarks or registered trademarks of the companies and organisations in question
Endress+Hauser
ControlCare Application Designer: Function Blocks
Location
Hazardous areas
EMC
1 Safety
1 Safety
1.1
Designated use
ControlCare is a field-based control system comprising hardware and software components. It can be used to visualize, monitor and control production processes. The approved usage of the individual units used in the system can be taken from the corresponding parts of the operating instructions.
ControlCare Application Designer allows the engineering, configuring and commissioning of a
ControlCare SFC162 FOUNDATION Fieldbus or SFC173 PROFIBUS Field Controller as well as the programming of the hybrid function block in IEC 61131-3 language. This manual describes the
Function Block Application Process, the Function Blocks that can be created with Application
Designer and which are supplied with Endress+Hauser instruments as well as examples for their use. Workflows and practical examples for the the engineering of FOUNDATION Fieldbus,
PROFIBUS, Modbus projects as well as for the programming of hybrid function blocks are also to be found in the appropriate tutorial, see Chapter 1.5.
1.2
Installation, commissioning and operation
ControlCare Field Controllers have been designed to operate safely in accordance with current technical safety and EU directives. Essential to their use is the ControlCare Application Designer software suite, which allows control strategies to be created for FOUNDATION Fieldbus and
PROFIBUS I/O applications. Field devices, links, junction boxes, cables and other hardware comprising the Fieldbus sytem must also be designed to operate safely in accordance with current technical safety and EU directives.
If devices are installed incorrectly or used for applications for which they are not intended, or if the controller is not configured correctly, it is possible that dangers may arise. For this reason, the system must be installed, connected, configured, operated and maintained according to the instructions in this and the associated manuals: personnel must be authorised and suitably qualified.
1.3
Operational safety
Field Controllers must be mounted in a permanent and weather-protected location in a safe area.
The environment shall be a metal cabinet or an installation frame with a well grounded mounting plane. The environment shall be protected.
The controller must be connected to networks operating in explosion hazardous areas via barriers or other safety components. When installing components in explosion hazardous areas:
• Ensure that all installion and maintenance personnel are suitably qualified
• Check that all equipment has the appropriate safety certificates
• Observe the specifications in the device certificates as well as national and local regulations.
This topic is discussed in BA013S (FF Guidelines) and BA034S (PROFIBUS Guidelines).
All modules are suitable for industrial use and conform with the following standard, see Appendix:
• EN 61326: 1997/A1: 1998
Interference emmision: Class A apparatus
Interference immunity: as per Annex A, industrial environment
Depending upon the environment in which the bus is operating, particular attention should be paid to the grounding of the bus cables. This topic is discussed in BA013S (FF Guidelines) and BA034S
(PROFIBUS Guidelines).
Endress+Hauser 7
1 Safety ControlCare Application Designer: Function Blocks
IP Address
Technical improvement
A ControlCare Field Controller is normally configured from a workstation connected into the control system backbone. You will require a unique IP address to set it up.
It is recommended that ControlCare Field Controllers and OPC servers are not installed in an office network, as the large data packets exchanged between office equipment may lead to timeouts and intermittent communication errors. Ideally, the ControlCare system network should operate within its own IP domain; if this is not possible it should be separated from other parts of the network by a managed switch.
Warning
• The use of IP addresses is strictly controlled. Usually your system administrator will be authorised to allocate unique addresses. Assigning an unauthorised address to a Field Controller may result in conflicts within your system and the failure of the associated devices!
Since the system can be accessed and manipulated through the various ControlCare tools, it is advisable to control access both to the workstation and the folders in which the configuration is stored. Always make a back-up of the project.
Endress+Hauser reserves the right to make technical improvements to its software and equipment at any time and without prior notification. Where such improvements have no effect on the operation of the equipment, they are not documentated. If the improvements effect operation, a new version of the operating instructions is normally issued.
Safety conventions
1.4
Conventions and icons
In order to highlight safety relevant or alternative operating procedures in the manual, the following conventions have been used, each indicated by a corresponding icon in the margin.
Icon Meaning
A note highlights actions or procedures which, if not performed correctly, may indirectly affect operation or may lead to an instrument response which is not planned
Caution!
Caution highlights actions or procedures which, if not performed correctly, may lead to personal injury or incorrect functioning of the instrument
Warning!
A warning highlights actions or procedures which, if not performed correctly, will lead to personal injury, a safety hazard or destruction of the instrument
8 Endress+Hauser
ControlCare Application Designer: Function Blocks 1 Safety
1.5
ControlCare documents
Table 1.1 indicates the documents, planned and realized, containing safety relevant information, installation, commissioning and operating instructions for the equipment and software associated with ControlCare.
All documentation available at the time of release is included on the ControlCare CD-ROM and is installed in Start=>Programs=>Endress+Hauser=ControlCare=Manuals during set-up.
Component Description
System ControlCare System Overview
ControlCare System Design
ControlCare System Specifications
Software Application Designer Overview
Application Designer: Local I/O Tutorial
Application Designer: FF Tutorial
Application Designer: PROFIBUS Tutorial
Application Designer: MODBUS Tutorial
Application Designer: IEC 61131-3
Ladder Logic Tutorial
Application Designer: IEC 61131-3
Structured Text Tutorial
Field Control (OPC) Servers
SFC162 Visitor
Field Controller Hardware Installation Guide
Commissioning and Configuration
Function Blocks Function Block Manual
Set-Up Getting Started
General FOUNDATION Fieldbus Guidelines
PROFIBUS Guidelines
Document type Designation Order No.
Operating manual BA016S/04/en 56004883
Operating manual BA039S/04/en Planned
Operating manual BA040S/04/en 56004888
Operating manual BA017S/04/en 70104301
Operating manual BA032S/04/en 71095009
Operating manual BA019S/04/en 70101151
Operating manual BA036S/04/en 70101152
Operating manual BA037S/04/en 70101153
Operating manual BA038S/04/en 70101386
Operating manual BA056S/04/en 71060063
Operating manual BA018S/04/en 71031428
Operation manual BA069S/04/en 71113457
Operating manual BA021S/04/en 56004885
Operating manual BA035S/04/en 56004887
Operating manual BA022S/04/en 56004886
Operating manual BA020S/04/en 56004884
Operating manual BA013S/04/en 70100707
Operating manual BA034S/04/en 56004242
Tab. 1-1: ControlCare documentation
Endress+Hauser 9
1 Safety ControlCare Application Designer: Function Blocks
1.6
About this manual
This manual is concerned with the function block model used in Foundation Fieldbus devices. It discusses the function block application process and then proceeds to describe the various blocks that are to be found in Endress+Hauser devices. It is structured as follows:
• Chapter 1: Safety gives general information on the ControlCare platform
• Chapter 2: Introduction briefly describes the FOUNDATION Fieldbus function block application process together with the associated objects, parameters and options
• Chapter 3: Resource block describes the resource block and its parameters. Every device has a resource block that is structured in the same way
• Chapter 4: Transducer block describes the temperature transducer and other transducer blocks associated with the SFC162 and SFC173 Field Controllers. Descriptions of the transducer blocks of devices offered by
Endress+Hauser and other vendors are to be found in the appropriate device manuals.
• Chapter 5: Input blocks describes the Analog Input block (AI), Multiple Analog Input block (MAI), Discrete Input block
(DI) and Multiple Discrete Input block (MDI), with particular reference to their use in the
ControlCare platform.
• Chapter 6: Control blocks describes the PID, PI, I controller block and other control blocks
• Chapter 7: Arithmetic and logic blocks describes the various arithmetuc and logic blocks, e.g. Signal Characterizer (SC), Input Selector block (IS), Integrator or Totalizer (IT), Arithmetic (AR) etc.
• Chapter 8: Output blocks describes the Analog Output block (AO), Multiple Analog Output block (MAI), Discrete Output block (DO) and Multiple Discrete Output block (MDO), with particular reference to their use in the ControlCare platform.
• Chapter 9: PROFIBUS blocks describes the blocks used to integrate PROFIBUS devices into the ControlCare platform
• Chapter 10: Modbus blocks describes the blocks used to integrate Modbus devices into the ControlCare platform
• Appendices contain procedures and information on advance applications, e.g. interpretation of parameter status in SCADA systems
The manual aims to provide a balance between background information and the practical use of the blocks within ControlCare Application designer. Further information on their practical use can be found in the Control Application Designer Tutorials, see Chapter 1.5. A full description of the function block application process is to be found in the Fieldbus Foundation Specifications FF 891S and FF 892S. These form the basis of many of the parameter descriptions found here.
10 Endress+Hauser
ControlCare Application Designer: Function Blocks 2 Function Block Application Process
2 Function Block Application Process
2.1
Introduction
FOUNDATION Fieldbus function blocks are "black boxes" which transform input parameters into output parameters via parametric algorithms. They are executed repeatedly, either to a schedule or on the occurance of an event. Once invoked, they run to completion.
The output of one function block can be linked to the input of another, see ControlCare Application
Designer Tutorials, Chapter 1.5. Such linkages exist both within a device or between devices.
Interfaces between function blocks located in the same device are locally defined. External links use the services of the function block shell, which provides access to FMS application layer services.
Function blocks are supported by resource and transducer blocks as well as by view, trend, alert and link objects as illustrated in Fig. 2.1.
Trend object
Link object
Local I/O
Transducer block
Function Block Application Process
Function block
Link object
Function block
View object
Link object Link object
Local hardware support
Resource block
Alert object
Link object
Fig. 2-1: Function block linkages (Fig 11, Foundation Fieldbus FF-800-1.3)
Figure 2-1 shows a general function block application process. The input parameter values to the transducer block and particular function blocks are collected from other blocks or, in the case of a transmitter, the sensor electronics. When the process is invoked, a snapshot is made of the momentary values, which are then used to execute the block. Any changes in input values during the execution are ignored.
Once the process has started, the algorithm takes the input values and generates outputs as it progresses. The execution is controlled by so-called contained parameters, which are not visible as input and output parameters, but which may be accessed and modified remotely as specified by the function block.
The operation of the algorithm may be affected by input events. The receipt of events during execution is regulated by a control function, which also generates corresponding output events.
On completion of the algorithm, the block data is saved for use on the next invocation and a snapshot is made of the output data. This is then released simultaneously for use in other function blocks.
Endress+Hauser 11
2 Function Block Application Process ControlCare Application Designer: Function Blocks
2.2
Block objects
The various objects within the function block application process have the function described in
Table 2-1 below, see also Fig. 2.1:
Object
Resource blocks
Description
Only one resource block is defined for each fieldbus device. It contains the associated hardwarespecific characteristics. These comprise a set of contained parameters but no input or output parameters.
Transducer blocks
A resource block contains an algorithm that is used to control and monitor the operation of the device hardware. Its execution is dependent upon the characteristics of the physical device, as defined by the manufacturer. The algorithm might cause events to be generated during its execution.
Transducer blocks decouple local input/output functions from the function blocks. They read from sensor hardware and write to actuator hardware. This allows the transducer block to be executed as frequently as is necessary to obtain good data from the sensor or to ensure valid writes to the actuators without burdening the function block(s) to which they are linked. By having standardised signal as output, they also isolate the function block from vendor-specific characteristics of the sensor/actuator.
Function blocks Function blocks comprise a complete set of parameters, an algorithm and events. Unlike resource and transducer blocks, function blocks are executed to a schedule or on the occurance of an event. The algorithms perform input, ouput, calculation, logic and control functions for the application system. In the case of input and output functions, they are linked to the transducer blocks of actuators and sensors respectively, which are in turn connected to the actuator or sensor hardware.
View and trend objects View objects aid the management and control of function blocks by making the configuration and operational parameters visible to the user. They allow operator data to be grouped together for efficient transfer and processing.
Alert objects
Link objects
Trend objects provide history information which allows the behaviour of a function block to be examined.They allow short-term history data can be collected and saved within the device.
Alert objects generate messages when alarms and events are detected. They report these by sending an event notification and waiting a specified period of time for an acknowledgement.
This process is completed, even when the condition that triggered the alert no longer exists. If no acknowledgement is received within a predefined time-out, the event notification will be retransmitted. This ensures that the alert message is not lost.
The function block model recognises two types of alert: events and alarms. Events are used to report a change of status of a function block, for example when a parameter crosses a particular threshold. Alarms are used to report not only the status change, but also the return to original status.
Link objects contain information regarding the connecting together of the inputs and outputs of function blocks. They are also used to define external access to trend, view and alert objects.
They identify the parameter or object to be linked, the field message service (FMS) used to transfer the data and the virtual communications relationship (VCR) used for transfer. In the case of input/output parameter links, the remote parameter is also identified.
Tab. 2-1: Function block alpplication process objects
12 Endress+Hauser
ControlCare Application Designer: Function Blocks 2 Function Block Application Process
Generation, access and storage
Usage
2.3
Block parameters
2.3.1
Parameter types
Resource blocks, transducer blocks and function blocks all contain parameters. They can be classified according two criteria:
• How they are generated, accessed and stored
• How they are used by the function block application process
Every parameter is characterized by one type attribute from each of these classes.
The type attributes associated with generation, access and storage are listed in Table 2-2 below:
Parameter type Description
Dynamic Dynamic parameters are normally read only. Their value is calculated by the block algorithm, e.g. the output value of a function block. If there is a power failure, they are recalculated.
Static
Non-volatile
Static parameters are normally read-write and have a specific configured value that seldom changes. If there is a power failure, they are restored by the device in which they reside. An interface or temporary device may write to them on an infrequent basis. All parameter changes are tracked by incrementing the static revision parameter ST_REV of the associated block, see Chapter 2.3.4, and generate an update event.
Non-volatile parameters are normally read-write and are frequently overwritten. If there is a power failure, the last saved value must be restored by the device. Normally changes in the value are not tracked.
Tab. 2-2: Parameter type attributes associated with generation and strarge
The type attributes associated with usage listed in Table 2-3 below:
Parameter type Description
Input Input parameters obtain their value from outside the block, normally thorough a link to an output parameter of another function block. The block algorithm will normally transform or operate on the input parameter to produce the block’s ouput value. Most blocks use a single input value in their algorithm, the so-called primary input value. The execution may be supported by other so-called secondary input values, see e.g. PID Control Block, Chapter 6.1.
Contained
Output
Contained parameters may be set by an operator, a higher level device, or calculated. They are parameters that reside within the block and cannot be linked to another function block input or output. They may be viewed, however, by an external application. An example of a contained parameter common to all blocks is the block mode parameter MODE_BLK.
Output parameters are normally generated by the block algorithm. Their value may be dependent on the value of the mode parameter of the block. The primary output parameter of a block will normally be linked to an input parameter of another function block. Some blocks also contain secondary output parameters such as alarm and event parameters that play a supporting role to the primary output parameter.
Tab. 2-3: Parameter type attributes associated with usage
Endress+Hauser 13
2 Function Block Application Process ControlCare Application Designer: Function Blocks
2.3.2
Parameter identifiers
Details of the formal model for parameter identification can be taken from Foundation Fieldbus
Specification FF-890, Function Block Application Process, Part 1. Expressed briefly, the host application must be able to find any parameter in the system by means of a unique identifier. This is composed of two elements, which are put together to form the construct Tag.Parameter
• Tag is the block tag assigned to the function block by the host application
• Parameter is the DD member ID of the parameter and is unique to the block.
Using the Tag.Parameter construct, the host application is able to access the parameter value or its description, its data type index and the parameter semantics. In the case of Application Designer, a view of this information can be obtained by clicking on the FB VFD node of the Control Module tree, when the associated device is on line, see Application Designer Tutorials. In this manual, the data type etc. is also to be found in the parameter tables that accompany every function block description.
Export to OPC Server
Fig. 2-2: DD member ID information for Micropilot viewed in the Block List dialog
Application Designer presents parameter information in easily readable form by using the parameter names as can be viewed in the Off Line and On Line Characterization dialogs, see Chapter 2.3.4.
These are then identified using the same construct. Thus, for instance, the process value PV value of an Analog Input block with the tag "TT100_AI_1.PV" can be expanded to show its two elements
Value and Status. The two paramenters can thus be identified from the Tag.Parameter construct as:
TT100_AI_1.PV.Value and
TT100_AI_1.PV.Status
whereby the block tag is generated by default and can be influenced by the Preference settings in
Application Designer, see Application Designer Tutorials.
Fig. 2-4 shows and example of export to an OPC Server with tags taken from the control strategy shown in Fig. 2-6. The project was off-line, hence the bad quality status.
Aliases
14
Fig. 2-3: Example of the Tag.Parameter construct in the Tag View program suppllied with ControlCare
From ControlCare Version 2.04.xx onwards, it is possible to assign alias names to the parameter identifiers generated by the system. These are also exported to the OPC Server. Should a project made with Version 2.03.xx or less be updated by adding alias names, it is not necessary to update any SCADA application, as the parameter identifiers will still be found.
Endress+Hauser
ControlCare Application Designer: Function Blocks
ST_REV
2 Function Block Application Process
2.3.3
Universal parameters
Resource blocks, transducer blocks and function blocks all operate in the same manner. To this end, there are a number of parameters that are common to all. These appear in the order below and are used for the following purposes:
Parameter
ST_REV
TAG_DESC
STRATEGY
ALERT_ KEY
MODE_BLK
BLOCK_ERR
Description
Indicates the revision level of the block’s static parameters and may be used in configuration management
Allows the entry of a block description (up to 32 characters) which may be used in a human interface or in block documentation to clarify the block application
Allows the entry of a user assigned value that may be used in configuration or diagnostics as a key in sorting block information
Allows the entry of a user assigned value that may be used in sorting alarms or events generated by a block
Determines the block operating mode and available modes for a block instance
Indicates the error status of hardware and software components associated with the block
Tab. 2-4: Universal parameters found in all function blocks
The parameters MODE_BLK and BLOCK_ERR are described in Chapter 2.4 and Chapter 2.8 respectively.
As described in Section 2.3.1, each block contains dynamic data, which change during the execution of the block and static data which normally do not. Since static data are seldom changed, a means is provided to avoid reading them more than once, unless they change. This is the static revision parameter ST_REV , which is incremented every time a static parameter attribute value is changed. It may also be incremented if a static parameter attribute is overwritten but the value is not changed.
Devices using the static data of another device receive a copy of ST_REV when either the static or dynamic data are read. As long as two successive copies match, the static data has not changed.
Should the ST_REV of a device change, the UPDATE_EVT parameter is output to alert other devices that one or more changes have occurred. A time stamp, relative parameter index and associated block index of the last parameter changed are included in the alert, along with the new value of ST_REV . If ST_REV has incremented by more than 1, the interface device will update all static data.
In order that downloads do not generate a burst of update alerts, these are not generated when a block is out of service. If a parameter is changed when the block is out of service, ST_REV is incremented as normal. This triggers an UPDATE_EVT alert when the block returns from OOS to an operational mode.
Endress+Hauser 15
2 Function Block Application Process
Control strategy and navigation tree
ControlCare Application Designer: Function Blocks
2.3.4
Parameters in Application Designer
Fig 2-4 shows a screenshot of a Process Cell navigation tree and the associated control strategy.
Fig. 2-4: Process Cell and cascade control stratetgy created off-line in ControlCare Application Desogner
The control strategy is as created from the strategy window, i.e. the function blocks have yet to be assigned to the fieldbus devices (also indicated in the navigation tree by the "?" in the function block icon). When used in this way, Application Designer temporarily assigns a block tag that is named after the Control Module and the block tag, e.g. Control Module 1_PID_1. As the links are made between the function blocks, the input and output parameters, indicated by the icons and , are added to the navigation tree. The arrows in the control strategy are in fact visualizations of the link objects, and the navigation tree a visualization of the tag.parameter construct.
Depending on the preferences set for tag naming, the tag name will change to that of the device when the function block is assigned to a device. Thus if the function block Control Module 1_PID_1 is assigned to a device with tag FC102, the tag name is automatically changed to FC102_PID_1, see Fig. 2-5.
16
Fig. 2-5: Process Cell and cascade control stratetgy after assignment of function blocks to the devices
The parameters with the icon are contained parameters that were automatically set when the device was created, or have been configured in the Off Line or On Line Characterization dialog.
Endress+Hauser
ControlCare Application Designer: Function Blocks 2 Function Block Application Process
Off Line Characterization dialog
When Application Designer is offline, a double-click on the Function Block leaf of the Control
Module or Fieldbus navigation tree opens the corresponding Off Line Characterization dialog, see also Application Designer Tutorials.
On Line Characterization dialog
Fig. 2-6: Example of Off Line Characterization dialog
The dialog shows the parameters associated with the block in the dialog header. These are arranged in a tree, and depending upon data type, they can be expanded to show their elements. For example, the PV parameter expands to show the two elements PV.VALUE and PV.STATUS. The dialog also shows the value, the offset within the block and whether the parameter is read-write (RW) or Read
Only (RO).
The row of buttons at the top of the dialog calls up several different views of the parameters (view objects). In addition to the input, output and contained parameters, views can be had of the operational, diagnositic, alarms, tuning parameters, etc., see Application Designer Overview,
BA017S/04/en for more details. It is also possible to build customized views of parameters for configuration or online monitoring.
When Application Designer is online, a double-click on the Function Block leaf of the Control
Module or Fieldbus navigation tree opens the corresponding On Line Characterization dialog. Now the Read Only parameters will contain parameters read from the associated field devices.
Endress+Hauser
Fig. 2-7: Example of On Line Characterization dialog with parameter quality
Expand the PV parameter and observe the status. Now expand the MODE_BLK parameter and set the Target to OOS (out of service). To do this Press Edit , click in the Value space, select OOS from the drop-down menu, then click End Edit . Note that the PV status changes from Good to Bad.
Toggle between status codes and texts with the button . Put the block target back into Auto, and note that the quality changes from bad to good again.
The execution of a block involves the inputs, outputs, contained parameters, and the algorithm of the block. The execution time for a block algorithm is defined as a parameter of the block. Its value is dependent on how the block was implemented.
17
2 Function Block Application Process
Retained target mode
ControlCare Application Designer: Function Blocks
2.4
Block operation
2.4.1
Block mode parameter MODE_BLK
The MODE_BLK parameter controls the operational mode of the block. It has four elements with the functions summarized in Table 2-5.
Element
Target mode
Actual mode
Permitted mode
Normal mode
Description
Sets the mode in which the block should normally operate. Most blocks have the target mode
Auto, exceptions being output and cascaded PID blocks which normally operate in Cas mode.
In addition, when parameters are changed on-line, the Target mode must normally be changed to OOS (out of service) before the change can be made.
Indicates the current mode of operation of the block. This may differ from the target mode, because under certain operating conditions, a block may not be able to reach the target mode, e.g. because it is not configured correctly or not receiving the correct information from an upstream or downstream block linked to it.
Lists the modes in which a block is able to operate. The modes supported vary according to the type and function of a block.
The normal mode indicates the mode in which the block normally operates. This parameter is not supported by all devices.
Tab. 2-5: MODE_BLK parameter elements
The user sets the target mode when the block is configured. When it goes on-line, the algorithm checks if the block can be executed in the requested mode. If this is not possible, the mode with the priority nearest to the target mode is selected, see Chapter 2.4.3. The actual mode displays the current mode of block operation.
When the target mode is OOS, Man, RCas or ROut, see Chapter 2.4.2, the target mode attribute may retain information about the previous target mode. This information may be used by the block in mode shedding and setpoint tracking, see Chapter 2.4.4.
2.4.2
Block modes
Resource blocks, transducer blocks or function blocks may support one or more of the modes listed in Table 2-6 below. They may be operated only in the modes they support.
Block Mode
Out of service (OOS)
Description
In this mode, the block is not executed. The output is maintained at last value or, in the case of output blocks, the output value may be maintained at an assigned fault state value.
For control blocks, the setpoint is maintained at last value, see Chapter 2.4.4.
Initialization manual (Iman) This mode cannot be requested through the target mode. Blocks connected to a downstream block by a back calculation link (BKCAL_OUT/BKCAL_IN) are forced into it when the status of the parameter indicates that the downstream block is not in cascade
(Cas mode). The normal algorithm is not executed, and the output tracks the
(BKCAL_IN) parameter. The setpoint may be maintained or initialized to the value of the process variable parameter.
Local override (LO) This mode is to be found in control and output blocks that support a track input parameter (TRK_VAL). Tracking is enabled in the Control Options parameter group, see
Chapter 2.8.2, and is initiated by the TRK_IN_D discrete parameter. For some devices a local lock-out switch must be used to enable Local Override.
Manual (Man)
In the local override mode, the block output tracks the value of the track input parameter
(TRK_VAL). The algorithm initializes so that no bump is experienced when the mode switches from LO back to the target mode. The setpoint may be maintained or initialized to the process variable parameter value.
In this mode, the block output is not calculated, but set by the operator. It may be limited.
The algorithm initializes so that no bump is experienced when the mode switches. Any setpoint may be maintained or initialized to the value of the process variable parameter or to the setpoint value associated with the previous (retained) target mode.
18 Endress+Hauser
ControlCare Application Designer: Function Blocks 2 Function Block Application Process
Block Mode
Automatic (Auto)
Cascade (Cas)
Remote cascade (RCas)
Remote output (ROut)
Description
This is the normal operating mode of the majority of blocks. For control blocks operating in this mode, a local setpoint value SP is used by the normal block algorithm to determine the primary output value. The local setpoint value may be overwritten on-line – without changing the target mode to OOS – by a user using Application Designer or a SCADA program such as ControlCare P View.
This is the normal operating mode of a cascaded control block or output block. In this mode, the setpoint value used in the block algorithm is the cascade input v alue (CAS_IN) provided by an upstream function block. This and the BKCAL_OUT parameter are used to establish a bumpless cascade with the upstream block.
Note: the target mode of PROFIBUS output blocks integrated via the SPC173 Field
Controller is Auto.
In this mode, the setpoint value used in the block algorithm is the remote cascade input parameter (RCAS_IN) provided by an external control application. A remote cascade output parameter (RCAS_OUT) is maintained by the block to support initialization of the control application when the block mode is not remote cascade. The control application acts as a normal upstream block. Its algorithm is not synchronized to the function block schedule, however, and it does not use a link to transfer the setpoint to the block.
In this mode, the block output is not calculated but set to the value of the remote-output input parameter (ROUT_IN) provided by an external control application. A remoteoutput output parameter (ROUT_OUT) is maintained by the block to support initialization of the control application when the block output is not provided remotely.
The control application acts as a normal upstream block. Its algorithm is not synchronized to the function block schedule, however, and it does not use a link to transfer the setpoint to the block.
Tab. 2-6: Possible operation modes for fuinction blocks
Table 2-7 summarizes the source of the setpoint value SP and the output value OUT for the various modes.
Man
Auto
Cas
Rcas
Rout
Block mode Source of SP
OOS
Iman
LO
User
User
PID/EPID/APID: User
AO/DO: Fault state (last value or FSTATE_VAL)
Source of OUT
User
Other function block - following BKCAL_IN parameter
PID/EPID/APID: Other function block following
TRK_VAL parameter
AO/DO: Fault state (last value or FSTATE_VAL)
User
User (for PROFIBUS AO, PID)
User
Block algorithm
Other function block - following CAS_IN parameter Block algorithm
Control application running on an interface device Block algorithm
Block keeps last value Control Application running on an interface device
Tab. 2-7: Source of SP and OUT as a function of block mode
Endress+Hauser 19
2 Function Block Application Process ControlCare Application Designer: Function Blocks
2.4.3
Mode priority
Each mode has an associated priority, see Table 2-8. Priority is used when the block calculates the actual mode or checks whether write access is allowed for a particular mode or another of higher priority. To calculate the actual mode, the block checks whether certain conditions are present which will prevent a change to the mode with the next lower priority.
Mode
OOS
IMan
LO
Man
Auto
Cas
Rcas
Rout
Description
Out of Service
Initialization Manual 6
Local Override 5
Priority
7 - highest
Manual
Automatic
Cascade
Remote Cascade
Remote Output
4
3
2
1
0 - lowest
Tab. 2-8: Block modes with corresponding priorities
When a block goes online, the actual mode is set to OOS. The block now checks whether it may change to the Iman mode. This is the case when all block parameters are valid and the target mode is not set to OOS, see Table 2-10. This procedure is repeated through all the modes supported by the block until the target mode is achieved. For instance, if the target mode is Cas, the conditions for OOS, IMan, LO, Man and Auto must be checked in this order. If all conditions are false, the actual mode will be the same as target mode.
Table 2-9 summarizes the conditions that force a block to operate in a particular mode when they are true.
Block Mode Conditions
OOS • Resource block is in OOS (resource state is Standby)
• Enumerated parameter has an invalid value
IMan
LO
• BKCAL_IN.status is Bad
• BKCAL_IN.status is Good - Fault State Active, Not Invited or Initialization Request.
• Fault state is active (in an output function block)
• CONTROL_OPTS.Track Enable active and TRK_IN_D is active.
• If target is Man then the CONTROL_OPTS.Track in Manual must be active
Man
Auto
• Target mode has just been changed manually from OOS
• Status attribute of primary input parameter (IN parameter) is Bad or Uncertain with option to treat
Uncertain as Bad and Bypass not set.
• Target mode is RCas or ROut and SHED_OPT=shed to Manual or shed to next
• Target mode is Cas and CAS_IN.status=Bad or cascade initialization not completed
• Target mode is RCas and RCAS_IN.status=Bad and SHED_OPT=shed to Auto or shed to next
• Target mode is ROut and ROUT_IN.status=Bad and SHED_OPT = shed to Auto or shed to next.
Cas
RCas
ROut
• Actual mode last execution was Cas.
• Target mode is Cas and cascade initialization has just completed
• Target mode is RCas and RCAS_IN.status=Bad and SHED_OPT=shed to next and cascade initialization has just completed
• Target mode is ROut and ROUT_IN.status=Bad and SHED_OPT=shed to next and cascade initialization has just completed
• RCas cascade initialization has just completed or actual mode last execution was RCas.
• ROut cascade initialization has just completed or actual mode last execution was ROut.
Tab. 2-9: Conditions governing Actual Mode calculation
20 Endress+Hauser
ControlCare Application Designer: Function Blocks
Trouble-shooting
2 Function Block Application Process
If a function block does not run in the desired target mode, Table 2-10 can be used to analyze the possible reason.
Target Mode Symptom, cause and remedy
OOS Block remains in OOS
• Resource block target mode is OOS
– Set the Resource block target mode to Auto
• Bad status for enumerated parameters
– Check that block has been configured correctly
Iman
LO
Block remains in Iman
• BKCAL_IN.status is Bad
– Link failure in backward path BKCAL_OUT/ BKCAL_IN
• BKCAL_IN.status is NotInitiated
– Downstream block can not execute in Cas
Check the target mode of downstream block as well fault state condition
– Link failure in forward path OUT/CAS_IN
Target mode LO cannot be attained
• CONTROL_OPTS setting wrong
– Check if setting is Track Enable or Track in Manual
• Value and status of TRK_IN_D wrong
– Check link, condition for activation, upstream block configuration
• Value and status of TRK_VAL bad
– Check parameter settings
• CAS_IN status of downstream block bad
– Check if CAS_IN and the delay time for fault state are being forced by FSTATE_TIME
Man
Auto
Cas
Block does not reach target mode Cas
• IN status bad
– Link failure in backward path BKCAL_OUT/ BKCAL_IN
– Link failure in forward path OUT/CAS_IN
Block does not reach target mode Rcas or Rout
• Block not synchronized
– Check that the update rate of RCAS_IN and ROUT_IN of the control application corresponds to the values in SHED_RCAS and SHED_ROUT respectively
• SHED_OPT parameter set Shed to Manual, no return; remote communcation has failed
– When communication reestablished, reset target mode to RCas or ROut
Block does not reach Auto
• Bad status for enumerated parameters
– Check that block has been configured correctly
– Check all parameters required for the block algorithm have been set
Block does not reach target mode Cas
• IN status bad
– Link failure in backward path BKCAL_OUT/ BKCAL_IN
– Link failure in forward path OUT/CAS_IN
Block does not reach target mode Rcas or Rout
• Block not synchronized
– Check that the update rate of RCAS_IN and ROUT_IN of the control application corresponds to the values in SHED_RCAS and SHED_ROUT respectively
• SHED_OPT parameter set Shed to Auto, no return; remote communcation has failed
– When communication reestablished, reset target mode to RCas or ROut
Block does not reach target mode Rcas or Rout
• Block not synchronized
– Check that the update rate of RCAS_IN and ROUT_IN of the control application corresponds to the values in SHED_RCAS and SHED_ROUT respectively
Tab. 2-10: Trouble-shooting table for block target mode
Endress+Hauser 21
2 Function Block Application Process
SHED_OPT
ControlCare Application Designer: Function Blocks
2.4.4
Mode shedding
Mode shedding is a mechanism that allows the function block application process to interface with external, proprietary control applications running e.g. on a host computer, distributed control system controller (DCS) or programmable logic controller (PLC). Such applications are allowed to adjust the setpoint value SP of a function block in RCas mode and/or its primary output value OUT in ROut mode. When they do, they provide the application with the value of each parameter together with its status.
In order to ensure bumpless transfer in the event of an interface failure or a breakdown in communication, the function block involved monitors the traffic between the external application and itself. If a new value is not received within a specified "update time", determined by the parameters SHED_RCAS and SHED_ROUT in the device resource block, or a bad status is received, then the function block mode is changed to a non-remote mode of higher priority.
4
5
6
7
The SHED_OPT parameter is to be found in control and output blocks and configures the desired behavior when a remote mode, i.e. Rcas and Rout is shed. It also determines whether the shed mode is to be maintained once the RCAS_IN or ROUT_IN parameter updating is recovered. Table 2-11 summarizes the options
Index
0
1
2
3
8
Meaning
Uninitialized - Invalid
Normal shed, Normal return
– Actual mode changes to the next lowest priority non-remote mode permitted but returns to the target remote mode when the remote computer completes the initialization handshake.
Normal shed, No return
– Target mode changes to the next lowest priority non-remote mode permitted. The target remote mode is lost so there is no automatic return to it.
Shed to Auto, Normal return
– Target mode changes to Auto but returns to the target remote mode when the remote computer completes the initialization handshake.
Shed to Auto, No return
– Target mode changes to Auto. The target remote mode is lost so there is no automatic return to it.
Shed to Manual, Normal return
– Target mode changes Man but returns to the target remote mode when the remote computer completes the initialization handshake.
Shed to Manual, No return
– Target mode changes to Man. The target remote mode is lost so there is no automatic return to it.
Shed to Retained target, Normal return
– Target mode changes to retained target but returns to the target remote mode when the remote computer completes the initialization handshake.
Shed to Retained target, No return
– Target mode changes to retained target. The target remote mode is lost so there is no automatic return to it.
Tab. 2-11: Mode shedding options offered by Application Designer in RCas and Rout modes
22 Endress+Hauser
ControlCare Application Designer: Function Blocks
Linearization
Time constant
2 Function Block Application Process
2.5
Parameter calculation
2.5.1
Process variable PV
The process variable (PV) parameter of a block reflects the value and status of the primary input value or calculated value based on a multiple input. Depending on the function block it is characterized as follows:
• In the PID control and analog alarm (AALM) blocks, PV is the IN parameter after filtering
• In the analog input (AI) and output (AO) blocks, PV reflects the value from the transducer or transducer readback respectively, after filtering
• In the Arithmetic block (ARTH), PV is the combination of two input parameters for range extension.
Although it is a contained parameter, PV has a status. This is a copy of the primary input status or, when PV is based on multiple inputs, the worst encountered status. The PV value reflects the value of the calculated input regardless the mode of the block, unless its input is not usable. In this case,
PV holds the last usable value.
The parameter L_TYPE allows one of the following linearisation types to be selected:
Direct
Indirect
Indirect square root
With this setting the measured value from the transducer block (input value) avoids the linearisation function and is looped unchanged with the same unit through the block.
PV = Input value
The scaling and unit of XD_SCALE and OUT_SCALE must be the identical, otherwise the block will switch to OOS.
With this setting the measured value from the transducer block (input value) is re-scaled linearly via the input scaling XD_SCALE to the desired output range OUT_SCALE
PV =
X
100
– – Z where X = FIELD_VAL, Y = OUTSCALE_100%, Z = OUTSCALE_0%
With this setting the measured value from the transducer block (input value) is re-scaled via the parameter group XD_SCALE and recalculated using an evolution function. It is then rescaled again to the desired output range via the parameter group OUT_SCALE..
PV =
X
100
– – Z where X = FIELD_VAL, Y = OUTSCALE_100%, Z = OUTSCALE_0%
A damping filter may be applied in the PV signal through the time constant parameter PV_FTIME.
This represents the time in seconds PV requires to reach 63.2% of the final value after a step change to the input. If the PV_FTIME value is zero, the filter is disabled.
Endress+Hauser 23
2 Function Block Application Process ControlCare Application Designer: Function Blocks
Scaling algorithm
2.5.2
Scaling parameters XD_SCALE, PV_SCALE, OUT_SCALE
A control system must deal with a number of different signals, e.g. 4 mA to 20 mA, relays, pulse, fieldbus etc. as well as a variety of engineering units. The scaling parameters are used to convert from one set of units to another. There are two main applications:
• Display devices require the range and engineering units for bar graphs and trending
• Control blocks require the range as percent of span, so that the tuning constants can remain dimensionless.
There are three main scaling parameters which operate back-to-back across a function block,
XD_SCALE , PV_SCALE and OUT_SCALE . Normalized parameters are used between the two scalings, which is reflected in a number of contained parameters that can be viewed only in % of scale, see Fig. 2-8. Each scaling parameter has four elements:
• EU_100:
• EU_0:
Upper range-end value in engineering units
Lower range-end value in engineering units
• UNITS_INDEX: Engineering units of range-end values
• DECIMAL: Number of figures after the decimal point (default = 2)
The scaled value is obtained from the formulae:
• Conversion to % of scale: VALUE% = (VALUE - EU_0) * 100/ (EU_100 - EU_0)
• Conversion to engineering units: VALUE = [VALUE%* (EU_100 - EU_0) /100 ] + EU_0
By default, the EU_0 and EU_100 parameters are set to 0 and 100 respectively.
XD_SCALE
PV_SCALE
EU_100 100%
Block
Algorithm
EU_0 0%
0% 100% EU_0 EU_100
OUT_SCALE
OUT_RANGE parameters
Fig. 2-8: Scaling of block parameters
Table 2-12 summarizes the typical use of the scaling parameters in the blocks in which they appear.
Block
Analog Input (AI)
XD_SCALE PV_SCALE
Scales transducer output range n/a
OUT_SCALE
Scales to engineering range
PIDcontrol n/a Engineering range to % of scale % of scale to engineering range
Analog Output (AO) Scales to transducer input range Scales to engineering range n/a
Tab. 2-12: Typical scaling parameter usage in different function blocks
A number of blocks offer an OUT_RANGE or similar range parameter which scales the associated value for output to a HMI. The ranging proceeds in exactly the same way as for the SCALE parameters.
24 Endress+Hauser
ControlCare Application Designer: Function Blocks
Example using scaling parameters
2 Function Block Application Process
The temperature of the liquid in a small feed tank is to be kept constant at around 60°C. The tank is heated by a heating element with a 4 mA –20 mA control input and which is capable of heating the tank to 120°C. The temperature is measured by a 4 mA – 20 mA transmitter with a measuring range of -50°C to +150°C. A simple AI – PID – AO loop is used to control the input signal to the heater element controller.
Analog Input Block
The 4 mA to 20 mA input signal is converted to a % scale via the XD_SCALE parameter:
EU_100 = 20; EU_0 = 4; UNITS_INDEX = mA and DECIMAL = 2 (default)
The temperature signal in °C is obtained from the OUT_SCALE parameter:
EU_100 = 150; EU_0 = –50; UNITS_INDEX = °C and DECIMAL = 2 (default)
PID Control Block
The setpoint SP and the IN value are in °C, but PID algorithm works internally with values in percent of span. The PID block therefore converts the error to percentage (PV_SCALE), it calculates the output in percentage, and then it converts to engineering unit of output (OUT_SCALE).
The –50°C to 150°C input signal is converted to % of scale with the PV_SCALE parameter:
EU_100 = 150; EU_0 = –50; UNITS_INDEX = °C and DECIMAL = 2 (default)
If setpoint SP = 60°C and IN = 50°C, the scaled values are, see also previous page,
SP% = (60+50)*100/(150+50) = 55.00%
PV% = (50+50)*100/(150+50) = 50.00%
The PID algorithm calculates the error in percent. If reverse action is configured, the error is the difference between SP% and PV%.
Error% = SP% - PV % = 5.00%
The PID algorithm applies the Error% to the calculation of the P, I and D terms. If, for the sake of simplicity, only the proportional term is enabled, the value of the output is:
GAIN = 2.0; RESET = +INF; RATE = 0.0; OUT% = 10.00%
The output value could be converted from percentage to engineering units with the OUT_SCALE parameter, however, in order to illustrate scaling in the Analog Output block, in the example the output is set to %:
EU_100 = 100; EU_0 = 0; UNITS_INDEX = % and DECIMAL = 2 (default)
OUT = 10%
Analog Output Block
The heating coil controller requires a 4 –20 mA signal at its input, which is done though the two scaling parameters PV_SCALE which converts the CAS_IN value to 0% – 100% and the XD_SCALE parameter which converts from 0% – 100% to the signal range required by the transducer, in our case, 4 mA –20 mA.
For PV_SCALE: EU_100 = 100; EU_0 = 0; UNITS_INDEX = % and DECIMAL = 2 (default)
For XD_SCALE: EU_100 = 20; EU_0 = 4; UNITS_INDEX = mA and DECIMAL = 2 (default)
The CAS_IN signal of 10% is unchanged after PV scaling. The OUT value and the value at the transducer channel is:
10*(16 mA – 4 mA)/100 + 4 mA = 5.6 mA
It should be noted that the readback signal from the transmitter is subject to a scaling in the other direction, i.e. XD_SCALE => (0% – 100%) => PV_SCALE, so that the BKCAL_OUT parameter is always in the same units as are output by the PID block.
Endress+Hauser 25
2 Function Block Application Process
Setpoint limits
Setpoint rate limits
ControlCare Application Designer: Function Blocks
2.5.3
Setpoint SP
A setpoint is required by all control and output blocks. In non-cascaded control blocks it is set by the user in Application Designer. For output blocks and cascaded control blocks, it is provided by the CAS_IN parameter, see also Table 2-7. In addition, it is also possible to write a setpoint from a remote application when the block is operating in RCas mode.
Application Designer allows the user to apply limits to the setpoint value SP by entering appropriate values in the SP_HI_LIM and SP_LO_LIM parameters. These apply only if the block is operating in Auto mode. If the limits are to apply when the block is operating in Cas or RCas mode, then the option "Obey SP limits if Cas or RCas" must be selected in the CONTROL_OPTS parameter.
To avoid bump when the setpoint SP is changed, a ramp can be applied by entering appropriate values in SP_RATE_UP and SP_RATE_DN . Whether this function is available depends upon the block type and the block mode.
Target SP
Decrease in SP
Increase in SP
Time
Value SP
DELTA_2
DELTA_1
Time
DELTA_1/SP_RATE_UP DELTA_2/SP_RATE_DN
Fig. 2-9: Effect of SP_RATE_UP nad SP_RATE_DOWN on a change in setpoint
The setpoint rate limits can be applied to the:
• PID block in Auto mode
• AO block in Auto, Cas or RCas modes.
When the block is in Auto mode and the user changes the setpoint SP to a value greater than the current value, then the SP value ramps upward at a rate based on the parameter SP_RATE_UP . If the new setpoint is less than the current value, the SP value ramps downward at a rate based on the
SP_RATE_DN . If the parameter SP_RATE_DN and/or SP_RATE_UP is zero the rate limiting is disabled.
The Table 2-13 summarizes the conditions for setpoint limits and setpoint rate limits.
Block type Mode
PID
Required configuration for SP limits
SP_HI_LIM/SP_LO_LIM
None Auto
Cas/Rcas CONTROL_OPTS
"Obey SP limits if Cas or Rcas" is true
AO Auto None
Cas/Rcas Not applicable
Required configuration for SP rate limits
SP_RATE_UP/SP_RATE_DN
SP_RATE_UP/SP_RATE_DN not zero
Not applicable
SP_RATE_UP/SP_RATE_DN not zero
SP_RATE_UP/SP_RATE_DN not zero.
Tab. 2-13: Configuration of setpoint limit and rate limits
26 Endress+Hauser
ControlCare Application Designer: Function Blocks
Setpoint tracking PV
Ouput limits
2 Function Block Application Process
Some control strategies require that the transition from a "manual" mode (Rout, Man, LO and Iman) to an "auto" mode (Auto, Cas, Rcas) must be done with the control error equal to zero. In this case, the setpoint SP must be set equal to process value PV.
The CONTROL_OPTS of the PID block and the IO_OPTS of the AO block allow setpoint tracking of the process value to be activated when the block is in a "manual" mode.
This option is summarized in the following Table 2-14:
Option
SP-PV Track in Man
SP-PV Track in Rout
SP-PV Track in LO or Iman
CONTROL_OPTS
(PID)
X
X
X
IO_OPTS
(AO)
X
X
Meaning
The SP tracks the PV when the target mode is Man.
The SP tracks the PV when the actual mode is Rout.
The SP tracks the PV when the actual mode is LO or Iman.
Tab. 2-14: Setpoint tracking in CONTROL_OPS and IO_OPS
2.5.4
Ouput variable, OUT
When the actual block mode is Auto, Cas or RCas, the normal block algorithm is executed and the result output as the OUT parameter. This calculation is specific for each function block type. If the mode is a "manual" mode, the output will follow a value provided by another block (LO, Iman), the user (Man) or a control application running on an interface device (Rout).
In the PID and ARTH function blocks the parameters OUT_HI_LIM and OUT_LO_LIM can be used to limit the range of the OUT value. The limitation applies to all modes. For the PID block, output limits can be disabled in manual mode by selecting the option "No OUT limits in Manual" in the CONTROL_OPTS parameter.
2.5.5
Back calculation
The purpose of back calculation is to provide a value at the BKCAL_OUT (or BKCAL_SEL_N ) parameter that will cause the output of the upstream block to do the right thing to provide a bumpless mode transfer should there be no path from the downstream block to the final control element. BKCAL_OUT is linked to BKCAL_IN in all cases where it is used, and BKCAL_IN always sets the output value when the status requires that action.
The BKCAL_IN parameter carries the feedback, i.e. value and status, from the BKCAL_OUT parameter of a downstream control or analog output block. When BKCAL_IN is linked, the PID
Control block always acts on the status it carries. Should the status of BKCAL_IN indicate that there is no path to the final element, the block assumes IMan mode and initializes.
If the actual mode of the block is Auto, Cas, or Rcas and BKCAL_IN sees a limit status of high or low, the block will treat the value as the high or low OUT where the OUT limit may be the value offset by the block’s BKCAL_HYS parameter. The actual mode will not change, and the output will be free to move away from the limit.
If the actual mode of the block is Auto, Cas, or Rcas and BKCAL_IN sees a limit status of constant, the block will set its OUT to the BKCAL_IN value. It will not set the actual mode to IMan, unless the sub-status requires it.
If the status of BKCAL_IN is Bad, the actual block mode will go to IMan. The source of CAS_IN or BKCAL_IN is normally a block that follows the initialization procedure. If the source is a calculation block, the status may be Good (Non-cascade). If the source is a constant, the status may be Uncertain with an Initial or Substitute Value sub-status. In these cases, the initialization procedure will not be followed. The block will go immediately to its target mode when all other conditions are met.
Endress+Hauser 27
2 Function Block Application Process ControlCare Application Designer: Function Blocks
2.6
Status handling
Fieldbus devices have the ability to detect faults that make a measurement bad or prevent an actuator from responding. This information is transmitted together with the value generated by the device in the form of a status attribute. One of the most important features of the function block application process is that the status is passed with the value from one block to another block and can be accessed by an interface device for use in a human interface or a historian.
2.6.1
Status propagation
Fig. 2-9 shows the information flow in a simple control loop. In the so-called forward path, the primary output value of the Analog Input (AI) block provides the input to the PID control block and the primary output of the PID block provides the input to the Analog Output (AO) block. This acts on the information, e.g. by opening or closing the connected valve, and reports the position change to the PID block via the so-called backward path by means of the back calculation parameter.
Backward path
AI
Primary output
Back calculation input
Primary input
Primary output
PID
Cascade input
Back calculation output
AO
Forward path
Fig. 2-10: Information flow in a simple control loop
Each value exchanged along the loop has an associated status. In our example, the status of the primary output of the AI block will be used as the status of the primary input of the PID block.
Simularly, the status of the back calculation output of the AO block is passed on to the back calculation input of the PID block. There is no specific propagation rule for statuses within blocks, however, so it is perfectly feasible that the status of the primary input of the PID Control block is
"Bad", but the primary output has the status "Good".
In normal operation all statuses within the loop will be "Good". A "Bad" status can be generated by a number of situations, e.g. by putting a block into manual mode when changing parameters online, incorrect configuration of the block, communication failure, device failure etc. Once the cause of a "Bad" status has been remedied, the follow-up statuses will normally turn to "Good" again. It is possible, however, to configure the application such that certain status changes require an acknowledgement before they return to "Good" again
2.6.2
Status message
All input and output parameters and some contained parameter values, e.g. setpoint SP and process value PV, are accompanied by a status. This gives the receiver information not only about the quality of the value but also information that it can use in exceptional circumstances. The status itself comprises three components: quality, substatus and limits, as described in Table 2-15.
Table 2-16 lists the possible status messages that can occur during operation. The hexadecimal value indicates that the "Not Limited" limit status is active. Each message may be output with the alternative limit status "High Limited", Low Limited" or "Constant". The associated hexadecimal values are 1, 2 or 3 units higher than that in the table. In ControlCare Application Designer, the numerical value of the status parameter can be displayed by pressing the Symbol button in the toolbar, , see also Appendix A.
28 Endress+Hauser
ControlCare Application Designer: Function Blocks
Status attributes
Substatus values
Endress+Hauser
2 Function Block Application Process
Bad
Bad
Bad
Bad
Bad
Bad
Bad
Bad
.
Status attribute Description
Quality Provides an indication of whether the value can be used in subsequent block processing. It may assume one of four values:
• Good Cascade : the quality of the value is good; it may be part of a cascade path
• Good Non-Cascade : the quality of the value is good; the block has a cascade path
• Uncertain: the quality of the value cannot be determined, but the value may still be useful
• Bad : the value is not useful.
Substatus
Limits
Complements the quality and carries information to initialize or break cascade control, alarms and others. There are different sets of substatus for each quality, which are listed in Table 2.14.
Provides information on whether the associated value is limited or not, as well the direction of the limits. The limits are classified as:
• Not Limited : the associated value is within limits or no limits have been set
• High Limited : the associated value is violating a high limit
• Low Limited: the associated value is violating a high limit
• Constant : the block sending the status is operating in IMAN, MAN or LO mode
Tab. 2-15: Status attributes
Quality Substatus Hex value
Not in
X
X
Cascade path
Forward Backward
X
X
X
X
0 = Non-specific (lowest priority)
1 = Configuration Error
2 = Not Connected
3 = Device Failure
4 = Sensor Failure
5 = No Communication, Last Usable Value
6 = No Communication, No Usable Value
7 = Out of Service (highest priority)
0x00
0x04
0x08
0x0c
0x10
0x14
0x18
0x1c
X
X
X
X
X
X
X
X
X
Quality Substatus
Uncertain 0 = Non-specific (lowest priority)
Uncertain 1 = Last Usable Value
Uncertain 2 = Substitute
Uncertain 3 = Initial Value
Uncertain 4 = Sensor Conversion not Accurate
Uncertain 5 = Engineering Unit Range Violation
Uncertain 6 = Sub-normal
Quality Substatus
GoodNC
GoodNC
GoodNC
GoodNC
GoodNC
GoodNC
GoodNC
0 = Non-specific (lowest priority)
1 = Active Block Alarm
2 = Active Advisory Alarm
3 = Active Critical Alarm
4 = Unacknowledged Block Alarm
5 = Unacknowledged Advisory Alarm
6 = Unacknowledged Critical Alarm
Quality Substatus
GoodC
GoodC
GoodC
GoodC
GoodC
GoodC
GoodC
GoodC
0 = Non-specific (lowest priority) 0xc0
1 = Initialization Acknowledge(IA) 0xc4
2 = Initialization Request(IR)
3 = Not Invited (NI)
0xc8
0xcc
4 = Not Selected(NS)
6 = Local Override(LO)
7 = Fault State Active(FSA)
8 = Initiate Fault State (IFS)
0xd0
0xd8
0xdc
0xe0
0x80
0x84
0x88
0x8c
0x90
0x94
0x98
Hex value
Hex value
0x40
0x44
0x48
0x4c
0x50
0x54
0x58
Hex value
Not in
X
X
X
X
X
X
X
Cascade path
Forward Backward
Not in
X
X
X
X
X
X
X
Cascade path
Forward Backward
Not in
Cascade path
Forward Backward
X
X
X
X
X
X
X
X
X
Tab. 2-16: Substatus values as a function of status quality
29
2 Function Block Application Process
Status options
ControlCare Application Designer: Function Blocks
2.6.3
Substatus and limit propagation
The manner in which the status of block input parameters is propagated and used in the calculation of the block output status is determined for each function block type. The specific rules are described for each block, however, there are some general rules:
Rule Upstream status
Bad "Out of Service", "No Communication" are not propagated, as they are local to the block where they occur
Bad. Out of Service, Not Limited
Bad. No Communication, No Usable
Value, Not Limited
Bad "Sensor failure", "Device failure" are propagated intact through non-control functions. Control blocks generate an alert based on the input receiving the bad status.
Bad. Sensor Failure. Not Limited
Bad. Device Failure. Not Limited
Bad. Configuration Error. Not Limited
Received status
Bad. Non-specific, Not Limited
Bad. Sensor Failure. Not Limited
Bad. Device Failure. Not Limited
Bad. Non-Specific. Not Limited
Control blocks do not normally propagate input status to their output parameters.
Control Selector is an exception.
Input: Bad. Non-Specific. High
Limited
Uncertain substatusess are not propagated Uncertain. Subnormal.Not limited
GoodNC is propagated as GoodNC - Nonspecific, since all of substatuses are local
GoodNC. *** . Not Limited
GoodNC alarm substatuses are not propagated
Substatus is not propagated when two or more measurements are combined
Output. GoodC. Non-Specific. Not
Limited
Uncertain.Non-specific.Not limited
GoodNC. Non-Specific. Not Limited
GoodNC. Active Critical Alarm. Not
Limited
GoodNC. Non-Specific. Not Limited
GoodNC. Active Advisory Alarm. Not
Limited
GoodNC. Non-Specific. Not Limited
GoodNC. Non-Specific. Not Limited
MAN mode GoodC. Non-Specific. Constant A manual mode output is constant, but never uncertain
GoodC substatuses are propagated according to the function block type
GoodC. ***. Not Limited GoodC. ***. Not Limited
Tab. 2-17: General rules for status propagation
In addition to the general rules, specific options may be selected in some function blocks using the
STATUS_OPTS parameter. :
Bit
0
1
2
3
4
5
6
7
8
9
10 -
15
Option
IFS if BAD IN
IFS if BAD CAS_IN
Uncertain as Good
Propagate Fail Forward
Description Block
Sets Initiate Fault State status in the OUT parameter if the status of the
IN parameter is Bad.
PID
Sets Initiate Fault State status in the OUT parameter if the status of the
CAS_IN parameter is Bad
PID
If the status of the IN parameter is Uncertain, treats it as Good.
Propagates a transducer block status Bad.DeviceFailure or
Bad.SensorFailure to OUT without generating an alarm
PID, IS
AI, DI
Propagate Fail Backward AO, DO
Target to Manual if BAD IN Sets the target mode to Man if the status of the IN parameter is BAD.
This latches a PID block into the Man state if the input ever goes bad.
Uncertain if Limited Sets the output status of the block to Uncertain when limit alarms
HI_HI_, HI_, LO_ or LO_LO_ are violated
PID
AI
BAD if Limited
If the status from the actuator is Bad "Device failure" or "Fault State
Active", or Local Override is active, propagates this as Bad "Device
Failure" or Good Cascade "Fault State Active", or Local Override to
BKCAL_OUT respectively without generating an alarm.
Uncertain if Man
Target to next permitted mode if BAD CAS_IN
Reserved
Sets the output status of the block to Bad when limit alarms HI_HI_,
HI_, LO_ or LO_LO_ are violated
Sets the output status of the block to Uncertain if the actual mode of the block is Man
AI
AI, DI, IS;
IT
Sets the target mode to next permitted mode if the target mode is CAS and the status of CAS_IN is BAD.
PID
Tab. 2-18: Satus options (STATIUS_OPTS)
30 Endress+Hauser
ControlCare Application Designer: Function Blocks
Forward path
2 Function Block Application Process
2.6.4
Control loop integrity
The status of control and output block parameters is used for a number of purposes, e.g. to ensure bumpless transfer from one operating mode to another, to prevent reset windup, etc.
Closed-loop control normally includes an integrator, which drives the valve to the position required to bring the measurement to the setpoint. As long as an error exists, the integrator will continue to move its output in a direction that corrects the error. For predictable control, the output must NOT move if the error cannot be corrected.
If the control loop is broken and integration is allowed to continue, it will proceed until it reaches a limit. If the loop is now closed, the process will be disturbed, perhaps dangerously, as the integrator forces the output to a value beyond the valve limits and must first decrease output before the valve begins to close again. This behaviour is known as reset or integral wind-up. The error between measurement and setpoint, therefore, cannot be brought to zero by integration. The integration must be brought back to a reasonable value before control can resume. This period of lost control is avoided by utilizing status information passed between function blocks.
There are four cases to be considered for status generation:
• the forward path
• the backward path
• cascade control
• cascade initialization
Each case requires its own part of the status information.
In addition to normal operation with "Good" status, the following conditions might occur:
• Measurement is lost
• Connection to the process is lost
• Measurement is calculated using bad data, but the calculation has enough process data in it to allow control to continue
The following conditions can be passed forward from the source of the problem to the first integrating controller on the path:
Status*
GoodNC. Non-Specific. High Limited
Condition
Value is from a block that cannot generate a higher value because it is limited in that direction, either internally or by the transducer
GoodNC. Non-Specific. Low Limited Value is from a block that cannot generate a lower value because it is limited in that direction, either internally or by the transducer
Value cannot move; it is constant GoodNC. Non-Specific. Constant
GoodC. Initiate Fault State (IFS). Not Limited Value is from a block that has failed. The failure may be propagated to the downstream block for alarm and display purposes
Bad. No Communication, Last Usable Value.
Not Limited
Communication has failed along the path, the last usable value is offered
Bad. No Communication, No Usable Value.
Not Limited
Uncertain. Non-Specific. Not Limited
Communication has failed along the path, there is no usable value
Quality of the value is uncertain i.e. not good, but not bad either. The loop is degraded, but not broken. The block has an option to use the data or treat it as bad
*Examples of status messages: if a higher priority substatus or limit status is present, it will be passed on
Tab. 2-19: Forward path status and conditions
In the case of multiple sensors measuring the same value, "Good" status will indicate agreement of a specified number of sensors. "Uncertain" is used for anything less than the required number of sensors, provided at least one is working.
Endress+Hauser 31
2 Function Block Application Process
Backward path
Cascade control
ControlCare Application Designer: Function Blocks
In addition to normal operation with "Good" status, it is possible that the loop has been broken between control function block to the actuator.
In order that the upstream block is informed of the condition of the downstream block, a backcalculation value and status is sent along the backward path, i.e. from the downstream block to the upstream block. In the case of an actuator or control function block in cascade mode, this includes information about constrained movement and the working setpoint (or process variable). The information can be used for limiting or locking the output of an integrating controller or for initializing the upstream block.
The following conditions can be passed backward from the source of the problem to the first integrating controller on the path:
Status*
GoodC. Non-Specific. High Limited
Condition
Value is from a block that cannot generate a higher value because it is limited in that direction, either internally or externally
GoodC. Non-Specific. Low Limited Value is from a block that cannot generate a lower value because it is limited in that direction, either internally or externally
Value cannot move; it is constant GoodC. Non-Specific. Constant
GoodC. Initiate Fault State (IFS). Not Limited Value is from a block that has failed. The failure may be propagated to the upstream block for alarm and display purposes
GoodC. Local Override (LO). Not Limited Value is from an output block that has been locally overridden by a local key switch or has interlock logic active
GoodC. Fault State Active (FSA). Not Limited Value is from an output block that has Fault State logic active
Bad. No Communication, Last Usable Value.
Not Limited
Communication has failed along the path, the last usable value is offered
Bad. No Communication, No Usable Value.
Not Limited
Bad.Configuration Error.Not Limited
Communication has failed along the path, there is no usable value
Value is from a Control Selector which has not selected the corresponding input
*Examples of status messages: if a higher priority substatus or limit status is present, it will be passed on
Tab. 2-20: Backward path status and conditioins
In cascade control, the output of control function blocks does not go to an actuator, but becomes the setpoint of a downstream output function block or another control function block.
As far as the upstream control block is concerned, the loop can be broken by anything that breaks the loop of the downstream block or by the downstream control or output block operating in the wrong mode. When the cascade loop is broken, the output of the upstream control block must be made to match exactly the setpoint (or process variable)of the downstream block, in order to ensure bumpless transfer into a cascade mode. The value passed from the downstream to the upstream block to do this is called the initialization value. While the upstream block is setting its output to the initialization value, it with adopt the Iman mode.
In some cases, the source of the setpoint of a block is an interface device which does not contain the function block application. The application running on the interface device still has the same initialization requirements.
32 Endress+Hauser
ControlCare Application Designer: Function Blocks
Cascade initialization
2 Function Block Application Process
In order to implement cascade control, the following conditions are passed between the blocks:
Status Condition
Conditions passed from the downstream block to the upstream block or interface device
GoodC. Not Invited. Not Limited
GoodC. Initialization Request (IR).
Not Limited
Value is an initialization value for a source (CAS_IN, RCAS_IN or
ROUT_IN), because the downstream loop is broken or the mode of the downstream block is wrong. Cascade control is not invited.
Downstream block invites an initialized response on CAS_IN, RCAS_IN or ROUT_IN because the downstream loop is no longer broken and the target mode is now correct for the input.
Condition passed from the upstream to the downstream block
GoodC. Initialization Acknowledge (IA).
Not Limited
Downstream block invites an initialized response on CAS_IN, RCAS_IN or ROUT_IN because the downstream loop is no longer broken and the target mode is now correct for the input.
*Examples of status messages: if a higher priority substatus or limit status is present, it will be passed on
Tab. 2-21: Cascade status and conditions
The cascade path is always handled the same way for any block that supports a cascade structure
(i.e. has at least one backward path output). It is handled in the same way for each of Cas, RCas, and ROut modes, but with different parameters in the forward and backward paths. Table 2-22 specifies the parameters.
Mode Forward
Cas OUT
RCas
ROut
RCAS_IN
ROUT_IN
Backward
BKCAL_OUT
RCAS_OUT
ROUT_OUT
Tab. 2-22: Back calculation parameters as a function of block mode
In the case of RCas and ROut modes, both forward and backward parameters are part of the same block and are contained parameters read or written by an interface device. For Cas mode, the forward path is the OUT parameter of the upstream block linked to the CAS_IN parameter of the downstream block. The backward path comprises the BKCAL_OUT parameter of the downstream block linked to BKCAL_IN parameter of the upstream block.
When two blocks are operating in cascade and the loop is broken, the substatuses exchanged between them control the recovery to normal operation. Provided both blocks have the target modes required for cascade control, the procedure is as follows:
Step Mode*
1 Not cascade mode
2
3
4
Initialize
Initialization complete
Cascade complete
Action
• The loop is broken because the operating mode or conditions do not permit the cascade
• The downstream block sends "Not Invited" as its output status
• The operating mode of the upstream block moves to Iman and a reply is sent
• Provided the upstream block has not replied with "Initialization
Acknowledge", the downstream block moves to the next permissible operating mode.
• The downstream block now sends "Initialization Request" as its output status and waits for the reply "Initialization Acknowledge".
• The upstream block initializes, moves to the next permissible mode and replies with "Initialization Acknowledge"
• The downstream block moves to its normal operating mode, begins normal operation using the input value provided by the upstream control block, and sends a normal status, e.g. "Non-Specific" as its output
• The upstream block now begins normal operation and sends a normal status as its output , e.g. Non-Specific.
Tab. 2-23: Status generation on block initialization
Endress+Hauser 33
2 Function Block Application Process ControlCare Application Designer: Function Blocks
2.7
Fault state handling
Fault state is a special condition for an Analog Output or Discrete Output block that allows the connected device to fail-to-safe when the block detects an abnormal situation or the user sets the condition "Fault State" in the resource block.
An abnormal situation occurs when:
• there is bad input to the block (bad sensor, for example)
• there is no communication between blocks for a period longer than a specified time
Blocks that support cascade control such as PID, OSDL and SPLT, propagate the fault state status forward to the output block. When the condition that activated the fault state is rectified, the fault state is cleared and the block returns to the normal operation.
2.7.1
Control blocks
Blocks such as PID, OSDL and SPLT that support cascade control must be configured to send an
Initiate Fault State (IFS) status when they detect a bad input. The following options must be selected:
• Option "IFS if bad IN" in the STATUS_OPTS parameter and/or
• Option "IFS if bad CAS_IN" in the OSDL_OPTS parameter must be selected
The block now generates an IFS status in its OUT value when it detects a bad input.
Should a block operating in cascade mode (Cas, RCas) receive an IFS status, it is reported to forward path. For example, a PID block might receive a "Good Cascade IFS" status in the CAS_IN input from an upstream PID block. If the target mode of the PID block is Cas, then the IFS status will become the status of OUT , replacing the normal status. If the block is operating in Auto, however, the IFS status is not propagated forward.
2.7.2
Output blocks
Output blocks must be configured to respond to the IFS status. This is done by setting up a timeout parameter FSTATE_TIME and a fail-safe parameter FSTATE_VAL (AO block ) or
FSTATE_VAL_D (DO block) as follows:
• Set FSTATE_TIME , in units of 1/32 ms, to the time the output block can normally wait before responding to a fault state in or loss of communication with the upstream block
• Set FSTATE_VAL/FSTATE_VAL_D to the set point value (SP/SP_D)that causes the output device to assume fail-safe position.
The IO_OPTS parameter must now be configured to determine the block response to a fault state, whereby multiple choices are allowed. The option is set by ticking the selection box:
Option
Fault State to value
Target to Man if IFS
Set
On fault state, FSTATE_VAL/
FSTATE_VAL_D substitutes SP/SP_D
On fault state, the block mode is forced to
Man. In this mode, parameters can be changed
Clear)
On fault state, the last valid SP/SP_D value is used
On fault state, the block mode is forced to
Local Override, parameters cannot be changed until the fault state is cleared
Tab. 2-24: Configuration of IO_OPS for falut state handling
A third option, "Use Fault State value on restart" causes the value of FSTATE_VAL/FSTATE_VAL_D to be used on device restart. In this case, the value is used, although no fault state exists.
34 Endress+Hauser
ControlCare Application Designer: Function Blocks 2 Function Block Application Process
The output block will now respond to the following fault conditions by entering the configured fault state:
• Loss of communication to CAS_IN for a time that exceeds FSTATE_TIME
• IFS status in the CAS_IN input when the target mode is Cas for a time that exceeds
FSTATE_TIME
• IFS status in the RCAS_IN when the target mode is Rcas for a time that exceeds
FSTATE_TIME
In the backward path, the block sends the Not Invited (NI) status to indicate that the block is in
"Fault State".
After re-establishment of communication or closing of the circuit which initiated the action:
• blocks in Local Override recover automatically to the target mode
• blocks in Man must be reconfigured to adopt the target mode.
2.7.3
Forcing fault state
The resource block can be used to force all output function blocks associated with the device to change immediately to their fault state condition. The setup is as follows:
• Check that "Fault State supported" is available in the FEATURES parameter
• Select the option "Fault State supported" in FEATURES_SEL to enable the Fault State function in the resource block.
• Set SET_FSTATE to On to cause all output blocks to adopt their fault state behaviour
( FAULT_STATE becomes active in the STATUS_OPTS )
• Set CLEAR_FSTATE to On to cause all output blocks to resume normal operation
( FAULT_STATE is cleared in the STATUS_OPTS ).
• FAULT_STATE indicates the current Fault State in the resource block.
Endress+Hauser 35
2 Function Block Application Process
Grant
Deny
Options
ControlCare Application Designer: Function Blocks
2.8
Function block options
In addition to the common parameters, many blocks share common option parameters with which control the responses to input/output, control or status conditions. These are available in four bit strings that contain static configuration binary choices, see also previous chapters.
2.8.1
GRANT_DENY
GRANT_DENY controls access permission to various types of block parameter for higher level applications, e.g. a host computer or local operating panel. The parameter has two attributes named
Grant and Deny. The operation of these parameters is as described below, but the actual usage (if any) depends on the philosophy of the plant.
Depending on the philosophy of the plant, the operator, a higher level device or when local is selected, a local operator's panel may turn on an item of the Grant attribute. By doing or allowing this action, the operator gives up control of the selected parameters to the intervening device.
The function block does not check writes to any of the selected parameters for grant-deny permission. It is up to other devices to obey and enforce the rules, because the function block has no way to know what is writing to it. When the operator wants to regain control of the parameters, he clears the Grant item. The function block will then automatically set the corresponding Denied item. This indicates to the intervening device that control has been taken away.
The Deny attribute is provided for use by a monitoring application in an interface device and may not be changed by an operator. It allows the monitoring application to determine if control has been temporarily taken away during the execution of a batch program. This is done by first clearing one or all of the Denied items before execution of a batch program, then checking the Denied item after execution. The Grant item itself should not be checked for this condition, because the operator may have cleared and subsequently set the Grant item during batch program execution, a sequence that might be missed by a slowly scanning monitor program. The Denied item may not be cleared by the operator, thus latching the fact that control was taken away.
1
2
3
Table 2-25 indicates the various options of the GRANT_DENY parameter
Description Bit Option
GRANT
0 Program
Tune
Alarm
Local
A higher level device may change the:
• target mode,
• setpoint (if the block mode is Man or Auto) or
• output (if the block mode is Man) of the block
A higher level device may change the tuning parameters of the block
A higher level device may change the alarm parameters of the bloc
A local operator's panel or hand-held device may change the:
• target mode,
• setpoint (if the block mode is Man or Auto) or
• output (if the block mode is Man) of the block
1
2
DENY
0 Program Denied
3
Tune Denied
Alarm Denied
Local Denied
The Program permission item has been turned off
The Tune permission item has been turned off
The Alarm permission item has been turned off
The Local permission item has been turned off
Tab. 2-25: GRANT_DENY options
36 Endress+Hauser
ControlCare Application Designer: Function Blocks 2 Function Block Application Process
2.8.2
IO_OPTS
IO_OPTS activates the options for processing the input and output values of the function block
(I/O options). The following options apply when the they have been selected and the appropriate condition is true:
Bit
0
1
Option
Invert
SP-PV Track in MAN
Description
Permits the setpoint to track the process variable when the target mode of the block is MAN.
Block
Indicates whether the discrete input or ouput value should be logically inverted before it is stored in the process variable.
Normally a discrete value of zero(0) will be considered to be a logical zero(0) and an non-zero discrete value will be considered to be a logical (1). If invert is selected, the logical NOT of a non-zero field value would result in a zero(0) discrete output, the logical NOT of a zero field value would result in a discrete output value of one(1).
DI, DO
AO, DO
2
3
4
5
6
7
8
9
Reserved
SP-PV Track in LO
SP Track retained target
Increase to close
Fault State to value
Use Fault State value on restart
Target to Man if Fault State activated
Use PV for BKCAL_OUT
Permits the setpoint to track the process variable when the actual mode of the block is LO.
AO, DO
Permits the setpoint to track the RCAS or CAS parameter based on the retained target mode when the actual mode of the block is LO or
MAN. When SP-PV track options are enabled, then SP Track retained target will have precedence in the selection of the value to track if the actual mode is MAN and LO
AO, DO
AO Indicates whether the output value should be inverted before it is communicated to the I/O channel.
Selects the output action to take when fault occurs.
(0: freeze, 1: go to preset value)
AO, DO
Uses the value of FSTATE_VAL(_D) if the device is restarted, otherwise use the non-volatile value. This does not act like Fault State, just uses the value
AO, DO
AO, DO Sets the target mode to MAN, thus losing the original target, if Fault
State is activated. This latches an output block into the manual mode
The BKCAL_OUT value is normally the working SP. This option changes it to the PV
Enables the low cutoff algorithm for flow measurements
AO, DO
AI 10 Low cutoff
11 Reserved
12 Reserved
13 Reserved
14 Reserved
15 Reserved
Tab. 2-26: Input/Output block options
Endress+Hauser 37
2 Function Block Application Process ControlCare Application Designer: Function Blocks
2.8.3
CONTROL_OPTS
CONTROL_OPTS contains the available controller options for specifying the automation strategy.
The options apply when the they have been selected and the appropriate condition is true:
6
7
Bit
0
1
2
3
4
5
Option
Bypass Enable
SP-PV Track in MAN
SP-PV Track in ROUT
Permits the setpoint to track the process variable when the target mode of the block is MAN..
Permits the setpoint to track the process variable when the actual mode of the block is ROUT
PID, EPID,
APID, STEP
PID, EPID,
APID
SP-PV Track in LO or IMan Permits the setpoint to track the process variable when the actual mode of the block is LO or IMAN.
SP Track retained target
PID, EPID,
APID, STEP
Permits the setpoint to track the RCAS or CAS parameter based on the retained target mode when the actual mode of the block is IMAN, LO,
MAN, or ROUT. When SP-PV track options are enabled, then SP
Track retained target will have precedence in the selection of the value to track when the actual mode is MAN, IMAN, ROUT, and LO
PID, EPID,
APID, STEP
Direct Acting Defines the relationship between a change in PV and corresponding change in output. When Direct is selected, an increase in PV results in an increase in the output.
PID, EPID,
APID; STEP
Balance Ramp
Track Enable
Description
Allows BYPASS to be set. Some control algorithm applications cannot provide closed loop control if bypassed.
Block
PID, EPID,
APID, CHAR
8
9
Track in Manual
Use PV for BKCAL_OUT
Not used
Enables the external tracking function. If true, the value in TRK_VAL will replace the value of OUT if TRK_IN_D becomes true and the target mode is not MAN.
PID, E; PID,
APID
Enables TRK_VAL to replace the value of OUT when the target mode is MAN and TRK_IN_D is true. The actual mode will then be LO
PID, EPID,
APIDP
BKCAL_OUT and RCAS_OUT values are normally the working SP. If this option is enabled, then the PV value will be used after the cascade is closed.
PID, EPID,
APID, STEP
10 BIAS may be adjusted
11 Convert IN_1 to
OUT_SCALE
10 Act on IR
Not used
Not used
If this option is true, then when IR (initiation request) is received as the status in BKCAL_IN, the SP will be adjusted within setpoint limits to provide bumpless transfer when the cascade is closed. If the setpoint required to provide bumpless transfer is outside the setpoint limits, then any difference added to provide bumpless transfer will be removed in the BAL_TIME
PID, EPID,
APID
11 Use BKCAL_OUT with IN_1 Normally, BKCAL_OUT is associated with initialization of an upstream block which is providing CAS_IN. If this option is set, then
BKCAL_OUT is to be associated with the upstream block providing
IN_1. This option may be used with the Ratio and Bias/Gain block to determine the value and status which must be provided in
BKCAL_OUT for proper initialization and handshaking.
PID, EPID,
APID
PID, EPID,
APID, STEP
12 Restrict SP to limits in CAS or
RCAS
Normally the setpoint will not be restricted to the setpoint limits except when entered by a human interface device. However, if this option is selected, the setpoint will be restricted to the setpoint absolute limits in the Cas and RCas modes
13 No OUT limits in MAN Does not apply OUT_HI_LIM or OUT_LO_LIM when target and actual modes are MAN. Trust the operator to do the right thing.
PID, EPID,
APID
14 Reserved
15 Reserved
Tab. 2-27: Control options
Tab. 2-28:
38 Endress+Hauser
ControlCare Application Designer: Function Blocks
Handling mechanism
2 Function Block Application Process
2.9
Alert handling
FOUNDATION Fieldbus Specification 890 describes an alert handling concept for FOUNDATION
Fieldbus applications. Alerts are alarms and events, which represent state changes within function block applications. Within the model, devices supporting alert handling report to an interface device via an alert object. The interface device is responsible for alert processing. If e.g. a SCADA system is used as operational interface, this has the consequence that the alarming can be configured offline in the individual function block during the engineering phase. The operating system then accesses the alert parameters through the HSE OPC server.
Alerts are handled as follows. The alert notifier examines the results of resource, transducer and function block executions to determine if any of a defined set of alert states has been entered. When this is the case, the alert object builds a report message, a so-called event notification, and publishes it to the network. The time at which the alert state was detected is included as a time stamp in the alert message.
If several alerts are present at one time, they are queued and published according thier age and priority. The associated alert is removed from the queue as soon as a reply is received confirming the receipt of the notification. The time-out period for receiving replies and number of alerts awaiting reply can be configured in the Resource Block of each device. If the time-out period is exceeded, the alert is added to a retransmission list.
Alert handling also includes acknowledgement of alerts. This indicates that the alert has been processed by an interface device to satisfy operational interface requirements. The acknowledgement can be configured to be disabled, manual or automatic.
2.9.1
Events and alarms
Events are usually associated with a change in configuration caused by , e.g. a user intervention. As mentioned previously, specific changes in dynamic parameters are not tracked, as these are part and parcel of normal operation. The following events are signalled and can be tracked when the appropriate parameters are set:
• A change of status of the WRITE_LOCK parameter in the Resource Block, see Chapter 3.2.6
• Any change in a static parameter in any block
The parameter UPDATE_EVT provides an alert for any change in a static parameter and includes the relative parameter index and its associated block index together with the new value of ST_REV . The alert is auto-acknowledged. Alerts are not generated while a block is
Out of Service, but the ST_REV parameter continues to increment. When the block returns to normal operation, an alert is generated if the ST_REV parameter has increased.
There are two basic types of alarm, whereby both entering and exiting a limiting alarm condition creates a change in alert status:
• Block alarms reflect errors in the hardware and software associated with the block
The alarms generated are displayed in the parameter BLOCK_ERR and depend upon the block. Block alarms always have Priority 2. The parameter BLOCK_ALM displays details, communicates the alarm to the interface device and allows the alarm to be acknowledged.
• Limit alarms are generated due to the limiting of process variables
The parameter ALARM_SUM summarizes the current status of all the limit alarms. Limits are set in the xxx_LIM parameter of the block and the ALARM_HYS parameter imposes a universal hysteresis. Alarm priority is set in the appropriate xxx_PRI parameter. The xxx_ALM parameter displays the current status of the limit and allows alarms to be acknowledged.
Endress+Hauser 39
2 Function Block Application Process
Reporting
Priority and acknowledgement
ControlCare Application Designer: Function Blocks
2.9.2
Reporting, priority and acknowledgement
Alert reporting is set up for the entire resource through the device Resource Block. The message
"Reports supported" in the FEATURES parameter of the resource block indicates that the device has an alert notifier. The reporting of alerts must be activated in the Resource Block by selecting the option "Reports supported" in the FEATURE_SEL parameter, see Chapter 3.2.4.
Three parameters control the queuing of alerts:
• MAX_NOTIFY can be read online and indicates the maximum number of alert reports that the device can send without receiving a confirmation
• LIM_NOTIFY allows the user to select the number of alert reports the device can send without receiving a confirmation. If LIM_NOTIFY is set to zero, then no alerts are reported.
• CONFIRM_TIME determines the time the resource will wait for confirmation of receipt of a report before trying again. If the CONFIRM_TIME = 0 the device will not retry.
The alert priority is set in the corresponding alarm priority parameter of the function block concerned. By default, an alert must be manually acknowledged in the corresponding alarm display parameter, see Chapters 2.9.4 and 2.9.5. manual acknowledgement can be disabled for one or more alarm classes by ticking the option "xxx Alarm Disable" or "xxx Alarm Auto Acknowledge" (depends on the device DD) in the parameter ACK_OPTION . When disabled, the alert is automatically acknowledged .
Table 2-29 summarizes the parameters to be configured to activate alert reporting and set up alarm priorities and acknowledgement.
Parameter
ALERT_KEY
Description
Optional index that identifies the plant unit, see Chapter 2.3.4
FEATURE_SEL Activates the salient feature provided it is supported by the device
• Reports: When ticked, activates reporting for all blocks
• Soft Write Lock: When ticked, activates reporting for change in WRITE_LOCK parameter, provided there is no hardware lock
Indicates maximum number of unconfirmed reports that can be stored by the device MAX_NOTIFY
LIM_NOTIFY Sets number of unconfirmed reports that to be stored by the device
– LIM_NOTIFY may not exceed MAX_NOTIFY
– If LIM_NOTIFY = 0, then no alerts are reported
CONFIRM_TIME Sets time limit for receipt of alert notification confirmation from interface device.
– Setting is multiplied by 1/32 milliseconds to obtain time period
– If no confirmation is received within this time, the report is sent again
ACK_OPTION Enables or disables auto-acknowledgment in block for each class of alarm. When disabled (no tick in box), the alarms must be acknowledged in the salient xxx_ALM parameter.
For resource block:
• 1: Write Lock Alarm Disabled /Write Lock Alarm Auto Acknowledge
• 8: Block Alarm Disabled (Resource block)/Block Alarm Auto Acknowledge
For other blocks, see also Table 2-31:
• 0: Discrete Alarm Disabled
• 1: HiHi Alarm Disabled
• 2: Hi Alarm Disabled
• 3: LoLo Alarm Disabled
• 4: Lo Alarm Disabled
• 5: Deviation Hi Alarm Disabled/Deviation Hi Alarm Auto Acknowledge
• 6: Deviation Lo Alarm Disabled/Deviation Lo Alarm Auto Acknowledge
• 7: Block Alarm Disabled/Block Alarm Auto Acknowledge
WRITE_PRI
DISC_PRI
LO_LO_PRI
LO_PRI
HI_PRI
HI_HI_PRI
DV_HI_PRI
DV_LO_PRI
Priority of an alarm or event. If no setting is made the acknowledgement is "undefined".
• 0-1: Associated alert is not sent as a notification; normally auto-acknowledged.
• 2: Reserved for alerts that do not require the attention of a plant operator.
Block alarm and update event have this priority; normally auto-acknowledged.
• 3-7: Advisory alarms. Alarms of this priority will normally be acknowledged.
• 8-15: Critical alarms. Alarms of this priority will normally be acknowledged.
Tab. 2-29: Parameters for alert reporting
40 Endress+Hauser
ControlCare Application Designer: Function Blocks 2 Function Block Application Process
2.9.3
Limit alarms
The user can set limits on a number of process values that are used by various function blocks.
Table 2-30 summarizes the possibilities
Block
AI
DI
PID, AALM
PID
SPG
Parameter
OUT
OUT_D
PV
PV-SP
BKCAL_IN/OUT
Disc x
Hi_Hi x x
Hi x x
Lo_Lo x x
Lo x x
Dev_Hi Dev_Lo x x x x
Tab. 2-30: Limit values as a function of parameter and block
An alarm occurs when a value meets, exceeds or drops below a limit.
• For a high alarm, an alarm is true when the analog value is greater than the limit. The status of the alarm remains true until the value drops below the limit minus any alarm hysteresis.
• For a low alarm, an alarm is true when the analog value is lower than the limit. The status of the alarm remains true until the value rises above the limit plus any alarm hysteresis.
An alarm type can be disabled by setting its respective alarm limit parameter to
infinity. This is the default value of all alarm limits. The value range is given by the scaling of the output parameter.
If the entered value exceeds this range (excluding
infinity), a block configuration error is flagged in BLOCK_ERR .
The parameters required to set up process value limiting are summarized in Table 2-31.
Parameter
DISC_LIM
HI_HI_LIM
HI_LIM
LO_LIM
LO_LO_LIM
DV_HI_LIM
DV_LO_LIM
Block
DI
PID, SPG
Description
Value of discrete output OUT_D (0 or 1) for which an alert is to be sent
AI, AALM, PID Limit value in units of PV_SCALE or OUT_SCALE for upper critical limit
Limit value in units of PV_SCALE or OUT_SCALE for upper advisory limit
Limit value in units of PV_SCALE or OUT_SCALE for lower advisory limit
Limit value in units of PV_SCALE or OUT_SCALE for lower critical limit
Limit value in units of PV_SCALE for PV or PV-SP upper limit
Limit value in units of PV_SCALE for PV or PV-SP lower limit
ALARM_HYS AI, AALM, PID Amount the PV or OUT value must return within the alarm limits, expressed as a percent of the PV/OUT span, before the alarm condition clears. The span used depends on the block type:
• PID: PV_SCALE
• AI, Setpoint generator, Analog alarm: OUT_SCALE
DI, AI, AALM,
PID, SPG
DISC_PRI
LO_LO_PRI
LO_PRI
HI_PRI
HI_HI_PRI
DV_HI_PRI
DV_LO_PRI
Priority of an alarm or event. If no setting is made the acknowledgement is "undefined".
• 0-1: Associated alert is not sent as a notification; normally auto-acknowledged.
• 2: Reserved for alerts that do not require the attention of a plant operator.
Block alarm and update event have this priority; normally auto-acknowledged.
• 3-7: Advisory alarms. Alarms of this priority will normally be acknowledged.
• 8-15: Critical alarms. Alarms of this priority will normally be acknowledged.
ACK_OPTION Enables or disables auto-acknowledgment in block for each class of alarm. When disabled (no tick in box), the alarms must be acknowledged in the salient xxx_ALM parameter.
• 0: Discrete Alarm Disabled
• 1: HiHi Alarm Disabled
• 2: Hi Alarm Disabled
• 3: LoLo Alarm Disabled
• 4: Lo Alarm Disabled
• 5: Deviation Hi Alarm Disabled/Deviation Hi Alarm Auto Acknowledge
• 6: Deviation Lo Alarm Disabled/Deviation Lo Alarm Auto Acknowledge
• 7: Block Alarm Disabled/Block Alarm Auto Acknowledge
Tab. 2-31: Parameters for process value limiting
Endress+Hauser 41
2 Function Block Application Process
BLOCK_ERR
XD_ERROR
UPDATE_EVT
ALARM_SUM
ControlCare Application Designer: Function Blocks
2.9.4
Event update and alarm summaries
The BLOCK_ERR parameter reflects the error status of hardware or software components associated with the block and that have a direct impact on its correct operation. It comprises a bit string in which block error conditions (0= inactive, 1 = active) are reflected as follows:
5
6
3
4
7
1
2
Bit
0
Condition
Other (LSB)
Block Configuration Error
Link Configuration Error
Simulate Active
Local Override
Device Fault State Set
Device Needs Maintenance Soon
Input Failure/ process variable has BAD status
11
12
13
14
15
Bit
8
9
10
Condition
Output Failure
Memory Failure
Lost Static Data
Lost NV Data
Readback Check Failed
Device Needs Maintenance Now
Power-up
Out-of-Service (MSB)
Tab. 2-32: Block error parameter conditions
The bits maintained depend upon the type and function of the block. The block alarms are displayed and communicated to the host system via the parameter BLOCK_ALM . The alarms must be acknowledged in the BLOCK_ALM parameter, see also Chapter 2.9, unless the option "Block
Alarm Auto Acknowledge"/"Block Alarm Disabled" (Depends on Device DD) has been ticked in the parameter ACK_OPTION .
Note!
• For the resource block, simulate active is used to indicate whether the simulate hardware jumper is present on the associated device. An active state (1) of this attribute indicates that the jumper is present and that it is possible for the user to enable simulation in an input or output class function block.
The XD_ERROR parameter reflects the error status of hardware or software components associated with a transducer block and that have a direct impact on its correct operation. It comprises a bit string in which block error conditions (0= inactive, 1 = active) are reflected as follows:
Bit
16
17
18
19
20
Condition
Unspecified Error
General Error
Calibration Error
Configuration Error
Electronics Failure
Bit
21
22
23
24
25
Condition
Mechanical Failure
I/O Failure
Data Integrity Error
Software Error
Algorithm Error
Tab. 2-33: Transducer block parameter conditions
The UPDATE_EVT parameter captures the dynamic information associated with a write to a static parameter within the block. The parameter has the following attributes:
• UNAKNOWLEDGED: shows the status of the alert acknowledgement
• UPDATE_STATE: shows reported state of the update
• TIME_STAMP: shows the time at which the static parameter was changed
• STATIC_REVISION: shows the new static revision level (ST_REV)
• RELATIVE_INDEX: shows the index of the changed parameter
The ALARM_SUM parameter summarizes the status of up to 16 process alarms belonging to the same block. The parameter has four attributes, see also Chapter 2.9.5:
• CURRENT: shows for each alarm whether it is active
• UNAKNOWLEDGED: shows for each alarm whether it has been acknowledged
• UNREPORTED: shows for each alarm whether it has been reported
• DISABLED: shows for each alarm whether it has been disabled in ACK_OPTION
42 Endress+Hauser
ControlCare Application Designer: Function Blocks 2 Function Block Application Process
2.9.5
Alarm display parameters
Each block has one or more parameters to capture the dynamic information associated with an alarm.
• Hardware and software errors for the block are captured in the parameter BLOCK_ALM
• For the resource block, WRITE_LOCK changes are captured in the parameter WRITE_ALM
• Limit value alarms are captured in the corresponding parameter xxx_ALM
All types have the structure shown in Table 2-34. The information contained is transferred to an alert object when the alarm is reported. If the alert has a priority greater than 2 and the alarm class has not been disabled in the ACK_OPTIONS parameter, it can be acknowledged in the parameter
UNACKNOWLEDGE .
Parameter
BLOCK_ALM
WRITE_ALM
DISC_ALM
HI_HI_ALM
HI_ALM
LO_ALM
LO_LO_ALM
DV_HI_ALM
DV_LO_ALM
Attribute Value
UNACKNOWLEDGED As read or entered
ALARM_STATE
TIME_STAMP
As read
As read
SUB_CODE
VALUE
As read
As read
Description
Indicates acknowledgement of current alert state: i.e.
Undefined, Acknowledged, Unacknowledged
• User can acknowledge via this parameter
Indicates of whether the alert is active and reported.
The alarm state is cleared when the block goes to
Out of Service mode. Possible values are:
• Clear-Reported, Clear-Not Reported,
Active-Reported, Active-Not Reported
Indicates time when the alarm state was detected.
The value is maintained until alert confirmation has been received.
Displays number specifying the cause of the alert
The value of the associated parameter at the time the alert was detected
Tab. 2-34: Alarm display parameters
Endress+Hauser 43
2 Function Block Application Process ControlCare Application Designer: Function Blocks
2.9.6
Example
Fig. 2-11 shows a typical response to a HI limit violation. A HI_LIM of 190 is set for the OUT variable of a function block. The alarm hysteresis parameter ALARM_HYS is set to 10. When the
OUT value exceeds 190, the HI_ALM.Unacknowledged parameter changes from Acknowledged to
Unacknowledged and the HI_ALM.ALARM_STATE parameter changes to Active_Not_Reported.
An alarm notification message is now output to the bus. The HI_ALM.ALARM_STATE parameter changes to Active_Reported. The Alarm Notification is answered within the set CONFIRM_TIME.
When the operator acknowledges the alarm in the HI_ALM.Unacknowledged parameter, this changes to Acknowledged.
The process value now returns to limits, the HI_ALM.ALARM_STATE parameter changes to
Clear_Not_Reported only after it passes the HI limit minus the hysteresis (for LO limits, the hysteresis acts in the other direction). At this point an alarm notification message is output to the bus and the HI_ALM.ALARM_STATE parameter changes to Clear_Reported. In the example, no reply is received to the message within the set CONFIRM_TIME, and the message is output again.
OUT. VALUE
190
180
ALARM_HYS t
HI_ALM.ALARM_ STATE
ACTIVE_NOT_REP
ACTIVE_REP
CLR_NOT_REP
CLR_REP t
HI_ALM.
UNACKNOWLEDGED
UNACK
ACK t
44
BUS
INTERFACE DEV_TX
FIELD DEV_TX
ALERT NOTIFY - CONFIRMATION
1
2 3
ALERT ACK (OPERATOR PLANT INTERVENTION)
ALERT NOTIFY 1 ALERT NOTIFY 1
2 t
> CONFIRM_TIME < CONFIRM_TIME
Fig. 2-11: Alert processing
Endress+Hauser
ControlCare Application Designer: Function Blocks
Enable simulation
Disable simulation
Effect
2 Function Block Application Process
2.10 Simulation
Simulation allows the checking and diagnosis of function blocks and control loops during installation and commissioning of the plant. To this end, all input and output function blocks have a
SIMULATE , SIMULATE_D or SIMULATE_P parameter, which overrides the transducer block input or hardware channel output when the function is enabled.
In order to prevent accidental switching to simulation mode during operation, every device has a hardware lock, i.e. a jumper, switch or relay that controls the simulation function within the device as a whole. The state of this lock is indicated in the resource block BLOCK_ERR parameter, which flags "Simulation Active" when it is enabled. If the hardware lock is in the disable position, it is not possible to write to the SIMULATE ( SIMULATE_D or SIMULATE_P ) parameters.
Once activated within the device as a whole, simulation can be enabled within an individual I/O block by expanding the SIMULATE ( SIMULATE_D or SIMULATE_P ) parameter.
• Set the status of the simulated variable in SIMULATE_STATUS etc.
• Set the value of the simulated variable in SIMULATE_VALUE etc.
• Set ENABLE_DISABLE to "Active" to start simulation in the block
The parameters TRANSDUCER_STATUS and TRANSDUCER_VALUE indicate the status and value of the raw process value or readback value. The block output/readback reflects the simulated parameters after processing in the block. When simulation is active, the BLOCK_ERR parameter of the I/O block flags "Simulation Active".
Simulation in an I/O block is disabled by setting ENABLE_DISABLE to "Disable". In this state
SIMULATE_STATUS and SIMULATE_VALUE etc. track TRANSDUCER_STATUS and
TRANSDUCER_VALUE in order to provide a bumpless transfer from disabled to enabled.
Simulation for the whole device is disabled by resetting the hardware lock.
Note
• Some devices must be restarted in order to detect a change in the hardware lock, while others do this during normal device operation.
Table 2-35 indicates the effect of simulation on the output of the block. When simulation is enabled in an input block, the simulated parameter becomes the OUT parameter (Process Value) after scaling, linearization and filtering. The status value can be used to simulate transducer faults.
For output blocks, the simulated parameter becomes the READBACK parameter. The status can be used to simulate transducer faults. The transducer value and status reflect the transducer readback value and status. The transducer maintains last the output and ignores the OUT of the block.
Block Simulation condition
Action
AI, DI, PUL Enable
Disable
SIMULATE.Simulate Value and Status -> PV
(after scaling,linearization and filtering)
SIMULATE.Transducer Value and Status -> PV
(after scaling,linearization and filtering) and
SIMULATE.Simulate Value and Status
AO, DO Enable
Disable
SIMULATE.Simulate Value and Status -> READBACK
SIMULATE.Transducer Value and Status -> READBACK and SIMULATE.Simulate Value and Status
Tab. 2-35: Effect of simulation
Endress+Hauser 45
2 Function Block Application Process ControlCare Application Designer: Function Blocks
2.11 Changing function block parameters
In Application Designer, function block parameters may be set either off-line, e.g. during the planning stage, or on-line when the project is running. When on-line, Read Only parameters show the current values generated by the devices in the project. With a few exceptions, e.g. SP of a PID block, Read/Write parameters are not directly editable on-line and the block must be put out of service as described in Chapter 2.11.2 below.
2.11.1 Off-line characterization
1 In the Fieldbus/PROFIBUS network or Control module workspace, right-click on the function block and select Off-line Characterization
– The function block Off-line Characterization dialog appears
2 Change the parameters you wish to modify
– If appropriate, open the parameter leaf and double-click in the space next to the parameter you require
– Enter the new parameter or select it from the drop-down menu
– Click End Edit to set the parameter
– Repeat the procedure for all the parameters you wish to modify
– Press Close to store the values
3 Click on the Project View workspace and Export Tags ...,
– Open Project File , then press Save Entire Project to save the project
46 Endress+Hauser
ControlCare Application Designer: Function Blocks 2 Function Block Application Process
2.11.2
On-line characterization
1 In the Control strategy workspace double-click on the function block you want to modify, or in the Fieldbus/ PROFIBUS network or Control module workspace, right-click on the function block and select On-line Characterization
Endress+Hauser
2 The function block On-line Characterization dialog appears:
– Open the Mode leaf and double-click in the space next to Target
– Set the Target to OOS (Out of Service)
– Click End Edit to set the parameter
3 Change the parameters you wish to modify
– If appropriate, open the parameter leaf and double-click in the space next to the parameter you require
– Enter the new parameter or select it from the drop-down menu
– Click End Edit to set the parameter
– Repeat the procedure for all the parameters you wish to modify
4 Put the function block back into standard operating mode
– Open the Mode leaf and double-click in the space next to Target
– Set the Target back to the original value ( Auto (Automatic) or Cas (Cascade))
– Click End Edit to set the parameter
– Check that the Mode really changes to the Target Mode (failure to do so indicates a configuration error)
– Press Close to store the values (if you are prompted - answer with Yes )
5 Click on the Project View workspace and Export Tags ...,
– Open Project File , then press Save Entire Project to save the project
6 If your changes have any effect on the function block schedule, e.g. modifying execution times, download the modified project
– In the Project workspace right-click on Fieldbus Network and select Download
47
3 Resource Block ControlCare Application Designer: Function Blocks
3 Resource Block
Every FOUNDATION Fieldbus device has a resource block comprising all data that uniquely identify and characterize its hardware and software. Since the resource block has contained parameters only, i.e. no block input/output data, it cannot be linked to other blocks.
Resource block parameters can be classified into two groups, informative and operational. Each group is further divided into static and dynamic data.
• Informative parameters provide an overview of the hardware and software implemented in the device. Parameters of this nature include device type, device name, manufacturer ID, serial number. In addition, when on-line, the block also indicates the settings of any hardware switches controlling the write lock and simulation functions.
• Operational parameters influence the execution of the other blocks in the field device. In this case, the resource block acts as a central unit that checks the device status, flags alarms when necessary and controls the operability of the other blocks and hence the device itself.
In the following, only the major parameters are described in detail. Short descriptions of parameters with specialised use and described elsewhere in this manual are to be found in Table 3.8. of
Chapter 3.3.
3.1
Informative parameters
3.1.1
Device software
The resource block contains a number of parameters which act as an "electronic" nameplate for the associated device. In addition, there are a number of parameters that indicate or influence the performance of the device. They can be viewed in the On Line Characterization dialog.
Parameter
DD_RESOURCE
MANUFAC_ID
DEV_TYPE
DEV_REV
DD_REV
MIN_CYCLE_T
MEMORY_SIZE
FREE_SPACE
FREE_TIME
Description
Tag of the resource containing the device description
Manufacturer’s identification number
Manufacturer's model number associated with the resource
Manufacturer’s revision number associated with the resource
Revision of the DD associated with the resource
Minimum time, in units of in 1/32 ms, that the device requires for function block execution
• Any function block schedule time downloaded to the device must be greater than this value
Indicates the total memory in kbytes available in the device for function b lock configuration
Indicates the percentage of configuration memory that is still available
Indicates the approximate percentage of time that the device has left for processing new function blocks, should they be configured
ITK_VER
ENP_VERSION
DEVICE_TAG
SERIAL_NUMBER
Version number of the ITK test used as basis for certifying the device
Version number of the Electronic Nameplate
Device tag downloaded from the project to the device
Manufacturer’s serial number for the device
ORDER_CODE Manufacturer’s order code for the device
FIRMWARE_REVISION Revision number of the firmware of the device
48 Endress+Hauser
ControlCare Application Designer: Function Blocks 3 Resource Block
3.1.2
Device hardware
In addition to the "nameplate", the resource block has a number of parameters that indicate the hardware configuration of the device. They can be viewed in the On Line Characterization dialog. In some cases it is possible to influence the configuration of the device through an associated parameter.
Parameter
HARD_TYPES
FEATURES
FEATURE_SEL
WRITE_LOCK
Description
Read only bitstring that indicates the types of hardware that are available to the device
• If an I/O block is configured that requires a type of hardware that is not available to the device, the BLOCK_ERR parameter indicates a configuration error
Read only parameter indicating the hardware and sofware features available in the device
• See Chapter 3.2.4 for additional information
Read/Write parameter allowing the selected hardware and sofware features to be enabled
• Click in the box to activate the feature; multiple selections allowed
Indicates the position of the hardware jumper controlling the write protection of the device
• LOCKED: device data cannot be modified
• NOT LOCKED: device data can be modified
3.1.3
Hardware write lock
If the device is provided with a hardware lock, e.g. jumper, switch or magnetic relay, for configuring write protection, the option "Hard Write lock supported" will appear in the FEATURES parameter.
After selection of the option "Hard Write lock" in the FEATURE_SEL parameter, the parameter
WRITE_LOCK shows the status of the jumper. The following statuses are possible:
• LOCKED: static and non-volatile parameters cannot be changed. Block connections and calculation results will proceed normally, but the configuration will be locked
• NOT LOCKED: static and non-volatile parameters can be changed
When the jumper is configured for "LOCKED" and "Hard Write lock" is activated in
FEATURE_SEL , there can be no write actions to parameters in the device. The hard lock stays active until the jumper position is changed.
If the position of the jumper is changed from "LOCKED" to "NOT LOCKED", the discrete alert
WRITE_ALM is generated at the priority WRITE_PRI . Resetting the´jumper will clear the alert, if it exists.
Note
• Some devices must be restarted in order to detect a change in the hardware lock, while others do this during normal device operation.
3.1.4
Simulation
Simulation is obligatory in all FOUNDATION Fieldbus devices and is controlled by a hardware lock, e.g. a jumper, switch or magnetic relay. When the hardware lock is in the position "Enable
Simulation", the alert "Simulation active" appears in the BLOCK_ERR parameter.
Chapter 2.10 contains a full description of simulation.
Note
• Some devices must be restarted in order to detect a change in the simulationock, while others do this during normal device operation.
Endress+Hauser 49
3 Resource Block ControlCare Application Designer: Function Blocks
3.2
Operational parameters
3.2.1
Block operation
Chapter 2.4 provides a general description of block operation and block parameters.
In the case of the resource block, the MODE_BLK parameter MODE_BLK.Target
controls operation of the entire device. If the parameter is set to "Out of Service" (OOS), all function block execution within the complete device is disabled. The actual mode of all the function blocks within the device are changed to OOS, but their target mode is not changed.
The resource block operates normally when it is in AUTO mode. In some cases, the IMAN mode is also supported: the block assumes this status when the resource is initializing or receiving a software download.
When the block is out of service, the status is flagged with the message "Block status OOS" in the parameter BLOCK_ERR .
3.2.2
Resource state
The current operating status of the resource block can be viewed in the On Line Characterization dialog through the parameter RS_STATE . Depending upon the device, the following states are possible:
State
UNDEFINED
START/RESTART
INITIALIZATION
ON-LINE LINKING
ON-LINE
STANDBY
FAILURE
Description
The block is in an invalid state.
This state is entered on power-up or on restoration of power to a device. In it, the memory and other hardware necessary for reliable operation are tested. If the hardware tests are successful, the initialization state will be entered. Otherwise, the failure state is assumed.
The initialization state is entered from the start/restart or failure states. In it, all unreported function block alarms will be automatically confirmed and acknowledged. Once the system management SM_STATE object is detected to be operational, block execution may be scheduled and the resource state will move to on-line linking.
This state is entered from the on-line and initialization states. In it, the status of defined links is evaluated. If all defined links are established, then the resource state move to on-line.
This is the normal operating status; the resource block is in operating mode AUTO. it is entered from the on-line linking status. The connections configured between the function blocks have been linked. If any connections are missing, the state reverts to on-line linking.
This state is entered if the mode of the resource block is changed to out-of-service (OOS). In it, the actual mode of all function blocks in the resource will be forced to OOS mode. The mode of transducer blocks may not be affected. On a change in the resource block mode to AUTO, the state will revert to start/restart.
This state may be entered from any state except standby. Transition to this state is caused by the detection of a memory or other hardware failure which would prevent reliable operation. The failure may pertain either to the whole device or only to the resource. Based on this state being active, a function block of the output class may change its output to a fault state position. In this state, hardware status will be tested. If the hardware failure clears, then the state will move to initialization.
50 Endress+Hauser
ControlCare Application Designer: Function Blocks 3 Resource Block
3.2.3
Resource restart
The RESTART parameter offers several options for restarting the device, see the table below. The device is restarted by selecting the restart mode from the drop-down menu in the On Line
Characterization dialog, when the resource block is out of service. After restart, the RESTART parameter returns to the value "Run"
2
3
Index Option
1 Run
Restart resource
Restart with defaults
Description
Passive state of the parameter
Restarts the resource as configured (clears up garbage problems)
Restarts the resource with default configuration
4 Restart processor Restarts the processor only
5 – 10 Restart with factory defaults Restarts with manufacturer specific default values
• If these restarts are not implemented, the parameter defaults to Run
3.2.4
Resource options
The FEATURES parameter indicates the resouce block options that are supported by the device
(see FF Specification 890). The features themselves are enabled by selecting the appropriate option from the drop-down menu of FEATURE_SEL parameter in the Off Line Characterization dialog.
Multiple selections are allowed.
If an option is selected in FEATURE_SEL that is not available in FEATURES , a block configuration error is flagged in the parameter BLOCK_ERR .
3
4
5
Index Option
0
1
2
6
7
8
9
109
11
12
Unicode strings
Reports supported
Fault State supported
Description
Device supports output as unicode strings
See Chapter 2.9, Alert handling
Device supports alert reports
See Chapter 2.7, Fault State handling
Device causes all output blocks to assume the predefined fault state defined in
Fault State type I/O action when the physical input or the SET_FSTATE parameter flags a fault.
Soft Write lock supported
Hard Write lock supported
Device has a software write lock
Device has a hardware write lock
Output readback supported Device reads back the actual valve position to the associated output function block (actuators only)
Direct write to output hardware
Device writes one or more hardware values when the resource is dead
(manufacturer-specific option)
Change of BYPASS in an automatic mode
Device allows the change of bypass when the associated function block is in an automatic mode
• Normally this is only possible when the block is out of service or in manual
MVC Report Distribution supported
MVC Publishing/Subscribing supported
Multi-bit Alarm (Bit-Alarm)
Support
Restart/Relink required after using FB_Action
Deferral of Inter-Parameter
Write Checks
Device supports multivarible container functionality
• The resource receiving the report must also support MVC
Device supports multivarible container publishing/subscribing
• All resources in the system must also support MVC publishing/subscribing
Device supports multibit alarm parameters
• When not selected, the device treats multibit alarms as simple alarms
• For more information, see Chapter 4.4.3.12 of FF Specification 890
Device requires restart/relink after instantiation or deletion of function blocks with the FB_Action service
• For more information see Chapter 4.14.3.6 of FF Specification 890
Disables inter-parameter write checks when the resource and function blocks are out of service or the transducer block is out of serve or in manual mode
Endress+Hauser 51
3 Resource Block
Resource block alerts
ControlCare Application Designer: Function Blocks
3.2.5
Alert reporting
Alert reporting, see Chapter 2.9, is enabled for the entire resource by selecting the option "Reports supported" in the FEATURE_SEL parameter of the device resource block. The associated alert priority is set in the corresponding priority parameter xxx_PRI of the function block where the alert is generated.
The priority and time stamp of the alert determines the order of processing when more than one alarm is active at a particular time, whereby the oldest alert with highest priority is processed first.
Three parameters control the queuing of alerts:
• MAX_NOTIFY can be read online and indicates the maximum number of alert reports that the device can send without receiving a confirmation
• LIM_NOTIFY allows the user to select the number of alert reports the device can send without receiving a confirmation. If LIM_NOTIFY is set to zero, then no alerts are reported.
• CONFIRM_TIME determines the time the resource will wait for confirmation of receipt of a report before trying again. If the CONFIRM_TIME = 0 the device will not retry.
For the resource block, two types of alert are of interest:
• Block alarms, which are automatically assigned priority 2
• Write (protection) alarms, which are normally configured as advisory alarms
The parameter ACK_OPTION configures the automatic acknowledgement of alerts. Depending on the device, it may be implemented as a tickbox to enable automatic acknowledgement or disable manual acknowledgement in the xxx_ALM parameter of the corresponding alert.
• Disabling automatic acknowledgement of the write protection alert, means that the alert must be manually acknowledged in the WRITE_ALM parameter
• Disabling automatic acknowledgement of block alarms, means that each alert must be manually acknowledged in the BLOCK_ALM parameter
The table below summarizes the parameters to be set to activate alert reporting and setting up of alarm priorities and acknowledgement.
Parameter
ALERT_KEY
CONFIRM_TIME Sets time limit for receipt of alert notification confirmation from interface device.
– Setting is multiplied by 1/32 milliseconds to obtain time period
– If no confirmation is received within this time, the report is sent again
MAX_NOTIFY
LIM_NOTIFY
Indicates maximum number of unconfirmed reports that can be stored by the device
Sets number of unconfirmed reports that to be stored by the device
– LIM_NOTIFY may not exceed MAX_NOTIFY
– If LIM_NOTIFY = 0, then no alerts are reported
ACK_OPTION
Description
Optional index that identifies the plant unit. May be used in the host for sorting alarms, etc.
WRITE_PRI
When unticked, disables auto-acknowledgment in block for each class of alarm. The alarms must then be acknowledged in the salient xxx_ALM parameter.
• 1: Write Lock Alarm Disabled/Write Lock Alarm Auto Acknowledgement
• 8: Block Alarm Disabled/Block Alarm Auto Acknowledgement (Resource block only)
Priority of an alarm or event. If no setting is made the acknowledgement is "undefined".
• 0-1: Associated alert is not sent as a notification; normally auto-acknowledged.
• 2: Reserved for alerts that do not require the attention of a plant operator.
Block alarm and update event have this priority; normally auto-acknowledged.
• 3-7: Advisory alarms. Alarms of this priority will normally be acknowledged.
• 8-15: Critical alarms. Alarms of this priority will normally be acknowledged.
52 Endress+Hauser
ControlCare Application Designer: Function Blocks 3 Resource Block
3.2.6
Software write lock
If the device supports software write protection, the option "Soft Write lock supported" will appear in the FEATURES parameter. If the device also has a hardware write lock and this is active, see
Chapter 3.1.2, the corresponding hardware jumper must be configured for "UNLOCKED" before the soft write lock can be activated. In some cases, the device must be restarted before the change in jumper position is registered.
To activate the soft write lock, first select the option "Soft Write lock" in the FEATURE_SEL parameter. The write protection can now be activated through the WRITE_LOCK parameter. The following statuses can be selected from the drop-down menu:
• LOCKED: static and non-volatile parameters cannot be changed. Block connections and calculation results will proceed normally, but the configuration will be locked
• NOT LOCKED: static and non-volatile parameters can be changed
If WRITE_LOCK is changed from LOCKED to NOT LOCKED , the discrete alert WRITE_ALM is generated at the priority WRITE_PRI . The priority of the alarm determines if it is to be acknowledged or not, see Chapter 2.9.2. Resetting WRITE_LOCK will clear the alert, if it exists.
3.2.7
Block errors
The ALARM_SUM parameter provides a summary of all alarms active for the resource block. The parameter BLOCK_ERR indicates the type of error that is present. If automatic acknowledgement of block alarms is disabled in the ACK_OPTION parameter, they must be acknowledged in the
BLOCK_ALM parameter.
The table below indicates the possible alarms for the Resource Block..
Condition
Block Configuration Error
Simulate Active
Device Fault State Set
Out-of-Service
Reason
• I/O block has been configured that requires a type of hardware that is not available to the device
• Feature selected in FEATURE_SEL that is not supported by the device
• More than one CYCLE_TYPE selected in CYCLE_SEL
• CYCLE_TYPE selected in CYCLE_SEL not supported by device
• The hardware jumper for simulation is set to allow simulation
Note: this is not an alarm, but an indication the simulation is possible by selecting "Simulation Enable" in the I/O function block
• FAULT_STATE is active
• MODE_BLK.Target currently set to OOS
Endress+Hauser 53
3 Resource Block
Resource block
54
ControlCare Application Designer: Function Blocks
3.3
Block parameters
Parameter
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
RS_STATE
TEST_RW
DD_RESOURCE
MANUFAC_ID
DEV_TYPE
DEV_REV
DD_REV
GRANT_DENY
HARD_TYPES
RESTART
FEATURES
FEATURE_SEL
CYCLE_TYPE
CYCLE_SEL
MIN_CYCLE_T
MEMORY_SIZE
NV_CYCLE_T
FREE_SPACE
FREE_TIME
SHED_RCAS
SHED_ROUT
FAULT_STATE
–
–
–
–
–
–
–
–
–
Valid range
Default value
0
Blank
–
–
– 0
1 – 255 0
O/S
1 – 4
–
–
–
0
Description/Action
See Chapter 2.3.4
See Chapter 2.4
–
0
–
–
–
See Chapter 3.1.2.
Read/write test parameter - used only for conformance testing.
Blank Tag of the resource containing the device description
– Manufacturer’s identification number
Manufacturer's model number associated with the resource
Manufacturer’s revision number associated with the resource
Revision of the DD associated with the resource
See Chapter 2.8.1
Types of hardware available as channel numbers.
See Chapter 3.2.3
See Chapter 3.2.4.
–
–
–
–
0
Identifies the event input types supported by the device, which invoke the execution of the device function blocks
• Scheduled: the blocks execute when a schedule event input is received from the LAS
• Block execution: the blocks execute when a block execution event input is received from another block that has just completed its execution
• Manufacturer specific: the blocks execute according to a manufacturer-specific schedule event input
Selects the block execution method for the device.
• Endress+Hauser devices require no configuration
Indicates the interval, in units of 1/32 ms, at which modified non-volatile parameters are stored to a non-volatile memory
• 0 indicates that parameters are not stored in normal operation
• For Endress+Hauser devices, non-volatile parameters are stored on power down only
Available configuration memory (kbytes) in empty resource.
• Check before attempting a download.
Interval between writing copies of NV parameters to nonvolatile memory (1/32 ms). Zero means never.
0 to 100
0 to 100
–
–
–
Percent of memory available for further configuration.
Zero in a preconfigured resource.
Percent of the block processing time that is free to process additional blocks.
640000 See Chapter 2.4.4
Timeout, in units of 1/32 ms, for communication with an external application writing to function block RCas locations
• If the timeout is exceed, communication is assumed to be lost and the mode is shed, see Chapter 2.4.4
• If the timeout is 0, mode shedding is disabled
640000 See Chapter 2.4.4
Timeout, in units of 1/32 ms, for communication with an external application writing to function block ROut locations
• If the timeout is exceed, communication is assumed to be lost and the mode is shed, see Chapter 2.4.4
• If the timeout is 0, mode shedding is disabled
Indicates whether the output function blocks of the device are being forced into failsafe mode, see Chapter 2.6
• 1: Blocks in normal operation
• 2: Blocks being forced into failsafe mode (see SET_FSTATE)
Endress+Hauser
ControlCare Application Designer: Function Blocks 3 Resource Block
Parameter
SET_FSTATE
CLR_FSTATE
MAX_NOTIFY
LIM_NOTIFY
CONFIRM_TIME
WRITE_LOCK
UPDATE_EVT
BLOCK_ALM
ALARM_SUM
ACK_OPTION
WRITE_PRI
WRITE_ALM
ITK_VER
ENP_VERSION
DEVICE_TAG
SERIAL_NUMBER
ORDER_CODE
FIRMWARE_REVISION
MS_RESOURCE_DIRECTORY
Legend: RO - Read only
Valid range
1, 2
1, 2
Default value
1
Description/Action
1
Forces all output blocks of the device into their failsafe mode.
• 1: Off,
• 2: Enable force
Disables the force of failsafe mode caused by SET_FSTATE
• 1: Off,
• 2: Disable force
See Chapter 3.2.5
MAX_
NOTIFY
RO
0 to
MAX_
NOTIFY
1,2
0, 1 0
0 to 15 0
640000
1 See Chapters 3.1.2, 3.2.4
Alert generated by any change in static data, see Chapter 2.9.4.
See Chapter 3.2.7
The current alert status, unacknowledged states, unreported states, and disabled states of the alarms associated with the function block.
See Chapter 3.2.5
Priority of the alarm generated by clearing the write lock.
Alert is generated if the write lock parameter is cleared.
Version number of the ITK test used as basis for certifying the device
Version number of the Electronic Nameplate
Device tag downloaded from the project to the device
Manufacturer’s serial number for the device
Manufacturer’s order code for the device
Revision number of the firmware of the device
Array describing the grouping of the enhanced parameters
(not relevant to operatioin)
Endress+Hauser 55
4 Transducer Blocks
Measuring devices
ControlCare Application Designer: Function Blocks
4 Transducer Blocks
A transducer block acts as a "buffer" between a measuring or actuating device and the function block application process. Its purpose is to:
• encapsulate all parameters influencing the physical set up of the device
• for measuring devices, provide a standardized signal to an analog input block
• for actuating devices, process the standardized signal provided by an analog output block
In addition to measuring and actuating devices, transducer blocks are also required for local I/O modules of the ControlCare Field Controller.
Fig. 4-1 shows the how the transducer block functions in simple measuring device. The measuring signal of the device is converted to a process value by the transducer block and transmitted to the analog (or discrete) input block. Here the process value can be scaled or limits can be set before it is made available as the IN value to a control loop.
Actuating devices
56
Transducer
Block
Resource Block
Analog
Input
Block
OUT value of measuring device/
IN value of control loop
Signal from device
Process value (PV)
Fig. 4-1: Function of transducer block in an analog measuring device
The CHANNEL parameter links the transducer and analog input blocks. In the case of multivariable devices, each process variable is assigned a different channel number and the device provides an equal number of input blocks for use in the control strategy.
For an actuator, see Fig. 4-2, the analog (or discrete) output block receives a setpoint value from the control loop, which may run centrally in the controller or distributed in the field devices. After scaling, e.g. to a current signal range, the setpoint value is transmitted to the transducer block as the output value of the function block. The transducer block now generates the physical signal that drives the valve to the desired position.
OUT value of control loop
CAS_IN value of actuator
Analog
Output
Block
Resource Block
Transducer
Block
OUT value
Fig. 4-2: Function of transducer block in an analog actuating device
Signal to actuator
Endress+Hauser
ControlCare Application Designer: Function Blocks
MODE_BLK.Target
IO_TYPE_Rxx
SLOT_x
4 Transducer Blocks
4.1
Hardware Configuration block
The Hardware Configuration block configures the local I/O module type for each slot in a
ControlCare Field Controller rack. In ControlCare Application Designer it is assigned the generic name Device Tag-HC-n and can be found by expanding the controller leaf in the fieldbus or process cell window.
In the following, only the major parameters are described in detail. Short descriptions of parameters with specialised use are to be found in Table 4.3. of Chapter 4.1.3.
4.1.1
Block configuration
For normal operation, MODE_BLK.Target
is set to Auto. This is set during offline configuration and comes into effect when the control strategy is downloaded to the controller.
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
The physical arrangement of the modules on the rack assemblies with the addresses 0 to 14 is declared in the parameters IO_TYPE_R0 to IO_TYPE_R14 respectively. Each IO_TYPE_Rx parameter has four slot parameters, SLOT_0 to SLOT_3 , where the module type is entered. The
I/O types together with the permissible function blocks for each type are listed below.
IO_TYPE_R0 (Field Controller) is preset to "Not I/O" and should not be changed.
Designation
SFC050
SFC056
SFC162
SFC173
SFC252
SFC260
SFC353
SFC411
SFC415
SFC420
SFC428
SFC432
SFC435
SFC438
SFC441
SFC442
SFC444
SFC445
SFC446
SFC457
SFC467
Description
Available slot
Power Supply 90-264 VAC
Power Supply for Backplane 20-30 VDC
FF Field Controller, 1x100 Mbps, 4xH1
PROFIBUS Field Controller, 1x100 Mbps, 4xH1
AC Power Supply for Fieldbus
DC Power Supply for Fieldbus
4-channel Power Supply Impedance
2 Groups of 8 24 VDC Inputs (Isolated)
2 Groups of 8 24 VDC Inputs (Sink, Isolated)
1 Group of 8 On/Off Switches
2 Groups of 8 NO Relays Outputs
1 Group of 8 24 VDC Inputs and
1 Group of 4 NO Relays
1 Group of 8 24 VDC Inputs and
1 Group of 4 NC Relays
1 Group of 8 24 VDC Inputs and
1 Group of 2 NO and 2 NC Relays
2 Groups of 8 pulse inputs - low frequency
2 Groups of 8 pulse inputs - high frequency
1 Group of 8 analog inputs with shunt resistors
1 Group of 8 temperature inputs
1 Group of 4 analog output
1 Group of 8 differential analog inputs with shunt resistors
2 Groups of 8 pulse inputs - AC
I/O type
No I/O
No I/O
No I/O
No I/O
No I/O
No I/O
No I/O
Function Block
None
None
None
RS/HC/DIAG
RS/HC/DIAG
None
None
No I/O
16-discrete input
16- discrete input
8- discrete input
None
MDI/DI
MDI/DI
MDI/DI
16- discrete output MDO/DO
8- discrete input/
4- discrete output
MDI/DI
MDO/DO
8- discrete input/
4- discrete output
8- discrete input/
4- discrete output
MDI/DI
MDO/DO
MDI/DI
MDO/DO
16-pulse input
16-pulse input
8-analog input
8-temperature
4-analog output
8-analog input
PUL
PUL
MAI/AI
MAI/AI
MAO/AO
MAI/AI
16-pulse input PUL
Tab. 4-1: I/O types with associated function blocks
Addressing and slot numbers are explained in Chapters 3.5.3 and 3.5.4 of the Field Controller
Hardware manual, BA021S/04/en; the procedure for configuring the block in Chapter 5.2.1 of
Field Controller Commissioning manual BA35S/04/en. For direct mapping of I/Os to the embedded hybrid function block see the I/O Mapping Tool manual, BA032S/04/en.
Endress+Hauser 57
4 Transducer Blocks ControlCare Application Designer: Function Blocks
4.1.2
Block errors
On execution of the HC configuration block, the Field Controller writes to all declared output modules and reads all declared input modules. If any I/O module has failed in this scan, it is indicated in BLOCK_ERR and the MODULE_STATUS_x parameters. Other possible block errors are listed in the table below:.
Condition
Block Configuration Error
Out-of-Service
Reason
• Configured I/O type not present in controller
• I/O type present in controller that has not been configured in HC block
• Configured I/O type does not correspond to that present in controller
• MODE_BLK.Target currently set to OOS
Hardware Configuration block
4.1.3
Block parameters
The table below gives an overview of the HC block parameters
Parameter
ST_VER
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
REMOTE_IO
IO_TYPE_R0
IO_TYPE_R1
IO_TYPE_R2
IO_TYPE_R3
IO_TYPE_R4
IO_TYPE_R5
IO_TYPE_R6
IO_TYPE_R7
IO_TYPE_R8
IO_TYPE_R9
IO_TYPE_R10
IO_TYPE_R11
IO_TYPE_R12
IO_TYPE_R13
IO_TYPE_R14
MODULE_STATUS_R0_3
MODULE_STATUS_R4_7
MODULE_STATUS_R8_11
MODULE_STATUS_R12_14
UPDATE_EVT
BLOCK_ALM
HFB_STATUS_R0_3
HFB_STATUS_R4_7
HFB_STATUS_R8_11
HFB_STATUS_R12_14
Legend: RO - Read only
RO
RO
RO
RO
RO
RO
RO
RO
0
0
0
0
0
0
0
0
0
0
0
0
0
0
Valid range/
Options
Default value
0 to 255 0
1 to 255 1
0 blanks
TARGET O/S
0 to 15
RO
Description/Action
See Chapter 2.3.4
0
Set to AUTO
See Chapter 4.1.2
When on-line, indicates Remote I/O master
(MODBUS applications only)
Module type for rack 0, slots 0 to 3
Preset to "Not I/O" - do not change
Select module type for rack 1, slots 0 to 3
Select module type for rack 2, slots 0 to 3
Select module type for rack 3, slots 0 to 3
Select module type for rack 4, slots 0 to 3
Select module type for rack 5, slots 0 to 3
Select module type for rack 6, slots 0 to 3
Select module type for rack 7, slots 0 to 3
Select module type for rack 8, slots 0 to 3
Select module type for rack 9, slots 0 to 3
Select module type for rack 10, slots 0 to 3
Select module type for rack 11, slots 0 to 3
Select module type for rack 12, slots 0 to 3
Select module type for rack 13, slots 0 to 3
Select module type for rack 14, slots 0 to 3
Status of modules in rack 0-3
Status of modules in rack 4-7
Status of modules in rack 8-11
Status of modules in rack 12-14
Alert generated by any change in static data, see Chapter 2.9.4.
See Chapter 2.9
Status of modules in rack 0-3 assigned to Hybrid FB
Status of modules in rack 4-7 assigned to Hybrid FB
Status of modules in rack 8-11 assigned to Hybrid FB
Status of modules in rack 12-14 assigned to Hybrid FB
58 Endress+Hauser
ControlCare Application Designer: Function Blocks
MODE_BLK.Target
CHANNEL
SENSOR_TYPE_x
SENSOR_
CONNECTION_x
4 Transducer Blocks
4.2
Temperature Transducer block
A temperature transducer block is required for the every SFC445 temperature module in a Field
Controller rack. The module has eight input channels for RTD, TC, mV or Ohm. In ControlCare
Application Designer the temperature block is assigned the generic name Device Tag-TEMP-n and can be found by expanding the controller leaf in the fieldbus or process cell window.
In the following, only the major parameters are described in detail. Short descriptions of parameters with specialised use are to be found in Table 4.5. of Chapter 4.2.3.
4.2.1
Block configuration
The block mode, channel, sensor connection and sensor type at each input channel must be configured for each module.
For normal operation, MODE_BLK.Target
is set to AUTO. This is set during offline configuration and comes into effect when the control strategy is downloaded to the controller.
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
The CHANNEL parameter is set to the rack number and slot, where the SFC445 is installed, e.g. for Rack 1, Slot 2, all inputs = Rack+Slot+09 = 1209 in accordance with the instructions in
Chapter 5.1.1.
The type of temperature sensing element connected to the each input channel of the SFC445 and the method of connection are declared in the parameters:
• SENSOR_TYPE_x: select from the drop-down menu
• SENSOR_CONNECTION_x: select from the drop-down menu
If the ALL button in the Off Line Characterization dialog is active, the parameters are to be found under VALUE_RANGE_x in the reverse order.
When on-line the following parameters provide information on the status and configuration of each input:
• TEMP_x : value and status of the temperature measured at the input point
• VALUE_RANGE_x : copy of the XD_SCALE parameter of the AI Block connected to the input point
The VALUE_RANGE_x parameter can be viewed by pressing the ALL button in the On Line
Characterization dialog.
4.2.2
Block errors
On execution of the Temperature Transducer block, the Field Controller checks the CHANNEL and SENSOR_TYPE/SENSOR_CONNECTION pairs for correct configuration. It is not able, however, to check whether the physical sensor type or connection corresponds to that configured.
Block errors are indicated in the BLOCK_ERR parameter.
Condition
Block Configuration Error
Out-of-Service
Reason
• No channel no set or channel number does not end in 09
• One of the two parameters SENSOR_TYPE_x or
SENSOR_CONNECTION_x is missing for a particular output
• MODE_BLK.Target currently set to OOS
Endress+Hauser 59
4 Transducer Blocks ControlCare Application Designer: Function Blocks
Temperature Transducer block
4.2.3
Block parameters
The table below gives an overview of the Temperature Transducer block parameters
Parameter
ST_VER
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
CHANNEL.
TEMP_0...TEMP_7
VALUE_RANGE_0....
VALUE_RANGE_7
SENSOR_CONNECTION_0.
..
SENSOR_CONNECTION_7
SENSOR_TYPE_0
...
SENSOR_TYPE_7
UPDATE_EVT
BLOCK_ALM
Legend: RO - Read only
Valid range/
Options
Default value
0 to 255 0
1 to 255 1
0 blanks
Description/Action
See Chapter 2.3.4
TARGET
0 to 15
RO
RO
1, 2, 3 menu
O/S
0
Set to AUTO
See Chapter 4.2.2
Enter rack and slot number of the associated SFC445 module coded as per Chapter 5.3.1, whereby G = 0 and P = 9 (whole)
When on-line, indicates temperature value and status at input point 0...7
0-100% When on-line and connected to an Analog Input block, shows a copy of AI block’s XD_SCALE. parameter
1 Select type of sensor connection for points 0...7
1 = differential,
2 = 2-wire,
3 = 3-wire
Pt100 Select type of sensor connected to points 0...7
(Select from pull-down menu)
Alert generated by any change in static data, see Chapter 2.9.4.
See Chapter 2.9
60 Endress+Hauser
ControlCare Application Designer: Function Blocks
Example of a device transducer block
4 Transducer Blocks
4.3
Device transducer blocks (Endress+Hauser)
Device transducer blocks contain all parameters required to physically set up the measurement and present the result to the "outside" world. Thus they usually contain parameters associated with calibration, signal processing (square-root, linearization, inversion, cut-offs), output settings, safety settings etc. Depending on type, the measuring device may have a single or several transducer blocks.
Currently, there are no profiles for the various types of device, although work is going on to produce the first specifications in the near future. As a consequence, the user is faced with a variety of implementations.
• For older devices, the device is configured using manufacturer-specific parameters that are to be found at the end of the parameter list. In some cases, these parameters can be changed only when on-line and only after the entry of a enabling code.
• More recent devices, e.g. the TMT162 temperature measuring device, already follow Fieldbus
Foundation guidelines and use a quasi-standard parameter set. In this case, no manufacturerspecific parameters are required and the device can usually be configured offline.
Transducer Block “Flow”
Simulation -
Value Measurand
Low Flow
Cut Off
Off Value
On Value
Amplifier
Simulation -
Measurand
Positive Zero
Return
Low Flow Cut Off
Pressure Shock Suppression
Empty Pipe Detection
MODE_BLK
O/S
AUTO
Mass
Flow
Volume
Flow
Corr. Vol.
Flow
Density
Ref.
Density
Temp.
Ch 1
Ch 2
Ch 3
Ch 4
Ch 5
Ch 6
Transducer Block “Totalizer”, etc.
Fig. 4-3: Schematic diagram of Flow Transducer block of Promass 83 Coriolis flowmeter
Fig. 4-3 shows the example of the Endress+Hauser Promass 83 which has two transducer blocks as standard (flow and totalizer) and a number of others which are available for specific variants of the device. It can be seen that the flow transducer block allows the switching on and off of the functions
"Low Flow Cut Off", "Pressure Shock Suppression" and "Empty Pipe Detection". "Low Flow Cut Off" requires the entry of an "Off" and an "On" value to complete configuration. The block also supports simulation of the measurand and positive zero return.
The MODE_BLK parameter is to be found, along with other standard parameters, in every device transducer block. The process values measured by the device, in this case six, are presented at an equal number of channels. Thus volume flow is made available to a connected Analog Input block when the block’s CHANNEL parameter is set to "2". More information on the Promass 83 can be found in Device Function manual BA066D/06/en.
Endress+Hauser 61
4 Transducer Blocks
MODE_BLK.Target
Methods
Block errors
ControlCare Application Designer: Function Blocks
4.3.1
Block configuration
For more information on configuration of the transducer blocks of the individual devices, please consult the associated device manuals
For normal operation, MODE_BLK.Target
is set to AUTO. This is set during offline configuration and comes into effect when the control strategy is downloaded to the controller.
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
When MODE_BLK.Target
is set to MAN and block simulation is enabled, the process value output by the block can be entered manually.
The Foundation Fieldbus specification provides for the use of so-called methods to simplify the configuration of the device. A method is an interactive sequence of steps that must be followed in order to obtain a particular function from the device. Thus, for example, the steps for the basic calibration of a level device: reset, empty calibration, full calibration might comprise a method named “Basic calibration". The user can call up this method to calibrate the device. He need do nothing else but supply the information which the method asks for as it progresses through each step. The setting of the block mode, reading, writing and plausibility checking of the parameters etc. is automatically done by the program.
A method is part of the device description supplied with the device. Some Endress+Hauser devices support methods.
On execution of the block, the device checks for correct configuration. Block errors are indicated in the BLOCK_ERR parameter.
Condition
Block Configuration Error
Reason
• See associated device operating manual
Simulate Active • The current transducer block value has been entered manually
Input Failure/ process variable has BAD status • Device failure or device initiating etc.
Out-of-Service • MODE_BLK.Target currently set to OOS
Device transducer block
4.3.2
Block parameters
The table below gives an overview of the common Device Transducer block parameters
Parameter
ST_VER
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
Device specific parameters.
UPDATE_EVT
BLOCK_ALM
Legend: RO - Read only
Valid range/
Options
Default value
0 to 255 0
1 to 255 1
0 blanks
TARGET O/S
0 to 15
0
Description/Action
See Chapter 2.3.4
Set to AUTO; Set to MAN to enter parameter by hand
See Chapter 4.3.2
See device operating manuaol
Alert generated by any change in static data, see Chapter 2.9.4.
See Chapter 2.9
62 Endress+Hauser
ControlCare Application Designer: Function Blocks 4 Transducer Blocks
4.4
Display block (DISP)
The Display transducer block is provided by all instruments that support the use of an integral or pluggable display module. In addition to the common block parameters, it contains parameters which allow the on and off-line configuration of the display. When on-line, it is possible to read the selected variables.
Depending on device, the block is either automatically generated on creation of the device or must be created separately via the New Block...
context menu. In this case, it is also possible that the generic name is DEVICE_TAG_BLK_x .
MODE_BLK.Target
Configuration parameters
4.4.1
Block configuration
For normal operation, MODE_BLK.Target
is set to AUTO. This is set during offline configuration and comes into effect when the control strategy is downloaded to the controller.
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
The configuration parameters provided depend upon the device providing the block. Normally the user can configure:
• The source of the displayed value
• Accompanying text
• Number of decimal points
• Max and minimum value of bargraph, if provided
• Alternation time for multiple value displays
In addition, advanced functions such as display lighting and brightness might be influenced. The appropriate device manual should be consulted.
Display transducer block
4.4.2
Block parameters
The table below gives an overview of the common Display transducer block parameters
Parameter
ST_VER
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
UPDATE_EVT
BLOCK_ALM
TRANSDUCER_TYPE
XD_ERROR
Device specific parameters.
Legend: RO - Read only
Valid range/
Options
Default value
0 to 255 0
1 to 255 1
0 blanks
TARGET O/S
0 to 15
Description/Action
See Chapter 2.3.4
0
Set to AUTO
See Chapter 4.3.2
Alert generated by any change in static data, see Chapter 2.9.4.
See Chapter 2.9
Transducer type to which the display block is connected
Transducer Block Errors, see Chapter 2.9.4
See device operating manuaol
Endress+Hauser 63
4 Transducer Blocks ControlCare Application Designer: Function Blocks
4.5
Diagnosis block (DIAG)
The Diagnosis transducer block provides information on the hardware and software features provided by the device. Some devices offer an additional Advanced Diagnosis transducer block which can be used if this option has been implemented in the device.
MODE_BLK.Target
Configuration parameters
4.5.1
Block configuration
For normal operation, MODE_BLK.Target
is set to AUTO. This is set during offline configuration and comes into effect when the control strategy is downloaded to the controller.
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
The configuration parameters provided depend upon the device providing the block. For the
SFC162 Field Controller, for example, it contains:
• Online measurement of block execution time
• Hardware revision
• Firmware revision
• Serial number of device
• Serial number of main board
• A parameter BEHAVIOR which defines which initial values for parameters will be used after a block instantiation.
For other devices it might contain locking statuses and access codes. The appropriate device manual should be consulted.
4.5.2
Block parameters
The table below gives an overview of the common Diagnosis transducer block parameters
Diagnosis transducer block Parameter
ST_VER
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
UPDATE_EVT
BLOCK_ALM
TRANSDUCER_TYPE
XD_ERROR
Device specific parameters.
Legend: RO - Read only
Valid range/
Options
Default value
0 to 255 0
1 to 255 1
0 blanks
TARGET O/S
0 to 15
0
Description/Action
See Chapter 2.3.4
Set to AUTO
See Chapter 4.3.2
Alert generated by any change in static data, see Chapter 2.9.4.
See Chapter 2.9
Transducer type to which the display block is connected
(optional)
Transducer Block Errors, see Chapter 2.9.4 (Optional)
See device operating manuaol
64 Endress+Hauser
ControlCare Application Designer: Function Blocks
Field Controller
5 Input Blocks
5 Input Blocks
5.1
CHANNEL parameter
The CHANNEL parameter connects the transducer block to the input function block of the device.
For the Field Controller I/O modules, this is compiled according to the following hierarchy:
Level
Rack (R)
Slot (S)
Group (G)
I/O Point (P)
Range
0 – 14
0 – 3
0 – 1
0 – 7
9 = whole group
The value in the CHANNEL parameter is given by the value RSGP:
• Rack assembly address (R):
Each rack assembly has a unique address between 0 an 14 .
The rack assembly with the address "0" cannot be used by the I/O modules.
• Slot (S): Each rack assembly has four slots. One slot supports one I/O module.
Slots are numbered from 0 (first slot) to 3 (last slot).
• Group (G): Ordinal number of group in the specified I/O module
Groups are numbered from 0 (first group) to number of groups minus 1.
• Point (P): Ordinal number of I/O point in a group
I/O points are numbered from 0 (first I/O point) to 7 (last I/O point in the group)
9 means the whole group of points and is used when a module is connected to a MAI, MDI,
MAO or MDO function block.
Thus, a single I/O point in the Field Controller may be identified by specifying the rack (R), slot (S), group (G) and point (P). As the CHANNEL parameter in the multiple I/O blocks (MIO) must specify the whole group (8 points), the point must be 9, meaning the whole group. For example:
• The CHANNEL parameter 1203 means rack 1, slot 2, group 0 and I/O point 3.
• The CHANNEL parameter for a MAI block 10119 means rack 10, slot 1, group 1 and
I/O point 9, i.e. the whole group.
FF devices
PROFIBUS devices
Endress+Hauser
Provided that the HC transducer block is configured before the CHANNEL parameter, the system verifies that the I/O type configured in the HC block is suitable for block type. If the CHANNEL parameter of the AI block accesses an I/O of a different type, the setting will be rejected during download. In this case the channel is set to "0" and a corresponding error is set in the BLOCK_ERR parameter, which can be viewed online.
The CHANNEL parameter of a FF device Input block determines which process value provided by the device is to be connected to the block. More information is to be found in the device manuals.
In the case of PROFIBUS devices, there is no CHANNEL parameter in I/O function blocks. Instead a function block is created for each of the parameters selected during device configuration in
PROFIBUS Configurator. If the GSD uses generic block names, e.g. "AI", and the device has several process values, an AI block must be created for each value required. The "FREE SPACE" parameter can be used to ensure that the correct value to is assigned to the block, i.e. if values 1 and 5 are required, the configuration AI, FREE SPACE, FREE SPACE, FREE SPACE, AI is created. Application designer will then create the blocks Device Tag PB-AI-1 and Device Tag PB-AI-2 .
65
5 Input Blocks
CHANNEL
L_TYPE
ControlCare Application Designer: Function Blocks
5.2
Analog Input (AI)
The Analog Input block characterizes the incoming analog signal from a device transducer, temperature or hardware configuration block. The result of execution is the OUT parameter. In
ControlCare Application Designer it is assigned the generic name Device Tag-AI-n . It can be found by expanding the appropriate device or Field Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 5-1.
Note
• Information on the PROFIBUS Analog Input block can be found in Chapter 9.2
From modules
SFC444
SFC445
(via TEMP transducer block)
SFC457 or
FF device
CHANNEL
(RRSGP) or as per device manual
FIELD_VAL(X)
OUT_SCALE
OUT_SCALE
DIRECT
L_TYPE
INDIRECT
IND_SQRT
IO_OPTS
LOW_CUT
PV MANUAL
PV_FTIME
AUTO
ALARMS
OUT
Fig. 5-1: Schematic diagram of the analog input block
5.2.1
Functional description
The CHANNEL parameter determines the transducer block logical channel that is to be connected to the Analog Input block, see Chapter 5.1, and thus the process value to be used by the block. If more than one process value from a device is required for the control strategy, an Analog Input block must be created for each one.
The linearization parameter L_TYPE determines how the process value from the transducer block will be scaled in the input block. One of the following options must be set:
• Direct no scaling, i.e. the process value is the OUT value.
• Indirect linear scaling, i.e. the process value is scaled by XD_SCALE and OUT_SCALE before it becomes the OUT value.
• Indirect Sq Root square root scaling, i.e. the OUT value is the square root of the process value after scaling in
XD_SCALE and OUT_SCALE . This option is used for
p flow measurement.
Note
• If a device transducer block already provides or has been configured to provide a square root output, then only the direct or indirect options should be used.
66 Endress+Hauser
ControlCare Application Designer: Function Blocks 5 Input Blocks
XD_SCALE
OUT_SCALE
IO_OPTS and LOW_CUT
PV_FTIME
ALARM_HYS
XXX_PRI
XXX_LIM
FSAFE_TYPE
FSAFE_VAL
,
XD_SCALE is used prior to output scaling to convert the raw process value from the transducer block to a process value expressed as percentage of range. The result can be read from the
FIELD_VAL parameter. The XD_SCALE parameter expands to reveal the following elements (the example illustrates the scaling of a current input with range limits of 4 mA and 20 mA):
• EU_100 is the upper range limit of the input signal, e.g. 20
• EU_0 is the lower range limit of the input signal, e.g. 4
• UNIT_INDEX is the unit of the input signal, e.g. mA
• DECIMAL is the number of figures behind the decimal point
Examples of input ranges for temperature sensing elements associated with the Temperature
Transducer block are to be found in Chapter 5.2.3.
OUT_SCALE is used to scale the process value to the range and units required by any follow-up block. The result is the OUT value. The OUT_SCALE parameter expands to reveal the following elements (the example illustrates the scaling to an output value range limits of 0% and 100%):
• EU_100 is the upper range limit of the output signal, e.g. 100
• EU_0 is the lower range limit of the output signal, e.g. 0
• UNIT_INDEX is the unit of the output signal, e.g. %
• DECIMAL is the number of figures behind the decimal point
For flow measurement, a low-flow cut-off limit can be set which causes the OUT value to be set to zero when it falls below the value entered in LOW_CUT .
• Activate the function by selecting the Low Cut-Off option in the IO_OPTS parameter.
• Enter the cut-off value in percent of OUT_SCALE in the LOW_CUT parameter.
The PV_FTIME parameter allows the ouput to be damped by entering a suitable positive value in seconds. The default value is zero.
The Analog Input block supports alarming of the OUT value using the parameters ALARM_HYS ,
XXX_PRI and XXX_LIM , in which global hysteresis, alarm priority and alarm values can be set individually for HI_HI_, HI_, LO_ and LO_LO_ limits. A full description of the function is to be found in Chapter 2.9.
The latest Endress+Hauser devices have an enhanced AI function block with two extra parameters
FSAFE_TYPE and FSAFE_VAL . When configured, these dictate how the block reacts on failure.
FSAFE_TYPE determines the value to be output on block failure:
• Fail Safe Value: the block outputs the value FSAFE_VAL with the last valid status
• Last Good Value: the lock outputs last good value with the last valid status
• Wrong Value: the block outputs last good value with Bad status
If the first option is used, a value with the same engineering units as OUT_SCALE must be entered in FSAFE_VAL .
Endress+Hauser 67
5 Input Blocks
Order of parameters
ControlCare Application Designer: Function Blocks
5.2.2
Block Configuration
The basic configuration of an Analog Input block is shown in the table below for a TMT162 temperature transmitter and a Promass 83F mass flowmeter. A full description of the configuration is to be found in the Operating Instructions
• BA224REN for TMT162
• BA065DEN for Promass 83F
The range limits for the TMT162 temperature transmitter are determined by the transducer block parameters SENSOR_TYPE and PRIMARY_OUTPUT_TYPE. For SENSOR_TYPE = Pt100 and
PRIMARY_OUTPUT_TYPE = SV_1 the transducer block outputs a temperature signal in the range
-200°C to +850°C, see Chapter 5.2.4. The XD_SCALE and OUT_SCALE parameters generate the
OUT value of the Anlaog Input block from any part of this range, in our case -50°C to 150°C.
Parameter
MODE BLOCK/TARGET
XD_SCALE/EU_100*
XD_SCALE/EU_0
XD_SCALE/UNITS_INDEX
OUT_SCALE/EU_100
OUT_SCALE/EU_0
OUT_SCALE/UNITS_INDEX
CHANNEL
L_TYPE
PV_FTIME
FSAFE_TYPE
FSAFE_VAL
Function Temperature
TMT162
Auto Normal operating mode of block
Upper range value for process variable
Lower range value for process variable
Unit of process variable
Upper range limit for output variable
Lower range limit for output variable
Unit of output variable
150 (max.850)
–50 (min. –200)
°C
100
0
%
Output channels of Transducer Block aasigned to Ananlog Input Block.
• TMT = Primary, RJ or Sensor vlaue 1/2 depending on whether one or two sensors are connected
• Promass = 1 to 7, depending on which type of process value is required
Sensor Value 1
Selects the type of linearisation for the input value.
• Direct : PV value = OUT value,
Identical XD_SCALE and OUT_SCALE
• Indirect: PV value scaled to OUT value
• Indirect Square Root: as Indirect but scaling with root function
Indirect
Output damping constant (in seconds).
Selects fail safe type to be output on block failure
Sets value for FSAFE_TYPE option Fail Safe
Value
1
Fail Safe Value
0
Flow
Promass 83F
Auto
18
0 t/h (unit)
100
0
%
1 = mass flow
Indirect
1 n/a n/a
Some block parameters have a write check based on the value of others parameters. It is therefore important to set the parameters in the order shown in Table 4-1 (the same order in which they are displayed in the Off Line Characterization dialog.
After characterization of the block, the parameters will appear in the FOUNDATION Fieldbus tree.
If you find a parameter in the wrong position, it can be move by dragging and dropping to the correct one.
68 Endress+Hauser
ControlCare Application Designer: Function Blocks
Mode
SIMULATE
Status propagation
5 Input Blocks
5.2.3
Block operation
The block normally operates in AUTO mode. When online, the status and value of block output is displayed in the OUT parameter. The value and status of the signal from the transducer block can be viewed in the FIELD_VAL parameter. Any limit alarms are displayed in the ALARM_SUM and, if necessary, can be acknowledged in the HI_HI_ALM etc. parameters.
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
When MODE_BLK.Target
is set to MAN, the block output can be manipulated by entering the desired status and value in the OUT parameter. The PV parameter indicates the correct state.
The process value in the Analog Input block can be simulated in order to check the function of it and subsequent blocks during commissioning. A prerequisite for this is that the hardware lock of the device is set to enable. When simulation is enabled, "Simulation Active" appears in the resource block parameter BLOCK_ERROR by , see Chapter 2.9 and Chapter 3.2.7.
Simulation parameters can be changed when the block is in AUTO mode. Expand the SIMULATE parameter to enter a simulated value:
• Set the status of the simulated variable in SIMULATE_STATUS
• Set the value of the simulated variable in SIMULATE_VALUE
• Set ENABLE_DISABLE to "Active" to start simulation
The parameters TRANSDUCER_STATUS and TRANSDUCER_VALUE indicate the status and value of the raw process value. The block output OUT reflects the simulated parameters after processing in the block.
Simulation in an I/O block is disabled by setting ENABLE_DISABLE to "Disable". In this state
SIMULATE_STATUS and SIMULATE_VALUE etc. track TRANSDUCER_STATUS and
TRANSDUCER_VALUE in order to provide a bumpless transfer from disabled to enabled.
The Analog Input block supports the qualities Bad, Uncertain and GoodNC together with the associated substatuses, see Chapter 2.3.2. For example, if the OUT value exceeds the OUT_SCALE range and no worse condition exists in the block then the OUT status will be "Uncertain, EU Range
Violation".
Status propagation can be influenced by selecting the following options in the STATUS_OPTS parameter, see Chapter 2.8.3.
Option
Propagate Fail Forward
Uncertain if Limited
BAD if Limited
Uncertain if Man
Description
Propagates a transducer block status Bad.DeviceFailure or Bad.SensorFailure to OUT without generating an alarm.
– Allows the user to detemine whether alarming (sending of an alert) will be done by the block or propagated downstream
Sets the output status of the block to Uncertain when limit alarms HI_HI_, HI_, LO_ or LO_LO_ are violated
– Option when alarms have been set on the output value
Sets the output status of the block to Bad when limit alarms HI_HI_, HI_, LO_ or
LO_LO_ are violated
– Option when alarms have been set on the output value
Sets the output status of the block to Uncertain if the actual mode of the block is Man
Endress+Hauser 69
5 Input Blocks
Block errors
ControlCare Application Designer: Function Blocks
On execution of the block, the device checks for correct configuration. Block errors are indicated in the BLOCK_ERR parameter.
Condition
Block Configuration Error
Reason
• CHANNEL or L_TYPE parameter has an invalid value
• CHANNEL and HC transducer block configuration not compatible
• XD_SCALE does not have a suitable engineering unit or range for the sensor type of the transducer block
• XXX_LIM limit value is out of valid range
Simulate Active • The current OUT value and status is simulated
Input Failure/ process variable has BAD status • I/O module or device failure, device initiating etc.
Out-of-Service • MODE_BLK.Target currently set to OOS
• L_TYPE is "Uninitialised": set to one of other options
RTDs
Thermocouples
Voltage and resistance
5.2.4
SFC445 temperature ranges (XD_SCALE)
The tables below indicate the valid temperature ranges for XD_SCALE as a function of sensing element type.
RTD
Type
Cu10 GE
Ni 120 DIN
Pt50 IEC
Pt100 IEC
Pt500 IEC
Pt50 JIS
Pt100 JIS
2-wire or 3-wire
Range °C Range °F
–20 to 250
–50 to 270
–4 to 482
–58 to 518
–200 to 850
–200 to 850
–200 to 450
–200 to 600
–200 to 600
–328 to 1562
–328 to 1562
–328 to 842
–328 to 1112
–328 to 1112
Differential
Range °C Range °F
–270 to 270
–320 to 320
–486 to 486
–576 to 576
–1050 to 1050
–1050 to 1050
–650 to 650
–800 to 800
–800 to 800
–1890 to 1890
–1890 to 1890
–1170 to 1170
–1440 to 1440
–1440 to 1440
Thermocouples
Type
B NBS
E NBS
J NBS
K NBS
N NBS
R NBS
S NBS
T NBS
L DIN
U DIN
2-wire or 3-wire
Range °C Range °F
+100 to 1800
–100 to 1000
+212 to 3272
–238 to 1832
–150 to 750
–200 to 1350
–100 to 1300
0 to 1750
–238 to 1382
–328 to 2462
–148 to 2372
32 to 3182
0 to 1750
–200 to 400
–200 to 900
–200 to 600
32 to 3182
–328 to 752
–328 to 1652
–328 to 1112
Differential
Range °C Range °F
–1700 to 1700
–1100 to 1100
–3060 to 3060
–1980 to 1980
–900 to 900
–1550 to 1550
–1400 to 1400
–1750 to 1750
–1620 to 1620
–2790 to 2790
–2520 to 2520
–3150 to 3150
–1750 to 1750
–600 to 600
–1100 to 1100
–800 to 800
–3150 to 3150
–1080 to 1080
–1980 to 1980
–1440 to 1440
Electrical
Unit mV
Single
Range
–6 to +22
–10 to 100
Differential
Range*
–29 to + 28
–110 to 110
Ohms
–50 to 500
0 to 100
0 to 400
0 to 2000
–550 to 550
–100 to 100
–400 to 400
–2000 to 2000
*Each sensor must be designed for the single range
70 Endress+Hauser
ControlCare Application Designer: Function Blocks
Analog Input block
5 Input Blocks
5.2.5
Block parameters
Parameter
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
PV
OUT
SIMULATE
XD_SCALE
OUT_SCALE
GRANT_DENY
IO_OPTS
STATUS_OPTS
CHANNEL
L_TYPE
LOW_CUT
PV_FTIME
FIELD_VAL
UPDATE_EVT
BLOCK_ALM
ALARM_SUM
ACK_OPTION
ALARM_HYS
HI_HI_PRI
HI_HI_LIM
HI_PRI
HI_LIM
LO_PRI
LO_LIM
LO_LO_PRI
LO_LO_LIM
HI_HI_ALM
HI_ALM
LO_ALM
LO_LO_ALM
FSAFE_TYPE
FSAFE_VAL
Legend: RO = Read Only
Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
RO
Description/Action
See Chapter 2.3.4
Disable
0
0
Block mode, set to MODE_BLK.Target to AUTO
Block errors, see Chapter 5.2.3
Process value used in executing the block
Output value calculated as a result of executing the block
See Chapter 5.2.2, Enable/Disable options:
• Disable
• Active
0
0
0-100% Transduced value scaling to % of range
0-100% OUT value scaling t engineering units
Access options, see Chapter 2.8.1
I/O options, see Chapter 2.8.2 and Chapter 5.2.1
Status options, see Chapter 2.8.4 and Chapter 5.2.2
The number of the logical hardware channel to the transducer that is connected to this I/O block, see Chapter 5.1.
0 - 3 0
0, 1
0 %
0 s
0
Linearization mode, see Chapter 5.2.1
• 1: Direct
• 2: Indirect
• 3: Indirect Square Root.
Low flow cut-off value in % of scale, see Chapter 5.2.1
Time constant (s) of a single exponential filter for process value
Raw value of the field device in percent of PV range
Alert generated by any change to the static data.
Block alarms, see Chapter 2.9
Alarm summary, see Chapter 2.9
See Chapter 2.9
• 0: Auto ACK Disable
• 1: Auto ACK Enable
0 to 50 % 0.5%
0 to 15
+INF
0 to 15
+INF
0 to 15
0 to 15
-INF
-INF
Alarm hysteresis in % of OUT_SCALE, see Chapter 2.9
Priority of the HI_HI alarm, see Chapter 2.9
Setting of HI_HI alarm in engineering units, see Chapter 2.9.
Priority of the HI alarm, see Chapter 2.9
Setting of HI alarm in engineering units, see Chapter 2.9.
Priority of the LO alarm, see Chapter 2.9.
Setting of LO alarm in engineering units, see Chapter 2.9.
Priority of the LO_LO alarm, see Chapter 2.9
Setting of LO_LO alarm in engineering units, see Chapter 2.9
Status of HI_HI alarm and its associated time stamp.
Status of HI alarm and its associated time stamp.
Status of LO alarm and its associated time stamp.
Status of LO_LO alarm and its associated time stamp.
Customized AI block parameter
Selects fail safe type to be output on block failure
• Fail Safe Value: block outputs FSAFE_VAL
• Last Good Value: block outputs last good value with status
• Wrong Value: block outputs last good value with Bad status
Customized AI block parameter
Sets value for FSAFE_TYPE option Fail Safe Value
Endress+Hauser 71
5 Input Blocks
CHANNEL
IO_OPS.Invert
STATUS_OPTS
PV_FTIME
DISC_PRI
DISC_LIM
ControlCare Application Designer: Function Blocks
5.3
Discrete Input (DI)
The Discrete Input block characterizes the incoming discrete signal from a limit switch transducer or hardware configuration block. The result of execution is the OUT_D parameter. In ControlCare
Application Designer it is assigned the generic name Device Tag-DI-n . It can be found by expanding the appropriate device or Field Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 5-2.
Note
• Information on the PROFIBUS Discrete Input block can be found in Chapter 9.3
From modules
SFC411
SFC415
SFC420
SFC432
SFC435
SFC438 or
FF device
CHANNEL
(RRGSP) or as per device manual
SIMULATE_D
OPTIONAL
INVERT
FILTER
PV_FTIME
FIELD_VAL_D
PV_D
OUTPUT
ALARMS
DISC
MODE
OUT_D
Fig. 5-2: Schematic diagram of Discrete Input block
5.3.1
Functional description
The CHANNEL parameter determines the transducer block logical channel that is to be connected to the Discrete Input block, see Chapter 5.1.
If required, the INVERT option in the parameter group IO_OPTS inverts the discrete signal by placing a boolean NOT between the field value FIELD_VAL_D and the output OUT_D when true.
False (default)
True (box ticked)
A discrete value of zero (0) is considered to be a logical zero (0), and a non-zero discrete value a logical one (1)
A discrete value of zero (0) is considered to be a logical one (1), and a non-zero discrete value a logical zero (0)
FIELD_VAL_D uses the XD_STATE value to indicate the true state on/off state of the connected hardware.
STATUS_OPTS controls the status propagation of the signal to downstream blocks, see
Chapter 5.3.3.
PV_FTIME can be used to specify the time the hardware must be in a particular state before the logical state is passed on to PV_D. The default value is zero.
The Discrete Input block supports alarming of the OUT_D value using the parameters DISC_PRI and DISC_LIM , in which alarm priority and alarm value ("0" or "1") can be set. A full description of the function is to be found in Chapter 2.9.
72 Endress+Hauser
ControlCare Application Designer: Function Blocks
Order of parameters
SIMULATE_D
5 Input Blocks
5.3.2
Block configuration
The basic configuration of a Discrete Input block is shown in the table below. It is assumed that the discrete signal originates from rack 1, slot 2, group 0 and I/O point 3 of the local I/O, i.e. channel number 1203, and is to be inverted. In our case the default status options will be taken, so that the
STATUS_OPTS parameter does not have to be configrued (see Chapter 5.3.3).
Parameter
MODE BLOCK/TARGET
IO_OPS
CHANNEL
PV_FTIME
Function
Normal operating mode of block
Causes signal to be inverted when option ticked
Output channel of the local I/O connected to the block
• Rack 1, slot 2, group 0 and I/O point 3 = 1203
Output damping constant (in seconds).
Example value
Auto
Invert
1203
1
Some block parameters have a write check based on the value of others parameters. It is therefore important to set the parameters in the order shown (the same order in which they are displayed in the Off Line Characterization dialog.
After characterization of the block, the parameters will appear in the FOUNDATION Fieldbus tree.
If you find a parameter in the wrong position, it can be move by dragging and dropping to the correct one.
5.3.3
Block operation
The block normally operates in AUTO mode. When online, the status and value of block output is displayed in the OUT_D parameter. The XD_STATE parameter indicates the true state on/off state of the connected hardware. Any discrete alarm is displayed in the ALARM_SUM and, if necessary, can be acknowledged in the DISC_ALM parameter.
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
When MODE_BLK.Target
is set to MAN, the block output can be manipulated by entering the desired status and value in the OUT_D parameter. The PV_D value indicates the correct state.
The process value in the Discrete Input block can be simulated in order to check the function of it and subsequent blocks during commissioning. A prerequisite for this is that the hardware lock of the device is set to enable. When simulation is enabled, "Simulation Active" appears in the resource block parameter BLOCK_ERROR by , see Chapter 2.9 and Chapter 3.2.7.
Simulation parameters can be changed when the block is in AUTO mode. Expand the
SIMULATE_D parameter to enter a simulated value:
• Set the status of the simulated variable in SIMULATE_STATUS
• Set the value of the simulated variable in SIMULATE_VALUE
• Set ENABLE_DISABLE to "Active" to start simulation
The parameters TRANSDUCER_STATUS and TRANSDUCER_VALUE indicate the status and value of the raw process value. The block output OUT_D reflects the simulated parameters after processing in the block.
Simulation in an I/O block is disabled by setting ENABLE_DISABLE to "Disable". In this state
SIMULATE_STATUS and SIMULATE_VALUE etc. track TRANSDUCER_STATUS and
TRANSDUCER_VALUE in order to provide a bumpless transfer from disabled to enabled.
Endress+Hauser 73
5 Input Blocks
Status propagation
Block errors
ControlCare Application Designer: Function Blocks
The Discrete Input block supports the qualities Bad, Uncertain and GoodNC together with the associated substatuses, see Chapter 2.3.2. Status propagation can be influenced by selecting the following options in the STATUS_OPTS parameter, see Chapter 2.8.3.
Option
Propagate Fail Forward
Uncertain if Man
Description
Propagates a transducer block status Bad.DeviceFailure or Bad.SensorFailure to
OUT_D without generating an alarm.
– Allows the user to detemine whether alarming (sending of an alert) will be done by the block or propagated downstream
Sets the output status of the block to Uncertain if the actual mode of the block is Man
On execution of the block, the device checks for correct configuration. Block errors are indicated in the BLOCK_ERR parameter.
Condition
Block Configuration Error
Reason
• CHANNEL parameter has an invalid value
• CHANNEL and HC transducer block configuration not compatible
Simulate Active • The current OUT_D value and status is simulated
Input Failure/ process variable has BAD status • I/O module or device failure, device initiating etc.
Out-of-Service • MODE_BLK.Target currently set to OOS
5.3.4
Block parameters
Parameter
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
PV_D
OUT_D
SIMULATE_D
XD_STATE
OUT_STATE
GRANT_DENY
IO_OPTS
STATUS_OPTS
CHANNEL
PV_FTIME
FIELD_VAL_D
UPDATE_EVT
BLOCK_ALM
ALARM_SUM
ACK_OPTION
DISC_PRI
DISC_LIM
DISC_ALM
Legend: RO = Read Only
Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
RO
Description/Action
See Chapter 2.3.4
0, 1
0, 1
0, 1
0 to 15
0, 1
Disable
0
0
0
0
0
0
0 s
0
+INF
Block mode, set to MODE_BLK.Target to AUTO
Block errors, see Chapter 5.2.3
Process value used in executing the block
Output value calculated as a result of executing the block
See Chapter 5.2.2, Enable/Disable options:
• Disable
• Active
True logic state of connected hardware
Logic state used by PV_D and OUT_D
Access options, see Chapter 2.8.1
"Invert" inverts signal, see Chapter 2.8.2 and Chapter 5.3.1
Status options, see Chapter 2.8.4 and Chapter 5.2.3
The number of the logical hardware channel to the transducer that is connected to this I/O block, see Chapter 5.1.
Time constant (s) of a single exponential filter for process value
Raw value of the field device
Alert generated by any change to the static data.
Block alarms, see Chapter 2.9
Alarm summary, see Chapter 2.9
See Chapter 2.9
• 0: Auto ACK Disable
• 1: Auto ACK Enable
Priority of the discrete alarm, see Chapter 2.9
State for which alarm must be output, see Chapter 2.9.
Status of discrete alarm and its associated time stamp.
74 Endress+Hauser
ControlCare Application Designer: Function Blocks 5 Input Blocks
5.4
Pulse Input (PULS)
The Pulse Input Block provides analog output values based on a pulse (counter) transducer input.
Two primary outputs are available:
• OUT provides an analog rate based on the number of pulses counted per block execution.
It is characterized by PULSE_VAL and TIME_UNITS and the engineering units are selected by scaling the output: the resulting range can be alarmed.
• OUT_ACCUM is the accumulated number of pulses and is intended to be connected to an integrator block for differencing, conversion, and integration. It is used when the count rate is low relative to the block execution rate.
In ControlCare Application Designer it is assigned the generic name Device Tag-PULS-n . It can be found by expanding the appropriate device or Field Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 5-3
From modules
SFC441
SFC442
SFC467 or
FF device
CHANNEL
(RRSGP) or as per device manual
SIMULATE
PULSE_VAL
TIME_UNITS
PV_FTIME
MAN
CONVERTION CONDITIONING
AUTO
ALARM
PROCESSING
AUTO
MAN
OUT
OUT_ACCUM
CHANNEL
PULSE_VAL
TIME_UNITS
OUT_SCALE
PV_FTIME
ALARM_HYS ,
XXX_PRI
XXX_LIM
Endress+Hauser
Fig. 5-3: Schematic diagram of Pulse Input block
5.4.1
Functional description
The CHANNEL parameter determines the transducer block logical channel carrying the pulse value (device or local I/O), see Chapter 5.1. The number of pulse counted over the block execution cycle is available at OUT_ACCUM , an analog rate at OUT .
If the OUT parameter is being used, the rate is set with the following parameters:
• The engineering quantity associated with one pulse in PULSE_VAL
• The time units of the measurement in TIME_UNITS (for HMI system)
If the OUT parameter is being used, the process value is scaled to the range and units required by any follow-up block with OUT_SCALE . Expand it to reveal the following elements
• EU_100 is the upper range limit of the output signal
• EU_0 is the lower range limit of the output signal
• UNIT_INDEX is the unit of the output signal
• DECIMAL is the number of figures behind the decimal point
The PV_FTIME parameter allows the ouput to be damped by entering a suitable positive value in seconds. The default value is zero.
The Analog Input block supports alarming of the OUT value using the parameters ALARM_HYS ,
XXX_PRI and XXX_LIM , in which global hysteresis, alarm priority and alarm values can be set individually for HI_HI_, HI_, LO_ and LO_LO_ limits. A full description of the function is to be found in Chapter 2.9.
75
5 Input Blocks
SIMULATE_P
ControlCare Application Designer: Function Blocks
5.4.2
Block configuration
The basic configuration of a Pulse Input block is shown in the table below. It is assumed that the pulse signal is obtained from a SFC442 pulse input module located in rack 1, slot 3, group 0 and
I/O point 0 of the local I/O, i.e. channel number 1300. Each pulse corresponds to 0.01 kg. The possible flow rate lies between 0 and 80 kg/min. In our case the default status options will be taken, so that the STATUS_OPTS parameter does not have to be configured (see Chapter 5.4.3).
Parameter
MODE BLOCK/TARGET
PULSE_VAL
TIME_UNITS
OUT_SCALE/EU_100
OUT_SCALE/EU_0
OUT_SCALE/UNITS_INDEX
CHANNEL
PV_FTIME
Function
Normal operating mode of block
Engineering quantity associated with one pulse
Time units of the measurement
Upper range limit for output variable
Lower range limit for output variable
Unit of output variable
Output channel of the local I/O connected to the block
• Rack 1, slot 3, group 0 and I/O point 0 = 1300
Output damping constant (in seconds). 1
Example value
Auto
0.01
minutes
80
0 kg
1300
5.4.3
Block operation
The block normally operates in AUTO mode. When online, the status and value of block output is displayed in the OUT parameter. The value and status of the signal from the transducer block can be viewed in the FIELD_VAL parameter. Any limit alarms are displayed in the ALARM_SUM and, if necessary, can be acknowledged in the HI_HI_ALM etc. parameters.
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
When MODE_BLK.Target
is set to MAN,
• the block output can be manipulated by entering the desired status and value in the OUT parameter. The PV parameter indicates the correct state.
• the OUT_ACCUM counter can reset by entering a new value (0) – it starts counting again as soon as the block is set to AUTO.
The process value in the Pulse Input block can be simulated in order to check the function of it and subsequent blocks during commissioning. A prerequisite for this is that the hardware lock of the device is set to enable. When simulation is enabled, "Simulation Active" appears in the resource block parameter BLOCK_ERROR by , see Chapter 2.9 and Chapter 3.2.7.
Simulation parameters can be changed when the block is in AUTO mode. Expand the
SIMULATE_P parameter to enter a simulated value:
• Set the status of the simulated variable in SIMULATE_STATUS
• Set the value of the simulated variable in SIMULATE_VALUE
• Set ENABLE_DISABLE to "Active" to start simulation
The parameters TRANSDUCER_STATUS and TRANSDUCER_VALUE indicate the status and value of the raw process value. The block output OUT reflects the simulated parameters after processing in the block.
Simulation in an I/O block is disabled by setting ENABLE_DISABLE to "Disable". In this state
SIMULATE_STATUS and SIMULATE_VALUE etc. track TRANSDUCER_STATUS and
TRANSDUCER_VALUE in order to provide a bumpless transfer from disabled to enabled.
76 Endress+Hauser
ControlCare Application Designer: Function Blocks
Status propagation
Block errors
5 Input Blocks
The Pulse Input block supports the qualities Bad, Uncertain and GoodNC together with the associated substatuses, see Chapter 2.3.2. Status propagation can be influenced by selecting the following options in the STATUS_OPTS parameter, see Chapter 2.8.3.
Option
Propagate Fail Forward
Uncertain if Limited
BAD if Limited
Uncertain if Man
Description
Propagates a transducer block status Bad.DeviceFailure or Bad.SensorFailure to OUT without generating an alarm.
– Allows the user to detemine whether alarming (sending of an alert) will be done by the block or propagated downstream
Sets the output status of the block to Uncertain when limit alarms HI_HI_, HI_, LO_ or LO_LO_ are violated
– Option when alarms have been set on the output value
Sets the output status of the block to Bad when limit alarms HI_HI_, HI_, LO_ or
LO_LO_ are violated
– Option when alarms have been set on the output value
Sets the output status of the block to Uncertain if the actual mode of the block is Man
On execution of the block, the device checks for correct configuration. Block errors are indicated in the BLOCK_ERR parameter.
Condition
Block Configuration Error
Reason
• CHANNEL parameter has an invalid value
• CHANNEL and HC transducer block configuration not compatible
• XXX_LIM limit value is out of valid range
Simulate Active • The current OUT value and status is simulated
Input Failure/ process variable has BAD status • I/O module or device failure, device initiating etc.
Out-of-Service • MODE_BLK.Target currently set to OOS
Endress+Hauser 77
5 Input Blocks
Pulse Input block
ControlCare Application Designer: Function Blocks
ALARM_HYS
HI_HI_PRI
HI_HI_LIM
HI_PRI
HI_LIM
LO_PRI
LO_LIM
LO_LO_PRI
LO_LO_LIM
HI_HI_ALM
HI_ALM
LO_ALM
LO_LO_ALM
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
PV
OUT
OUT_ACCUM
SIMULATE_P
PULSE_VAL
TIME_UNITS
OUT_SCALE
GRANT_DENY
IO_OPTS
STATUS_OPTS
CHANNEL
PV_FTIME
FIELD_VAL
UPDATE_EVT
BLOCK_ALM
ALARM_SUM
ACK_OPTION
5.4.4
Block parameters
Parameter Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
RO
Description/Action
See Chapter 2.3.4
Disable
Block mode, set to MODE_BLK.Target to AUTO
Block errors, see Chapter 5.2.3
Process value used in executing the block
Output value calculated as a result of executing the block
Accumulated number of pulses since last reset
See Chapter 5.2.2, Enable/Disable options: Disable; Active
Engineering quantity associated with one pulse
Time units of the measurement
0
0
0-100% OUT value scaling to require engineering units
0 Access options, see Chapter 2.8.1
0
Not used
Status options, see Chapter 2.8.4 and Chapter 5.4.2
The number of the logical hardware channel to the transducer that is connected to this I/O block, see Chapter 5.1.
0 s Time constant (s) of a single exponential filter for process value
Raw value of the field device in percent of PV range
Alert generated by any change to the static data.
Block alarms, see Chapter 2.9
RO
0, 1 0
0 to 50 % 0.5%
0 to 15
0 to 15
0 to 15
0 to 15
+INF
+INF
-INF
-INF
Alarm summary, see Chapter 2.9
See Chapter 2.9
• 0: Auto ACK Disable;
• 1: Auto ACK Enable
Alarm hysteresis in % of OUT_SCALE, see Chapter 2.9
Priority of the HI_HI alarm, see Chapter 2.9
Setting of HI_HI alarm in engineering units, see Chapter 2.9.
Priority of the HI alarm, see Chapter 2.9
Setting of HI alarm in engineering units, see Chapter 2.9.
Priority of the LO alarm, see Chapter 2.9.
Setting of LO alarm in engineering units, see Chapter 2.9.
Priority of the LO_LO alarm, see Chapter 2.9
Setting of LO_LO alarm in engineering units, see Chapter 2.9
Status of HI_HI alarm and its associated time stamp.
Status of HI alarm and its associated time stamp.
Status of LO alarm and its associated time stamp.
Status of LO_LO alarm and its associated time stamp.
78 Endress+Hauser
ControlCare Application Designer: Function Blocks
CHANNEL
Channel configuration
5 Input Blocks
5.5
Multiple Analog Input (MAI)
The Multiple Analog Input block scales up to eight electrical input signals of 4 mA to 20 mA or
1 V to 5 V to OUT_x values of 0% to 100%. The block can be used together with the ControlCare
SFC444 and SFC457 analog input modules. If other input signals are used with these modules,
Analog Input blocks must be used.
The block does not support linearization, scaling, low-flow cut off or simulation. If these properties are required, an Analog Input block must be created for the output channel in question.
In ControlCare Application Designer the Multiple Analog Input block is assigned the generic name
Device Tag-MAI-n . It can be found by expanding the appropriate device or Field Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 5-4.
From modules
SFC444
SFC457
I/O points
AI 0 to AI 7 read together
CHANNEL
RRSG
9
INPUT
SNAP OF
TRANSDUCER
BLOCK
OUTPUTS
MANUAL
AUTO
MANUAL
AUTO
MANUAL
AUTO
MANUAL
AUTO
MANUAL
AUTO
MANUAL
AUTO
MANUAL
AUTO
MANUAL
AUTO
MODE
Fig. 5-4: Schematic diagram of Multiple Analog Input block
OUT_1
OUT_2
OUT_3
OUT_4
OUT_5
OUT_6
OUT_7
OUT_8
5.5.1
Functional description
The CHANNEL parameter determines the transducer block logical channel carrying the analog inputs according to the scheme Rack+Slot+Group+ 9 , see Chapter 5.1.
The input channels of the SFC444 and SFC457 can be configured individually by jumpers on the printed circuit board to accept current or voltage signals, default setting current, see Chapter 3.5.1 of operating instructions BA021S/04/en, Field Controller: Hardware Installation.
5.5.2
Block configuration
The basic configuration of a Multiple Analog Input block is shown in the table below. It is assumed that the analog signals are obtained from a SFC444 analog input module located in rack 1, slot 4.
Parameter
MODE BLOCK/TARGET
CHANNEL
Function
Normal operating mode of block
Output channel of the local I/O connected to the block
• Rack 1, slot 4, group 0 and I/O point 9 = 1409
Example value
Auto
1409
Endress+Hauser 79
5 Input Blocks
Status propagation
Block errors
ControlCare Application Designer: Function Blocks
5.5.3
Block operation
The block normally operates in AUTO mode. When online, the status and value of block output is displayed in the OUT_X parameter.
The OUT_X value is proportional to the electrical signal over the range 0 mA to 40 mA and 0 V to
10 V. The MAI block converts the input as shown below
Value
Underrange limit
Lower range limit
Upper range limit
Overrange limit
Out of range
Current Voltage
Input value OUT value OUT status Input value OUT value OUT status
0 mA
4 mA
-25%
0 %
GOOD
GOOD
0 V
1 V
-25%
0 %
GOOD
GOOD
20 mA
40 mA
>40 mA
100%
225%
BAD
GOOD
GOOD
BAD
5 V
10 V
>10 V
100%
225%
BAD
GOOD
GOOD
BAD
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
When MODE_BLK.Target
is set to MAN, the block output can be manipulated by entering the desired status and value in the OUT_x parameter.
The Multiple Analog Input block supports the qualities Bad, Uncertain and GoodNC together with the associated substatuses, see Table 5-11 above and Chapter 2.3.2.
On execution of the block, the device checks for correct configuration. Block errors are indicated in the BLOCK_ERR parameter.
Condition
Block Configuration Error
Reason
• CHANNEL has an invalid value
• CHANNEL and HC transducer block configuration not compatible
Input Failure/ process variable has BAD status • I/O module or device failure, device initiating etc.
Out-of-Service • MODE_BLK.Target currently set to OOS
Multiple Analog Input block
5.5.4
Block parameters
Parameter
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
CHANNEL
OUT_1...OUT_8
UPDATE_EVT
BLOCK_ALM
Legend: RO = Read Only
Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
0
Description/Action
See Chapter 2.3.4
Block mode, set to MODE_BLK.Target to AUTO
Block errors, see Chapter 5.2.3
The number of the logical hardware channel to the transducer that is connected to this I/O block, see Chapter 5.1.
Output value and status for channel x calculated as a result of executing the block
Alert generated by any change to the static data.
Block alarms, see Chapter 2.9
80 Endress+Hauser
ControlCare Application Designer: Function Blocks
CHANNEL
5 Input Blocks
5.6
Multiple Discrete Input (MDI)
The Multiple Discrete Input block converts up to eight electrical input signals of low or high value into OUT_Dx values of 0 or 1. It can be used together with the SFC411, SFC415, SFC420,
SFC432, SFC435 and SFC438 discrete input and discrete input/output modules. If signal characterization or simulation is required, Discrete Input blocks must be used.
In ControlCare Application Designer the Multiple Analog Input block is assigned the generic name
Device Tag-MDI-n . It can be found by expanding the appropriate device or Field Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 5-5.
From modules
SFC411
SFC415
SFC420
SFC432
SFC435
SFC438
I/O points
DI 0 to DI 7 read together
CHANNEL
RRSG
9
INPUT
SNAP OF
TRANSDUCER
BLOCK
OUTPUTS
MANUAL
AUTO
MANUAL
AUTO
MANUAL
AUTO
MANUAL
AUTO
MANUAL
AUTO
MANUAL
AUTO
MANUAL
AUTO
MANUAL
AUTO
MODE
Fig. 5-5: Schematic diagram of Multiple Discrete Input block
OUT_D1
OUT_D2
OUT_D3
OUT_D4
OUT_D5
OUT_D6
OUT_D7
OUT_D8
5.6.1
Functional description
The CHANNEL parameter determines the transducer block logical channel carrying the descrete inputs according to the scheme Rack+Slot+Group+ 9 , see Chapter 5.1..
5.6.2
Block configuration
The basic configuration of a Multiple Analog Input block is shown in the table below. It is assumed that the analog signals are obtained from a SFC411 discrete input module located in rack 2, slot 2.
The Group 1 connections are used:
Parameter
MODE BLOCK/TARGET
CHANNEL
Function
Normal operating mode of block
Output channel of the local I/O connected to the block
• Rack 2, slot 2, group 1 and I/O point 9 = 2219
Example value
Auto
2219
Endress+Hauser 81
5 Input Blocks
Block errors
ControlCare Application Designer: Function Blocks
5.6.3
Block operation
The block normally operates in AUTO mode. When online, the status and value of block output is displayed in the OUT_DX parameter.
The MDI block converts the input signals as into OUT_Dx = "0" or "1" as shown below.
OUT_Dx Value SFC411
ON state level (True)
OUT_Dx = 1
OFF state level (False)
OUT_Dx = 0
18 – 30 VDC
0 – 5 VDC
SFC415
0 – 5 VDC,
< 200
20 – 30 VDC,
> 10 k
SFC420
Switch latched
Switches unlatched
SFC432, SFC435
SFC438
15 - 30 VDC
0 - 5 VDC
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
When MODE_BLK.Target
is set to MAN, the block output can be manipulated by entering the desired status and value in the OUT_Dx parameter. Status propagation
The Multiple Discrete Input block supports the qualities Bad, Uncertain and GoodNC together with the associated substatuses, see Chapter 2.3.2.
On execution of the block, the device checks for correct configuration. Block errors are indicated in the BLOCK_ERR parameter.
Condition
Block Configuration Error
Reason
• CHANNEL has an invalid value
• CHANNEL and HC transducer block configuration not compatible
Input Failure/ process variable has BAD status • I/O module or device failure, device initiating etc.
Out-of-Service • MODE_BLK.Target currently set to OOS
Multiple Discrete Input block
5.6.4
Block parameters
Parameter
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
CHANNEL
OUT_D1...OUT_D8
UPDATE_EVT
BLOCK_ALM
Legend: RO = Read Only
Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
0
0 s
Description/Action
See Chapter 2.3.4
Block mode, set to MODE_BLK.Target to AUTO
Block errors, see Chapter 5.2.3
The number of the logical hardware channel to the transducer that is connected to this I/O block, see Chapter 5.1.
Output value and status after execution of the block
Alert generated by any change to the static data.
Block alarms, see Chapter 2.9
82 Endress+Hauser
ControlCare Application Designer: Function Blocks 6 Control Blocks
6 Control Blocks
6.1
PID Control
The PID Control block provides proportional, integral and derivative control of the process. The block attempts to correct the error or control deviation between a measured process variable, PV and a desired setpoint, SP , by calculating an actuating or manipulated variable and then outputting a corrective action as an OUT value that adjusts the process accordingly.
The block can be configured to perform a number of control tasks including closed-loop control, feedforward control, cascade control and remote interfacing. A number of options, e.g. bypass or tracking, ensure that the connected actuator continues to operate or fails to safe on bad input under certain process conditions.
In ControlCare Application Designer the PID Control block is assigned the generic name Device
Tag-PID-n . It can be found by expanding the appropriate device or Field Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 6-1.
CAS_IN
RCAS_IN
SP
LIMITS
RCAS_OUT
SP
SELECTOR
IN
OPERATOR ENTRY
PV_TIME
FF_VAL
FF_SCALE
FF_GAIN
TRK_VAL
TRK_IN_D
BKCAL_IN
TRK_SCALE
OUT_SCALE
SP
ROUT_IN
PID +
FF
OUT_SCALE
OUT
SELECTOR
OUT
LIMITS
ROUT_OUT
SP
PV
CONTROL_OPTS
OUT
BKCAL_OUT
Fig. 6-1: Schematic diagram of PID Control block
Chapter 6.1.1 contains a general description of the block. Subsequent parts of Chapter 6.1 concentrate on its configuration for specific tasks and its behaviour during operation. Chapter 6.1.8 contains a overview of all parameters of the block.
Endress+Hauser 83
6 Control Blocks
Process value
Feedforward
ControlCare Application Designer: Function Blocks
6.1.1
Functional description
Fig. 6.2 shows the internal structure of the PID function block.
FF_VAL
PID Bloc k
Feed forward calculation
CAS_IN
Setpoint from supervisory host system
RCAS_IN
FF_GAIN
FF_SCALE
RCAS_OUT
Setpoint limiting
SP SP_HI_LIM
SP_LO_LIM
SP_RATE_DN
SP_RATE_UP
TRK_IN_D
BKCAL_IN
IN
MODE
Scaling and filtering
PV
PV_SCALE
PV_FILTER
TRK_SCALE
OUT_SCALE
Bypass
PID
Equation
GAIN
RATE
RESET
Alarm detection
HI_HI_LIM / HI_LIM
LO_LO_LIM / LO_LIM
DV_HI_LIM / DV_LO_LIM
Output from supervisory host system
ROUT_IN ROUT_OUT
Output limiting
Calculated actuating variable
OUT_HI_LIM
OUT_LO_LIM
OUT_SCALE
TRK_VAL Converter
BCAL_OUT
OUT
Fig. 6-2: Functional diagram of PID Control block
The control variable is connected to IN , scaled in PV_SCALE and passed through the filter
PV_FTIME . If the value of PV_TIME is zero (default), the filter is disabled. The resulting process value PV is used in conjunction with the setpoint SP in the PID algorithm. PV will normally adopt the status of IN , unless there is a block or process alarm, in which case its quality will become
"Uncertain". If the block operates in Local Override (LO), the limit status of PV is "Constant" and the PID algorithm is not executed.
PV can be limited using the parameters HI_HI_LIM , HI_LIM , LO_LO_LIM , and LO_LIM , whereby the default value is no limit. A universal alarm hysteresis in percent of PV span can be set for all limits in the ALARM_HYS parameter. Alarm priorities are set in the associated parameter, i.e. HI_HI_PRI etc.
If PV is out of limits, an alarm is sent to the fieldbus host system. Alarms are displayed in the
ALARM_SUM parameter and must be acknowledged in the associated alarm parameter, i.e.
HI_HI_ARM etc. Automatic alarm acknowledgement can be enabled by selecting the appropriate option in ACK_OPTS .
The PID Control block supports the feedforward algorithm. An external value that is proportional to some disturbance in the control loop is connected to FF_VAL . The value is converted to percent of output span by FF_SCALE . This is multiplied by FF_GAIN and added to the target output of the
PID algorithm ("F" in the PID equation).
To prevent bumping the output, the last good value of "F" is used if the status of FF_VAL is "Bad".
When the status returns to good, the block adjusts its integral term to maintain the previous output.
84 Endress+Hauser
ControlCare Application Designer: Function Blocks
Setpoint
PID control algorithm
6 Control Blocks
Depending upon the operating mode of the PID Control block, the target setpoint and status is provided by SP , CAS_IN or RCAS_IN as shown below:
MODE_BLK
AUTO
CAS
RCAS
Setpoint value
SP
CAS_IN
RCAS_IN
Origin
Value is constant and entered manually by the operator.
Originates from an upstream function or control block
Originates from a supervisory host
The setpoint SP can be adjusted in AUTO mode. To ensure bumpless transfer when the setpoint SP changes, a downward or upward ramp in PV units per second can be set in the parameters
SP_RATE_DN and SP_RATE_UP respectively. The setpoint then moves from the old to the new value at the set rate. If the ramp rate is set to zero, the new setpoint will be used immediately.
A valid range for setpoint operator entries can be defined by entering appropriate limits in
SP_HI_LIM and SP_LO_LIM in units of PV_SCALE. If an invalid SP is entered, the parameter reverts to the last valid entry. Normally, the limits apply to SP only but they can be enabled for
CAS_IN and RCAS_IN by selecting the option "Obey SP limits if CAS or RCAS" in
CONTROL_OPTS .
The PID Control block algorithm involves three separate parameters:
• the proportional value or P-term determines the reaction to the current error
• the integral value of I-term determines the reaction based on the sum of recent errors and
• the derivative value or D-term, determines the reaction to the rate at which the error has been changing.
The weighted sum of these three actions is output to a control element such as the position of a control valve or power into a heating element according to the following equation: y = GAIN e +
1
RESET
e t +
+ + F whereby:
• y = Actuating (or manipulated) variable calculated from the PID algorithm (OUT).
• GAIN= Proportional gain factor (100/proportional band)
• RESET= Time constant for the integral action in seconds/repeat
• RATE= Time constant for the derivative action in seconds
• e =
• PV
• F =
Control deviation or error (e = SP - PV)
Process value
Disturbance variable (F = FF_VAL x FF_GAIN)
By default, the PID algorithm is "Indirect Acting", i.e. the output increases when PV is less than SP and decreases when the reverse is true. This behaviour can be reversed by selecting the "Direct
Acting" option in CONTROL_OPTS . The output will now decrease when PV is less than SP and vice versa. The option also controls whether positive or negative feedback is applied and affects the calculation of the limit state for BKCAL_OUT .
The control deviation "e" can be limited using the parameters DV_HI_LIM and DV_LO_LIM , whereby the default value is not limited-. A universal alarm hysteresis in percent of PV span can be set for both limits in the ALARM_HYS parameter (this also applies to HI_HI_LIM etc.). Alarm priorities are set in DV_HI_PRI and DV_LO_PRI .
If DV violates the defined limit values, an alarm is sent to the fieldbus host system. Alarms are displayed in the ALARM_SUM parameter and must be acknowledged in DV_HI_ARM and
DV_LO_ALM . Automatic alarm acknowledgement can be enabled by selecting the appropriate option in ACK_OPTS .
Endress+Hauser 85
6 Control Blocks
Bypass
Back calculation
Output
Output tracking
ControlCare Application Designer: Function Blocks
The bypass function allows an operator to bypass the PID algorithm if the PV of a secondary cascade control-loop is "Bad". The function is enabled by selecting the option "Bypass Enable" in
CONTROL_OPTS . The bypass itself can be switched on and off by changing to MAN or OOS mode and selecting the appropriate option in BYPASS .
When BYPASS is "On", the value of SP , in percent of range, is passed directly to the target output, and the value of OUT is used for BKCAL_OUT . When the operating mode returns to CAS, the upstream block is requested to initialize to the value of OUT .
When BYPASS is reset to "Off" and the block returns to CAS, the upstream block is requested to initialize to the PV value, regardless of the “Use PV for BKCAL_OUT” option, see back calculation.
The BKCAL_IN parameter carries the feedback, i.e. value and status, from the BKCAL_OUT parameter of a downstream block and is used to prevent reset windup and to initialize the control loop. The PID Control block always acts on the status it carries, independent of any control options and independent of whether it is operating in AUTO, CAS or RCAS mode. Possible statuses and actions are listed in Chapter 2.3.
Normally, the BKCAL_OUT parameter of the PID Control block itself carries the value and status of SP . Depending on the CONTROL_OPTS parameter, it may be forced to a different condition.
When the block operates in RCAS, RCAS_OUT (= SP) provides the back calculation for the host, allowing action to be taken under limiting conditions or mode change.
CONTROL_OPS option
None
None, but RCAS mode
Bypass Enable, BYPASS "On"
Bypass Enable, BYPASS "Off"
Use PV for BKCAL_OUT
BKCAL_OUT value and status
SP value and status
PV value and status after limiting
OUT value and substatus "Initialization Request" on return to CAS
OUT value and status after receipt of substatus "Initialization Acknowledge"
PV value and substatus "Initialization Request" on return to CAS,
SP value and status after receipt of substatus "Initialization Acknowledge"
PV value and status
When the block is operating in AUTO, CAS or RCAS mode, the actuating variable becomes the output OUT after being being scaled in OUT_SCALE . It can also be limited in OUT_HI_LIM and
OUT_LOW_LIM . If the calculated value of the output exceeds or drops below these limits, the appropriate limit value is used as output. The BKCAL_HYS parameter places a hysteresis, in percent of output scale, on the limit values.
If the block is in MAN mode, the OUT value and status may be set by hand. In order to prevent bumps on change from one mode to another, the OUT value is balanced. The time taken for the transition from the old to the new value can be entered in BAL_TIME .
If the block is in ROUT mode, the PID algorithm is not used and OUT is fed directly from a supervisory host system via the parameter ROUT_IN . It may also be replaced by an external tracking value as in output tracking. ROUT_OUT provides the feedback to the host
The PID Control block supports the track algorithm, allowing the output to be forced to a value on command by a discrete value. The actual mode then goes to local override, LO. Tracking is enabled for AUTO and RCAS modes by selecting the option "Track Enable" in CONTROL_OPTS . If tracking is to be enabled in MAN mode, the option "Track in Manual" must be selected as well. The
TRK_VAL input brings in an external track value or may be set manually. The value is converted to percent of output span using the parameter values of TRK_SCALE . When TRK_IN_D is true, the converted TRK_VAL replaces OUT and the operating mode is forced to LO. The track request is ignored if the current mode is OOS.
If the status of TRK_IN_D is "Bad", its last usable value will be maintained and acted upon. If the device restarts, losing the last usable value, the status will be set to false. If there is no last usable value, the present value of the output will be used.
86 Endress+Hauser
ControlCare Application Designer: Function Blocks
Example
6 Control Blocks
6.1.2
Closed-loop control
Basic closed-loop control requires process input, e.g. a measurement provided by an Analog Input block, that has an effect on the process output, e.g. the Analog Output block, which is calculated by the control block. The result (the control signal) is used as input to the process, closing the loop.
A measurement of flow upstream of a valve ensures a constant flow rate downstream of a valve, by causing the valve to open and close, see Fig. 6-2.
CV
102
FCV
101
PID control
FT
100
Block configuration
Fig. 6-3: Example of closed-loop control
Fig. 6-3 shows the control strategy together with links that must be made between the blocks.
FT100
AI
OUT IN
BKCAL_IN
PID
OUT CAS_IN
AO
OUT
BKCAL_OUT
FCV101 CV102
Fig. 6-4: Links required for basic closed-loop control
The block is configured as follows, see also the table below:
• Set MODE_BLK.Target
to AUTO
• Enter the setpoint value in the units required by the PID algorithm in SP
• Scale the input from the AI block to the units required by the PID algorithm in PV_SCALE
• Scale the output of the block in the units required by the AO block in OUT_SCALE
• To bypass the PID algorithm on bad input status, select Bypass Enable in CONTROL_OPTS
• To ensure bumpless transfer should SP change, e.g. though a manual intervention, set a rate of change in the SP_RATE_DN and SP_RATE_UP parameters with which the old SP value adapts to the new SP value
• Set the parameters GAIN , RESET and RATE to values appropriate to your application.
Parameter
MODE_BLK.Target
SP
PV_SCALE.EU_100
PV_SCALE.EU_0
PV_SCALE.UNITS_INDEX
OUT_SCALE/EU_100
OUT_SCALE/EU_0
OUT_SCALE/UNITS_INDEX
CONTROL_OPTS
SP_RATE_DN
SP_RATE_UP
GAIN
RESET
RATE
Function
Normal operating mode of block
Setpoint for ideal process control
Upper range limit for process variable
Lower range limit for process variable
Unit of process variable
Upper range limit for output variable
Lower range limit for output variable
Unit of output variable
Sets control options for bad input
Rate of change from old to new, higher SP
Rate of change from old to new, lower SP
Tuning constants for the P, I and D terms of the PID block respectively.
Example value
Auto
60%
100
0
%
100
0
%
Bypass Enable
0
0
1.5
0.1 s
0.5 s
Endress+Hauser 87
6 Control Blocks
Example
ControlCare Application Designer: Function Blocks
6.1.3
Feedforward control
Feedforward control may be used where a system responds to a measured disturbance in a predictable way. Provided that the disturbance is measurable, the effect of the disturbance on the output of the system is known and the controller affects the output before the disturbance does, feedforward control can be implemented. Feedforward control can also be used with closed-loop control to improve reference tracking performance.
The temperature of water measured downstream of a heat exchanger controls the supply of steam by opening and closing a control valve, see Fig. 6-4. A flowmeter upstream of the heat exchanger gives information on the the amount of water to flowing through the exchanger. The flowmeter
Analog Output block supplies the feedforward information, the temperature device Analog Input block the process value. The Analog Output block of the control valve controls the control valve actuator.
Feedforward TCV
102
PID control
CV
103
FT
101
TT
100
Fig. 6-5: Example of feedforward control
Fig. 6-5 shows the control strategy together with links that must be made between the blocks.
OUT
FT101
AI
TT100
AI
FF_VAL
OUT IN
BKCAL_IN
PID
OUT CAS_IN
AO
OUT
BKCAL_OUT
TCV102 CV103
Fig. 6-6: Links required for feedforward and closed loop control
88 Endress+Hauser
ControlCare Application Designer: Function Blocks
Block configuration
6 Control Blocks
The table blelow lists the basic parameters for feedforward control with some examples of values.
The block is configured as follows:
• Set MODE_BLK.Target
to AUTO
• Enter the setpoint value in the units required by the PID algorithm in SP
• Scale the input from the AI block providing the control measurement to the units required by the PID algorithm in PV_SCALE
• Scale the output of the block in the units required by the AO block in OUT_SCALE
• To bypass the PID algorithm on bad input status, select Bypass Enable in CONTROL_OPTS
• To ensure bumpless transfer should SP change, e.g. though a manual intervention, set a rate of change in the SP_RATE_DN and SP_RATE_UP parameters with which the old SP value adapts to the new SP value
• Set the parameters GAIN , RESET and RATE to values appropriate to your application
• Scale the input from the AI block providing the feedforward measurement to the units required by the PID algorithm in FF_SCALE
• Enter the gain associated with the feedforward variable in FF_GAIN .
Parameter
MODE_BLK.Target
SP
PV_SCALE.EU_100
PV_SCALE.EU_0
PV_SCALE.UNITS_INDEX
OUT_SCALE/EU_100
OUT_SCALE/EU_0
OUT_SCALE/UNITS_INDEX
CONTROL_OPTS
SP_RATE_DN
SP_RATE_UP
GAIN
RESET
RATE
FF_SCALE.EU_100
FF_SCALE.EU_0
FF_SCALE.UNITS_INDEX
FF_GAIN
Function
Normal operating mode of block
Setpoint for ideal process control
Upper range limit for process variable
Lower range limit for process variable
Unit of process variable
Upper range limit for output variable
Lower range limit for output variable
Unit of output variable
Sets control options for bad input
Rate of change from old to new, higher SP
Rate of change from old to new, lower SP
Tuning constants for the P, I and D terms of the PID block respectively.
Upper range limit for feedforward variable
Lower range limit for feedforward variable
Unit of feedforward variable
The gain that the feedforward input is multiplied by before it is added to the calculated control output.
Example value
Auto
60%
100
0
%
1.5
0.1 s
0.5 s
100
0
%
1
100
0
%
Bypass Enable
0
0
Endress+Hauser 89
6 Control Blocks
Example
ControlCare Application Designer: Function Blocks
6.1.4
Cascade control
Cascade control uses the output of the primary PID Control block to manipulate the setpoint of the secondary PIC Control block as if it were the final control element. This allows disturbances in the secondary loop as well as non-linear valve and other final control element problems to be handled by the secondary PID Control block. In addition, the operator can directly control the secondary loop during certain modes of operation, such as startup
The requirements for cascade control are:
• the process dynamics of the secondary loop must be at least four times as fast as those of the primary loop
• the secondary loop must have influence over the primary loop.
• the secondary loop must be measurable and controllable.
The temperature of water measured upstream of a heat exchanger is used as input to a primary PID
Control block which manipulates a secondary block controlling the supply of steam by opening and closing a control valve, see Fig. 6-7. The input to the secondary block is the flowrate of the steam.
The flowmeter Analog Output block supplies the input value to the secondary loop, the temperature device Analog Input block the process value. The Analog Output block of the control valve controls the control valve actuator. secondary loop
FT
102
FCV
103 primary loop
TC
101
CV
104
TT
100
90
Fig. 6-7: Example of cascade control
Fig. 6-7 shows the control strategy together with links that must be made between the blocks.
TT100
AI
FT102
AI
OUT IN
PID
BKCAL_IN
TC101 OUT
OUT
CAS_IN
IN
BKCAL_IN
PID
FCV103
BKCAL_OUT AO
OUT CAS_IN
CV104
OUT
BKCAL_OUT
Fig. 6-8: Links required for cascade control
Endress+Hauser
ControlCare Application Designer: Function Blocks
Block configuration
Primary loop
Secondary loop
6 Control Blocks
The table below lists the basic parameters for cascade control with some examples of values. The block is configured as follows:
• Set MODE_BLK.Target
to AUTO
• Enter the setpoint value in the units required by the PID algorithm in SP
• Scale the input from the AI block to the units required by the PID algorithm in PV_SCALE
• Scale the output of the block in the units required by the AO block in OUT_SCALE
• To bypass the PID algorithm on bad input status, select Bypass Enable in CONTROL_OPTS
• To ensure bumpless transfer should SP change, e.g. though a manual intervention, set a rate of change in the SP_RATE_DN and SP_RATE_UP parameters with which the old SP value adapts to the new SP value
• Set the parameters GAIN , RESET and RATE to values appropriate to your application.
• Set MODE_BLK.Target
to CAS
• Enter the setpoint value in the units required by the PID algorithm in SP
• Scale the input from the AI block to the units required by the PID algorithm in PV_SCALE
• Scale the output of the block in the units required by the AO block in OUT_SCALE
• To bypass the PID algorithm on bad input status, select Bypass Enable in CONTROL_OPTS
• To ensure bumpless transfer should SP change, e.g. though a manual intervention, set a rate of change in the SP_RATE_DN and SP_RATE_UP parameters with which the old SP value adapts to the new SP value
• Set the parameters GAIN , RESET and RATE to values appropriate to your application
• To ensure automatic recovery to CAS if the mode changes, e.g. due to bad input, select the option "Normal shed, Normal return" in the SHED_OPT parameter
(For other options see Chapter 2.4.4)
Parameter
MODE_BLK.Target
SP
PV_SCALE.EU_100
PV_SCALE.EU_0
PV_SCALE.UNITS_INDEX
OUT_SCALE/EU_100
OUT_SCALE/EU_0
OUT_SCALE/UNITS_INDEX
CONTROL_OPTS
SP_RATE_DN
SP_RATE_UP
GAIN
RESET
RATE
SHED_OPT
Function
Normal operating mode of block
Setpoint for ideal process control
Upper range limit for process variable
Lower range limit for process variable
Unit of process variable
Upper range limit for output variable
Lower range limit for output variable
Unit of output variable
Sets control options for bad input
Rate of change from old to new, higher SP
Rate of change from old to new, lower SP
Tuning constants for the P, I and D terms of the PID block respectively.
Behaviour when shedding from remote mode
Example value
Primary loop: AUTO
Secondary loop: CAS
60%
100
0
%
100
0
%
Bypass Enable
0
0
1.5
0.1 s
0.5 s
Normal shed, normal return
Endress+Hauser 91
6 Control Blocks
Example
Block configuration
ControlCare Application Designer: Function Blocks
6.1.5
Output tracking
The output tracking function allows the PID Control block output to be overridden and replaced by a predefined value set in the TRK_VAL parameter. The override is only effective when tracking is enabled and the TRK_IN_D value is true. During this time, the block mode changes to LO (local override). The function is normally used to force the block to output a fail-safe value.
A measurement of flow upstream of a valve is used to ensure a constant flow rate into a vessel, see
Fig. 6-9. To prevent overspill, the vessel is equipped with a level limit switch. If the liquid rises to the switch the latter switches, causing the valve to close (and the pump to stop). The flowrate is controlled as in Chapter 6.1.1, the tracking signal is delived through a Discrete Input block.
M
104
CV
103
FCV
102
Track input
PID control
FT
100
LS
101
Fig. 6-9: Example of output tracking
Fig. 6-10 shows the control strategy together with links that must be made between the blocks.
OUT_D
LS101
DI-0
Channel e.g. 1300
LS101
DI
FT100
AI
TRK_IN_D
OUT IN
BKCAL_IN
PID
OUT CAS_IN
FCV102
AO
OUT
BKCAL_OUT
CV103
Fig. 6-10: Links required for tracking (with basic loop-control)
Output tracking is configured as follows:
• Depending upon type, configure the control loop is as described in Chapters 6.1.1 to 6.1.3.
• Enable tracking by selecting "Track Enable" in the CONTROL_OPS parameter
• Select the option "Use uncertain as good" in the STATUS_OPS parameter
• Scale the track value to the units of the OUT value in TRK_SCALE
• Enter the track value in TRK_VAL .
Parameter
CONTROL_OPTS
STATUS_OPTS
TRK_SCALE.EU_100
TRK_SCALE.EU_0
TRK_SCALE.UNITS_INDEX
TRK_VAL
Function
Enables output tracking
Sets the way the status of the tracking value is used
Upper range limit for track value
Lower range limit for track value
Unit of process track value
Value to be output by the block
Example value
Track Enable
Use uncertain as good
100
0
%
0%
92 Endress+Hauser
ControlCare Application Designer: Function Blocks
Example
6 Control Blocks
6.1.6
Remote cascade
The remote cascade function allows a setpoint value calculated by an external application, e.g. a
Modbus controller, to be used as the primary loop input of a cascade control loop. Since the external application is not contained in the function block schedule, a timeout must be set in the resource block as well as the response of the PID Control block when the timeout is exceeded.
The temperature of water measured upstream of a heat exchanger is acquired by an external
Modbus controller and used as input to a primary PID Control block that runs in it. The resulting setpoint manipulates a secondary block controlling the supply of steam by opening and closing a control valve, see Fig. 6-11. The input to the secondary block is the flowrate of the steam. The flowmeter Analog Output block supplies the input value to the secondary loop, the Modbus Control
Slave block provides the setpoint to the secondary block, see Chapter 10.3. The Analog Output block of the control valve controls the control valve actuator.
Note
• The connection to the external application may also be made via OPC server, in which case the parameter Device Tag-PID-n.RCAS_IN
carries the setpoint and the parameter Device Tag-PID-n.RCAS_OUT
the feedback.
secondary loop
FT
102
FCV
103 setpoint
CC
101
Primary loop running in external controller
CV
104
TT
100
Endress+Hauser
Fig. 6-11: Example of remote cascade
Fig. 6-12 shows the control strategy together with links that must be made between the blocks. For more details on creating control strategies, see the appropriate ControlCare tutorial.
FT102
AI
MBCS
IN1
CC101
OUT1
OUT
RCAS_IN
IN
BKCAL_IN
PID
FCV103
RCAS_OUT AO
OUT CAS_IN
CV104
OUT
BKCAL_OUT
Fig. 6-12: Links required for remote cascade (through MBCS block)
93
6 Control Blocks
Block configuration
SHED_OPT
ControlCare Application Designer: Function Blocks
The remote cascade is configured as follows:
• In the Resource Block of the device set SHED_RCAS to the maximum time allowable for the execution of the Control PID block
• In the PID Control block set MODE_BLK.Target
to RCAS
• Scale the input from the AI block to the units required by the PID algorithm in PV_SCALE
• Scale the output of the block in the units required by the AO block in OUT_SCALE
• To bypass the PID algorithm on bad input status, select Bypass Enable in CONTROL_OPTS
• To ensure bumpless transfer should SP change, e.g. though a manual intervention, set a rate of change in the SP_RATE_DN and SP_RATE_UP parameters with which the old SP value adapts to the new SP value
• Set the parameters GAIN , RESET and RATE to values appropriate to your application
• To ensure automatic recovery to RCAS if the mode changes, e.g. due to a timeout, select the option "Shed to Auto, Normal return" in the SHED_OPT parameter
Parameter
Resource Block
SHED_RCAS
Function Value
Timeout, in units of 1/32 ms
• If the timeout is exceed, communication is assumed to be lost and the mode is shed, SHED_OPTS
• If the timeout is 0, mode shedding is disabled e.g. 6400 (= 200 ms)
PID Control Block
MODE_BLK.Target
SP
PV_SCALE.EU_100
PV_SCALE.EU_0
PV_SCALE.UNITS_INDEX
OUT_SCALE.EU_100
OUT_SCALE.EU_0
OUT_SCALE.UNITS_INDEX
CONTROL_OPTS
STATUS_OPTS
BYPASS
SP_RATE_DN
SP_RATE_UP
GAIN
RESET
RATE
SHED_OPT
Normal operating mode of block
Setpoint for safe operation
(used if RCAS_IN fails due to timeout)
Upper range limit for process variable
Lower range limit for process variable
Unit of process variable
Upper range limit for output variable
Lower range limit for output variable
Unit of output variable
Sets control options for bad input
Enables output tracking
Sets the way the status of the tracking value is used
When ON, SP value is transferred to the OUT without the calculation of PID terms.
Rate of change from old to new, higher SP
Rate of change from old to new, lower SP
Tuning constants for the P, I and D terms, of the PID block respectively.
RCAS
60%
100
0
%
100
0
%
Bypass Enable
Track Enable
Use uncertain as good
OFF
0
0
1.5
0.1 s
0.5 s
Shed to Auto, Normal return
Behaviour when shedding from remote mode
• 1: Normal shed, Normal return (sheds to CAS)
• 2: Normal shed, No return (sheds to CAS)
• 3: Shed to Auto, Normal return
• 4: Shed to Auto, No return
• 5: Shed to Manual, Normal return
• 6: Shed to Manual, No return
• 7: Shed to Retained target, Normal return
• 8: Shed to Retained target, No return
The option "Shed to Auto, Normal return" causes the PID Control block to run in AUTO mode should the communication between the block and the external controller be interrupted. When communication is re-establishment the block automatically to recovers to RCAS.
The option "Shed to Auto, No return" causes the PID Control block to run in AUTO mode should the communication between the block and the external controller be interrupted. When communication is re-establishment the block stays in AUTO mode. It must be manually reset to
RCAS.
The other modes set the the block mode specified and behave analogously.
94 Endress+Hauser
ControlCare Application Designer: Function Blocks 6 Control Blocks
6.1.7
Remote output
The remote output function allows a the output of a PID Control block to be overridden by an external application. To do this the block target must be set to ROUT mode and a value must be written to ROUT_IN . Since the external application is not contained in the function block schedule, a timeout set in the resource block as well as the response of the PID Control block when the timeout is exceeded must also be set.
The connection to the external application may be made via OPC server, in which case:
• the parameter Device Tag-PID-n.ROUT_IN
carries the output value,
• the parameter Device Tag-PID-n.ROUT_OUT
the feedback
• the parameter Device Tag-PID-n.MODE_BLK.Target sets the mode block target.
For example, a measurement of flow upstream of a valve is used to ensure a constant flow rate into a vessel, see Fig. 6-13. To prevent overspill, the vessel is equipped with a level limit switch. If the liquid rises to the switch the latter switches, sending an alarm to the operating system. The operator now responds responds by setting the block mode to ROUT and writing a value to ROUT_IN .
M
105
CV
104
FCV
103
Remote track
PID control
FT
100
CC
102 e.g.
intervention via SCADA program
LS
101
Overspill alarm
Fig. 6-13: Example of remote output
Fig. 6-11 shows the control strategy together with links that must be made between the blocks. For more details on creating control strategies, see the appropriate ControlCare tutorial.
FT102
AI
OPC Server
Device Tag-PID-n.ROUT_IN
Device Tag-PID-n.ROUT_OUT
ROUT_IN ROUT_OUT
OUT IN
BKCAL_IN
PID
FCV103
AO
OUT CAS_IN
CV104
OUT
BKCAL_OUT
Fig. 6-14: Links required for remote output
Endress+Hauser 95
6 Control Blocks
Block configuration
SHED_OPT
ControlCare Application Designer: Function Blocks
The remote cascade is configured as follows:
• In the Resource Block of the device set SHED_RCAS to the maximum time allowable for the execution of the Control PID block
• To ensure automatic recovery to ROUT if the mode changes, e.g. due to a timeout, select the option "Normal shed, Normal return" in the SHED_OPT parameter
The remote output track is made operational on-line by writing ROUT to the MODE_BLK.Target
parameter. When the override is to be lifted, the block target is reset to the normal operating mode.
Parameter
Resource Block
SHED_RCAS
Function Value
Timeout, in units of 1/32 ms
• If the timeout is exceed, communication is assumed to be lost and the mode is shed, SHED_OPTS
• If the timeout is 0, mode shedding is disabled e.g. 6400 (= 200 ms)
PID Control Block
SHED_OPT Normal shed, normal return
Behaviour when shedding from remote mode
• 1: Normal shed, Normal return
• 2: Normal shed, No return
• 3: Shed to Auto, Normal return
• 4: Shed to Auto, No return
• 5: Shed to Manual, Normal return
• 6: Shed to Manual, No return
• 7: Shed to Retained target, Normal return
• 8: Shed to Retained target, No return
The option "Normal shed, Normal return" causes the PID Control block to run in CAS mode should the communication between the block and the external controller be interrupted. When communication is re-establishment the block automatically to recovers to RCAS.
The option "Normal shed, No return" causes the PID Control block to run in CAS mode should the communication between the block and the external controller be interrupted. When communication is re-establishment the block stays in CAS mode. it must be manually reset to RCAS.
The other modes set the the block mode specified and behave analogously.
96 Endress+Hauser
ControlCare Application Designer: Function Blocks
Operating mode
Status propagation
6 Control Blocks
6.1.8
Block operation
When configured as a primary control-loop, the block normally operates in AUTO mode. For secondary control-loops the operating mode may be CAS or RCAS. The value and status of the setpoint SP can be changed on-line in AUTO and CAS modes.
When MODE_BLK.Target
is set to MAN, the block output can be manipulated by entering the desired status and value in the OUT parameter. Similarly, when the block is set to ROUT, the OUT parameter is overwritten by the value and status in ROUT_IN . In both cases, the PV parameter indicates the correct value and state.
The block is forced to LO, when output track is configured and TRK_IN_D is true. It recovers to the set target mode, when TRK_IN_D returns to false. The block will be forced to IMAN from CAS or RCAS if the BKCAL_IN parameter has the substatus "Initialisation Request". After initialisation and clearing of the substatus, the block will recover to target mode.
If other parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
Operation can be checked on-line by viewing a number of parameters:
Parameter
IN
Meaning
Value and status of input from upstream block
PV Value and status of process value after scaling
SP, CAS_IN, RCAS_IN Depending upon operating mode, current value and status of set point
OUT
FF_VAL
TRK_VAL
TRK_IN_D
BKCAL_IN
BKCAL_OUT
Value and status of block output
Value and status of any variable connected to the feedforward input
Value and status of any variable connected to the output track input
Value and status of any discrete variable connected to the output track trigger
For a secondary control-loop, value and status of feedback from downstream block
Value and status of feedbackfor an upstream block
The PID Control block supports the qualities Bad, Uncertain and GoodC together with the associated sub-and limit statuses, see Chapter 2.3.2.
PV normally adopts the status quality of IN . If the status of IN is "Good", but there is a block or process alarm, PV will have the status "Uncertain". OUT follows PV , BKCAL_IN and the setpoint, carrying the quality, substatus and limit status with the highest priority.
Status propagation can be influenced by selecting any of the following options in the
STATUS_OPTS parameter, see Chapter 2.8.3.
STATUS_OPTS option
IFS if BAD IN
IFS if BAD CAS_IN
Uncertain as Good
Target to Manual if BAD IN
Target to next permitted mode if
BAD CAS_IN
Description
Sets Initiate Fault State status in the OUT parameter when IN is "Bad"
Sets Initiate Fault State status in the OUT parameter when CAS_IN is "Bad"
If the status of the IN parameter is "Uncertain", treats it as "Good"
Sets the target mode to "Man" if the status of IN is "Bad"
Sets the target mode to next permitted mode if the target mode is "Cas" and CAS_IN is "Bad"
Endress+Hauser 97
6 Control Blocks
Block errors
PID block
98
ControlCare Application Designer: Function Blocks
On execution of the block, the device checks for correct configuration. Block errors are indicated in the BLOCK_ERR parameter.
Condition
Block Configuration Error
Reason
• Invalid parameter setting, e.g. Bypass or SHED_OPT
• Not all required parameters have a value
Link Configuration Error
Local Override
Device Fault State Set
• Missing link, e.g. for secondary loop, BKCAL_IN not connected
• Parameter link mismatch
• The current OUT value is forced (TRK_VAL or ROUT_IN operative)
• The IFS option is active in STATUS_OPS and the input is "Bad"
Input Failure/ process variable has BAD status • Input module or device failure, device initiating etc.
Output Failure • Output module or device failure, device initiating etc.
Out-of-Service • MODE_BLK.Target currently set to OOS
Tab. 6-1: Possible PID Control block errors
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
PV
SP
OUT
PV_SCALE
OUT_SCALE
GRANT_DENY
CONTROL_OPTS
STATUS_OPTS
IN
PV_FTIME
BYPASS
CAS_IN
SP_RATE_DN
SP_RATE_UP
SP_HI_LIM
SP_LO_LIM
GAIN
RESET
BAL_TIME
RATE
BKCAL_IN
OUT_HI_LIM
OUT_LO_LIM
BKCAL_HYS
BKCAL_OUT
RCAS_IN
ROUT_IN
SHED_OPT
RCAS_OUT
ROUT_OUT
TRK_SCALE
6.1.9
Block parameters
Parameter Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
RO
Description
See Chapter 2.3.4
Block mode, set MODE_BLK.Target to AUTO, CAS or RCAS
Block errors, see Chapter 6.1.9
Process value used in executing the block
Setpoint used by the block in AUTO mode (PV_SCALE ± 10%)
Output value calculated as a result of executing the block
(OUT_SCALE ± 10%).
0-100% PV and SP value scaling to required engineering units
Positive
Positive
Positive
Positive
Positive
0
0
0
0
0-100% OUT value scaling to required engineering units
0 Access options, see Chapter 2.8.1
Control options, see Chapter 2.8.4 and Chapter 6.1.1
Status options, see Chapter 2.8.4 and Chapter 6.1.9
Process value
Time constant of a single exponential filter for process value
Off/On toggle for CONTROL_OPS option "Bypass"
Setpoint used by the block in CAS mode
Ramp rate for positive setpoint change in PV units/s +INF
+INF
100
0
Ramp rate for negative setpoint change in PV units/s
High limit for setpoint limiting (PV_SCALE ± 10%)
Low limit for setpoint limiting (PV_SCALE ± 10%)
Proportional term of the PID (Kp value) 0
+INF
0
0
Integral term of the PID (Tr value)
Time allowed to balance OUT changes as a result of a change from Auto, Cas or Rcas to Man
Derivative term of the PID (Td value)
100
0
0 to 50% 0.5%
Feedback from BKCAL_OUT of a downstream block
Maximum allowable output value (OUT_SCALE ± 10%)
Minimum allowable output value (OUT_SCALE ± 10%)
Output limit hysteresis in % of OUT_SCALE
1 - 8 0
Feedback for BKCAL_IN of an upstream block.
Setpoint used by the block in RCAS mode (from host)
Output of the block in ROUT mode (from host)
Mode shedding options, see Chapter 6.1.6
Setpoint and status for host back calculation in RCAS mode
Setpoint and status for host back calculation in ROUT mode
TRK_VAL value scaling to required engineering units
Endress+Hauser
ControlCare Application Designer: Function Blocks 6 Control Blocks
Parameter
TRK_IN_D
TRK_VAL
FF_VAL
FF_SCALE
FF_GAIN
UPDATE_EVT
BLOCK_ALM
ALARM_SUM
ACK_OPTION
ALARM_HYS
HI_HI_PRI
HI_HI_LIM
HI_PRI
HI_LIM
LO_PRI
LO_LIM
LO_LO_PRI
LO_LO_LIM
DV_HI_PRI
DV_HI_LIM
DV_LO_PRI
DV_LO_LIM
HI_HI_ALM
HI_ALM
LO_ALM
LO_LO_ALM
DV_HI_ALM
DV_LO_ALM
Legend: RO = Read Only
Valid range/
Options
Default value
Description
0, 1 0
0 to 50 % 0.5%
0 to 15
+INF
0 to 15
+INF
0 to 15
-INF
0 to 15
0 to 15
0 to 15
-INF
0
+INF
0
-INF
Discrete input for output track, see Chapter 6.1.5
Analog input for output track, see Chapter 6.1.5
Feedforward value and status, see Chapter 6.1.3.
FF_VAL scaling to required engineering units
Gain for feedforward input, see Chapter 6.1.3
This alert is generated by any change to the static data.
Block alarms, see Chapter 2.9
Alarm summary, see Chapter 2.9
See Chapter 2.9
• 0: Auto ACK Disable
• 1: Auto ACK Enable
Alarm hysteresis in % of OUT_SCALE, see Chapter 2.9
Priority of the HI_HI alarm, see Chapter 2.9
Setting of HI_HI alarm in engineering units, see Chapter 2.9.
Priority of the HI alarm, see Chapter 2.9
Setting of HI alarm in engineering units, see Chapter 2.9.
Priority of the LO alarm, see Chapter 2.9.
Setting of LO alarm in engineering units, see Chapter 2.9.
Priority of the LO_LO alarm, see Chapter 2.9
Setting of LO_LO alarm in engineering units, see Chapter 2.9
Priority of the control deviation HI alarm, see Chapter 2.9
Setting of control deviation HI in engineering units
Priority of the control deviation LO alarm, see Chapter 2.9
Setting of control deviation LO in engineering units
Status of HI_HI alarm and its associated time stamp.
Status of HI alarm and its associated time stamp.
Status of LO alarm and its associated time stamp.
Status of LO_LO alarm and its associated time stamp.
Status of deviation HI alarm and its associated time stamp.
Status for deviation LO alarm and its associated time stamp.
Endress+Hauser 99
6 Control Blocks ControlCare Application Designer: Function Blocks
6.2
Enhanced PID Control
The Enhanced PID Control block provides following enhancements with respect to the standard
PID Control block:
• Additional mechanisms to ensure bumpless transfer from manual to automatic mode
• Additional options for output tracking
When the default values of these enhanced parameters are used, the block exhibits identical behaviour to the PID Control block.
In ControlCare Application Designer the Enhanced PID Control block is assigned the generic name
Device Tag-EPID-n . It can be found by expanding the appropriate device or Field Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 6-15.
CAS_IN
RCAS_IN
SP
LIMITS
RCAS_OUT
SP
SELECTOR
IN
OPERATOR ENTRY
PV_TIME
FF_VAL
FF_SCALE
FF_GAIN
TRK_VAL
TRK_IN_D
BKCAL_IN
TRK_SCALE
OUT_SCALE
SP
ROUT_IN
PID +
FF
OUT_SCALE
OUT
SELECTOR
OUT
LIMITS
ROUT_OUT
SP
PV
CONTROL_OPTS
OUT
BKCAL_OUT
Fig. 6-15: Schematic diagram of EPID Control block
6.2.1
Bumpless transfer
One of four options for transfer from a "manual" mode, e.g. MAN to an "automatic" mode, e.g.
AUTO, CAS or RCAS must be selected from the parameter BUMPLESS_TYPE :
BUMPLESS_TYPE option
Bumpless (default)
Last + proportional
Bias
Bias + proportional
Meaning block behaves as standard PID Control block and using the last value for "manual" mode to start the PID calculation block uses the last value for "manual" mode plus the proportional term to start the
PID calculation block uses the BIAS parameter to start the PID calculation block uses the BIAS parameter plus the proportional term to start the PID calculation
When options 3 and 4 are used, a bias must be entered as % of PV_SCALE in the BIAS parameter during off-line configuration. The BIAS parameter is an additional parameter used in the PID algorithm: y = GAIN e +
1
RESET
e t +
+
100 Endress+Hauser
ControlCare Application Designer: Function Blocks 6 Control Blocks
Fig. 6-16 shows the effect of the various options on the transfer from "manual" to "automatic" mode.
Unless OUT has been set by hand, it takes the value of SP in manual mode and the PID algorithm is bypassed. Assuming the the setpoint value SP is 50% of OUT_SCALE and the process value PV is 40% of OUT_SCALE, then when the block mode changes from manual to automatic, the PID algorithm will try to reduce the control deviation between SP and PV by increasing the OUT value.
Default behaviour ( BUMPLESS_TYPE = "Bumpless") may produce too steep a rise in OUT , causing problems with overshoot. For some control-loops, overshoot must be avoided at all costs, since it may lead to dangerous situations. The other BUMPLESS_TYPE options cause a more gradual rise in OUT with the starting points for calculation offset to a greater or lesser degree.
50
40
MANUAL AUTOMATIC
SP
PV
OUT
SP
50
BUMPLESS_TYPE = “Bumpless” t t
OUT
SP 60
50 t
BUMPLESS_TYPE = “Bumpless+Proportional”
50
40
MANUAL AUTOMATIC
SP
PV
OUT
BIAS = 20
SP
50
20
BUMPLESS_TYPE = “Bias” t t
OUT
BIAS = 20
SP
50
30 t
BUMPLESS_TYPE = “Bias+Proportional”
Fig. 6-16: Effect of BUMPLESS_TYPE option on OUT value
6.2.2
Enhanced output tracking
The parameter PID_OPTS provides additional options to deal with "Bad" input for TRK_IN_D or
TRK_VAL. These cause:
• an IFS status to be generated, see Chapter 2.7
• the actual mode to be set to MAN
• the target mode to be changed to MAN
In addition the target mode can be set to MAN on power up or when tracking is active. The effect of the various options is summarized in the following ables, whereby "Auto" signifies AUTO, CAS or RCAS modes. If no selection is made in PID_OPTS, the block behaves as per the PID Control block.
Endress+Hauser 101
6 Control Blocks
Bad TRK_IN_D
Bad TRK_VAL
Good TRK_IN_D
Good TRK_VAL
ControlCare Application Designer: Function Blocks
PID_OPTS
IFS if Bad TRK_IN_D
Man if Bad TRK_IN_D
Target to Man if Bad TRK_IN_D
Mode
Target Actual
Man
Algorithm Action
"auto" ->
Iman
• Output tracking is disabled
• The PID algorithm continues the normal calculation.
• OUT.Status is GoodC-IFS.
• When the output block goes to fault state, the upstream blocks are forced to Iman.
Man
Man
• Output tracking is disabled; the mode is forced to Man
• The PID algorithm stops the calculation
• SP is passed to OUT unless the operator enters an OUT value
• Output tracking is disabled; the target mode changes to Man
• The PID algorithm stops the calculation
• SP is passed to OUT unless the operator enters an OUT value
PID_OPTS
IFS if Bad TRK_VAL
Man if Bad TRK_VAL
Target to Man if Bad TRK_VAL
Mode
Target Actual
Man
Algorithm Action
"auto" ->
Iman
• Output tracking is disabled
• The PID algorithm continues the normal calculation.
• OUT.Status is GoodC-IFS.
• When the output block goes to fault state, the upstream blocks are forced to Iman.
Man
Man
• Output tracking is disabled; the mode is forced to Man
• The PID algorithm stops the calculation
• SP is passed to OUT unless the operator enters an OUT value
• Output tracking is disabled; the target mode changes to Man
• The PID algorithm stops the calculation
• SP is passed to OUT unless the operator enters an OUT value
PID_OPTS
All options
Target to Man if Tracking Active Man
Target to Man on Power Up
Mode
Target Actual
Man
LO
Man
Man
Algorithm Action
Output Tracking is active, mode is LO (local override)
Output Tracking is active, mode is Man
Target mode set to Man on power up
6.2.3
Additional parameters
In addition to those listed in Chapter 6.1.10, the Enhanced PID Control block has the following parameters:
Parameter
BUMPLESS_TYPE
BIAS
PID_OPTS
Legend: RO = Read Only
Valid range/
Options
Default value
Description
0
0
0
Algorithm action to start the output when the block transfers from a "manual" to an "automatic" mode
• 0: Bumpless
• 1: Last+Proportional
• 2: Bias
• 3: Bias+Proportional
Bias value used in BUMPLESS_TYPE options Bias and
Bias+Proprtional
Output tracking options
102 Endress+Hauser
ControlCare Application Designer: Function Blocks 6 Control Blocks
6.3
Advanced PID Control
The Advanced PID Control block provides following enhancements with respect to the standard
PID Control and Enhanced PID Control blocks:
• PID algorithm selection
• PI Sampling algorithm
• Adaptive gain
• Configurable limits for anti reset wind-up
• Special treatment of the error (control deviation)
• Discrete output to indicate the actual mode
When the default values of these enhanced parameters are used, the block exhibits identical behaviour to the PID Control block.
In ControlCare Application Designer the Enhanced PID Control block is assigned the generic name
Device Tag-APID-n . It can be found by expanding the appropriate device or Field Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 6-17.
CAS_IN
IN
AD_GAIN_IN
FF_VAL
TRK_VAL
TRK_IN_D
BKCAL_IN
SETPOINT
SELECTION
PV
FILTERS
PV
SP
ERROR TYPE
SELECTION
RCAS_OUT
PID
ALGORITHM
ADAPTIVE
GAIN
FF SCALING
+ GAIN
TRACK
SCALING
ROUT_OUT
ROUT_IN
OUTPUT
SELECTION
SCALING
+ LIMIT
BKCAL_OUT
MODE_OUT
OUT
Fig. 6-17: Schematic diagram of APID Control block
Endress+Hauser 103
6 Control Blocks
104
ControlCare Application Designer: Function Blocks
6.3.1
PID algorithm
The algorithm to be used by the block when it calculates the OUT parameter is selected with the
PID_TYPE parameter. The options are summarized in the table below:
PID_TYPE options Description
PI.D + ISA P and I terms are calculated based on the error and the D term on the PV (as PID Control block) y = GAIN e +
1
RESET
e t +
+ F
PI.D + Parallel P and I terms are calculated based on the error and the D term on the PV y = GAIN e +
1
RESET
e t +
+ F
PI Sampling + ISA P and I terms are calculated based on the error and the D term on the PV; the output is ramped according to the settings in PI Sampling) y = GAIN e +
1
RESET
e t +
+ F
PI Sampling + Parallel P and I terms are calculated based on the error and the D term on the PV the output is ramped according to the settings in PI Sampling y = GAIN e +
1
RESET
e t +
+ F
PID + ISA
PID + Parallel
P, I and D terms are calculated based on the error y = GAIN e +
1
RESET
e t +
-----t
+ F
P, I and D terms are calculated based on the error y = GAIN e +
1
RESET
e t +
RATE
1 0.13xRATE
+ F
I.PD + ISA
I.PD + Parallel
I is calculated based on the error and the P and D terms on the PV y = GAIN PV +
1
RESET
e t +
+
I is calculated based on the error and the P and D terms on the PV y = GAIN e +
1
RESET
e t +
+ F
+ F
6.3.2
PI sampling
If the PI Sampling options are chosen, the output is ramped as illustrated in Fig. 6-18. The output is calculated based on the PI algorithm during time t
0
. After that, the algorithm stops calculating and it holds the last value during time t
1
.
PV
SP STEP
SP
PV
OUT
SAMP_PER
SAMP_ON
0 t 0 t
0 t
1 t
Fig. 6-18: Effect of step rise in SP on output when PI Sampling is active
Set the following parameters:
• Enter the calculation time t
0
in SAMP_ON
• Set sampling period for the ramp in SAMP_PER ; t
1
= SAMP_PER - SAMP_ON .
If the sampling period SAMP_PER is less than the calculation time SAMP_ON or the latter is zero, then the algorithm works as an ordinary PI controller.
Endress+Hauser
ControlCare Application Designer: Function Blocks
Configuration
Error handling
6 Control Blocks
6.3.3
Adaptive gain
The adaptive gain option allows the PID terms in the algoritm to be modified according to function determined by the CURVE_X and CURVE_Y parameters. Depending upon the configuration, one or more of the PID constants GAIN, RESET and RATE are acted upon as follows:
• GAIN'= G * GAIN
• RESET' = RESET / G
• RATE' = G * RATE
The function is configured with the following parameters:
Parameter
AD_GAIN_ACTION
AD_GAIN_IN_SEL
CURVE_X
CURVE_Y
Action Option/Value
Define the PID parameter(s) on which the adaptive gain acts
I
P
Disable
D
PI
PID
Select the input value to be used for the adaptive gain calculation
• If the AD_GAIN_IN option is selected the input value is supplied an upstream block
• If the error option is selected, the ERROR_TYPE parameter must be set to "Normal" (default setting)
SP
PV
Error
OUT
AD_GAIN_IN
Enter up to twenty input points in the same engineering units as the selected variable
–
Enter the adaptive gain corresponding to each input point
• If the curve has less than 20 configured points, the non-configured points are automatically set to +INF.
–
If the input/adaptive gain curve has a configuration error, it is indicated in BLOCK_ALM and the adaptive gain value assumes the CURVE_Y value corresponding to the highest CURVE_X point.
If the A D_GAIN_IN option is selected as the input value and this has bad status, the algorithm uses the last usable value to provide bumpless transfer.
6.3.4
Anti-reset wind-up
In order to prevent reset wind-up, LO and HI saturation limits can be imposed on the integral term by using the ARW_LOW and ARW_UP parameters respectively. When the output signal reaches the limits, the control algorithm stops the integral calculation. The proportional and derivative calculations are not affected.
The integral calculation is not stopped when OUT reaches the OUT_LO_LIM and OUT_HI_LIM values. For this reason, set ARW_LOW equal to or more than OUT_LO_LIM and ARW_UP equal to or less than OUT_HI_LIM .
Endress+Hauser 105
6 Control Blocks
Special gain
ControlCare Application Designer: Function Blocks
6.3.5
Special treatment for error
Provided the option "error" has not been selected in AD_GAIN_IN_SEL , the ERROR_TYPE parameter provides various options for treatment of the error (or control deviation):
ERROR_TYPE option
Normal (default)
Quadratic (all terms)
Quadratic (Integral)
Special gain
Meaning
Error type function is disabled
Error term is applied to all PID calculations is a quadratic function of the input value
Error term is applied to the integral calculation is a quadratic function of the input value
Gain entered in the GAIN_BAND term is applied to the error when it lies within the range entered in ERROR_BAND, see Special gain
When a quadratic error option is chosen, the error is calculated as follows:
ê = e · | e |/100 %
Fig 6-16 shows the effect of using this option.
Output error ê
100% linear (normal)
0% quadratic
100%
Input error e
Fig. 6-19: Effect of quadratic error option in ERROR_TYPE parameter
The special gain option allows adaptive control to be used in cases it would be normally unstable around the setpoint SP due the dead band of the actuator, noise or other factors. The option ramps the error over the band defined in ERROR_BAND according to the function:
ê = G · e
Where G is the gain value entered in GAIN_BAND . Fig 6-20 shows the effects of this function.
ERROR_BAND = 10%
GAIN_BAND = 0
ê [%]
ERROR_BAND = 10%
GAIN_BAND = 0.6
ê [%]
ERROR_BAND = 10%
GAIN_BAND = 2.0
ê [%]
20
-30 -20 -10 10 20 30 e [%]
-30 -20
Error band
10 20 30 e [%]
Error band
-30 -20 -10
-20
10 20 30 e [%]
Error band
Fig. 6-20: Effect of ERROR_BAND and GAIN_BAND on error
106 Endress+Hauser
ControlCare Application Designer: Function Blocks 6 Control Blocks
6.3.6
Mode indication
The MODE_OUT parameter provides a discrete output that can be used to indicate the actual mode of the block. It outputs the value TRUE (=1) when block is operating in the the mode selected in the MODE_IND parameter. If more than one mode type is chosen in MODE_IND, OR logic is applied.
Parameter
MODE_IND
Action
Determines the actual block modes that will force the
MODE_OUT parameter into TRUE status
Option/Value
OOS,
IMAN
LO
MAN
AUTO
CAS
RCAS
ROUT
6.3.7
Additional parameters
In addition to those listed in Chapters 6.1.10 and 6.2.3, the Advanced PID Control block has the following parameters:
Parameter
MODE_OUT
MODE_IND
AD_GAIN_ACTION
AD_GAIN_IN_SEL
AD_GAIN_IN
CURVE_X
CURVE_Y
ERROR_TYPE
ERROR_BAND
GAIN_BAND
PID_TYPE
SAMP_ON
SAMP_PER
BUMPLESS_TYPE
BIAS
ARW_UP
ARW_LOW
Legend: RO = Read Only
Valid range/
Options
Default value
Description
All modes
–
–
Max. 20
Max. 20
0-300
0-10
RO
OOS
Disable
SP
–
0
0
Normal
Discrete output indicating whether one of the modes selected in MODE_IND is the actual mode (TRUE/"1")
Mode to be used by MODE_OUT, multiple selection supported
PID parameter(s) on which the adaptive gain acts
• Options: Disable, D, I, P, PI, PID
Input value to be used for the adaptive gain calculation
• Options: SP, PV, Error, OUT, AD_GAIN_IN
Input value provided by another block for adaptive gain when option "AD_GAIN_IN" is chosen in AD_GAIN_IN_SEL
Input values of the adaptive gain characteristic
• Engineering units as variable selected in AD_GAIN_IN_SEL
Output values of the adaptive gain characteristic
• No. of output points must correspond to no. of input points
Type of error used by PID algorithm
• Options: Normal, quadratic (all terms), quadratic (Integral), special gain
0 s
0 s
0
0
0
Error band applicable to "special gain" option in ERROR_TYPE
Gain band applicable to "special gain" option in ERROR_TYPE
PI.D+ISA PID algorithm used by the block
• Options: PI.D+ISA, PID+ISA, I.PD+ISA, PI Sampling+ISA,
PI.D+Parallel, PID+Parallel, I.PD+Parallel,
PI Sampling+Parallel
Active sampling time for "PI Sampling" options in PID_TYPE
Sampling period of "PI Sampling" options in PID_TYPE
Type of transfer from “manual” mode to “automatic” mode
• Options: Bumpless, Last+Proportional, Bias,
Bias+Proportional
0
+INF
–INF
Bias value for "Bias" options in BUMPLESS_TYPE
High limit for anti reset windup
Low limit for anti reset windup
Endress+Hauser 107
6 Control Blocks
108
ControlCare Application Designer: Function Blocks
6.4
Step Output PID
The Step Output PID block is used to manipulate final control elements that have an actuator driven by an electric motor. In addition to providing PID control, the block acts as transducer output for a
ControlCare discrete output module connected to the fieldbus actuator or switch gear. Depending upon the value of the PID output, signals are provided at the output that drive the motor clockwise or anticlockwise to position the final control element. When the required position is reached, the motor is stopped.
In ControlCare Application Designer the Step Output PID block is assigned the generic name
Device Tag-STEP-n . It can be found by expanding the appropriate device or Field Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 6-21.
CAS_IN
IN
RCAS_IN
SP
LIMITS
SP
PV_FTIME
PV
PID
ALGORITHM
STEP OUTPUT
OUT_D
TRANSDUCER
ALARM
PROCESSING
SP
PV
CONTROL_OPTS
BKCAL_OUT
Fig. 6-21: Schematic diagram of Step Output PID block
6.4.1
Functional description
The Step Output PID block combines two basic functions:
• Basic PID control as described in Section 6.1, without feedforward, tracking and bypass functions, providing a manupulating signal for an electric motor
• Discrete output with valve actuator transducer block functions
It can be used as a positioner within a cascade loop or as a step controller.
a) Function within cascade control loop
Setpoint e
PID
OUT
Process variable
PROCESS b) Function as step controller
Setpoint e
Process variable
OPEN
STEP
CLOSE
LOGIC
Valve position
OPEN
STEP
CLOSE
LOGIC
POWER
M
POWER
M
PROCESS
Fig. 6-22: Functional diagram of step control
Endress+Hauser
ControlCare Application Designer: Function Blocks
PID control
Gap deviation
6 Control Blocks
The PID control uses the travel time of the actuator, TRAVEL_TIME , i.e. the time it takes to drive the final control element from one end limit to another, as the basis for signal output. The proportional action will actuate the final control element in the required direction for a time t
P proportional to: t
P
= GAIN * (ê /100)* TRAVEL_TIME .....(s) where ê is the difference between the setpoint SP and the process value PV. If the proportional action is not enough force ê to zero, the integral action moves the final control element at a speed of:
V = GAIN * ê / RESET ......(% / s) where the RESET is the integral time constant in seconds.
As most actuators work at a constant and fixed speed, they cannot move faster than:
Maximum speed = 100% / TRAVEL TIME .......(% / s)
Slower reponses required by the integral action are therefore obtained by generating pulses of a specified duration PULSE_DUR . Each pulse will move the final control element a distance
x % in the required direction.
x % = PULSE_DUR * 100% / TRAVEL_TIME ..........(%)
The pulse frequency f is given by: f = V /
x %..........(pulses / s)
The derivative or rate action is given by: t
D
= GAIN * (dê/dt) * RATE
Where RATE is the derivative time constant in seconds.
The Step Output PID activates the OPEN or CLOSE signals according to the modified deviation, ê, the PID parameters and the other parameters as follows:
• The signal is activated during a time equivalent to = t
P
+ t
D
• If the modified deviation is not equal to zero, the integral or reset action will give pulses with a duration defined by PULSE_DUR and a frequency calculated by “f."
• t and f are dynamically modified by ê.
In order to avoid reset wind-up, the actuation time in one direction is integrated and limited. If the actuation time in one direction is larger than the TRAVEL_TIME , the output signal is not pulsed, but is continuously activated.
The block provides a full PV and deviation alarm support as described in Chapter 6.1.
In order to prevent jitter around the desired valve position, the Step Output PID block also offers the possibility of gap deviation action, see Fig. 6-23. When DEAD_BAND is greater than zero, a zone
±
0.5 of its value is defined around the point of zero deviation, in which a change in the actual deviation e produces no effect on the modified deviation ê and thus no corrective action by the motor. The transition from either end of the dead band is via a HYSTERESIS .
modified
deviation (ê)
–0.5 DB
0
HYSTERESIS
+0.5 DB actual deviation (e)
DEAD_BAND (DB)
Fig. 6-23: Gap deviation using the DEAD:_BAND and HYSTERESIS parameters
Endress+Hauser 109
6 Control Blocks
Discrete output
Status propagation
ControlCare Application Designer: Function Blocks
The CHANNEL parameter selects the output channel of the connected ControlCare module to be used by the open signal. The adjacent output, i.e. " CHANNEL + 1" is automatically reserved for the close signal. OUT_D provides an indication of the current signal being provided to the actuator:
1
2
OUT_D.value
0
Action
Stop
Close
Open
0
1
Signal at CHANNEL
0
Signal at CHANNEL + 1
0
1
0
The initial value of the output signal is zero, i.e. there is no action in either direction and the integral action value is also zero.
Normally, the BKCAL_OUT parameter of the Step Output PID block carries the value and status of SP . Depending on the CONTROL_OPTS parameter, it may be forced to a different condition.
When the block operates in RCAS, RCAS_OUT (= SP) provides the back calculation for the host, allowing action to be taken under limiting conditions or mode change.
CONTROL_OPS option
None
None, but RCAS mode
Use PV for BKCAL_OUT
BKCAL_OUT value and status
SP value and status
PV value and status after limiting
PV value and status
The status of the output reflects the worst quality of the status of any connected input. The behaviour can be changed by selecting an appropriate option in the STATUS_OPTS parameter:
Option
Uncertain as Good
Propagate Fail Backward
Target to Manual if BAD IN
Target to next permitted mode if
BAD CAS_IN
Description
If the status of the IN parameter is Uncertain, treat it as Good.
If the status from the actuator is Bad "Device failure" or "Fault State Active", or Local
Override is active, propagates this as Bad "Device Failure" or Good Cascade "Fault
State Active", or Local Override to BKCAL_OUT respectively without generating an alarm.
Sets the target mode to Man if the status of the IN parameter is BAD.
Sets the target mode to next permitted mode if the target mode is CAS and the status of CAS_IN is BAD.
The SHED_OPT parameter provides options which govern the recovery of the block after a change in mode e.g. due to a timeout.
The block also supports fault state handling as described in Chapter 6.5. When used in a cascade loop, it can be configured to respond to the IFS status by setting FSTATE_TIME , in units of 1/32 ms, to the time the output block can normally wait before responding to a fault state in or loss of communication with the upstream block. FSTATE_VAL_D is set to the set point value (SP_D =
OUT_D) that causes the output device to assume fail-safe position.
The IO_OPTS parameter determines the block response to a fault state, whereby multiple choices are allowed. The option is set by ticking the selection box:
Option
Fault State to value
Target to Man if IFS
Set
On fault state, FSTATE_VAL_D substitutes
SP_D
On fault state, the block mode is forced to
Man. In this mode, parameters can be changed
Clear)
On fault state, the last valid SP_D value is used
On fault state, the block mode is forced to
Local Override, parameters cannot be changed until the fault state is cleared
A third option, "Use Fault State value on restart" causes the value of FSTATE_VAL_D to be used on device restart. In this case, the value is used, although no fault state exists.
110 Endress+Hauser
ControlCare Application Designer: Function Blocks 6 Control Blocks
6.4.2
Block configuration
Fig. 6-24 shows a typical application for the Step Output PID block. The block is connected to the actuator switchgear via a ControlCare I/O module, in this example the SFC428 high density NO relay module, which supplies "Open" and "Close" signals according to the demand of the control loop. The switchgear powers and reverses the electric motor accordingly.
In addition, to the "Open" and "Close" signals, most of the electric actuators require an interlock circuit to prevent the motor from overheating when the actuator reaches one of its travel limits or when something blocks its movement, increasing the torque beyond an established limit. Such protection is normally provided by torque switches and limit switches. Other inputs might be a local override control and an enabling signal. These signals are not considered in the applications described here, but could be realized by the appropriate ControlCare module and strategy. channel
STEP channel+1
DO-1
DO-2
INTERLOCK
SIGNALS*
LOCAL
CONTROL*
ENABLING*
O
C
O
C
O
C
E
ACTUATOR
LOGIC
OPEN
CLOSE
POWERING
AND
REVERSING
Closed-loop control
Block configuration
Endress+Hauser
Torque switch “Open”
Limit switch “Open”
Torque switch “Closed”
Limit switch “Closed”
M
*Signals not considered in this description
Fig. 6-24: Use of STEP PID Output block with motor switchgear
Fig. 6-25 shows a control strategy that uses the Step Output PID block for the simple closed-loop control example described in Fig. 6-2 of Chapter 6.1.2.
*
SP
OUT IN channel DO-1 OPEN
AI STEP channel+1 DO-2 CLOSED
Motor switchgear
FT100 FCV101
Fig. 6-25: Links required for basic closed-loop control with Step Output PID
The block is configured for operation without gap deviation as follows:
Parameter
MODE_BLK.Target
SP
STATUS_OPTS
PV_SCALE.EU_100
PV_SCALE.EU_0
PV_SCALE.UNITS_INDEX
SP_RATE_DN
SP_RATE_UP
Function
Normal operating mode of block
Setpoint for ideal process control
Options for handling IN status
Upper range limit for process variable
Lower range limit for process variable
Unit of process variable
Rate of change from old to new, higher SP
Rate of change from old to new, lower SP
5
5
100
0
%
Example value
Auto
60%
Uncertain as Good
111
6 Control Blocks
Cascade control
Block configuration
112
ControlCare Application Designer: Function Blocks
Parameter
GAIN
RESET
BAL_TIME
RATE
CHANNEL
SHED_OPTS
TRAVEL_TIME
Function
Tuning constants for the P, I and D terms of the PID block respectively.
Rack+Slot+Group+I/O point for OPEN signal
• CLOSE signal at CHANNEL+1, e.g. 2101
Mode shedding recovery options
Time (s) to drive from one end position to the outer
Example value
1.5
0.1 s
5 s
0.5 s e.g. 2100
Normal Shed, Normal
Return
3 s
Tab. 6-2: Basic parameters for closed-loop control
Fig. 6-26 shows a control strategy that uses the Step Output PID block for the cascade control example described in Fig. 6-4 of Chapter 6.1.4.
OUT IN
AI PID
BKCAL_IN
TT100
AI
OUT
TC101 OUT
CAS_IN
IN
STEP channel channel+1
BKCAL_OUT
DO-1
DO-2
FCV103
OPEN
CLOSED
Motor switchgear
FT102
Fig. 6-26: Links required for cascade control with Step Output PID
The blocks are configured with gap deviation as follows:)
Function Parameter
PID Block
MODE_BLK.Target
SP
PV_SCALE.EU_100
PV_SCALE.EU_0
PV_SCALE.UNITS_INDEX
OUT_SCALE/EU_100
OUT_SCALE/EU_0
OUT_SCALE/UNITS_INDEX
CONTROL_OPTS
SP_RATE_DN
SP_RATE_UP
GAIN
RESET
RATE
SHED_OPT
STEP block
MODE_BLK.Target
STATUS_OPTS
PV_SCALE.EU_100
PV_SCALE.EU_0
PV_SCALE.UNITS_INDEX
SP_RATE_DN
SP_RATE_UP
Normal operating mode of block
Setpoint for ideal process control
Upper range limit for process variable
Lower range limit for process variable
Unit of process variable
Upper range limit for output variable
Lower range limit for output variable
Unit of output variable
Sets control options for bad input
Rate of change from old to new, higher SP
Rate of change from old to new, lower SP
Tuning constants for the P, I and D terms of the PID block respectively.
Behaviour when shedding from remote mode
Normal operating mode of block
Options for handling IN status
Upper range limit for process variable
Lower range limit for process variable
Unit of process variable
Rate of change from old to new, higher SP
Rate of change from old to new, lower SP
Example value
AUTO
60%
100
0
%
100
0
%
Bypass Enable
3
3
1.5
0.1 s
0.5 s
Normal shed, normal return
Cas
Target to Manual if
BAD IN
0
0
100
0
%
Endress+Hauser
ControlCare Application Designer: Function Blocks
Mode
Status
Block errors
6 Control Blocks
Parameter
GAIN
RESET
BAL_TIME
RATE
CHANNEL
SHED_OPTS
TRAVEL_TIME
DEAD_BAND
HYSTERESIS
Function
Tuning constants for the P, I and D terms of the PID block respectively.
Example value
1.5
0.1 s
5 s
0.5 s e.g. 2100 Rack+Slot+Group+I/O point for OPEN signal
• CLOSE signal at CHANNEL+1, e.g. 2101
Mode shedding recovery options Normal Shed, Normal
Return
3 s Time (s) to drive from one end position to the outer
Interval, within which a change in input will not change the output
2%
Difference between the switching points dependent on direction of action
1%
6.4.3
Block operation
The block supports the modes Out-of-service, Manual, Auto, Cas and Rcas.
In Rcas mode the block setpoint is set by a control application running on a computer, DCS or PLC,
In Cas (cascade) mode, the by another function block through the CAS_IN parameter.
In Auto mode the setpoint value SP is provided by the operator and can be changed and downloaded while the block is operating.
When MODE_BLK.Target
is set to "Man", the block stops output calculation. OUT_D can be set by the operator. In addition, the parameter JOG_TIME allows the operator to determine how long the selected OUT_D action is to be active.
If parameters other than SP are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
Operation can be checked on-line by viewing a number of parameters:
IN Value and status of the process value
SP, CAS_IN, RCAS_IN Value and status of setpoint used to execute the block in Auto, Cas and RCas modes
PV
OUT_D
Value and status of the process value used top execute the block
Value and status of the current output action (0 = stop, 1 = open, 2 = close)
The significance of the output status is indicated below.
OUT_D status
Good
Bad
Meaning
• Normal operation as configured
• Input uncertain but option "Uncertain as Good" selected in STATUS_OPTS
• Block out of service
• Input bad
Block errors are indicated in the BLOCK_ERR parameter
Condition
Out-of-Service
Reason
• MODE_BLK.Target currently set to OOS
Endress+Hauser 113
6 Control Blocks
114
ControlCare Application Designer: Function Blocks
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
PV
SP
OUT_D
PV_SCALE
XD_STATE
GRANT_DENY
CONTROL_OPTS
STATUS_OPTS
IN
PV_FTIME
JOG_TIME
CAS_IN
SP_RATE_DN
SP_RATE_UP
SP_HI_LIM
SP_LO_LIM
GAIN
RESET
BAL_TIME
RATE
IO_OPTS
CHANNEL
FSTATE_TIME
FSTATE_VAL_D
BKCAL_OUT
RCAS_IN
SHED_OPT
RCAS_OUT
TRAVEL_TIME
PULSE_DUR
DEAD_BAND
HYSTERESIS
UPDATE_EVT
BLOCK_ALM
ALARM_SUM
ACK_OPTION
6.4.4
Block parameters
Parameter
ALARM_HYS
HI_HI_PRI
HI_HI_LIM
Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
RO
Description
See Chapter 2.3.4
Block mode, set MODE_BLK.Target to AUTO, CAS or RCAS
Block errors, see Chapter 6.1.9
Process value used in executing the block
Setpoint used by the block in AUTO mode (PV_SCALE ± 10%)
Discrete output value calculated as a result of executing the block
Positive
Positive
Positive
Positive
Positive
1 - 8
0, 1
0
0
0
60
1
0
0
0
0
0
0-100% PV and SP value scaling to required engineering units
0-100% Discrete state of the value obtained from the transducer.
0
Access options, see Chapter 2.8.1
Control options, see Chapter 2.8.4 and Chapter 6.1.1
Status options, see Chapter 2.8.4 and Chapter 6.1.9
Process value
Time constant of a single exponential filter for process value
Duration of OUT_D in the active state when commanded by the operator to jog open or jog closed
Setpoint used by the block in CAS mode
Ramp rate for positive setpoint change in PV units/s +INF
+INF
100
0
Ramp rate for negative setpoint change in PV units/s
High limit for setpoint limiting (PV_SCALE ± 10%)
Low limit for setpoint limiting (PV_SCALE ± 10%)
Proportional term of the PID (Kp value) 0
+INF
0
0
Integral term of the PID (Tr value)
Time allowed to balance OUT changes as a result of a change from Auto, Cas or Rcas to Man
Derivative term of the PID (Td value)
See Chapter 2.8.2
0
0
0 to 50 % 0.5%
0 to 15
+INF
Index of transducer block logical channel used by the block
Time in seconds from detection of a fault in the output block remote setpoint to the output action of the block output, if the condition still exists
Preset discrete SP_D value to be used when fault occurs, provided I/O option "Fault State to value" is selected.
Feedback for BKCAL_IN of an upstream block.
Setpoint used by the block in RCAS mode (from host)
Mode shedding options, see Chapter 6.1.6
Setpoint and status for host back calculation in RCAS mode
Time in seconds required by the actuator to drive the final control element from one end position to the other
Width, in seconds, of the pulses given due to the integral action
Interval, within which a change in input will not change the output
Difference between the switching points dependent on direction of action
This alert is generated by any change to the static data.
Block alarms, see Chapter 2.9
Alarm summary, see Chapter 2.9
See Chapter 2.9
• 0: Auto ACK Disable
• 1: Auto ACK Enable
Alarm hysteresis in % of OUT_SCALE, see Chapter 2.9
Priority of the HI_HI alarm, see Chapter 2.9
Setting of HI_HI alarm in engineering units, see Chapter 2.9.
Endress+Hauser
ControlCare Application Designer: Function Blocks 6 Control Blocks
Parameter
HI_PRI
HI_LIM
LO_PRI
LO_LIM
LO_LO_PRI
LO_LO_LIM
DV_HI_PRI
DV_HI_LIM
DV_LO_PRI
DV_LO_LIM
HI_HI_ALM
HI_ALM
LO_ALM
LO_LO_ALM
DV_HI_ALM
DV_LO_ALM
Legend: RO = Read Only
Valid range/
Options
0 to 15
Default value
Description
0 to 15
0 to 15
0 to 15
0 to 15
+INF
-INF
-INF
0
+INF
0
-INF
Priority of the HI alarm, see Chapter 2.9
Setting of HI alarm in engineering units, see Chapter 2.9.
Priority of the LO alarm, see Chapter 2.9.
Setting of LO alarm in engineering units, see Chapter 2.9.
Priority of the LO_LO alarm, see Chapter 2.9
Setting of LO_LO alarm in engineering units, see Chapter 2.9
Priority of the control deviation HI alarm, see Chapter 2.9
Setting of control deviation HI in engineering units
Priority of the control deviation LO alarm, see Chapter 2.9
Setting of control deviation LO in engineering units
Status of HI_HI alarm and its associated time stamp.
Status of HI alarm and its associated time stamp.
Status of LO alarm and its associated time stamp.
Status of LO_LO alarm and its associated time stamp.
Status of deviation HI alarm and its associated time stamp.
Status for deviation LO alarm and its associated time stamp.
Endress+Hauser 115
7 Calculation and Logic Blocks ControlCare Application Designer: Function Blocks
7 Calculation and Logic Blocks
7.1
Arithmetic
The arithmetic block allows process values from two or more Analog Input blocks to be combined mathematically to produce a calculated output. It supports two basic functions:
• Range extension, by combining the outputs of a high-range and low-range measuring device
• Calculated variable, by combining the process variable with the outputs of up to three auxiliary measuring devices. Nine different calculated variables can be selected.
The block also allows the calculation of a variable from an input with an extended range.
The arithmetic block is not intended to be used in a control path, so that it does not support control status propagation or back calculation. It has no process alarms.
In ControlCare Application Designer the Arithmetic block (AR block) is assigned the generic name
Device Tag-ARTH-n . It can be found by expanding the appropriate device or Field Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 7-1.
IN
IN_LO
IN_1
IN_2
IN_3
RANGE_LO
RANGE_HI
RANGE
EXTENSION
FUNCTION
PV_SCALE
PV
(IN_1 + BIAS_IN_1) x GAIN_IN_1
(IN_2 + BIAS_IN_2) x GAIN_IN_2
(IN_3 + BIAS_IN_3) x GAIN_IN_3 t_1 t_2 t_3
ARITH_TYPE
BAL_TIME
ALGORITHM
TYPE
OUT_HI_LIM func x GAIN
+ BIAS
OUT_LO_LIM
GAIN_IN_i BIAS_IN_i
COMP_LO_LIM
COMP_HI_LIM
OUT_RANGE
OUT
Fig. 7-1: Schematic diagram of ARTH block (AR Block).
116 Endress+Hauser
ControlCare Application Designer: Function Blocks 7 Calculation and Logic Blocks
7.1.1
Range extension
The range extension function ensures a gradual transfer between e.g. a standard measuring device connected to IN and low range measuring device connected to IN_LO . The function is controlled by two constants referenced to IN according to the following equation, see also Fig. 7-2:
PV = g · IN + (1-g) · IN_LO where g is: zero when IN is less or equal to RANGE_LO one when IN is greater or equal to RANGE_HI
IN - RANGE_LO/(RANGE_HI - RANGE_LO) in the transistion zone
PV, g g = 1 PV = g · IN_LO + (1 - g) · IN PV = IN
Status propagation
PV = IN_LO
IN = RANGE_LO g = 0
IN = RANGE_HI
IN
Fig. 7-2: Transition function for range extension
After combination, the extended range is scaled in PV_SCALE before being passed on to the arithmetic algorithm. If no option has been selected in ARITH_TYPE (=default), PV is passed on unchanged to the output calculation:
• OUT = GAIN · PV + BIAS
If GAIN is set to one and the BIAS to zero (default), PV is again passed unchanged to OUT .
OUT_RANGE determines the range and units of OUT . The output may be limited by using the
OUT_HI_LIM and OUT_LO_LIM parameters.
The status of PV is handled according to the following table. Provided one input value is good in the transistion zone, PV will always have the status good.
IN_LO status IN status
Bad, Uncertain Good
Bad, Uncertain Good
Good Good
Good
Good
IN value
IN < RANGE_LO
Bad, Uncertain IN_LO > RANGE_HI
Bad, Uncertain IN_LO < RANGE_HI
PV value
PV = IN_LO
IN > RANGE_LO PV = IN
RANGE_LO < IN < RANGE_HI PV = g · IN + (1-g) · IN_LO
PV = IN
PV = IN_LO
PV status
Bad, Uncertain
Good
Good
Bad, Uncertain
Good
If the options "IN_LO Use uncertain" and "IN Use uncertain" are selected in the INPUT_OPTS parameter, then the status "Uncertain" will not force PV to IN or IN_LO within the transition zone, but the transition equation will be used. The status of PV will be "Good".
Endress+Hauser 117
7 Calculation and Logic Blocks
Control strategy
ControlCare Application Designer: Function Blocks
Fig. 7-3 shows the control strategy together with the links that must be made between the blocks:
Device 1
AI_1
OUT e.g. 1000 – 3000 (units)
Device 2
AI_2
OUT e.g. 0 – 1200 (units)
IN
IN_LO
ARTH OUT
Block configuration
Fig. 7-3: Links required for range extension
The inputs IN and IN_LO must be linked to OUT signals that have the same engineering units.
The arithmetic block is configured for range extension as follows:
Parameter
MODE_BLK.Target
PV_SCALE.EU_100
PV_SCALE.EU_0
PV_SCALE.UNITS_INDEX
OUT_RANGE.EU_100
OUT_RANGE.EU_0
OUT_RANGE.UNITS_INDEX
INPUT_OPTS
RANGE_LO
Action
Set the target mode of the block to Auto
Option/Value
Auto
Enter upper range limit of extended range
Enter lower range limit for extended range
Enter unit of process variable
Enter upper range limit for output variable
Enter lower range limit for output variable
Enter unit of output variable
If required, select the input options by ticking the box
• Multiple selections are allowed
• See status handling for more information e.g. 3000 units e.g. 0 units units e.g. 3000 units* e.g. 0 units* units*
IN Use uncertain
IN_LO Use uncertain
Enter the PV value at which transition from IN_LO to IN begins e.g. 1050 units
RANGE_HI
BIAS
GAIN
ARITH_TYPE
Enter the PV value at which transition from IN_LO to IN ends e.g. 1150 units
If required, enter a constant to be used in the calculation of OUT
• e.g. 273 for conversion °C to K
0 units (default)*
1* Enter the scaling value to be used in the calculation of
OUT
Do not make an entry here (= default) unless PV is to used to produce a calculated value, see Chapter 7.1.2
0 (default)
OUT_HI_ LIM
OUT_LO_LIM
If required, enter upper limit to be placed on OUT value –
If required, enter lower limit to be placed on OUT value –
*If BIAS is other than 0 or the GAIN is other than 1, the OUT_RANGE parameters must be adjusted accordingly
118 Endress+Hauser
ControlCare Application Designer: Function Blocks
Process value
7 Calculation and Logic Blocks
7.1.2
Calculated variables
The Arithmetic Block contains nine algorithms that find frequent use in process engineering. The functions together with examples of use are to be found in Table 7-1 below. All algorithms use the
.
process value PV supplied by IN as well as up to three auxiliary inputs, IN_1 , IN_2 and IN_3
Function
Flow compensation, linear.
Flow compensation, square root.
Flow compensation, approximate
BTU flow
Function/Example IN (PV) IN_1 (t_1) IN_2 (t_2) IN_3 (t_3) func = (t_1 / t_2), limited* e.g. Q b
= Q f
· K· P/T func =
t_1 /( t_2· t_3), limited* e.g. Q b
= Q f
· K·
P/T · Z) func =
(t_1 + t_2 + t_3
2
), limited*
Q
Q f f in m in m
3
3
/h
/h
P in MPa
P in MPa
T in K
T in K
–
Compress. Z
The square root of the third power is avaialble by connecting input to IN and IN_1.
The square root of the fifth power is available by connecting the input to IN, IN_1 and IN_3.
e.g. Q b
= Q f
· K e.g. Q b
= Q f
· K
1
·
K
1
·
K
2
+ K
3
T + K
4
T
2
) Q f in m
3
/h K
2
2
+ K
3
P) Q f in m
3
/h K
2 func = t_1 - t_2
T in K
P in MPa
T in K
– e.g. Q heat
= K · Q vol
· (T
2
- T
1
) func = (t_1 / t_2) + t_3, limited*
Q v
in m
3
/h T
2
T
1
–
Traditional Multiply
Divide
Average
Q sp
= Q f
· Ratio func = (PV + t_1 + t_2 + t_3)/n where n = number of inputs used e.g. T a
= (T
1
+ T
2
+ T
3
+ T
4
)/4
Traditional Summer.
func = PV + t_1 + t_2 + t_3
Q
T f
1
Quotient
T
2
Devisor
T
3
–
T
4
Fourth order polynomial e.g. P diff
= P
1
- P
2 func = PV + t_1
2
+ t_2
3
+ t_3
4 e.g.
T
= A + K
1
T + K
2
T
2
+ K
3
T
3 func = (PV -t_1) / (PV - t_2)
P
1
T in K
P
1
T in K
–
T in K
–
–
Simple HTG compensated level, l bt
= 1 bm
· (P b
- P where t
)/(P b
- P m
) P b
P t
P m
–
P b
is the tank base pressure,
P t
is the top pressure,
P m
is the density correction pressure,
1 bm
is the GAIN ( height of density tap)
*limited: the compensation function must be limited by the COMP_LO_LIM and COM P_HI_LIM parameters
Tab. 7-1: Algorithms and examples of use (units may differ from those shown here)
The process value PV supplied by IN is scaled in PV_SCALE before being passed on to the arithmetic algorithm. PV_SCALE will normally reflect the OUT_SCALE of the upstream block, and must be in the units required for calculation. If a range extension has been enforced, the extended range limits must be entered.
Depending upon the algorithm chosen in ARITH_TYPE , the output is generated by multiplying PV by the result of the function calculation, f, or PV is itself part of the function. The OUT value is therefore calculated either as:
OUT = PV · f · GAIN + BIAS or
OUT = f · GAIN + BIAS
(1)
(2)
The GAIN parameter can be used to simulate factors, e.g. the first order coefficient in the polynomial or height of the density tap, see Table 7-1. The BIAS parameter can be used to add or subtract constants from the final result. The result of the calculation function is always displayed in
PRE_OUT .
For compensated outputs of type (1) the algorithm itself must be limited by entering appropriate values in COMP_LO_LIM and COMP_HI_LIM .The parameter BAL_TIME is used to provide bumpless transfer from Auto to Man mode, the output being ramped from the last OUT value to the new value in the time entered. OUT itself may also be limited by the use of OUT_LO_LIM and OUT_HI_LIM .
Endress+Hauser 119
7 Calculation and Logic Blocks
Auxiliary inputs
Status propagation
Control strategy
ControlCare Application Designer: Function Blocks
Three inputs IN_1, IN_2 and IN_3 , connected to the OUT parameter of an upstream block, are available for the calculation. Ideally, OUT has the engineering units required for the calculation.
Each input has a BIAS_IN_i and a GAIN_IN_i parameter. BIAS is added to the input and GAIN is applied to the sum. The result is an internal value called t_i in the function equations: t_i = (IN_i + BIAS_IN_i) · GAIN_IN_i
BIAS is used to correct for absolute temperature, pressure etc.. GAIN can be used to represent a coefficient. The internal values t_i are used in the calculations as shown in Table 7-1.
The table below summarizes the status, which will normally follow that of PV, unless one or more of the auxiliary inputs is "Bad" or "Uncertain" . The status of unused inputs ignored.
IN_i status
Good
IN status
Good
OUT status
Good
Good Bad, Uncertain Bad, Uncertain
Bad, Uncertain Good Uncertain
If the options "IN_i Use uncertain" and/or "IN_i Use bad" are selected in the INPUT_OPTS parameter, then the corresponding input status will not force OUT to "Uncertain". Instead the status of OUT will be "Good". Simularly, The option "IN Use uncertain" will force OUT to "Good" if the status of PV is "Uncertain".
The links to the block inputs depend on the selected function. Fig. 7-4 shows those for a third order polynomial, for which all inputs come from the same source: e.g. Temperature
AI
OUT
OUT
OUT
IN
IN_1
IN_2 fourth order polynomial
ARTH OUT
Fig. 7-4: Links for third order polynomial (an additional link to IN_3 is required for fourth order polynomial)
Fig. 7-5 shows the links for linear flow compensatioin. In this case each of the inputs comes from a separate analog input block that has been scaled to provide the correct engineering units for the selected algorithm.
Flow
AI_1
OUT
Pressure
AI_2
OUT
Temperature
OUT
AI_2
Compensated flow, linear
IN
IN_1
IN_2
ARTH OUT
Fig. 7-5: Links required for linear flow compensation
120 Endress+Hauser
ControlCare Application Designer: Function Blocks
Block configuration
7 Calculation and Logic Blocks
The block is configured as follows:
Parameter
MODE_BLK.Target
PV_SCALE.EU_100
PV_SCALE.EU_0
PV_SCALE.UNITS_INDEX
OUT_RANGE.EU_100
OUT_RANGE.EU_0
OUT_RANGE.UNITS_INDEX
INPUT_OPTS
BIAS_IN_1
GAIN_IN_1
BIAS_IN_2
GAIN_IN_2
BIAS_IN_3
GAIN_IN_3
COMP_HI_LIM
COMP_LO_LIM
ARITH_TYPE
BAL_TIME
BIAS
GAIN
OUT_HI_ LIM
OUT_LO_LIM
Action
Set the target mode of the block to Auto
Enter upper range limit of PV
Enter lower range limit of PV
Enter unit of process variable
Enter upper range limit for output variable
Enter lower range limit for output variable
Enter unit of output variable
Option/Value
Auto e.g. 2000 units e.g. 0 units units e.g. 3000 units e.g. 0 units units
If required, select the input options by ticking the box
• Multiple selections are allowed
• See status handling for more information
Enter bias to be applied to first auxiliary input
Enter gain to be applied to first auxiliary input
IN Use uncertain
IN_i Use uncertain
IN_i Use bad
0, see below
>0, see below
Enter bias to be applied to second auxiliary input, if used 0, see below
Enter gain to be applied to second auxiliary input, if used >0, see below
Enter bias to be applied to third auxiliary input, if used 0, see below
Enter gain to be applied to third auxiliary input, if used >0, see below e.g. 2000 units Enter upper limit to which compensation applies
• Applies to the first five ARITH_TYPE functions
Enter upper limit to which compensation applies
– Applies to the first five functions in Table 7-1 only e.g. 0 units
Tick the function to be executed by the arithmetic block Flow, linear
Flow, sq root
Flow, approx
BTU flow
Multiply/Divide
Average
Summer
4th order polynomial
Compensated level
Enter the time in seconds for OUT to adjust to a new value if the block mode changes from Man to Auto
10 s
If required, enter a constant to be used in the calculation of OUT
0 units (default), see below
Enter the scaling value to be used in the calculation of
OUT
>0, see below
If required, enter upper limit to be placed on OUT value –
If required, enter lower limit to be placed on OUT value –
The GAIN and BIAS values to be entered depend upon the application selected. The table below offers suggestions for each of the functions shown in the table above
Function/Example OUT
GAIN BIAS
IN_1
GAIN BIAS
IN_2
GAIN BIAS
IN_3
GAIN
Q b
= Q f
· K· P/T
Q b
= Q f
· K·
P/T · Z)
K
K
Q b
= Q f
· K
Q b
= Q f
· K
1
·
K
2
+ K
3
T + K
4
T
2
) K
1
1
·
K
2
+ K
3
P) K
1
Q heat
= K · Q vol
· (T
2
- T
1
) K
0
0
0
0
0
1*
1*
1*
1*
1
0
0
0
0
0
1*
1*
1*
1*
1
(273)
(273)
(273)
0
0
N/A
1
1
N/A
N/A
Q sp
= Q f
· Ratio
T a
= (T
1
+ T
2
+ T
3
+ T
4
)/4
1
1
0
0
1*
1
0
0
1*
1
0
0
N/A
1
P diff
= P
1
- P
2
T
= A + K
1
T + K
2
T
2
+ K
3
T
3 l bt
= 1 bm
· (P b
- P t
)/(P b
- P m
)
1
K
1
1
0
A
0
1
K
1
2
0
(273)
0
N/A
K
1
3
N/A
(273)
0
N/A
–
1
*Assuming that input is already in the required units, otherwise GAIN must be used as conversion factor
BIAS
N/A
0
273
N/A
N/A
N/A
0
N/A
–
0
Endress+Hauser 121
7 Calculation and Logic Blocks
Operating mode
Status
Block Errors
ControlCare Application Designer: Function Blocks
7.1.3
Block operation
The block normally operates in AUTO mode. The algorithm never changes the mode, even when inputs go bad. Difficulties with a function, such as division by zero and roots of negative numbers, are handled such that they do not disturb the status of OUT or the mode. Division by zero produces a large number of the proper sign. Infinity is not used, as it has a special meaning for unused limits.
Roots of negative numbers produce the root of the absolute value, with a negative sign.
When MODE_BLK.Target
is set to MAN, the block output can be manipulated by entering the desired status and value in the OUT parameter. An internal value is set to the difference between
OUT and the output of the selected function, so that bumpless transfer is possible when the block is returns to AUTO. The difference decays to zero over the time period entered in BAL_TIME .
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
Operation can be checked on-line by viewing a number of parameters:
Parameter
IN
IN_LO
IN_1
IN_2
IN_3
PV
PRE_OUT
OUT
Meaning
Value and status of primary input from upstream block
Value and status of low range input from upstream block
Value and status of first auxiliary input from upstream block
Value and status of second auxiliary input from upstream block
Value and status of third auxiliary input from upstream block
Value and status of process value after scaling
Value and status of selected algorithm
Value and status of block output
The Arithmetic block supports standard status handling as described in Chapter 2.6 with the additions detailed in Chapter 7.1.1.
Output status
Good NonCascade
Uncertain
Bad NonCascade
Meaning
Normal operation as configured
• IN input status "Uncertain", IN_x status "Good"
• IN_x input status "Bad" or Uncertain, IN input status good
• IN input status "Bad" , IN_x input status "Good", "Uncertain" or "Bad"
• Block configuration error
On execution of the block, the device checks for correct configuration. Block errors are indicated in the BLOCK_ERR parameter.
Condition
Block Configuration Error
Out-of-Service
Reason
• Invalid parameter setting in ARITH_TYPE
• MODE_BLK.Target currently set to OOS
122 Endress+Hauser
ControlCare Application Designer: Function Blocks
Arithmetic block
7 Calculation and Logic Blocks
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
PV
OUT
PRE_OUT
PV_SCALE
OUT_RANGE
GRANT_DENY
INPUT_OPTS
IN
IN_LO
IN_1
IN_2
IN_3
RANGE_HI
RANGE_LO
BIAS_IN_1
GAIN_IN_1
BIAS_IN_2
GAIN_IN_2
BIAS_IN_3
GAIN_IN_3
COMP_HI_LIM
COMP_LO_LIM
ARITH_TYPE
7.1.4
Block parameters
Parameter
BAL_TIME
BIAS
GAIN
OUT_HI_LIM
OUT_LO_LIM
UPDATE_EVT
BLOCK_ALM
Legend: RO = Read Only
Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
RO
RO
Positive
Description
See Chapter 2.3.4
Block mode, set MODE_BLK.Target to AUTO, CAS or RCAS
Block errors, see Chapter 6.1.9
Process value used in executing the block
Output value calculated as a result of executing the block
(OUT_RANGE ± 10%)
Output value of calculation.
0
0
0
100
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0-100% PV scaling to required engineering units
0-100% OUT value scaling to required engineering units
Access options, see Chapter 2.8.1
Input options for handling block input status.
Primary input value of the block
Input for low range device in a range extension application.
Auxiliary input 1
Auxiliary input 2
Auxiliary input 3
PV value at which transition from IN_LO to IN begins
PV value at which transition from IN_LO to IN ends
Bias to be applied to first auxiliary input
Gain to be applied to first auxiliary input
Bias to be applied to second auxiliary input, if used
Gain to be applied to second auxiliary input, if used
Bias to be applied to third auxiliary input, if used
Gain to be applied to third auxiliary input, if used
High limit imposed on the PV compensation term.
Low limit imposed on the PV compensation term.
Function to be executed by the block
• 1= Flow comp. linear
• 2= Flow comp. square root
• 3= Flow comp. approx.
• 4= BTU flow
• 5= Traditional mult. div.
• 6= Average
• 7= Traditional summer
• 8= Fourth order polynomial
• 9= HTG comp. level
Decay time for OUT value for change from man to Auto mode
Constant to be used in the calculation of OUT
Scaling value to be used in the calculation of OUT
Upper limit to be placed on OUT value
Lower limit to be placed on OUT value
This alert is generated by any change to the static data.
Block alarms, see Chapter 2.9
Endress+Hauser 123
7 Calculation and Logic Blocks ControlCare Application Designer: Function Blocks
7.2
Output Splitter
The Output Splitter block allows two control outputs to be driven from a single input, whereby each output is a linear function of some portion of the input. The block is intended for use in split ranging or sequencing of multiple valve applications.
• Split range application:
– Normally both valves are closed when the splitter input is 50%.
– One valve opens fully as the input drops to 0%.
– The other valve opens as the input rises above 50%.
• Sequencing application
– Normally both valves are closed at 0% input.
– One valve opens fully as the input rises to 50%, and the other stays shut.
– The second valve opens as the input rises above 50%; the first valve may remain open or shut off quickly.
The block provides back calculation support by using the same linear function in reverse. Cascade initialization is supported by a decision table for combinations of input and output conditions. As this block is in the control path, it is able to pass limit and cascade initialization information back to the upstream block.
In ControlCare Application Designer the Output Splitter block (OS block) is assigned the generic name Device Tag-OS-n . It can be found by expanding the appropriate device or Field Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 7-6.
IN_ARRAY
OUT_ARRAY
LOCKVAL
CAS_IN
Auto
OUTPUT
SPLITTER
OUT_1
OUT_2
BKCAL_IN_1
BKCAL_IN_2 BKCAL_OUT
Fig. 7-6: Schematic diagram of Output Splitter block (OS Block)
124 Endress+Hauser
ControlCare Application Designer: Function Blocks 7 Calculation and Logic Blocks
7.2.1
Functional description
The CAS_IN input is connected to an upstream PID block which supplies the setpoint value SP in percentage of span to the block. The splitter outputs OUT_1 and OUT_2 are generated from SP by means of two linear functions.
Each function is defined by two end points, (X11, Y11) and (X12, Y12) for OUT_1 and (X21, Y21) and (X22, Y22) for OUT_2 . These parameters are configured by means of two arrays IN_ARRAY for the setpoint values (X) and OUT_ARRAY for the corresponding OUT values (Y).
Split range
100%
(X11, Y11)
OUT_1
OUT
(X22, Y22)
OUT_2
0%
0%
(X12, Y12)
50%
(X21, Y21)
100% SP
100%
Sequencing
(X12, Y12) (X22, Y22)
OUT
OUT_1 OUT_2
0%
0%
(X11, Y11)
50%
(X21, Y21)
100% SP
Fig. 7-7: Split range and sequencing operations
Fig. 7-7 shows the applications split range and sequencing. The corresponding array for these applications might be as follows:
Split range
IN_ARRAY OUT_ARRAY
[1] 0
[2] 50
100
0
[3] 50
[4] 100
0
100
Sequencing
IN_ARRAY OUT_ARRAY
[1] 0
[2] 50
0
100
[3] 50
[4] 100
0
100
Other configurations are possible. If the array is configured such that a region of the input range is not specified, then the block will interpolate to the endpoint of the input value (0% or 100%).
In sequencing, the decision whether valve 1 remains open when the endpoint of OUT_1 is reached is made in the parameter LOCKVAL .
• If LOCKVAL is true, OUT_1 remains at its current value when OUT_2 is non-zero
• If LOCKVAL is false, then as soon as the OUT_2 becomes non-zero then OUT_1 goes to zero
100%
LOCKVAL = TRUE
OUT_1 = 100%
100%
LOCKVAL = FALSE
OUT
0%
0%
OUT_1
50%
OUT
OUT_2
100% SP
0%
0%
Fig. 7-8: Effect of LOCKVAL on OUT_1
OUT_1 OUT_2
50%
OUT_1 = 0%
100% SP
Endress+Hauser 125
7 Calculation and Logic Blocks
Status propagation
ControlCare Application Designer: Function Blocks
The parameter HYSTVAL provides hysteresis in % of span for the switching point as follows:
Condition
X < X12 - HYSTVAL
X12 - HYSTVAL < X < X12 and
X
X12 since it was less than X12 - HYSTVAL
X12 - HYSTVAL < X < X12 and
X
X12 since it was less than X12 - HYSTVAL
X12 < X
Action
OUT_1 = calculated Y value
OUT_1 = calculated Y value
OUT_1 = as determined by LOCKVAL
OUT_1 = as determined by LOCKVAL
After splitting of the output, the values can be scaled in the OUT_1_RANGE and
OUT_2_RANGE respectively before they are passed to the downstream application as OUT_1 and
OUT_2 .
BKCAL_OUT normally provides the current SP to the upstream block . BKCAL_IN_1 and
BACK_IN_2 provide the back calculation from the downstream blocks.
Substatus values received at CAS_IN are passed to both outputs when the cascade is closed. The back calculation status originates from an active output only. An output held by LOCKVAL is not considered to be active. If neither output is active, no limits are sent back on BKCAL_OUT . An IFS is passed on to both the active and the inactive outputs.
Since the splitter has two independent outputs, cascade initialization is handled slightly differently than is described in Chapter 2.6.4. When a downstream block sends an initialization request to the splitter, one of two things can happen:
• The request can be passed on by the splitter to its upstream block, so that all three blocks balance for bumpless transfer to cascade mode.
• The request cannot be passed on and splitter output moves to the requested value by calculating the offset between the requested and actual value. The offset is ramped to zero in
BAL_TIME seconds immediately after the cascade closed.
Table 7-2 indicates the possible back caculation statuses together with the actions invoked by the
Output Splitter block..
BKCAL _IN_1 BKCAL _IN_2 BKCAL _OUT Action
NotInvited NotInvited NotInvited Not specified
NotInvited
OK
OK
NotInvited
OK BKCAL_OUT limited to X21 low and X22 high
Initial.Request
NotInvited
Initial.Request
OK
NotInvited
OK
Initial.Request
Initial.Request
Initial.Request
OK
Initial.Request
OK
OK = cascade is closed with status other than NI or IR
Initialize cascade to value given by curve X1 vs Y1
Initialize OUT_1 using internal offset from Y1
Initialize cascade to value given by curve X2 vs Y2
Initialize OUT_2 using internal offset from Y2
Tab. 7-2: Splitter bock actions as a funtion of back calcuilation status of the connected blocks
Cascade initialization is also required when the block moves from Auto to Cas mode. This action is identical to that described in Chapter 2.6.4.
The option "IFS if Bad CAS_IN" in STATUS_OPS causes the fault status to be propagated to the downstream blocks without causing the block mode to change.
126 Endress+Hauser
ControlCare Application Designer: Function Blocks
Control strategy
Block configuration
7 Calculation and Logic Blocks
7.2.2
Block configuration
Fig. 7-9 shows the control strategy together with the links that must be made between the blocks.
In this example the splitter receives its input from the OUT parameter of an upstream PID Control block. The split output is then passed on to a downstream Analog Output block and a second
Control PID block, however, the two outputs can be connected to any combination of blocks that operate in cascade mode.
PID_1
OUT
CAS_IN
BKCAL_IN
BKCAL_OUT
BKCAL_IN_1
BKCAL_OUT
AO
OUT
OUT_1
OS
CAS_IN
OUT_2
BKCAL_IN_2
CAS_IN
PID_2
BKCAL_OUT
OUT
Fig. 7-9: Links to be made for Output Splitter block
The block is configured as follows:
Parameter
MODE_BLK.Target
OUT_1_RANGE.EU_100
OUT_1_RANGE.EU_0
OUT_1_RANGE.UNITS_INDEX
OUT_2_RANGE.EU_100
OUT_2_RANGE.EU_0
OUT_2_RANGE.UNITS_INDEX
STATUS_OPTS
IN_ARRAY.[1]
IN_ARRAY.[2]
IN_ARRAY.[3]
IN_ARRAY.[4]
OUT_ARRAY.[1]
OUT_ARRAY.[2]
OUT_ARRAY.[3]
OUT_ARRAY.[4]
LOCKVAL
BAL_TIME
HYSTVAL
Action
Set the target mode of the block to Cas
Enter upper range limit for OUT_1 output variable
Enter lower range limit for OUT_1 output variable
Enter unit of OUT_1 output variable
Enter upper range limit for OUT_2 output variable
Enter lower range limit for OUT_2 output variable
Enter unit of OUT_2 output variable
Option/Value
Cas default 100 default 0 default % default 100 default 0 default %
IFS if Bad CAS_IN If required, select the status option by ticking the box
• If selected, the block continues to operate with bad input and the downstream blocks handle the fault
Enter setpoint values in upstream block units:
• Corresponding to lower range value of OUT_1
• Corresponding to upper range value of OUT_1
• Corresponding to lower range value of OUT_2
• Corresponding to upper range value of OUT_2 e.g. 0 e.g. 50 e.g. 50 e.g.100
Enter setpoint values in OUT_RANGE units:
• Lower range value of OUT_1
• Upper range value of OUT_1
• Lower range value of OUT_2
• Upper range value of OUT_2
For sequencing operation, select OUT_1 position
Enter the time in seconds for OUT to adjust to a new value if the block mode changes from Cas
If required, enter a switching point hysteresis for OUT_1 in percentage of output span e.g. 1 e.g. 0 e.g. 100 e.g. 0 e.g.100
e.g. Lock (= 100%) e.g. 10 s
Endress+Hauser 127
7 Calculation and Logic Blocks
Operating mode
Status
Block Errors
ControlCare Application Designer: Function Blocks
7.2.3
Block operation
The block normally operates in CAS mode and takes its setpoint SP from the CAS_IN parameter. If
BKCAL_IN_1 or BKCAL_IN_2 indicate that the cascade is broken, see Chapter 7.1.2, Status propagation, the block will be forced to IMan.
When MODE_BLK.Target
is set to AUTO, the block output can be manipulated on-line by entering the desired status and value in the SP parameter. An internal value is set to the difference between OUT and the output of the selected function, so that bumpless transfer is possible when the block is returns to CAS. The difference decays to zero over the time period entered in
BAL_TIME .
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
Operation can be checked on-line by viewing a number of parameters:
Parameter
CAS_IN
OUT_1
OUT_2
Meaning
Value and status of setpoint value from upstream block
Value and status of output 1
Value and status of output 2
The Output Splitter block supports standard status handling as described in Chapter 2.6 with the additions detailed in Chapter 7.2.1.
Output status
Good NonCascade
Good Cascade
Uncertain
Bad NonCascade
Bad Cascade
Meaning
Normal operation as configured - not operating in control loop
Normal operation as configured - operating in contrtol loop"
Input "Uncertain" - not operating in control loop
• Input "Bad" - not operating in control loop
• Block configuration error
• Input "Bad" - operating in control loop
• Block configuration error
On execution of the block, the device checks for correct configuration. Block errors are indicated in the BLOCK_ERR parameter.
Condition
Block Configuration Error
Out-of-Service
Reason
• IN_ARRAY configuration error
– Value [1]
Value [2],
– Value [3]
Value [4],
– Value [1] > Value [4]
• MODE_BLK.Target currently set to OOS
128 Endress+Hauser
ControlCare Application Designer: Function Blocks
Output Splitter block
7 Calculation and Logic Blocks
7.2.4
Block parameters
Parameter
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
SP
OUT_1
OUT_2
OUT_1_RANGE
OUT_2_RANGE
GRANT_DENY
STATUS_OPTS
CAS_IN
BKCAL_OUT
IN_ARRAY
OUT_ARRAY
LOCKVAL
BKCAL_IN_1
BKCAL_IN_2
BAL_TIME
HYSTVAL
UPDATE_EVT
BLOCK_ALM
Legend: RO = Read Only
Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
Positive
Description
See Chapter 2.3.4
Block mode, set MODE_BLK.Target to AUTO, CAS or RCAS
Block errors, see Chapter 6.1.9
Setpoint used by the block in AUTO mode (PV_SCALE ± 10%)
1 st
output value calculated as a result of executing the block
2 nd
output value calculated as a result of executing the block
0
0
0
0
0-100% OUT_1 value scaling to required engineering units
0-100% OUT_2 value scaling to required engineering units
Access options, see Chapter 2.8.1
Status options, see Chapter 2.8.4 and Chapter 6.1.9
Setpoint used by the block in CAS mode
Feedback for BKCAL_IN of an upstream block.
0, 0, 0, 0 2x 2 SP range-end values for OUT_1 and OUT_2
0, 0, 0, 0 2x 2 output range-end values for OUT_1 and OUT_2
No Lock Boolean value for controlling OUT_1 value when OUT_2 >0
• Lock = OUT_1 = 100%
• No Lock = OUT_1 = 0%
Feedback from BKCAL_OUT of downstream block connected to OUT_1
Feedback from BKCAL_OUT of downstream block connected to OUT_2
Decay time for OUT value for change from Auto to Cas mode
Switch point hysteresis for OUT_1
This alert is generated by any change to the static data.
Block alarms, see Chapter 2.9
Endress+Hauser 129
7 Calculation and Logic Blocks ControlCare Application Designer: Function Blocks
7.3
Signal Characterizer
The Signal Characterizer block is used to enter of a strapping table, comprising up to 21 pivot points, that allows the mapping of a non-linear relationship between input and output values. The block has two paths, which use a single look-up table. The second path allows an optional swapping of the x and y axes, allowing its use in a backward control path.
The status of an input is copied to the corresponding output, so that the block can be used in the control or process signal path.
In ControlCare Application Designer the Signal Characterizer block (SC block) is assigned the generic name Device Tag-CHAR-n . It can be found by expanding the appropriate device or Field
Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 7-10.
IN_1
IN_2
LOOK_UP TABLE
CALCULATION
OUTPUT y21 y1 x1 x21
INPUT
OUT_1
OUT_2
Standard operation
SWAP_2
(TRUE, IN_2 = Y, OUT_2 =X)
Fig. 7-10: Schematic diagram of Signal Characterizer block (SC Block)
7.3.1
Functional Description
In standard operating mode, IN_1 and IN_2 comprise a value and status from an upstream function block. The block calculates OUT_1 from IN_1 and OUT_2 from IN_2 using the same look-up table. The curve used is defined by up to 21 points:
[x
1
; y
1
], [x
2
; y
2
]...[x
21
; y
21
] in the parameters CURVE_X ; CURVE_Y where x corresponds to the input and y to the output. The x-coordinates are entered in the units of
IN and the y-coordinates in the units of OUT. The units and range limits can be made visible to an external application by using the parameters X_RANGE (= IN) and Y_RANGE (= OUT).
The output value is calculated by linear interpolation between the two table values bracketing the input value. For this reason, the values of x must rise monotonically. If this is not the case, a configuration error is set in BLOCK_ERR and the block switches to OOS mode.
If the look-up table has m points, where m is less than 21, all non-configured points [x m+1
; y m+1
],
[x m+2
; y m+2
] etc. will be set to +INFINITY to mark them as unused. Since x for the input and x m
the largest value, the output is set to y
1
1
is the smallest value
when the input value is smaller than x
1
, and to y m
when the input value is larger than x m
. When the input value is out of the limits, set by x
1
and x m
, the OUT status indicates the condition.
130 Endress+Hauser
ControlCare Application Designer: Function Blocks 7 Calculation and Logic Blocks
Use in backward control path
Status propagation
If the parameter SWAP_2 is set to "Swap", then the x and y axes of the look-up table are swapped on the IN_2 to OUT_2 path. This means that IN_2 must be connected to a downstream block and
OUT_2 to an upstream block, building a backward control path. In this case IN_2 must be in the units of OUT_1 (Y_RANGE ) and OUT_2 in the units of IN_1 (X_RANGE) .
In this case, the y values must also be monotonic, i.e. the y values must always increase or always decrease when the x values increase. If this is not the case, a configuration error is set in
BLOCK_ERR and the block switches to OOS mode.
The output values OUT_1 and OUT_2 replicate the status of the corresponding IN values or are generated by the block. If the BLOCK_ERR parameter indicates a block error, the status of the output is set to "Bad"
The sub-status is also passed to the outputs. If one of the CURVE_X/CURVE_Y limits is reached or the input is limited, "High Limited" or "Low Limited" will be indicated in the output limit status.
The limits are reversed if the curve slope is negative.
When the block is operating in a control loop, i.e. SWAP_2 = "Swap", cascade initialization is controlled by the lower block, see Chapter 2.6. When the block is out of service, the cascade to both the lower and upper blocks is broken by setting "Bad" at the outputs. When the block moves back to Auto mode, the lower block begins cascade initialization with status values that pass along the backward control path (IN_2 => OUT_2) to the upper block. The answering status signals from the upper block pass through this block to the lower block via IN_1 => OUT_1.
Control strategy
7.3.2
Block configuration
Fig. 7-11 shows the control strategy together with the links that must be made between the blocks for the standard mode of operation. In this example, the characterizer receives its inputs from the
OUT parameters of two upstream Analog Input blocks. The application requires that both signals are characterized in exactly the same way. The output of the characterizer is then passed on to two independent Control PID blocks.
Endress+Hauser
AI
OUT
OUT
AI
IN_1
IN_2
OUT_1
CHAR
OUT_2
PID_1 OUT
IN
IN
PID_2
OUT
Fig. 7-11: Links to be made for Signal Characterizer block in standard operation
Fig. 7-12 shows the characterizer operating in a backward control path, i.e. SWAP_2 = Swap. In this case it is used to characterize the OUT value of a Control PID block before this is used by the downstream analog output block. In order that the back calculation can be used by the upstream
PID block it must be reconverted by the characterizer, by connecting BKCAL_OUT of the output block to IN_2 and OUT_2 to BKCAL_IN of the Control PID block.
AI
OUT
IN
PID
OUT
IN_1
SWAP_2 = TRUE
CHAR
OUT_1
CAS_IN
OUT_2
IN_2
AO
BKCAL_OUT
BKCAL_IN
OUT
Fig. 7-12: Links to be made for Signal Characterizer block in a backward control path
131
7 Calculation and Logic Blocks
Block configuration
Operating mode
Status
ControlCare Application Designer: Function Blocks
The block is configured as follows:
Parameter
MODE_BLK.Target
X_RANGE.EU_100
X_RANGE.EU_0
X_RANGE.UNITS_INDEX
Y_RANGE.EU_100
Y_RANGE.EU_0
Y_RANGE.UNITS_INDEX
SWAP_2
CURVE_X.[1]
...
CURVE_X.[21]
CURVE_Y.[1]
...
CURVE_Y.[21]
Action
Set the target mode of the block to Auto
Enter upper range limit for the input variables
Enter lower range limit for input variables
Enter unit of the input variables
Enter upper range limit for the output variables
Enter lower range limit for output variables
Enter unit of the output variables
Option/Value
Auto e.g. 1000 e.g. 0 e.g. kg/hr e.g. 100 e.g. 0 e.g. %
Set to "Swap" if characterizer is to be used in a backward control path.
e.g. No Swap (default)
Enter X values (input variable) of strapping table
• Values must rise or fall monotonically
• Values must be within the range defined by
X_RANGE
• Unedited values are automatically set to infinity, which means they are not used
0 (kg/hr)
...
1000 (kg/hr)
Enter Y values (output variable) of strapping table^
• Exacly the same number of values must be entered as for the X_CURVE.
• Values must be within the range defined by
Y_RANGE
• If SWAP_2 = TRUE, values must rise or fall monotonically
• Unedited values are automatically set to infinity, which means they are not used
0 (%)
...
100 (%)
7.3.3
Block operation
The block normally operates in Auto mode and takes its input from the IN_1 and IN_2 .
If there is a block configuration error, the block switches to OOS (Out of Service).
When MODE_BLK.Target
is set to Man, the block output can be manipulated on-line by entering the desired status and value in the OUT_1 and/or OUT_2 parameter.
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
Operation can be checked on-line by viewing a number of parameters:
IN_1
IN_2
OUT_1
OUT_2
Input value and status used by the characterizer for path 1
Input value and status used by the characterizer for path 2.
Block output value and status for path 1
Block output value and status for path 2
The Signal Characterizer block supports the qualities Bad, Uncertain and Good NonCascade together with the associated sub- and limit statuses, see Chapter 2.3.2. When SWAP_2 = "Swap", the qualities Good Cascade and Bad Cascade are also supported. "
Status
Good NonCascade
Good Cascade
Uncertain
Bad NonCascade
Bad Cascade
Meaning
Block operating in standard mode; input and block execution "Good"
Block operating in control loop (SWAP_2 = "Swap"); input and block execution "Good"
Block operating in standard mode; input "Uncertain"
Block operating in standard mode; input "Bad" or block configuation error
Block operating in control loop (SWAP_2 = "Swap"); input "Bad" or block configuation error
132 Endress+Hauser
ControlCare Application Designer: Function Blocks
Block Errors
7 Calculation and Logic Blocks
On execution of the block, the device checks for correct configuration. Block errors are indicated in the BLOCK_ERR parameter.
Condition
Block Configuration Error
Reason
• Values in CURVE_X are not monotonic
• SWAP_2 is true and values in CURVE_Y are not monotonic
Input Failure/ process variable has BAD status • Upstream transducer block has status "Uncertain" or "Bad"
• Upstream Analog Output block is out of service
Out-of-Service • MODE_BLK.Target currently set to OOS
Signal Characterizer block
7.3.4
Block parameters
Parameter
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
OUT_1
OUT_2
X_RANGE
Y_RANGE
GRANT_DENY
IN_1
IN_2
SWAP_2
CURVE_X
CURVE_Y
UPDATE_EVT
BLOCK_ALM
Legend: RO = Read Only
Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
Description
See Chapter 2.3.4
Block mode, set MODE_BLK.Target to AUTO, CAS or RCAS
Block errors, see Chapter 6.1.9
Block output value and status for path 1
Block output value and status for path 2
0
0
0-100% IN value scaling to required engineering units, for HMI
0-100% OUT value scaling to required engineering units, for HMI
Access options, see Chapter 2.8.1
Input value and status used by the characterizer for path 1
No Swap Toggle to invert characteristic curve in path 2 when the block is linked to the back control path
INF
INF
Input value and status used by the characterizer for path 2.
X values (input variable) of characteristic in units of X_RANGE
Y values (output variable) of characteristic in units of
Y_RANGE
This alert is generated by any change to the static data.
Block alarms, see Chapter 2.9
Endress+Hauser 133
7 Calculation and Logic Blocks ControlCare Application Designer: Function Blocks
7.4
Cascade Signal Characterizer
The Cascade Signal Characterizer block differs from the signal characterizer in that:
• up to 51 pivot points can be entered for the strapping table
• several blocks can be used in cascade to map strapping tables with more than 51 values
Like the Signal Characterizer, the block has two paths, which use a single look-up table. The second path allows an optional swapping of the x and y axes, allowing its use in a backward control path.
The status of an input is copied to the corresponding output, so that the block can be used in the control or process signal path.
In ControlCare Application Designer the Signal Characterizer block (SC block) is assigned the generic name Device Tag-CCHAR-n . It can be found by expanding the appropriate device or Field
Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 7-13.
IN_1
IN_2
SWAP_2
(TRUE, IN_2 = Y, OUT_2 =X) y51
LOOK_UP TABLE
CALCULATION
E_CURVE_Y
MAN
AUTO
MAN
AUTO y1 x1 x51
E_CURVE_X
X_RANGE
Y_RANGE
CAS_CONTROL
Xmin
Xmax
Xmin
FB1
Xmax
Xmin
Xmax
FBN-1
Xmin
Xmax
FBN
None First Intermediate Last
OUT_1
OUT_2
Fig. 7-13: Schematic diagram of Cascade Signal Characterizer block
134 Endress+Hauser
ControlCare Application Designer: Function Blocks 7 Calculation and Logic Blocks
Standard operation
Use in backward control path
Status propagation
7.4.1
Functional Description
The Cascade Signal Characterizer block is identical in parameters and function to the Signal
Characterizer, see Chapter 7.3.1, with two exceptions:
• The strapping table of up to 51 pivot points is entered in the parameters E_CURVE_X and
E_CURVE_Y
• The cascading of the blocks is controlled by the parameter CAS_CONTROL
CAS_CONTROL determines whether the block is cascaded and what position it has in the chain.
It can be set to one of four values
• None: the block is used on its own
• First: the block is the first block in the cascade
• Intermediate: the block is at a position between the ends of the cascade
• Last: the block is the last block in the cascade
When cascaded, the units of E_CURVE_X and E_CURVE_Y must be consistent throughout the cascade. The controller sees the complete characteristic curve, and generates an OUT_1 and/or
OUT_2 value at the final block according to the corresponding value of IN_1 and/or IN_2 at the first block. The x-coordinates are entered in the units of IN and the y-coordinates in the units of
OUT. The units and range limits can be made visible to an external application by using the parameters X_RANGE (= IN) and Y_RANGE (= OUT), whereby these must be set individually for each block.
If the parameter SWAP_2 is set to "Swap", then the x and y axes of the look-up table are swapped on the IN_2 to OUT_2 path. This means that IN_2 must be connected to a downstream block and
OUT_2 to an upstream block, building a backward control path. In this case IN_2 must be in the units of OUT_1 (Y_RANGE ) and OUT_2 in the units of IN_1 (X_RANGE) .
In this case, the y values must also be monotonic, i.e. the y values must always increase or always decrease when the x values increase. When blocks are cascaded, this applies to all values in the cascade. If this is not the case, a configuration error is set in BLOCK_ERR and the block switches to
OOS mode.
The output values OUT_1 and OUT_2 replicate the status of the corresponding IN values or are generated by the block. If the BLOCK_ERR indicates a block error, the status of the output is set to "Bad"
The sub-status is also passed to the outputs. If one of the E_CURVE_X/E_CURVE_Y limits is reached or the input is limited, "High Limited" or "Low Limited" will be indicated in the output limit status. The limits are reversed if the curve slope is negative.
When the block is operating in a control loop, i.e. SWAP_2 = "Swap", cascade initialization is controlled by the lower block, see Chapter 2.6. When the block is out of service, the cascade to both the lower and upper blocks is broken by setting "Bad" at the outputs. When the block moves back to Auto mode, the lower block begins cascade initialization with status values that pass along the backward control path (IN_2 => OUT_2) to the upper block. The answering status signals from the upper block pass through this block to the lower block via IN_1 => OUT_1.
Endress+Hauser 135
7 Calculation and Logic Blocks
Control strategy
ControlCare Application Designer: Function Blocks
7.4.2
Block configuration
Fig. 7-14 shows the control strategy together with the links that must be made between the blocks for the standard mode of operation. In this example the cascade signal characterizer receives its inputs from the OUT parameters of upstream Analog Input blocks. The application requires that both signals are characterized in exactly the same way. The output of the characterizer is then passed on to two independent Control PID blocks.
AI
AI
CAS_CONTROL = First
OUT
IN_1
OUT
IN_2
CHAR
OUT_1
IN_1
OUT_2
IN_2
CAS_CONTROL = Last
PID_1 OUT
CHAR
OUT_1
IN
OUT_2
IN
PID_2
OUT
Fig. 7-14: Links to be made for Cascade Signal Characterizer block in standard operation (2 blocks cascaded)
Fig. 7-15 shows the cascade characterizer operating in a backward control path, i.e. SWAP_2 =
Swap. In this case it is used to characterize the OUT value of a Control PID block before this is used by the downstream analog output block. In order that the back calculation can be used by the upstream PID block it must be reconverted by the characterizer, by connecting BKCAL_OUT of the output block to IN_2 of the last characterizer block, OUT_2 of the last characterizer block to
IN_2 of the first characterizer block and OUT_2 of the first characterizer block to BKCAL_IN of the Control PID block.
AI
OUT
IN
PID
OUT
IN_1
IN_2
CAS_CONTROL = First
SWAP_2 = TRUE
CHAR
OUT_1
IN_1
OUT_2
IN_2
CAS_CONTROL = Last
SWAP_2 = TRUE
CHAR
OUT_1
IN
OUT_2
BKCAL_IN
AO
BKCAL_OUT
OUT
Fig. 7-15: Links to be made forCascade Signal Characterizer block in a backward control path (2 blocks cascaded)
136 Endress+Hauser
ControlCare Application Designer: Function Blocks
Block configuration
7 Calculation and Logic Blocks
The blocks are configured as follows:
Parameter
CCHAR Block 1
MODE_BLK.Target
X_RANGE.EU_100
X_RANGE.EU_0
X_RANGE.UNITS_INDEX
Y_RANGE.EU_100
Y_RANGE.EU_0
Y_RANGE.UNITS_INDEX
SWAP_2
CAS_CONTROL
Action Option/Value
Set the target mode of the block to Auto
Enter upper range limit for the input variables
Enter lower range limit for input variables
Enter unit of the input variables
Auto e.g. 500 e.g. 0 e.g. kg/hr
Enter upper range limit for the output variables
Enter lower range limit for output variables
Enter unit of the output variables e.g. 50 e.g. 0 e.g. %
Set to "Swap" if characterizer is to be used in a backward control path.
e.g. No Swap (default)
E_CURVE_X.[1]
...
E_CURVE_X.[51]
E_CURVE_Y.[1]
...
E_CURVE_Y.[51]
CAS_CONTROL
Enter X values (input variable) of strapping table
• Values must rise or fall monotonically
• Values must be within the range defined by
X_RANGE
• For use in cascade, all 51 values must be entered
• If not used in cascade, unedited values are automatically set to infinity, which means they are not used
0 (kg/hr)
...
500 (kg/hr)
Enter Y values (output variable) of strapping table^
• Exacly the same number of values must be entered as for the X_CURVE.
• Values must be within the range defined by
Y_RANGE
• If SWAP_2 = TRUE, values must rise or fall monotonically
0 (%)
...
50 (%)
Set to "First" if to be cascaded, otherwise "None"
CCHAR Block 2... (when used in cascade)
First
MODE_BLK.Target
X_RANGE.EU_100
X_RANGE.EU_0
X_RANGE.UNITS_INDEX
Y_RANGE.EU_100
Y_RANGE.EU_0
Y_RANGE.UNITS_INDEX
SWAP_2
E_CURVE_X.[1]
...
E_CURVE_X.[51]
Set the target mode of the block to Auto
Enter upper range limit for the input variables
Enter lower range limit for input variables
Enter unit of the input variables
Auto e.g. 1000 e.g. 510 e.g. kg/hr
Enter upper range limit for the output variables
Enter lower range limit for output variables
Enter unit of the output variables
Enter X values (input variable) of strapping table
• Values must rise or fall monotonically
• Values must be within the range defined by
X_RANGE
• For use in intermdiate cascade, all 51 values must be entered
• If last in cascade, unedited values are automatically set to infinity, which means they are not used e.g. 100 e.g. 51 e.g. %
Set to "Swap" if characterizer is to be used in a backward control path.
e.g. No Swap (default)
510 (kg/hr)
...
1000 (kg/hr)
E_CURVE_Y.[1]
...
E_CURVE_Y.[51]
Enter Y values (output variable) of strapping table^
• Exacly the same number of values must be entered as for the X_CURVE.
• Values must be within the range defined by
Y_RANGE
• If SWAP_2 = TRUE, values must rise or fall monotonically
• Unedited values are automatically set to infinity, which means they are not used
51 (%)
...
100 (%)
Set to "Last" if last in cascade, otherwise "Intermediate" Last
Endress+Hauser 137
7 Calculation and Logic Blocks
Operating mode
Status
ControlCare Application Designer: Function Blocks
7.4.3
Block operation
The block normally operates in Auto mode and takes its input from the IN_1 and IN_2 .
If there is a block configuration error, the block switches to OOS (Out of Service).
When MODE_BLK.Target
is set to Man, the block output can be manipulated on-line by entering the desired status and value in the OUT_1 and/or OUT_2 parameter.
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
Operation can be checked on-line by viewing a number of parameters:
IN_1
IN_2
OUT_1
OUT_2
Input value and status used by the characterizer for path 1
Input value and status used by the characterizer for path 2.
Block output value and status for path 1
Block output value and status for path 2
The Signal Characterizer block supports the qualities Bad, Uncertain and Good NonCascade together with the associated sub- and limit statuses, see Chapter 2.3.2. When SWAP_2 = "Swap", the qualities Good Cascade and Bad Cascade are also supported.
" Status
Good NonCascade
Good Cascade
Uncertain
Bad NonCascade
Bad Cascade
Meaning
Block operating in standard mode; input and block execution "Good"
Block operating in control loop (SWAP_2 = "Swap"); input and block execution "Good"
Block operating in standard mode; input "Uncertain"
Block operating in standard mode; input "Bad" or block configuation error
Block operating in control loop (SWAP_2 = "Swap"); input "Bad" or block configuation error
7.4.4
Block Errors
On execution of the block, the device checks for correct configuration. Block errors are indicated in the BLOCK_ERR parameter.
Condition
Block Configuration Error
Reason
• Values in CURVE_X are not monotonic (throughout cascade)
• SWAP_2 is true and values in CURVE_Y are not monotonic
(throughout cascade)
• Less than 51 values in E_CURVE_X/E_CURVE_Y when
CAS_CONTROL options "First" or "Intermediate" selected
Input Failure/ process variable has BAD status • Upstream transducer block has status "Uncertain" or "Bad"
• Upstream Analog Output block is out of service
Out-of-Service • MODE_BLK.Target currently set to OOS
138 Endress+Hauser
ControlCare Application Designer: Function Blocks
Cascade Signal
Characterizer block
7 Calculation and Logic Blocks
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
OUT_1
OUT_2
X_RANGE
Y_RANGE
GRANT_DENY
IN_1
IN_2
SWAP_2
E_CURVE_X
E_CURVE_Y
UPDATE_EVT
BLOCK_ALM
CAS_CONTROL
7.4.5
Block parameters
Parameter Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
Description
See Chapter 2.3.4
Block mode, set MODE_BLK.Target to AUTO, CAS or RCAS
Block errors, see Chapter 6.1.9
Block output value and status for path 1
Block output value and status for path 2
0
0
0-100% IN value scaling to required engineering units, for HMI
0-100% OUT value scaling to required engineering units, for HMI
Access options, see Chapter 2.8.1
Input value and status used by the characterizer for path 1
No Swap Toggle to invert characteristic curve in path 2 when the block is linked to the back control path
INF
INF
Input value and status used by the characterizer for path 2.
X values (input variable) of characteristic in units of X_RANGE
Y values (output variable) of characteristic in units of
Y_RANGE
None
This alert is generated by any change to the static data.
Block alarms, see Chapter 2.9
Determines whether the block is cascaded with others and what position it has in the chain
• None: the block is used on its own
• First: the block is the first block in the cascade
• Intermediate: the block is at a position between the ends of the cascade
• Last: the block is the last block in the cascade
Legend: RO = Read Only
Endress+Hauser 139
7 Calculation and Logic Blocks ControlCare Application Designer: Function Blocks
7.5
Integrator
The Integrator function block is normally used to totalise flow, giving total mass or volume over a given time, or to totalise power, providing the total energy. It:
• integrates an analog rate value over time or
• accumulates pulses originating from pulse input blocks or other integrator blocks
The block may be used as a totalizer that counts up until reset or as a batch totalizer that has a setpoint, where the integrated or accumulated value is compared to pre-trip and trip settings, generating discrete signals when these settings are reached.
The integrated value may counted up, starting from zero, or down, starting from the trip value. The block has two flow inputs so that it can calculate and integrate net flow. This can be used to calculate volume or mass variation in vessels or as an optimizing tool for flow ratio control.
In order to determine the amount of uncertain or bad readings, the block integrates the variables with bad or bad and uncertain status separately. The values used in this second integration are the values with good status just before they went from good to bad or uncertain. The ratio of good to total counts determines the output status. Absolute values are used to avoid problems with changing signs.
In ControlCare Application Designer the Integrator block (IT block) is assigned the generic name
Device Tag-INTG-n . It can be found by expanding the appropriate device or Field Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 7-16.
REV_FLOW1
IN_1
REV_FLOW2
IN_2
RESET_
CONFIRM
RESET_IN
TIME_UNIT1
CONVERT RATE
TO UNITS/EXEC
CONVERT RATE
IN ACCUMULATION
TO UNITS/EXEC
PULSE_VAL1
TIME_UNIT2
CONVERT RATE
TO UNITS/EXEC
CONVERT RATE
IN ACCUMULATION
TO UNITS/EXEC
PULSE_VAL2
INTEG_OPTS
INPUT
TYPE
-1
INTEG_OPTS
INPUT
TYPE
-1
INTEG_TYPE
INTEG_OPTS (QUALITY)
PCT_GOOD_LIM
PCT_UNCERT_LIM
CLOCK_PER
UNIT_CONV
INTEG_OPTS
FLOW TYPE
ADD
INTEGRATE
TOTAL
RTOTAL
M_RESET
MANUAL
PRE_TRIP
COMPARE
SP MANUAL
COMPARE
INTEG_OPTS
CARRY
MANUAL
OP_CMD_INT
RESET
OUT
OUT_PTRIP
OUT_TRIP
Fig. 7-16: Schematic diagram of Integrator block
7.5.1
Functional description
The integrator block has two dual purpose inputs IN_1 and IN_2 that may receive a measurement per unit time (rate) or an accumulated number of pulses (accumulation). If IN_2 is not connected, no calculations are made along this path.
By default, the input type is rate. It can be changed to accumulation by selecting the integration options "Input 1 accumulate" and if used "Input 2 accumulate" in INTEG_OPTS .
Rate
Accum
Used when the variable connected to the input is e.g. kg/s, gal/h etc. The input may originate from the OUT value of a pulse input block or from the OUT value of an analog input block.
Used when the input originates from the OUT_ACCUM output of a pulse input block, which represents the accumulated number of pulse counts from a transducer, or from the output of another integrator block.
140 Endress+Hauser
ControlCare Application Designer: Function Blocks 7 Calculation and Logic Blocks
Input type: Rate (default) When the inputs are connected to rate outputs, the parameters TIME_UNIT1 and if required
TIME_UNIT2 are used to define the rate time unit. This allows the rate to be converted to units of mass, volume or energy per second. When the second input is in use, it may be necessary to convert it into the same units as the first. This is done by entering the conversion factor in
UNIT_CONV .
When multiplied by the block execution time each rate gives the mass, volume or energy increment per block execution, see Fig. 7-17.
Input type: Accum
Net flow
Endress+Hauser
IN_1 kg/h
TIME_UNIT1 sec: +1 min: +60 hour: +3600 day: +86400 kg/s x (block execution time) kg
Increment 1
IN_2 lb/min
TIME_UNIT2 sec: +1 min: +60 hour: +3600 day: +86400 lb/s
UNIT_CONV x conversion factor for units 2 to units 1
0.453 kg/lb kg/s x (block execution time) kg
Increment 2
Fig. 7-17: Increment calculation with rate input
When operating in "Accum" mode the input may be connected to the OUT_ACCUM parameter of an pulse input block or a the OUT parameter of another Integrator block. The connected block must count to 999,999 and have a maximum increment/decrement of 499,999 per cycle. The integrator block then determines the number of additional counts since the last execution of the block.
The variation of each input is then multiplied by the value, in engineering units, of each pulse as given by the parameters PULS_VAL1 and PULSE_VAL2 respectively. If necessary, a unit conversion factor can be entered in UNIT_CONV . The result is the increment in engineering units of e.g. mass ,volume or energy per block execution, see Fig. 7-18.
IN_1 counts
IN_2 counts
(Reading i) -
(Reading i-1) no. of pulses
PULS_VAL1 x (puls_val1) kg/pulse
Increment 1 kg
(Reading i) -
(Reading i-1) no. of pulses
PULS_VAL2 x (puls_val2) lb/pulse lb
UNIT_CONV x (conv. factor)
Increment 2 kg
Fig. 7-18: Increment calculation with accumulated input
The integrator considers a positive sign to be an indication of forward flow and negative sign to be an indication of reverse flow. Some flowmeters already indicate the forward and reverse flows by adding a sign to their output, others use a separate binary output. A binary signal can be connected to the inputs REV_FLOW1 and REV_FLOW2 , whereby a true status indicates a reverse flow condition.
The net flow over two inputs is obtained by adding the two increments. The net increment has a positive or negative sign to indicate the net flow direction. If the flow into and out of a tank is being monitored, for example, the inflow should be assigned a positive sign and the outflow a negative sign. This can be done, e.g. by connecting the outflow to IN_2 and assigning a negative value to the unit conversion parameter.
141
7 Calculation and Logic Blocks
Integration of inputs
Types of integration
Resetting the totals
ControlCare Application Designer: Function Blocks
The net flow direction to be considered in the totalization is set with the the INTEG_OPTS parameters "Flow forward" and "Flow reverse". The following totalizing options are available and apply after application of REV_FLOW1 or REV_FLOW2 .
Flow forware
Flow reverse
Any
Positive flows are totalized. The negative values are treated as zero.
• Select the option "Flow forward" in INTEG_OPTS only
Only negative flows are totalized. The positive values are treated as zero.
• Select the option "Flow reverse" in INTEG_OPTS only
Both positive and negative values are totalized.
• Select the both options "Flow forward" and "Flow reverse" in INTEG_OPTS
Three internal registers are used for the totalization.
Total
Atotal
Rtotal
The net increment is added every cycle, dependent on status.
• Total provides the value that can be read in the output OUT
The absolute value of the net increment is added every cycle, regardless of status.
• This value is used in the calculation of the percentage of good counts PCT_INCL.
The absolute value of the net increments with bad status (rejects) are added to this register.
• RTotal provides the value that can be read in the output RTOTAL and is used in the calculation of the percentage of good counts PCT_INCL
A further value, OUT_RANGE is used only for display of the totals by a host. The high and low range values of OUT_RANGE have no effect on the block.
The integration can start from zero and increase or it can start from a setpoint value (TOTAL_SP) and decrease. Reset may be automatic, periodic, or on demand. This is defined by the enumerated parameter INTEG_TYPE:
UP_AUTO
UP_DEM
DN_AUTO
DN_DEM
PERIODIC
DEMAND
PER&DEM
Counts up with automatic reset when TOTAL_SP is reached.
– Uses the TOTAL_SP, OUT_TRIP and OUT_PTRIP parameters
Counts up with demand reset.
Counts down with automatic reset when zero is reached
– Uses the TOTAL_SP, OUT_TRIP and OUT_PTRIP parameters
Counts down with demand reset
Counts up and is reset periodically according to CLOCK_PER.
– Disables the operator reset OP_CMD_INT
Counts up and is reset on demand
Counts up and is reset periodically or on demand
The block uses a discrete input RESET_IN to reset the internal integration registers. The operator can also send an operator command to reset the same registers by making OP_CMD_INT = RESET.
This is a momentary switch, which is turned off when the block is evaluated. Either method causes a reset of the registers.
A reset occurs at the end of the block execution after the totals have been adjusted. The block takes a snapshot of Total, Rtotal and TOTAL_SP prior to the reset and moves the values to the registers
STOTAL , SRTOTAL and SSP , respectively. This information is kept until the next reset.
The integrator rejects renewed reset requests for at least 5 seconds after a reset. This allows time for other devices to read the snapshot values before they are overwritten. If the option "Confirm Reset" in INTEG_OPTS is set, another reset is prevented from occuring until the value 1 has been written to RESET_CONFIRM . This procedure provides a guarantee that a host has recorded the snapshot values before the next reset occurs.
The number of resets is counted in the register N_RESET . This counter can not be written or reset.
It provides verification that the total has not been reset since N_RESET was last checked. The counter rolls over from 999999 to 0.
142 Endress+Hauser
ControlCare Application Designer: Function Blocks
Batch totalizer outputs
Status propagation
Percentage bad counts
7 Calculation and Logic Blocks
Reset always clears the internal registers Total, Atotal and Rtotal. If the option "UP_AUTO" or
"DN_AUTO" is selected in INTEG_TYPE and the option "Carry" is selected in INTEG_OPTS , however, a residual value beyond the trip value may be carried to the next integration. In this case,
TOTAL_SP is subtracted from Total, leaving the residual value.
The option "Generate reset event" in INTEG_OPTS causes an analog event to be generated at each reset. This provides a timestamp, the value of Total prior to the reset in units of OUT_RANGE and the substatus of OUT.
When the integration is counting up, it starts from zero and counts to TOTAL_SP ; When counting down, it starts from TOTAL_SP and counts to zero.
The discrete output OUT_TRIP indicates when the target count is reached.
The parameter PRE_TRIP allows a warning to be output in the form of the discrete signal
OUT_PTRIP . The conditions are summarized in the table below.
INTEG_TYPE OUT OUT_PTRIP
"UP_AUTO" or "UP_DEM" < TOTAL_SP - PRE_TRIP
TOTAL_SP - PRE_TRIP and
<TOTAL_SP
TOTAL_SP
"DOWN_AUTO" or
"DOWN_DEM"
> PRE_TRIP
PRE_TRIP and >0
= 0
"0" (False)
"1" (True)
"1" (True)
"0" (False)
"1" (True)
"0" (False)
OUT_TRIP
0" (False)
0" (False)
"1" (True)
0" (False)
0" (False)
0" (False)
OUT_TRIP remains set for five seconds after an automatic reset ( INTEG_TYPE options
"UP_AUTO" or "DOWN_AUTO"). If "Confirm Reset" has been selected in INTEG_OPTS and or
RESET_CONFIRM is connected, it remains set until the reset has been confirmed.
The input status is checked and handled as described below, whereby when two inputs are in use, the resulting status is the worst of the two. The limit status of the inputs is ignored..
–
–
INTEG_OPTS
–
Use Uncertain
–
Use Bad
Add zero if Bad
Input status Output status Remarks
Good NonCascade Good NonCascade Normal operation
Good Cascade
Uncertain
Good Cascade
Bad
Normal operation
Last good value is used as increment
Uncertain
Bad
Bad
Bad
Good
Bad
Good
Good
New value is used as increment
Last good value is used as increment
New value is used as increment
Zero is used as increment
If the block mode is Man, then the status of OUT , OUT_PTRIP , and OUT_TRIP will be Good
(NC) constant. If the option "Uncertain if Man" is selected in the STATUS_OPTS parameter, then the status of these three outputs will be Uncertain constant. No limits are applied to the output.
The parameter PCT_INCL indicates the percentage of good counts in the current total. This parameter can be limited by entering an allowable level of rejects in percent in the parameters
GOOD_LIM and UNCERT_LIM . These parameters influence the OUT status when the block is in Auto according to the table below:
Condition Output status
PCT_INCL
GOOD_LIM Good NonCascade
GOOD_LIM > PCT_INCL
UNCERT_LIM Uncertain
PCT_INCL < UNCERT_LIM Bad
Endress+Hauser 143
7 Calculation and Logic Blocks ControlCare Application Designer: Function Blocks
Control strategy: Rate
7.5.2
Block configuration
Fig. 7-19 shows a control strategy example together with the links that must be made between the blocks. Here, a vessel is filled with a quantity of Liquid 1 determined by PRE_TRIP , with the flowrate being measured by Flowmeter 1. Afterwards, Liquid 2 is added until TOTAL_SP is reached, the flowrate being measured by Flowmeter 2. The flowmeters indicate reverse flow by a discrete signal (DI links are omitted if flowmeter sends positive and negative flow values). The OUT value is used to record the filling of the vessel. The discrete outputs OUT_PTRIP amd OUT_TRIP are used e.g. to switch off pumps and close valves (can be connected to more than one DO block).
AI_1
Flowmeter 1
DI_1
OUT_D OUT
OUT_D
OUT
REV_FLOW1
IN_1
REV_FLOW2
IN_2
DI_2 AI_2 e.g. recorder or display
AO
INTG
OUT
IN
OUT_PTRIP
OUT_TRIP
OUT
IN_D IN_D
DO_1 DO_2
Flowmeter 2 e.g. pump or valve
Block configuration: Rate
Fig. 7-19: Links to be made for Integrator block for control strategy described above
The integration block is configured for the strategy in Fig 7-19 as follows:
Parameter
MODE_BLK.Target
TOTAL_SP
OUT_RANGE.EU_100
OUT_RANGE.EU_0
OUT_RANGE.UNITS_INDEX
TIME_UNIT1
TIME_UNIT2
UNIT_CONV
INTEG_TYPE
INTEG_OPTS
PRE_TRIP
Action
Set the target mode of the block to Auto
For batching, enter target quantity
Enter upper range limit for the input variables (HMI)
Enter lower range limit for input variables (HMI)
Enter unit of the input variables (HMI)
Select time units in which the rate 1 is measured:
• Select "days", "hours", "minutes" or "seconds"
Select time units in which the rate 2 is measured:
• Select "days", "hours", "minutes" or "seconds"
Enter conversion top match input 2 to input 1
• Default 1, in our case no entry required
Select type of integration and reset
• UP_AUTO: counts up, automatic reset
Select flow totalization type
• FORWARD: forward flow is counted
For batching, enter target quantity at which discrete output OUT_PTRIP is to switch
Option/Value
Auto e.g. 10 000 e.g. 10 000 e.g. 0 e.g. l e.g. min (for l/min) e.g. min (for l/min)
1
UP_AUTO
FORWARD e.g. 6 000
The block will totalize all sampled rates with a good status. Rates with bad and uncertain status can also be totalized if the appropriate option is set in INTEG_OPTS, see Chapter 7.5.3, Block operation.
144 Endress+Hauser
ControlCare Application Designer: Function Blocks 7 Calculation and Logic Blocks
Control strategy: Accum Fig. 7-20 shows a control strategy in which the Integrator block operates with the OUT_ACCUM parameter of a pulse input block. In this case, the Integrator is to count for a period determined by the clock or until stopped on demand. The demand reset signal is provided by a separate Discrete
Input block. The OUT value is e.g. used by an Analog Output block connected to a recorder or display. It is desired that both negative and positive flows (=TOTAL) as well as flows with uncertain and bad status (= ANY) should be counted.
PULS
OUT_ACCUM
IN_1
RESET_IN
INTG
OUT
AO e.g. recorder or display
DI
OUT_D
Fig. 7-20: Links to be made for the Integrator block for the control strategy described above
Block configuration: Accum The integration block is configured for the strategy in Fig 7-19 as follows:
Parameter
MODE_BLK.Target
OUT_RANGE.EU_100
OUT_RANGE.EU_0
OUT_RANGE.UNITS_INDEX
PULS_VAL1
INTEG_TYPE
INTEG_OPTS
CLOCK_PER
Action
Set the target mode of the block to Auto
Enter upper range limit for the input variables (HMI)
Enter lower range limit for input variables (HMI)
Enter unit of the input variables (HMI)
Enter value associated with each pulse
Option/Value
Auto e.g. 10 000 e.g. 0 e.g. l e.g. 100 (l)
Select type of integration and reset
• PER&DEM: counts up until reset at CLOCK per or by externally, whichever comes first
PER&DEM
Select flow totalization type
• FORWARD: forward flow is counted
• REVERSE: reverse flow is counted
• Use Uncertain: counts when input status "Uncertain"
• Use Bad: uses last "Good" or "Uncertain" value when status is "Bad"
Enter period of count until reset in seconds
FORWARD
REVERSE
Use Uncertain
Use Bad e.g. 3 600
Mode
7.5.3
Block operation
The block normally operates in Auto mode and takes its input from IN_1 and IN_2 .
If there is a block configuration error, the block switches to OOS (Out of Service).
When MODE_BLK.Target
is set to Man, the block output can be manipulated on-line by entering the desired status and value in OUT , RTOTAL , OUT_TRIP and OUT_PTRIP . No integration takes place. Each write to OUT or RTOTAL increments the N_RESET counter. When the block is switched to Auto again, the integration starts from the value set manually.
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller. An exception to this rule is the parameter OP_CMD_INT which can be used to reset the totalizer when the block is in Auto mode.
Endress+Hauser 145
7 Calculation and Logic Blocks
Status
Block errors
Integrator block
146
ControlCare Application Designer: Function Blocks
Operation can be checked on-line by viewing a number of parameters:
REV_FLOW1/
REV_FLOW2
IN_1/IN_2
OUT
OUT_PTRIP
OUT_TRIP
Value and status of reverse flow input: false = forward flow, true = reverse flow
Value and status of inputs 1 and 2
Value and status of totalizer
Value and status of pre-trip indicator: see batch totalizer outputs
Value and status of trip indicator: see batch totalizer outputs
When two inputs are in use, the worst status of the two is propagated to the output. The significance of the output status is indicated below.
Output status
Good NonCascade
Good Cascade
Uncertain
Bad
Meaning
Normal operation as configured
Normal operation as configured
• Block is in Man mode and "Uncertain if Man" selected in STATUS_OPTS
• PCT_INCL is limited and GOOD_LIM > PCT_INCL
UNCERT_LIM
• Block out of service
• One or both inputs have "Bad" or "Uncertain" status
• PCT_INCL is limited and PCT_INCL < UNCERT_LIM
Block errors are indicated in the BLOCK_ERR parameter
Condition
Block configuration error
Out-of-Service
Reason
• No option selected in INTEG_TYPE
• For rate input, no time unit entered in TIME_UNITx
• For batching, PRE_TRIP > TOTAL_SP
• MODE_BLK.Target currently set to OOS
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
TOTAL_SP
OUT
OUT_RANGE
GRANT_DENY
STATUS_OPTS
IN_1
IN_2
OUT_TRIP
OUT_PTRIP
TIME_UNIT1
TIME_UNIT2
UNIT_CONV
PULS_VAL1
PULS_VAL2
7.5.4
Block parameters
Parameter Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
0 -
999999
0
0/1
0
0
0
0
RO
RO
0
Description
See Chapter 2.3.4
0/1 0
–
–
1
0
0
Block mode, set MODE_BLK.Target to AUTO, CAS or RCAS
Block errors, see Chapter 6.1.9
Target count for batching
– For INTEG_TYPE options "UP_AUTO" or "DN_AUTO"
Block output value and status
Block output range and units for HMI
Access options, see Chapter 2.8.1
Status options, see Chapter 2.8.4 and Chapter 6.1.9
Value and status of input 1
Value and status of input 2
Value and status of trip (TOTAL_SP) indicator
– For INTEG_TYPE options "UP_AUTO" or "DN_AUTO"
Value and status of PRE_TRIP indicator
– For INTEG_TYPE options "UP_AUTO" or "DN_AUTO"
Rate units of input 1 (Days, hours, minutes, seconds)
– For INTEG_OPTS "Flow forward" and "Flow reverse"
Rate units of input 2 (Days, hours, minutes, seconds)
– For INTEG_OPTS "Flow forward" and "Flow reverse"
Conversion factor for input 2 to input 1 units
Pulse value for input 1
– For INTEG_OPTS "Input 1 accumulate"
Pulse value for input 2
– For INTEG_OPTS "Input 2 accumulate"
Endress+Hauser
ControlCare Application Designer: Function Blocks 7 Calculation and Logic Blocks
Parameter
REV_FLOW1
REV_FLOW2
RESET_IN
STOTAL
RTOTAL
SRTOTAL
SSP
INTEG_TYPE
INTEG_OPTS
CLOCK_PER
PRE_TRIP
N_RESET
PCT_INCL
GOOD_LIM
UNCERT_LIM
OP_CMD_INT
OUTAGE_LIM
RESET_CONFIRM
UPDATE_EVT
BLOCK_ALM
Legend: RO = Read Only
Valid range/
Options
0/1
Default value
Description
0/1
0/1
0 -
999999
0 - 100
0 - 100
RO
RO
RO
–
0 s
0
RO
RO
Value and status of reverse flow indicator input 1
– 0 = foward, 1 = reverse
Value and status of reverse flow indicator input 2
– 0 = foward, 1 = reverse
Value and status of external reset input 1
Snapshot of OUT value immediately prior to reset
Current total including bad and uncertain counts
– See 7.5.1, Status handling
Snapshot of RTOTAL immediately prior to reset
Snapshot of TOTAL_SP immediately prior to reset
– For INTEG_TYPE options "UP_AUTO" or "DN_AUTO"
Type of integration and reset
• UP_AUTO: counts up, automatic reset
• UP_DEM: counts up, external reset
• DN_AUTO: counts down, automatic reset
• DN_DEM: counts down, external reset
• PERIODIC: counts up until reset at CLOCK_PER
• DEMAND: counts up until externally reset
• PER&DEM: counts up until reset at CLOCK per or by externally, whichever comes first
Integration options, multiple selections possible
• Input 1 accumulate: accumulated value at input 1
• Input 2 accumulate: accumulated value at input 2
• Flow forward: forward flow values counted
• Flow reverse: reverse flow values counted
• Use Uncertain: values counted when status Uncertain
• Use Bad: last good value counted when status Bad
• Carry: residual value carried over to next count cycle
(For INTEG_TYPE options "UP_AUTO" or "DN_AUTO")
• Add zero if bad: zero counted when status Bad
• Confirm reset: next count cycle begins only after reset has been confirmed
• Generate reset event: event generated on reset
Period of count in seconds
– For INTEG_TYPE options "PERIODIC" and "PER&DEM"
Intermediate target count for batching
– For INTEG_TYPE options "UP_AUTO" or "DN_AUTO"
Number of resets made since commissioning of project
Percentage of good counts in total
Limit value for PLC_INCL, see 7.5.1, Percentage bad counts
Limit value for PLC_INCL, see 7.5.1, Percentage bad counts
Internal command reset command
• Select "Reset" in Auto mode
Maximum tolerated duration of power failure
• Not supported
Value and status of external reset confirmation input
This alert is generated by any change to the static data.
Block alarms, see Chapter 2.9
Endress+Hauser 147
7 Calculation and Logic Blocks ControlCare Application Designer: Function Blocks
7.6
Analog Alarm
The Analog Alarm block provides alarm condition reporting on an analog output of any block. Alarm conditions include high-high, high, low, and low-low alarms. The associated limits may be userentered or computed based on gains and biases from a process setpoint input, thus providing dynamic deviation alarming. A discrete output is provided which indicates the existence of one or more (configurable) alarm conditions.
An option to temporarily expand alarm limits after a setpoint change is provided. In addition, a new alarm condition may be ignored for a specified period of time after detection to avoid nuisance alarm reporting. The block can also be used as a comparator by comparing the input value to the process setpoint.
In ControlCare Application Designer the Analog Alarm block (AAL block) is assigned the generic name Device Tag-AALM-n . It can be found by expanding the appropriate device or Field
Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 7-21.
User-entered limits
IN
PSP
PV_FTIME
CONDITIONING
PV
MANUAL
AUTO
ALARM
TEST
SUMMARY
LOGIC
PRE_OUT_ALM
OUT_ALM_SUM
HI_GAIN
LO_GAIN
HI_HI_BIAS
HI_BIAS
LO_BIAS
LO_LO_BIAS
EXPAND_UP
EXPAND_DN
ALM_RATE_UP
ALM_RATE_DN
IGNORE_TIME
MANUAL
AUTO
HI_HI_LIM/X
HI_LIM/X
LO_LIM/X
LO_LO_LIM/X
OUT
OUT_ALM
Fig. 7-21: Schematic diagram of Analog Alarm block
7.6.1
Functional description
The Analog Alarm block has two inputs, IN , which is connected to an analog output of an upstream block and PSP , which may be connected to a process setpoint input. The latter is used to compute alarm limits which may also be dynamically adjusted on a change in process setpoint. After conditioning with a time filter PV_FTIME , the analog input value becomes the process value PV , which is made available to downstream blocks at the analog output OUT . The parameter
OUT_RANGE is used make the range and engineering units of OUT to a HMI.
In Auto mode, the process value PV is also alarmed, whereby the current value is compared to userentered or computed limits. OUT_ALM_SUM determines which alarm conditions are to be signalled and a discrete signal PRE_OUT_ALM is generated for output as OUT_ALM . This has the value "0" (false) when no alarms are present and "1" (true) when one or more limits have been violated.
When used as a standard alarm block, the user may enter up to four limits in the engineering units of the incoming IN signal, LO_LO_LIM , LO_LIM , HI_LIM and HI_HI_LIM, together with an alarm hysteresis ALARM_HYS as a percentage of the input span. Each alarm can be assigned a priority in the parameters LO_LO_PRI , LO_PRI , HI_PRI and HI_HI_PRI. The parameter
ACK_OPTION enables automatic acknowledgement of the alarms, which must otherwise be individually acknowledged in the associated LO_LO_ALM , LO_ALM , HI_ALM and
HI_HI_ALM parameters. A full description of alert handling is to be found in Chapter 2.9.
148 Endress+Hauser
ControlCare Application Designer: Function Blocks
Computed limits
Alarm limit expansion
7 Calculation and Logic Blocks
When the process setpoint PSP is connected to the block, alarm limits may be dynamically calculated. The operating limits (with suffix "X") are calculated from specified gains and biases as follows:
• HI_HI_LIMX = PSP * HI_GAIN + HI_HI_BIAS + EXPAND_UP
• HI_LIMX = PSP * HI_GAIN + HI_BIAS + EXPAND_UP
• LO_LIMX = PSP * LO_GAIN - LO_BIAS - EXPAND_DN
• LO_LO_LIMX = PSP * LO_GAIN - LO_LO_BIAS - EXPAND_DN
The operating limits default to HI_HI_LIM , HI_LIM , LO_LIM and LO_LO_LIM respectively if any parameter is undefined.
In order to avoid nuisance alarms, the effective alarm limits are temporarily expanded on step setpoint change. High alarm limits are increased by a calculated term, EXPAND_UP and low alarm limits are decreased by a calculated term, EXPAND_DN . The expansion terms correspond to the absolute value of the step change.
In order to avoid alarms on the initial change in normal and over-damped process responses and on overshooting or ringing in under-damped process, the expansions decay toward the base limits at a rate determined by ALM_RATE_UP and ALM_RATE_DN . Fig. 7-22 illustrates the function.
Ignoring alarm conditions
ALM_RATE_DN
HI_HI_LIMX
HI_LIMX
PSP
LO_LIMX
LO_LO_LIMX
PV
ALM_RATE_UP
HI_HI_LIMX
HI_LIMX
PSP
LO_LIMX
LO_LO_LIMX
Time
Fig. 7-22: Alarm limit expansion on step change in process setpoint
The expansion feature may be suppressed in the upwards or downwards direction by either not entering a value in the parameters ALM_RATE_UP and ALM_RATE_DN or setting them to zero.
The existence of a new alarm condition may be temporarily ignored by setting the IGNORE_TIME parameter to the number of seconds to disregard the alarm. Both the reporting of the alarm and the possible change to PRE_OUT_ALM will be ignored during this time. This parameter does not delay the clearing of the existence of the alarm on return-to-normal. If the alarm condition does not persist for IGNORE_TIME seconds, it will not be reported.
Endress+Hauser 149
7 Calculation and Logic Blocks ControlCare Application Designer: Function Blocks
Alarm summary
Alarm acknowledgement
Status propagation
The OUT_ALM_SUM parameter specifies the alarm conditions to be signalled at the OUT_ALM output. The following options can be selected:
Option
OUT_ALM_SUM
ANY
LOWs
HIGHs
LEVEL1
LEVEL2
LO_LO
LO
HI
HI_HI
NONE
HI_HI_ALM
X
X
X
X
Alarm conditions included
HI_ALM LO_ALM
X X
X
X
X X
X
X
LO_LO_ALM
X
X
X
X
Current alarms are summarized in the ALARM_SUM parameter. If the user has opted to acknowledge individual alarms, this must be done in the corresponding parameter xxx_ALM. The structure of the alarm parameter is as shown below:
Parameter
ALARM_SUM
HI_HI_ALM
HI_ALM
LO_ALM
LO_LO_ALM
Attribute Value
UNACKNOWLEDGED As read or entered
ALARM_STATE As read
TIME_STAMP
SUB_CODE
VALUE
As read
As read
As read
Description
Indicates acknowledgement of current alert state: i.e.
Undefined, Acknowledged, Unacknowledged
• User can acknowledge via this parameter
Indicates of whether the alert is active and reported.
The alarm state is cleared when the block goes to
Out of Service mode. Possible values are:
• Clear-Reported, Clear-Not Reported,
Active-Reported, Active-Not Reported
Indicates time when the alarm state was detected.
The value is maintained until alert confirmation has been received.
Displays number specifying the cause of the alert
The value of the associated parameter at the time the alert was detected
The status of the OUT value is checked and handled as described below..
STATUS_OPTS
–
IN status
Good
OUT status
Good
Remarks
IN filtered and used as PV => OUT
Use Uncertain as Good Uncertain
– Bad, Uncertain
Uncertain
Bad, Uncertain
IN filtered and used as PV => OUT
IN not filtered, last usable PV => OUT
The status of the OUT_ALM depends upon the status of both IN and PSP , see below:
STATUS_OPTS
–
–
IN status
– Good
Use Uncertain as Good Good
Use Uncertain as Good Uncertain
– Good
PSP status
Good
Uncertain
OUT_ALM status
Good
Uncertain
Good Uncertain
Bad, Uncertain Bad
Bad, Uncertain Good Bad
Bad, Uncertain Bad, Uncertain Bad
Remarks
Alarm test performed
Alarm test performed
Alarm test performed
Alarm test not performed
Alarm test not performed
Alarm test not performed
While the alarm test is not being performed, existing alarms will not be cleared and new alarms will not be generated. Alarm conditions existing prior to the unusable status may still be acknowledged.
When operating in manual mode, the limit status of OUT_ALM is set to double-limited.
150 Endress+Hauser
ControlCare Application Designer: Function Blocks
Control strategy: user limits
7 Calculation and Logic Blocks
7.6.2
Block configuration
Fig. 7-23 shows a control strategy example together with the links that must be made between the blocks. Here, an analog value, e.g. the level of liquid in a vessel, is monitored for two limits. When the level reaches the high limit, the inlet valve is to be closed and the outlet valve opened. The outlet valve is to be closed and the inlet valve opened when the level reaches the low limit. Alarms are to be automatically acknowledged. The control logic is done in a discrete hybrid block, which outputs to a Multiple Discrete Output block connected to the valves via e.g. a relay module. An Analog
Output block connects the analog value to a display or recorder which displays the current level in the tank.
e.g. level measuring device
OUT
AI
IN
HI_LIM
OUT
AALM_1
IN
LO_LIM
OUT
AALM_2
IN e.g. recorder or display
OUT
AO
OUT_ALM OUT_ALM
IN_D1 IN_D2
OUT_D1
HY_MD_IO IN_D1
OUT_D2
IN_D2
MDO e.g. to I/O module and valve
Block configuration: user limits
Fig. 7-23: Links to be made for Analog Alarm block for control strategy described above
The two Analog Alarm blocks are configured for the strategy in Fig 7-23 as follows:
Parameter
Block AALM_1
MODE_BLK.Target
OUT_RANGE.EU_100
OUT_RANGE.EU_0
OUT_RANGE.UNITS_INDEX
PV_FTIME
ALARM_HYS
HI_LIM
Block AALM_2
MODE_BLK.Target
OUT_RANGE.EU_100
OUT_RANGE.EU_0
OUT_RANGE.UNITS_INDEX
PV_FTIME
ALARM_HYS
LO_LIM
Action Option/Value
Set the target mode of the block to Auto
Enter upper range limit for the input variables (HMI)
Enter lower range limit for input variables (HMI)
Enter unit of the input variables (HMI)
Auto e.g. 100 e.g. 0 e.g. %
Enter time constant in seconds for 1st. order damping e.g. 3
Enter alarm hysteresis in % of OUT_RANGE e.g. 1
Enter limit of HI alarm in engineering units e.g. 90
Set the target mode of the block to Auto
Enter upper range limit for the input variables (HMI)
Enter lower range limit for input variables (HMI)
Enter unit of the input variables (HMI)
Auto e.g. 100 e.g. 0 e.g. %
Enter time constant in seconds for 1st. order damping e.g. 0
Enter alarm hysteresis in % of OUT_RANGE e.g. 1
Enter limit of LO alarm in engineering unit e.g. 10
Endress+Hauser 151
7 Calculation and Logic Blocks
Control strategy: computed limits
ControlCare Application Designer: Function Blocks
Fig. 7-24 shows a control strategy example together with the links that must be made between the blocks. Here, a liquid is to be heated and maintained with a set temperature band (Setpoint
5°C) by an immersion heater. Control is by simply switching on and off the heater when the temperature leaves the set band, the logic being done in a discrete hybrid block. The setpoint is set remotely, in this case by a constant block and can change, hence the limits must be dynamic. The temperature is measured by a RTD thermometer and monitored by a recorder or display. temperature measuring device
AI
OUT
IN
HI_LIM
OUT
AALM_1 temperature setpoint
CT
IN
LO_LIM
OUT
AALM_2
PSP
OUT_ALM OUT_ALM
IN_D1 IN_D2
HY_MD_IO
OUT_D1
IN_D1 MDO
IN e.g. recorder or display
OUT
AO e.g. to I/O module and heater
Block configuration: computed limits
Fig. 7-24: Links to be made for Analog Alarm block for control strategy described above
The two Analog Alarm blocks are configured for the strategy in Fig 7-24 as follows:
Parameter
Block AALM_1
MODE_BLK.Target
OUT_RANGE.EU_100
OUT_RANGE.EU_0
OUT_RANGE.UNITS_INDEX
PV_FTIME
HI_GAIN
HI_BIAS
ALM_RATE_UP
Block AALM_2
MODE_BLK.Target
OUT_RANGE.EU_100
OUT_RANGE.EU_0
OUT_RANGE.UNITS_INDEX
PV_FTIME
LO_GAIN
LO_BIAS
ALM_RATE_DN
Action Option/Value
Set the target mode of the block to Auto
Enter upper range limit for the input variables (HMI)
Enter lower range limit for input variables (HMI)
Enter unit of the input variables (HMI)
Auto e.g. 200 e.g. 0 e.g. °C
Enter time constant in seconds for 1st. order damping e.g. 3
Enter gain value for HI limit 1
Enter bias value for HI limit
Enter ramp rate for HI limits in engineering units/s
5 e.g. 2
Set the target mode of the block to Auto
Enter upper range limit for the input variables (HMI)
Enter lower range limit for input variables (HMI)
Enter unit of the input variables (HMI)
Auto e.g. 200 e.g. 0 e.g. °C
Enter time constant in seconds for 1st. order damping e.g. 0
Enter gain value for HI limit 1
Enter bias value for HI limit
Enter ramp rate for HI limits in engineering units/s
5 e.g. 2
The configured blocks maintain the temperature within band of
5°C on a change of setpoint.
152 Endress+Hauser
ControlCare Application Designer: Function Blocks
Mode
Status
Block errors
7 Calculation and Logic Blocks
7.6.3
Block operation
The block normally operates in Auto mode and takes its input from IN and, if connected, PSP .
When MODE_BLK.Target
is set to Man, the block output can be manipulated on-line by entering the desired status and value in OUT and OUT_ALM .
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
Operation can be checked on-line by viewing a number of parameters:
IN
PSP
HI_HI_LIMX
HI_LIMX
LO_LIMX
LO_LO_LIMX
OUT
OUT_ALM
OUT_TRIP
Value and status of input
Value and status of process setpoint, if connected
Value and status of dynamic HI_HI limit, if used
Value and status of dynamic HI limit, if used
Value and status of dynamic LO limit, if used
Value and status of dynamic LO_LO limit, if used
Value and status of analog output
Value and status of discrete alarm output
Value and status of trip indicator: see batch totalizer outputs
When two inputs are in use, the worst status of the two is propagated to the output. The significance of the output status is indicated below.
OUT/OUT_ALM status
Good
Uncertain
Bad
Meaning
Normal operation as configured
Block has an "Uncertain" input and "Use Uncertain as Good " selected in STATUS_OPTS
• Block out of service
• One or both inputs have "Bad" or "Uncertain" status
Block errors are indicated in the BLOCK_ERR parameter
Condition
Out-of-Service
Reason
• MODE_BLK.Target currently set to OOS
Endress+Hauser 153
7 Calculation and Logic Blocks
Analog Alarm block
ControlCare Application Designer: Function Blocks
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
OUT
OUT_RANGE
GRANT_DENY
STATUS_OPTS
PV_FTIME
IN
PSP
HI_GAIN
LO_GAIN
HI_HI_BIAS
HI_BIAS
LO_BIAS
LO_LO_BIAS
PRE_OUT_ALM
OUT_ALM
OUT_ALM_SUM
ALM_RATE_UP
ALM_RATE_DN
EXPAND_UP
EXPAND_DN
IGNORE_TIME
UPDATE_EVT
BLOCK_ALM
ALARM_SUM
ACK_OPTION
7.6.4
Block parameters
Parameter
ALARM_HYS
HI_HI_PRI
HI_HI_LIM
HI_HI_LIMX
HI_PRI
HI_LIM
HI_LIMX
LO_PRI
LO_LIM
LO_LIMX
LO_LO_PRI
LO_LO_LIM
LO_LO_LIMX
HI_HI_ALM
HI_ALM
LO_ALM
LO_LO_ALM
Legend: RO = Read Only
Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
0
0
0
0
0 s
RO
RO
Positive
Positive
Positive
Positive
RO
INF
INF
INF
INF
INF
INF
Description
See Chapter 2.3.4
RO
RO
Positive
0, 1
0 to 50 % 0.5%
0 to 15
+INF
0 to 15
0 to 15
0 to 15
0
0
0
0
+INF
-INF
-INF
Block mode, set MODE_BLK.Target to AUTO, CAS or RCAS
Block errors, see Chapter 6.1.9
Block output value and status
Block output range and units for HMI
Access options, see Chapter 2.8.1
Status options, see Chapter 2.8.4 and Chapter 7.6.1
Time constant (s) of a single exponential filter for process value
Value and status of input
Value and status of process set point
Gain value for calculation of dynamic HI and HI_HI limits
Gain value for calculation of dynamic LO and LO_LO limits
Bias value for calculation of dynamic HI_HI limit
Bias value for calculation of dynamic HI limit
Bias value for calculation of dynamic LO limit"
Bias value for calculation of dynamic LO_LO limit"
Display value for OUT_ALM value and status in Auto mode
Display value for actual OUT_ALM value and status
Selection parameter for OUT_ALM signal conditions
Ramp rate for HI limits in engineering units/s
Ramp rate for HI limits in engineering units/s
Calculated shift of HI and HI_HI limits on PSP step
Calculated shift of LO and LO_LO limits on PSP step
Time delay between detection and reporting of limit violation
Alert generated by any change to the static data.
Block alarms, see Chapter 2.9
Alarm summary, see Chapter 2.9
See Chapter 2.9
• 0: Auto ACK Disable
• 1: Auto ACK Enable
Alarm hysteresis in % of OUT_SCALE, see Chapter 2.9
Priority of the HI_HI alarm, see Chapter 2.9
Setting of HI_HI alarm in engineering units, see Chapter 2.9.
Computed HI_HI operating limit
Priority of the HI alarm, see Chapter 2.9
Setting of HI alarm in engineering units, see Chapter 2.9.
Computed HI operating limit
Priority of the LO alarm, see Chapter 2.9.
Setting of LO alarm in engineering units, see Chapter 2.9.
Computed LO operating limit
Priority of the LO_LO alarm, see Chapter 2.9
Setting of LO_LO alarm in engineering units, see Chapter 2.9
Computed LO_LO operating limit
Status of HI_HI alarm and its associated time stamp.
Status of HI alarm and its associated time stamp.
Status of LO alarm and its associated time stamp.
Status of LO_LO alarm and its associated time stamp.
154 Endress+Hauser
ControlCare Application Designer: Function Blocks 7 Calculation and Logic Blocks
7.7
Enhanced Analog Alarm
The Enhanced Analog Alarm block differs from the Analog Alarm block in one aspect only. It has an additional discrete output OUT_D which maps the OUT_ALM output. The OUT_D signals can be inverted, hoever, when the INVERT_OPTS parameter is set to "4".
In ControlCare Application Designer the Enhanced Analog Alarm block is assigned the generic name Device Tag-EAAL-n . It can be found by expanding the appropriate device or Field Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 7-25.
Additional parameters
IN
PSP
PV_FTIME
CONDITIONING
PV
MANUAL
AUTO
ALARM
TEST
HI_HI_LIM/X
HI_LIM/X
LO_LIM/X
LO_LO_LIM/X
Summary
Logic
HI_GAIN
LO_GAIN
HI_HI_BIAS
HI_BIAS
LO_BIAS
LO_LO_BIAS
EXPAND_UP
EXPAND_DN
ALM_RATE_UP
ALM_RATE_DN
IGNORE_TIME
PRE_OUT_ALM
OUT_ALM_SUM
Status
Check
MANUAL
AUTO
INV_S
OUT
Parameter
OUT_D
INVERT_OPTS
Legend: RO = Read Only
Fig. 7-25: Schematic diagram of Enhanced Analog Alarm block
Valid range/
Options
Default value
Description
Display value for actual OUT_D value and status
Inverts OUT_D signals when set to "4" (=Invert)
OUT_D
OUT_ALM
Endress+Hauser 155
7 Calculation and Logic Blocks ControlCare Application Designer: Function Blocks
7.8
Input Selector
The Input Selector block provides selection of four inputs, normally from analog input blocks, and generates an output based on the configured action. It supports two actions:
• Internal signal selection, based on maximum, minimum, middle, average and ‘first good’ algortithms
• External signal selection using the the DISABLE_n parameter.
The DISABLE_N parameter can also be used in Case 1 to generate a validated priority selection.
The block supports the concept of a middle selection. Although the normal configuration for this feature would be with three signals, the block will generate an average of the middle two if four signals are configured or the average of two if three are configured and a bad status is passed to one of the inputs. Logic is provided for handling uncertain and bad signals in conjunction with configured actions.
The intended application of this block is to provide control signal selection in the forward path only, therefore, no back calculation support is provided.
In ControlCare Application Designer the Input Selector block (IS Block) is assigned the generic name Device Tag-ISEL-n . It can be found by expanding the appropriate device or Field Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 7-26.
IN_1
DISABLE_1
IN_2
DISABLE_2
IN_3
DISABLE_3
IN_4
DISABLE_4
OP_SELECT
SELECTOR OUT
SELECTED
Fig. 7-26: Schematic diagram of Input Selector block
7.8.1
Functional description
The Analog Alarm block has four inputs, IN_1 to IN_4 , which may be connected to the OUT outputs of upstream Analog Input blocks. Four discrete inputs DISABLE_1 to DISABLE_4 , which may be connected to discrete signals, control the signal processing of the associated analog input. If
DISABLE_n is true, the corresponding signal is not used in the execution of the block.
After execution of the chosen selection algorithm, the result is made available at the OUT output.
The parameter OUT_RANGE is used make the range and engineering units of OUT known to a
HMI.
The analog input OP_SELECT allows the selection algorithm or a single input to be selected externally. SELECTED outputs an integer that normally corresponds to the number of the input used.
The block is not intended for use with controller outputs and has no back calculation support or propagation of control status values.
156 Endress+Hauser
ControlCare Application Designer: Function Blocks
Selection algorithm
Status propagation
7 Calculation and Logic Blocks
The selection process is controlled by the external parameter OP_SELECT or the internal parameter SELECT_TYPE .
• If OP_SELECT is zero or no signal is connected, the selection is made in SELECT_TYPE
• If OP_SELECT is greater than zero, then this value is used to select the Input (1 to 4) to be used as output by the block. The selection made by the SELECT_TYPE algorithm is then ignored.
The options available in SELECT_TYPE / OP_SELECT are shown below. MIN_GOOD allows the operator to set a limit on the number of bad signals allowed for a particular algorithm
Meaning SELECT_TYPE when
OP_SELECT = 0
No Selection
First Good
Minimum
Maximum
Middle
Average
All inputs bad, or number of Good inputs < MIN_GOOD
– If OP_SELECT = 0, the selection is always made with SELECT_TYPE
The value of the first usable input is transferred to the output of the block.
– SELECTED is set to the number of the input used
The usable inputs are sorted by value and the lowest value is transferred to the output of the block.
– SELECTED is set to the number of the input used
The usable inputs are sorted by value and the highest value is transferred to the output of the block.
– SELECTED is set to the number of the input used
The usable inputs inputs are sorted by value and the highest and lowest values discarded. If two values are remaining or there were only two values originally, their average is computed. The value is transferred to the output of the block.
– SELECTED is set to zero if an average was used, otherwise it contains the number of the input with the middle value.
The average of the usable inputs is calculated and the value is transferred to the output of the block.
– SELECTED is set to the number of inputs used in the average.
The block checks the status of the inputs before processing them. Inputs with status Good or
Uncertain are processed, those with status Bad are ignored. The table below summarizes the status of OUT under various conditions. The SELECTED output always has Good(NC) status, unless the block is out of service..
–
–
STATUS_OPTS
–
IN status
Good
Good
Uncertain
Usable inputs OUT status
>MINGOOD Good
<MINGOOD Bad
>MINGOOD Uncertain
–
–
Use Uncertain as Good Uncertain
– Uncertain
–
Bad
All Bad
Non connected
>MINGOOD Good
<MINGOOD Bad
<MINGOOD
–
–
Bad
Bad
Bad
Remarks
Block executed
Block not executed
Block executed
Block executed
Block not executed
Block not executed
Block not executed, SELECTED = 0
Block not executed, SELECTED = 0
When the block is operating in Man mode, the block is not executed and the following applies:
STATUS_OPTS
–
OUT status
As entered
Use Uncertain if Man Uncertain
Remarks
Block not executed
Block not executed
Endress+Hauser 157
7 Calculation and Logic Blocks ControlCare Application Designer: Function Blocks
Control strategy: internal priority selection
7.8.2
Block configuration
Fig. 7-27 shows a control strategy example for internal priority selection together with the links that must be made between the blocks. Here, a critical temperature measuring point has two redundant temperature transmitters. The first valid reading is taken for the subsequent control task.
The application can be upgraded to a validated priority selection, in that the disable signals
DISABLE_1 and DISABLE_2 are used to control the status of the associated inputs. When
DISABLE_n is true, the IN_n is disabled and will not be considered by the "First Good" algorithm.
temperature transmitter 1
OUT
AI_1
IN_1
IN_2
ISEL
OUT
IN e.g. to PID Block temperature transmitter 2
OUT
AI_2
Block configuration: internal priority selection
Control strategy: externally switched input
Fig. 7-27: Links to be made for Input Selector block for control strategy described above
The Input Selector block is configured for the strategy in Fig 7-27 as follows:
Parameter
MODE_BLK.Target
OUT_RANGE.EU_100
OUT_RANGE.EU_0
OUT_RANGE.UNITS_INDEX
SELECT_TYPE
Action
Set the target mode of the block to Auto
Enter upper range limit for the input variables (HMI)
Enter lower range limit for input variables (HMI)
Enter unit of the input variables (HMI)
Enter block algorithm, here "First Good"
Option/Value
Auto e.g. 200 e.g. 0 e.g. °C
First Good
Fig. 7-28 shows a control strategy example for switched input together with the links that must be made between the blocks. Here, a process is fed by two tanks which are used alternatively, i.e. first one is emptied then the other. The temperature of the fluid in each tank is to be used in a feedforward control loop. The stream selection is made in the HMI, which uses a hybrid discrete
I/O block to generate the switching signals. The outputs OUT_D1 and OUT_D2 indicate which tank is being used (= 0 when in use).
temperature transmitter 1
AI_1
OUT temperature transmitter 2
AI_2
OUT
IN_1
DISABLE_1
IN_2
DISABLE_2
ISEL
OUT
FF_VAL to PID Block
HMI
OUT_D1
HY_MD_IO
OUT_D2
Fig. 7-28: Links to be made for Input Selector block for control strategy described above
158 Endress+Hauser
ControlCare Application Designer: Function Blocks 7 Calculation and Logic Blocks
Block configuration: externally switched input
The Input Selector block is configured for the strategy in Fig 7-20 as follows:
Parameter
MODE_BLK.Target
OUT_RANGE.EU_100
OUT_RANGE.EU_0
OUT_RANGE.UNITS_INDEX
SELECT_TYPE
Action
Set the target mode of the block to Auto
Enter upper range limit for the input variables (HMI)
Enter lower range limit for input variables (HMI)
Enter unit of the input variables (HMI)
Make no selection in this parameter
Option/Value
Auto e.g. 200 e.g. 0 e.g. °C
Not Selected
Mode
Status propagation
Block errors
7.8.3
Block operation
The block normally operates in Auto mode and, depending on configuration, takes its input from one or more inputs IN_n .
When MODE_BLK.Target
is set to Man, the block output can be manipulated on-line by entering the desired status and value in OUT . The status will be automatically set to Man if "Use Uncertain if Man" has been selected in STATUS_OPTS
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
Operation can be checked on-line by viewing a number of parameters:
IN_n
DISABLE_n
OP_SELECT
OUT
SELECTED
Value and status of input value 1 to 4
Value and status of input disabling signal 1 to 4.
Value and status of external selection parament
Value and status of block output
Integer indicating which input has been selected
When two inputs are in use, the worst status of the two is propagated to the output. The significance of the output status is indicated below.
OUT status
Good
Uncertain
Bad
Meaning
Normal operation as configured
• Block has an "Uncertain" input and "Use Uncertain as Good " selected in STATUS_OPTS
• Block in Man mode and "Use Uncertain if Man" selected in STATUS_OPTS
• Block out of service
• One or both inputs have "Bad" or "Uncertain" status
• Number of usuable inputs < MINGOOD
Block errors are indicated in the BLOCK_ERR parameter
Condition
Out-of-Service
Block Configuration Error
Reason
• MODE_BLK.Target currently set to OOS
• SELECT_TYPE parameter has an invalid value
Endress+Hauser 159
7 Calculation and Logic Blocks
Input Selector block
ControlCare Application Designer: Function Blocks
7.8.4
Block parameters
Parameter
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
OUT
OUT_RANGE
GRANT_DENY
STATUS_OPTS
PV_FTIME
IN_1
IN_2
IN_3
IN_4
DISABLE_1
DISABLE_2
DISABLE_3
DISABLE_4
SELECT_TYPE
MIN_GOOD
OP_SELECT
UPDATE_EVT
BLOCK_ALM
Legend: RO = Read Only
RO
RO
RO
RO
RO
RO
RO
RO
0 - 5
Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
0
0
0
0
0 s
Description
See Chapter 2.3.4
Block mode, set MODE_BLK.Target to AUTO, CAS or RCAS
Block errors, see Chapter 6.1.9
Block output value and status
Block output range and units for HMI
Access options, see Chapter 2.8.1
Status options, see Chapter 2.8.4 and Chapter 7.6.1
Time constant (s) of a single exponential filter for process value
Value and status of input 1
Value and status of input 2
Value and status of input 3
Value and status of input 4
Value and status of discrete disable signal for input 1
Value and status of discrete disable signal for input 2
Value and status of discrete disable signal for input 3
Value and status of discrete disable signal for input 4
Selection parameter for block algorithm
• 0: No Selection
• 1: First Good
• 2: Minimum
• 3: Maximum
• 4: Middle
• 5: Average
Minimum number of good outputs allowed by user for selected algorithm
Value and status of external selection parameter for block algorithm:
– When >0, this parameter overrides SELECT_TYPE
Alert generated by any change to the static data.
Block alarms, see Chapter 2.9
160 Endress+Hauser
ControlCare Application Designer: Function Blocks 7 Calculation and Logic Blocks
7.9
Setpoint Ramp Generator (SPG)
The Setpoint Ramp Generator block generates an output value that changes with time. It is normally used to generate a setpoint for a PID block in applications such as temperature control, batch reactors, etc., where controlled temperature ramps are required during the process.
The block provides a “guaranteed soak” function that stops the timer when the deviation between the generated setpoint and an external variable is larger than a configured value. When operating in manual mode, the operator can pause the timer, select one point on the profile, advance or return the position in time. The first point of the profile can be balanced to the BKCAL_OUT value of a control block.
In ControlCare Application Designer the Setpoint Ramp Generator block (SPG Block) is assigned the generic name Device Tag-SPG-n . It can be found by expanding the appropriate device or Field
Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 7-29.
Ramp generator
Endress+Hauser
PAUSE
BKCAL_IN
START
RESET_IN
DV_HI_LIM
DV_LO_LIM
Compare
OP_CMD_SPG
PAUSE
Setpoint
Time
AUTOCYCLE
DURATION
START_VAL
START_TYPE
SETPOINT
Man
Man
Man
Man
OUT
STEP_POSN
TIME_POSN
TIME_POSN_T
Fig. 7-29: Schematic diagram of Setpoint Ramp Generator block
7.9.1
Functional description
The core element of the Setpoint Ramp Generator block is the ramp generator, which maps the desired the setpoint movement. Up to ten periods can be defined, each characterized by:
• a start value, START_VAL [x] ,
• an end value START_VAL [x+1] that is also the starting value of the next time period
• and a time duration, TIME_DURATION [x] – set to zero for the true "end value"
The parameter TIME_UNITS specifies the time units for display. Fig. 7-30 illustrates the concept:
SP
(°C)
100
START_VAL[3] START_VAL[4]
50
25
START_VAL[6]
DURATION [6] = 0
600 600 1200
DURATION [3]
600 600 t (seconds)
Fig. 7-30: Example of setpoint ramp generation based on five time periods
161
7 Calculation and Logic Blocks
Timer
Timer interruption
Operational status
ControlCare Application Designer: Function Blocks
The position in the time axis of the curve defining the setpoint ramp is determined by an internal timer. The timer is started automatically by a transition from false to true at the START discrete input or manually by the operator by setting Status true in the START parameter. The timer normally runs for the sum of the TIME_DURATION values and then stops. It must then be reset before it can be restarted.
The operator can reset the timer independent of block mode by selecting the RESET option in the
OP_CMD_SPG parameter. The timer is set to zero, i.e. to the beginning of the ramp. The timer is restarted manually by selecting the START option in the OP_CMD_SPG parameter.
The timer may also be reset automatically by a discrete signal at the RESET_IN input. The block will remain in reset while this input parameter has value TRUE. It can be restarted only after
RESET_IN changes from TRUE to FALSE.
When the parameter AUTO_CYCLE is set to "Autocycle", the timer will return to zero (RESET) and restart (START) automatically when the time reaches the last point of the profile.
The timer runs only when the block mode is Auto: a change to Man stops it. When the mode returns to Auto mode, the timer will reinitialize from the point that it stopped. If BK_CAL_IN is connected to BK_CAL_OUT of a PID block and START_TYPE option "Cascade” is selected, the time will stop and the block be forced to IMan should cascade initialization be in progress.
The timer may be interrupted at any time by changing the discrete signal PAUSE from false to true.
It resumes running when PAUSE is set to false. The block remains in Auto mode throughout the pause.
The timer will also be paused automatically when the deviation between BKCAL_IN and the generated setpoint exceeds the limit DV_HI_LIM or DV_LO_LIM . This allows the user to implement a temperature driven ramping, i.e. the time will pause until the temperature is within the set tolerance, see Fig- 7-31. If the deviation is out of limits, an alarm is indicated in
DV_HI_ALM or DV_LO_ALM respectively and the timer is stopped. It resumes normal operation when the deviation returns to a value within the prescribed limits.
Timer pauses
Timer restarts
DV_HI_LIM
START_VAL [x+1]
DV_LO_LIM
Setpoint
Hold band
START_VAL [x]
Process Value = BKCAL_IN
Timer restarts
Timer pauses
DURATION [x]
Fig. 7-31: Automatic extensiion of the duration when the setpoint is out of limits
The parameter SPG_STATE indicates the status of setpoint ramp generator:
• READY: the ramp generator is initialized and waiting for the starting signal
• ACTIVE: the timer is running
• PAUSE: the PAUSE signal stopped the timer
• DONE: the setpoint generator has reached the last point of the ramp
162 Endress+Hauser
ControlCare Application Designer: Function Blocks
OUT value
BKCAL_IN
Status propagation
7 Calculation and Logic Blocks
The parameter PAUSE_CAUSE displays the cause of the PAUSE state:
• 1 = Operator Pause
• 2 = Logic Pause
• 3 = Operator & Logic
• 4 = Deviation pause
• 5 = Operator & Deviation
• 6 = Logic & Deviation
• 7 = Operator & Logic & Deviation
A logic pause may be due to the violation of deviation limits or a downstream PID block not operating in Cascade mode.
After execution of the block, the calculated setpoint value is made available at the OUT output. The calculated setpoint value is also to be found in PRE_OUT , even when the block is in Man mode.
The parameter OUT_RANGE is used make the range and engineering units of OUT known to a
HMI.
Three parameters provide information on the point reached within the ramp:
• STEP_POSN : indicates the current segment or step
• TIME_POSN : indicates the time elapsed since the beginning of the current step
• TIME_POSN_T : indicates the time elapsed since the beginning of the profile
Depending upon application, the input BKCAL_IN may be unconnected, connected to the
BKCAL_OUT output of a downstream PID control block or connected to the OUT output of an upstream Analog Input block.
If there is no BKCAL_IN input, the timer will start at zero and the ramp will be generated as programmed. When there is an input, it is possible to start the curve from the BKCAL_IN value by selecting the appropriate option in the START_TYPE parameter. This ensures that the timer can always be started and/or the control starts without a large upset: :
START_TYPE option
Cascade
BKCAL_IN connection
PID block
Use Duration AI block
Use Rate AI block
Action
The time value is calculated from BKCAL_IN (= last valid OUT) using the curve. If no value can be calculated (BKCAL_IN not in curve range) the time starts at zero and BAL_TIME is used to bring the value of OUT to match PRE_OUT.
Time starts at zero. The START_VAL for the first segment is temporarily made equal to BKCAL_IN (= OUT from e.g. temperature transmitter)
The time starts at zero. The curve starts from the BKCAL_IN value (= OUT from e.g. temperature transmitter) and uses the rate specified by the first values of
START_VAL and the first value of TIME_DURATION.
If a PID is connected, the CONTROL_OPTS parameter of the PID block should be configured to use PV for BKCAL_OUT and be set to operate in Cas mode.
The status of the OUT value is checked and handled as described below..
STATUS_OPTS
–
–
START_TYPE BKCAL_IN status
Cascade
Not "Cascade"
Good
Good
– Not "Cascade" Uncertain
Use Uncertain as Good Not "Cascade" Uncertain
–
-
Cascade Bad
Not "Cascade" Bad
Use Uncertain as Good Not "Cascade" Bad
Target to Manual if
BAD IN
Any Bad
OUT status
GoodCascade
GoodNC
Bad
GoodNC
Bad
Bad
GoodNC
Bad
Remarks
Block in Auto
Block in Auto
Block forced to Man
Block in Auto
Block forced to Man
Block forced to Man
Block in Auto, deviation limits ignored
Block forced to Man
Endress+Hauser 163
7 Calculation and Logic Blocks
Control strategy: time driven ramp
ControlCare Application Designer: Function Blocks
7.9.2
Block configuration
Fig. 7-32 shows a control strategy example for the time driven generation of a temperature ramp.
This might be required to quickly bring an annealing furnace to its operating temperature, the temperature of the workpieces being secondary at this point. The SPG block is to connected a PID control block and provides its setpoint. The temperature measuring device monitors the generated temperature. The PID block generates the control output for e.g. a heater and sends the current SP as feedback to the SPG block. In this configuration, the ramp will be executed according to the time durations set. If the control loop is broken, the SPG block will reset to the last valid SP.
Block configuration: time driven ramp
Temperature transmitter
OUT
AI
Target Mode = Cas
SPG
BKCAL_IN
OUT
OUT
IN
PID
CAS_IN
BKCAL_IN
BKCAL_OUT
CAS_IN AO
BKCAL_OUT
Fig. 7-32: Links to be made for Setpoint Ramp Generator block for control strategy described above
The Setpoint ramp generator is configured for the strategy in Fig 7-32 as follows, whereby it is assumed that the ramp has the profile in Fig. 7-30:
Index/Parameter
START_VAL
DURATION
[1]
25
600
[2]
50
600
[3]
50
1200
[4]
100
600
[5]
100
600
[6]
25
–
Parameter
MODE_BLK.Target
OUT_RANGE.EU_100
OUT_RANGE.EU_0
OUT_RANGE.UNITS_INDEX
START_VAL.[1]
START_VAL.[2]
START_VAL.[3]
START_VAL.[4]
START_VAL.[5]
START_VAL.[6]
TIME_DURATION.[1]
TIME_DURATION.[2]
TIME_DURATION.[3]
TIME_DURATION.[4]
TIME_DURATION.[5]
TIME_UNITS
Action
Set the target mode of the block to Auto
Enter upper range limit for the input variables (HMI)
Enter lower range limit for input variables (HMI)
Enter unit of the input variables (HMI)
Enter the start values for each segment and the "end marker"
Enter the duration for each segment
(empty parameters are = 0 by default)
Display units for TIME_POSN and TIME_POSN_T
Option/Value
Auto e.g. 200 e.g. 0 e.g. °C
25
50
50
100
100
25 (end marker)
600
600
1200
600
600 seconds
164 Endress+Hauser
ControlCare Application Designer: Function Blocks 7 Calculation and Logic Blocks
Control strategy: temperature driven ramp
Fig. 7-33 shows a control strategy example for the temperature driven generation of a temperature ramp. This might be required, e.g. to ensure that a workpiece is held at a specific temperature for a minimum period of time, e.g. during annealing. The SPG block is connected a PID control block and provides its setpoint. The temperature measuring device monitors the generated temperature.
By selecting the CONTROL_OPTS option "Use PV as BKCAL_OUT", the SPG receives feedback on the current temperature. This is used to set tolerances on the setpoint, and to pause the timer if the temperature leaves the hold band, see Fig. 7-31. The current setpoint will be held until the temperature returns to the hold band. In order to be able to start the counter again when the ramp cycle is completed, the START_TYPE option "Cascade" is selected.
Note
• Temperature feedback may also be provided by a direct connection from an AI block to
BKCAL_IN , in which case, the START_TYPE option "Use Duration" or "Use Rate" must be selected. In this case, no CONTROL_OPTS options are required in the PID block
Block configuration: temperature driven ramp
Temperature transmitter
OUT
AI
Target Mode = Cas
CONTROL_OPS “Use PV as BKCAL_OUT”
START_TYPE
“Cascade”
SPG
OUT
BKCAL_IN
OUT
IN
PID
CAS_IN
BKCAL_IN
BKCAL_OUT
CAS_IN AO
BKCAL_OUT
Fig. 7-33: Links to be made for Setpoint Ramp Generator block for control strategy described above
The Setpoint Ramp Generator block is configured for the strategy in Fig 7-33 as follows:
Parameter
MODE_BLK.Target
OUT_RANGE.EU_100
OUT_RANGE.EU_0
OUT_RANGE.UNITS_INDEX
START_VAL.[1]
START_VAL.[2]
START_VAL.[3]
START_VAL.[4]
START_VAL.[5]
START_VAL.[6]
TIME_DURATION.[1]
TIME_DURATION.[2]
TIME_DURATION.[3]
TIME_DURATION.[4]
TIME_DURATION.[5]
TIME_UNITS
START_TYPE
BAL_TIME
ALARM_HYS
DV_HI_LIM
DV_LO_LIM
PID block
MODE_BLK.Target
CONTROL_OPTS
Action
Set the target mode of the block to Auto
Enter upper range limit for the input variables (HMI)
Enter lower range limit for input variables (HMI)
Enter unit of the input variables (HMI)
Enter the start values for each segment and the "end marker"
Enter the duration for each segment
(empty parameters are = 0 by default)
Display units for TIME_POSN and TIME_POSN_T
Determines the start value for a new rampo cycle
Sets time to balance the OUT value to the PRE_OUT value on cascade initialization
Alarm hysteresis in % of OUT_RANGE
Max. deviation between setpoint and measured value
Max. deviation between setpoint and measured value
Option/Value
Auto e.g. 200 e.g. 0 e.g. °C
25
50
50
100
100
25 (end marker)
600
600
1200
600
600 seconds
Cascade
60
1
2 (°C)
2 (°C
Set the target mode of the block to Cas
Select option
Cas
Use PV as
BKCAL_OUT
Endress+Hauser 165
7 Calculation and Logic Blocks ControlCare Application Designer: Function Blocks
Mode
Status
Block errors
7.9.3
Block operation
The block normally operates in Auto mode.
When MODE_BLK.Target
is set to Man, the block output can be manipulated on-line. The operator can write on the outputs STEP_POSN , TIME_POSN and TIME_POSN_T in order to select a particular point of the profile. When the block is switched back to Auto, the ramp will start from that point. The timer is restarted by activating the input START.
The operator can also write to OUT . As the adjusted value may correspond to more than one point on the profile or to none, if the operator adjusts a value beyond the profile limits, the OUT value goes from the last adjusted value to the point before mode switching following a ramp defined by
BAL_TIME . it is also possible to advance or return the time through the following operator commands
(OP_CMD_SPG):
• ADVANCE: sets the time to the beginning of the next step
• REPEAT: sets the time to the beginning of the current step
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
Operation can be checked on-line by viewing a number of parameters:
START
RESET_IN
PAUSE_CAUSE
SPG_STATE
STEP_POSN
TIME_POSN
TIME_POS_T
OUT
Value and status of start input signal
Value and status of reset input signal.
Reason for timer pause
Current state of the Sepoint Ramp Generator
Current position in ramp generator profile
Time elapsed since beginning of ramp step
Time elapsed since beginning of ramp cycle
Value and status of block output
When two inputs are in use, the worst status of the two is propagated to the output. The significance of the output status is indicated below.
OUT status
Good
Bad
Meaning
Normal operation as configured
• Block out of service
• One or both inputs have "Bad" or "Uncertain" status
Block errors are indicated in the BLOCK_ERR parameter
Condition
Out-of-Service
Block Configuration Error
Reason
• MODE_BLK.Target currently set to OOS
• START_TYPE parameter has an invalid value
Setpoint Ramp Generator block
7.9.4
Block parameters
Parameter
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
OUT
OUT_RANGE
GRANT_DENY
Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
0
0
Description
See Chapter 2.3.4
Block mode, set MODE_BLK.Target to AUTO, CAS or RCAS
Block errors, see Chapter 6.1.9
Output value calculated as a result of executing the block.
Block output range and units for HMI
Access options, see Chapter 2.8.1
166 Endress+Hauser
ControlCare Application Designer: Function Blocks 7 Calculation and Logic Blocks
TIME_UNITS
BKCAL_IN
START
START_TYPE
PAUSE
PAUSE_CAUSE
AUTO_CYCLE
STEP_POSN
TIME_POSN
TIME_POS_T
OP_CMD_SPG
Parameter
STATUS_OPTS
START_VAL
TIME_DURATION
SPG_STATE
PRE_OUT
RESET_IN
BAL_TIME
OUTAGE_LIM
UPDATE_EVT
BLOCK_ALM
ALARM_SUM
ACK_OPTION
ALARM_HYS
DV_HI_PRI
DV_HI_LIM
DV_LO_PRI
DV_LO_LIM
DV_HI_ALM
DV_LO_ALM
Legend: RO = Read Only
Valid range/
Options
Default value
Description
Positive
0, 1
0
0
0
0
0
0 to 50 % 0.5%
0 to 15
0 to 15
0
+INF
0
-INF
Status options, see Chapter 2.8.4 and Chapter 6.1.9
Up to 11 values defining the start value of each time period
• If ten time periods are in use, an eleventh value must be entered as end marker
Up to 10 values defining the duration in seconds of each time period
• If less than ten time periods are in use, the "end value" must be paired with "0"
Display units for TIME_POSN and TIME_POSN_T
Feedback from BKCAL_OUT of a downstream block or OUT value of a Analog Input block
Value and status of start input, if connected
• In Man, a change from false to true starts the timer, provided it is READY
Initialization type for ramp start when BKCAL_IN connected
Value and status of pause input, if connected
Reason for current pause, see Chapter 7.9.1
When set, causes ramp to autmatically reset and start
Displays current position in ramp generator profile
• In Man, adjusts ramp generator to entered position
Displays time elapsed since beginning of step
• In Man, adjusts time to entered value
Displays time elapsed since beginning of ramp cycle
• In Man, adjusts time to entered value
Operator commands for setpoint ramp generator
• ADVANCE: advances to next step
• No action
• REPEAT: repeats current step
• RESET: resets setpoint ramp generator
Displays the current state of the Sepoint Ramp Generator
• READY: the ramp generator is initialized and waiting for the starting signal
• ACTIVE: the timer is running
• PAUSE: the PAUSE signal stopped the timer
• DONE: the setpoint generator has reached the last point of the ramp
Displays the OUT value resulting from block execution
Value and status of reset input, if connected
Time allowed to balance OUT changes as a result of a change from Auto, Cas or Rcas to Man
Not used
This alert is generated by any change to the static data.
Block alarms, see Chapter 2.9
Alarm summary, see Chapter 2.9
See Chapter 2.9
• 0: Auto ACK Disable
• 1: Auto ACK Enable
Alarm hysteresis in % of OUT_SCALE, see Chapter 2.9
Priority of the control deviation HI alarm, see Chapter 2.9
Setting of control deviation HI in engineering units
Priority of the control deviation LO alarm, see Chapter 2.9
Setting of control deviation LO in engineering units
Status of deviation HI alarm and its associated time stamp.
Status for deviation LO alarm and its associated time stamp.
Endress+Hauser 167
7 Calculation and Logic Blocks ControlCare Application Designer: Function Blocks
7.10 Enhanced Setpoint Ramp Generator
The Enhanced Setpoint Ramp Generator has all parameters of the SPG block, and an additional output parameter, OUT_1, that indicates the current step or segment of profile. This is the same information as is carried by the parameter STEP_POSN , but value is transmitted in floating point format.
In ControlCare Application Designer the Setpoint Ramp Generator block is assigned the generic name Device Tag-ESPG-n . It can be found by expanding the appropriate device or Field Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 7-34.
PAUSE
BKCAL_IN
START
RESET_IN
DV_HI_LIM
DV_LO_LIM
Compare
OP_CMD_SPG
PAUSE
Setpoint
Time
AUTOCYCLE
DURATION
START_VAL
START_TYPE
SETPOINT
Man
Man
Man
Man
Fig. 7-34: Schematic diagram of Enhanced Setpoint Ramp Generator block
OUT
STEP_POSN
TIME_POSN
TIME_POSN_T
OUT_1
Block parameters Parameter
OUT_1
Legend: RO = Read Only
Valid range/
Options
0–4
Default value
RO
Description
Displays current position in ramp generator profile in floating point format
• 0=None
• 1= Step1
• 2= Step2
• 3= Step 3
• 4= Step 4
168 Endress+Hauser
ControlCare Application Designer: Function Blocks 7 Calculation and Logic Blocks
7.11 Timer and Logic
The Timer and Logic function block provides logic combination and timing functions, e.g.:
• Combine multiple inputs as OR, AND, vote, or EXACTLY count.
• Measure the duration of a combined discrete input signal
• Accumulate, until reset, the duration of a combined input signal
• Count changes of a combined discrete input signal
• Set a discrete output if the duration of a combined input signal exceeds a limit
• Extend, Delay, Pulse, or Debounce a combined input as an output
• Provide outputs indicating amount of time expired and amount of time remaining
• Selectively invert any connected discrete input or output
• Reset timer
In ControlCare Application Designer the Timer and Logic block (TMR Block) is assigned the generic name Device Tag-TMR-n . It can be found by expanding the appropriate device or Field Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 7-35.
Input combination
Endress+Hauser
IN_D1
IN_D2
IN_D3
IN_D4
NV_5
Comb.
Logic
PV_D
TIMER_SP
TIMER_TYPE
QUIES_OPT
Timer
Processing
INV_5
Man
PRE_OUT_D
Auto
N_START
COMB_TYPE
RESET_IN
OUT_D
OUT_EXP
OUT_REM
Fig. 7-35: Schematic diagram of Timer and Logic block
7.11.1 Functional description
Depending upon the option set in COMB_TYPE , see table below, up to four inputs may be
• logically combined (AND, OR),
• voted (any 2 or more true, any 3 or more true),
• or counted (exactly 1 true, exactly 2 true, exactly 3 true, odd count or even count).
Connected inputs may have the values of true (1) or false (0). If a connected input is undefined, it is treated as "Bad" (Out-of service). Non-connected inputs (operator entries) may have the values of true (1) or false (0). If a non-connected input is undefined, it is ignored.
COMB_TYPE
OR
ANY2
ANY3
AND
EXACTLY1
EXACTLY2
EXACTLY3
EVEN
ODD
PV_D value true if one or more used inputs are true true if two or more used inputs are true true if three or more used inputs are true true if all used inputs are true true if exactly 1 used input is true true if exactly 2 used inputs are true true if exactly 3 used inputs are true true if exactly 0, 2 or 4 used inputs are true (OR non exclusive) true if exactly 1 or 3 used inputs are true (OR exclusive)
169
7 Calculation and Logic Blocks
Timer Processing
Timer type
ControlCare Application Designer: Function Blocks
The timer processing type is specified by TIMER_TYPE , see below. The timer may operate to produce a measurement, delay, extension, pulse (non-re-triggerable or re-triggerable) or debounce of the combined input signal.
TIMER_SP specifies the time duration of the delay, extension, pulse, debounce filter or comparison limit. The result of block execution is PRE_OUT_D which is made avaílable at OUT_D when the block is in Auto mode. OUT_EXP indicates the time elapsed and OUT_REM indicates the remaining time when TIME_TYPE option is measurement, comparison, delay, extension, debounce, or pulse.
QUIES_OPT allows the user to select the behavior for OUT_EXP and OUT_REM when the timer is quiescent-- that is, the timer is stopped, waiting to start. The following table indicates the definition of quiescent state for each option of TIMER_TYPE :
Definition of quiescent state start and end as a function of TIMER_TYPE
TIMER_TYPE Quiescence state starts when combined input
(PV_D):
Quiescence state ends when combined input
(PV_D):
MEASURE
ACCUM
COMPARE
DELAY returns to false
[QUIES_OPT does not apply] returns to false returns to false changes from false-to-true
[QUIES_OPT does not apply] changes from false-to-true changes from false-to-true
EXTEND
DEBOUNCE
PULSE
RT_PULSE returns to true has changed and timer has expired as returned to false and timer has expired has returned to false and timer has expired changes from true-to-false changes changes from false-to-true changes from false-to-true
QUIES_OPT has two options, CLEAR and LAST:
• CLEAR causes both OUT_EXP and OUT_REM to be set to zero during quiescence.
• LAST causes both OUT_EXP and OUT_REM to hold their last values when the block becomes quiescent. That is, the time expired and time remaining will remain available until the quiescence ends with the start of the next activation.
Note that a false-to-true transition on RESET_IN will also reset OUT_EXP and OUT_REM .
N_START is a count of the number of starts (false-to-true) transitions of the combined input,
PV_D , since the last false-to-true change seen on RESET_IN .
TIMER_TYPE may be one of the following, operating on the combined input signal:
TIMER_TYPE
MEASURE
ACCUM
COMPARE
DELAY
EXTEND
DEBOUNCE
PULSE
RT_PULSE
Quiescence state starts when combined input (PV_D):
Indicates the duration of the most recent true signal
Accumulates the durations of a true signal
Compares a true signal duration to specified duration
Delays a false-to-true transition, eliminating it if short
Extends a true-to-false transition, eliminating it if short
Delays any transition, eliminating it if short
Generates a true pulse on a false-to-true transition, non-retriggerable
Generates a true pulse on a false-to-true transition, retriggerable
170 Endress+Hauser
ControlCare Application Designer: Function Blocks
MEASURE
7 Calculation and Logic Blocks
If TIMER_TYPE is MEASURE, PRE_OUT_D will be the same as the combined input, PV_D .
OUT_EXP indicates the length of time, in seconds, that the combined signal is true. OUT_REM is set to 0. Fig. 7-36 shows an example, whereby QUIES_OPT has been set to CLEAR. If
QUIES_OPT were set to LAST, OUT_EXT would accumlate and not return to zero, see
"ACCUM".
ACCUM true false
PV_D true false
PRE_OUT_D see note 1 see note 1
OUT_EXP
0
OUT_REM
0 see note 1
Note 1: Returns to zero if QUIES_OPT = CLEAR Time
Fig. 7-36: Timer example for TIMER_TYPE = MEASURE
If TIMER_TYPE is ACCUM, PRE_OUT_D will be the same as the combined input, PV_D .
OUT_EXP indicates the accumulated length of time, in seconds, that the combined signal has been true. Unlike TIMER_TYPE = MEASURE, it will not be automatically reset by the time of the next occurrence of a false-to-true change of PV_D . Instead, it will continue to accumulate "on" time or
"run" time until reset to 0 by a false-to-true change on RESET_IN . OUT_REM is unused (set to
0.0) for this timer type. QUIES_OPT is disabled for this option.
true false
PV_D true false
PRE_OUT_D
OUT_EXP
0
OUT_REM
0
Fig. 7-37: Timer example for TIMER_TYPE = ACCUM
Time
Endress+Hauser 171
7 Calculation and Logic Blocks
COMPARE
ControlCare Application Designer: Function Blocks
If TIMER_TYPE is COMPARE, the block will measure the time since a false-to-true change on the combined input, PV_D . The current duration will be indicated by OUT_EXP . OUT_REM will indicate the time remaining between the current expired duration, OUT_EXP , and current limit,
TIMER_SP . If OUT_EXP does not exceed TIMER_SP , PRE_OUT_D will be set to false. If
OUT_EXP equals or exceeds TIMER_SP , PRE_OUT_D will be set to true and OUT_REM will be set to zero. When the combined input returns to false, either with or without exceeding the limits specified by TIMER_SP , OUT_D will be set to false. (Note that this type of behavior is the same as
TIMER_TYPE = DELAY. The difference is merely in the application perspective).
DELAY
172 true false
PV_D true false
PRE_OUT_D
TIMER_SP
OUT_EXP
0
TIMER_SP
OUT_REM
0 see note 1 see note 1 see note 1
Time
TIMER_SP
Note 1: Returns to zero if QUIES_OPT = CLEAR
TIMER_SP
Fig. 7-38: Timer example for TIMER_TYPE = COMPARE
If TIMER_TYPE is DELAY, a false-to-true change on the combined input, PV_D , will be delayed at the output, PRE_OUT_D , until the amount of time specified by TIMER_SP has been expired.
If the combined input returns to false before the time expires, the output will remain as false, concealing the input transitions. If the PRE_OUT_D output has been set to true because the time has expired, a true-to-false transition in the combined input will be presented to PRE_OUT_D immediately. [Note that this type of behavior is the same as TIMER_TYPE = COMPARE. The difference is merely in the application perspective.] true false
PV_D true false
PRE_OUT_D see note 1
TIMER_SP
OUT_EXP
0
TIMER_SP
OUT_REM
0 see note 1
TIMER_SP
Note 1: Returns to zero if QUIES_OPT = CLEAR
TIMER_SP
Time
Fig. 7-39: Timer example for TIMER_TYPE = DELAY
Endress+Hauser
ControlCare Application Designer: Function Blocks
EXTEND
DEBOUNCE
7 Calculation and Logic Blocks
If TIMER_TYPE is EXTEND, a true-to-false change on the combined input, PV_D , will be delayed at the output, PRE_OUT_D , until the amount of time specified by TIMER_SP has expired. If the combined input returns to true before the time expires, the output will remain as true, concealing the input transitions. If the PRE_OUT_D output has been set to false because the time has expired, a false-to-true transition in the combined input will be presented to PRE_OUT_D immediately.
true false
PV_D true false
PRE_OUT_D see note 1
TIMER_SP
OUT_EXP
0
TIMER_SP
OUT_REM
0 see note 1 see note 1
TIMER_SP
Note 1: Returns to zero if QUIES_OPT = CLEAR
TIMER_SP
Time
Fig. 7-40: Timer example for TIMER_TYPE = EXTEND
If TIMER_TYPE is DEBOUNCE, and if PRE_OUT_D is false, a false-to-true change on the combined input, PV_D , will be delayed at the output, PRE_OUT_D , until the amount of time specified by TIMER_SP has expired. If the combined input returns to false before the time expires, the output will remain as false, concealing the input transitions. If PRE_OUT_D is true, a true-tofalse change on the combined input, PV_D , will be delayed at the output, PRE_OUT_D , until the amount of time specified by TIMER_SP has expired. If the combined input returns to true before the time expires, the output will remain as true, concealing the input transitions. This both delays true initiations and extends true terminations, acting as a filter for intermittent state changes.
true false
PV_D true false
PRE_OUT_D
*see note 1
TIMER_SP
OUT_EXP
0
TIMER_SP
OUT_REM
0
* *
TIMER_SP
TIMER_SP
TIMER_SP
*Note 1: Returns to zero if QUIES_OPT = CLEAR
*
TIMER_SP
Time
*see note 1
TIMER_SP
Fig. 7-41: Timer example for TIMER_TYPE = DEBOUNCE
Endress+Hauser 173
7 Calculation and Logic Blocks
PULSE
RT_PULSE
ControlCare Application Designer: Function Blocks
If TIMER_TYPE is PULSE, a false-to-true change on the combined input, PV_D , will initiate a true pulse at PRE_OUT_D whose duration is determined by the TIMER_SP value. At the end of the time duration, the output, will return to false. Further false-to-true transitions of the combined input while PRE_OUT_D is true will be ignored. true false
PV_D true false
PRE_OUT_D
*see note 1
TIMER_SP
OUT_EXP
0
TIMER_SP
OUT_REM
0
*see note 1
TIMER_SP
*Note 1: Returns to zero if QUIES_OPT = CLEAR
TIMER_SP
Time
Fig. 7-42: Timer example for TIMER_TYPE = PULSE
If TIMER_TYPE is RT_PULSE, (Re-Triggerable pulse type) a false-to-true change on the combined input, PV_D , will initiate a true pulse at PRE_OUT_D whose duration is determined by the
TIMER_SP value. At the end of that time duration PRE_OUT_D will return to false. If the combined input returns to false and presents a subsequent false-to-true transition while the timer is timing, the timer willl be reinitialized and PRE_OUT_D continues to be true.
true false
PV_D true false
PRE_OUT_D
TIMER_SP
OUT_EXP
0
TIMER_SP
OUT_REM
0
*see note 1
TIMER_SP
TIMER_SP
*Note 1: Returns to zero if QUIES_OPT = CLEAR
TIMER_SP
Time
*see note 1
Fig. 7-43: Timer example for TIMER_TYPE = RT_PULSE
174 Endress+Hauser
ControlCare Application Designer: Function Blocks 7 Calculation and Logic Blocks
Timer reset
Status propagation
Initialization Treatment
RESET_IN is a discrete input which, on a false-to-true transition, resets the timer. OUT_EXP output is set to 0, and then the timer follows processing described in "Initialization Treatment" for the values PRE_OUT_D and OUT_REM.
INVERT_OPTS allows the discrete input or output values to be inverted. Each input or output can be set individually.
The block checks the status of the inputs before processing them. The table below summarizes the status of OUT under various conditions. ..
STATUS_OPTS
–
–
Use Uncertain as Good
–
IN_Dx status
Good
Uncertain
Uncertain
Bad
OUT status
Good
Bad
Good
Bad
Remarks
Block executed
Block not executed, timer stops
Block executed
Block not executed, timer stops
When the outputs return to usable status, the timer returns to the measurement and the OUT_EXP and OUT_REM status is set to Uncertain while they are in quiescent state or a Reset occurs.
The following table summarizes the values of PRE_OUT_D, OUT_EXP and OUT_REM after the initial execution, as a function of TIMER_TYPE and the initial value of the combined input, PV_D:
TIMER_TYPE
MEASURE
MEASURE
ACCUM
ACCUM
COMPARE
COMPARE
DELAY
PV_D
False
True
False
True
False
True
False
PRE_OUT_D
False
True
False
True
False
False
False
OUT_EXP
0.0
0.0
0.0
0.0
TIMER_SP*
0.0
TIMER_SP*
OUT_REM
0.0
0.0
0.0
0.0
0.0
TIMER_SP*
0.0
DELAY
EXTEND
EXTEND
DEBOUNCE
DEBOUNCE
PULSE
PULSE
RT_PULSE
True
False
True
False
True
False
True
False
False
True
True
False
True
False
False
False
0.0
0.0
TIMER_SP*
TIMER_SP*
TIMER_SP*
0.0
TIMER_SP*
0.0
TIMER_SP*
TIMER_SP*
0.0
0.0
0.0
0.0
0.0
0.0
RT_PULSE True False TIMER_SP* 0.0
* Initialize to TIMER_SP value if QUIES_OPT = LAST, initialize to 0.0 if QUIES_OPT = CLEAR.
Active
Active
Inactive
Inactive
Inactive
Inactive
Inactive
Inactive
Inactive
Timer Status
Inactive
Inactive
Inactive
Inactive
Inactive
Active
Inactive
Endress+Hauser 175
7 Calculation and Logic Blocks
Control strategy: safety interlock
Block configuration: safety interlock
Control strategy: timed sequence
Block configuration: timed sequence
ControlCare Application Designer: Function Blocks
7.11.2 Block configuration
Fig. 7-44 shows a control strategy example for the use of the TMR block as a safety interlock. A motor can be started manally only when a key switch in the controlroom is turned on and a local pushbutton is latched. The motor is to run as long as the button is latched. The inputs are connected to a relay input module and made available to the control strategy via a multiple digital input block.
The AND function of the timer block is used to check the true condition of both inputs and the
MEASURE function is used to give a defined signal to a multiple discrete output block, to which the motor is connected via a output relay module.
COMB_TYPE = AND
TIMER_TYPE = MEASURE
Key switch
Pushbutton
MDI
OUT_D1
OUT_D2
IN_D1
IN_D2
TMR
OUT_D
IN_D1 MDO
Motor
Fig. 7-44: Links to be made for Timer and Logic block for control strategy described above
The Timer and Logic block is configured for the strategy in Fig 7-44 as follows:
Parameter
MODE_BLK.Target
COMB_TYPE
TIMER_TYPE
Action
Set the target mode of the block to Auto
Logic to be used by block
Timer to be used by block
Option/Value
Auto
AND
MEASURE
Fig. 7-45 shows a control strategy example for the use of the TMR block for a timed output. One of two silos is used to feed solid material to a reactor filled with water. After feeding is completed, the mixture must be stirred for a period of fifteen minutes. The signals used to close the silo valves, fed in via a MDI block, are used to start the timer, the OR function to detect the closing of either valve.
The PULSE function ensures a motor signal of duration 15 minutes is generated.
Note
• In this application, the outputs OUT_EXP and OUT_REM provide an analog timer output that may be used, e.g. in a hybrid function block, to time logic sequences.
Valve 1
Valve 2
MDI
OUT_D1
OUT_D2
IN_D1
IN_D2
COMB_TYPE = OR
TIMER_TYPE = PULSE
TIMER_SP = 900 s
OUT_D
TMR
IN_D1 MDO
Stirrer
Fig. 7-45: Links to be made for Timer and Logic block for control strategy described above
The Timer and Logic block is configured for the strategy in Fig 7-44 as follows:
Parameter
MODE_BLK.Target
TIMER_SP
COMB_TYPE
TIMER_TYPE
Action
Set the target mode of the block to Auto
Option/Value
Auto
Length of pulse, in seconds, generated after detection of closed valve
900
Logic to be used by block
Timer to be used by block
OR
PULSE
176 Endress+Hauser
ControlCare Application Designer: Function Blocks
Mode
Status
Block errors
Timer block
Endress+Hauser
7 Calculation and Logic Blocks
7.11.3 Block operation
The block normally operates in Auto mode, whereby PRE_OUT_D is passed to the OUT_D output.
When MODE_BLK.Target
is set to Man, the block output can be manipulated on-line. The operator can write on the output OUT_D outputs. The calculations continue and can be read in
PRE_OUT_D .
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
Operation can be checked on-line by viewing a number of parameters:
IN_Dx
RESET_IN
PRE_OUT_D
OUT_D
OUT_EXP
OUT_REM
Value and status of discrete input signal 1 to 4
Value and status of reset input signal.
Result of block execution, irrespective of operating mode
Value and status of discrete output signal
Time expired sing timer started
Time remaining until timer stops
When two inputs are in use, the worst status of the two is propagated to the output. The significance of the output status is indicated below.
OUT status
Good
Bad
Meaning
• Normal operation as configured
• Block out of service
• One or more inputs have "Uncertain" status and STATUS_OPTS "Use Uncertain as Good" is not set
• One or more input have "Bad" status
Block errors are indicated in the BLOCK_ERR parameter
Condition
Out-of-Service
Block Configuration Error
Reason
• MODE_BLK.Target currently set to OOS
• TIME_UNITS or QUIES_OPT parameter has an invalid value
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
PV_D
OUT_D
TIMER_SP
PV_STATE
OUT_STATE
GRANT_DENY
INVERT_OPTS
STATUS_OPTS
IN_D1
IN_D2
7.11.4 Block parameters
Parameter Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
Description
See Chapter 2.3.4
0
0
0
0
0
0
Block mode, set MODE_BLK.Target to AUTO, CAS or RCAS
Block errors, see Chapter 6.1.9
Either the primary discrete value for use in executing the function, or a process value associated with it
Primary discrete value calculated as a result of executing the function
Time used by the TMR block to set the delay, extend, debouncing and processing the pulse time.
Index to the text describing the states of a discrete PV.
Index to the text describing the states of a discrete output.
Access options, see Chapter 2.8.1
Signal inversion options
Status options, see Chapter 2.8.4 and Chapter 6.1.9
Value and status of discrete input 1
Value and status of discrete input 2
177
7 Calculation and Logic Blocks ControlCare Application Designer: Function Blocks
Parameter
IN_D3
IN_D4
COMB_TYPE
TIMER_TYPE
PRE_OUT_D
N_START
OUT_EXP
OUT_REM
RESET_IN
QUIES_OPTS
TIME_UNITS
UPDATE_EVT
BLOCK_ALM
ALARM_SUM
Legend: RO = Read Only
Valid range/
Options
Default value
Description
Value and status of discrete input 3
Value and status of discrete input 4
Or Determines how the inputs IN_D[i] are combined
• AND
• OR
• ANY2
• ANY3
• EXACTLY1
• EXACTLY2
• EXACTLY3
• EVEN
• ODD
Measure Type of processing applied to PV_D to determine PRE_OUT_D.
• MEASURE
• ACCUM
• COMPARE
• DELAY
• EXTEND
• DEBOUNCE
• PULSE
• RT_PULSE
RO
RO
RO
RO
Combined and time-processed output of the timer block
Count of false-to-true transitions of the combined input, PV_D.
– Reset by false-to-true transition of RESET_IN.
Time expired.
– Stops when TIMER_SP is reached.
– Reset to zero (1) by RESET_IN, (2) at start of next timer event if QUIES_OPT = LAST, or (3) when block becomes quiescent if QUIES_OPT = CLEAR.
Time remaining if the timer is active.
– Stops when event ceases (block becomes quiescent).
– Reset to 0.0 if QUIES_OPT = CLEAR, and the timer is inactive.
Resets the timer
Behavior option for OUT_EXP and OUT_REM during quiescence.
• CLEAR resets them to zero.
• LAST causes last values to be held
Not used: This parameter has fixed unit: seconds
This alert is generated by any change to the static data.
Block alarms, see Chapter 2.9
Alarm summary, see Chapter 2.9
178 Endress+Hauser
ControlCare Application Designer: Function Blocks 7 Calculation and Logic Blocks
7.12 Lead-Lag
The Lead-Lag block provides dynamic compensation of an input signal. Its primary use is in feedforward control when the dynamic response of the manipulated variable differs significantly from that of a disturbance variable, e.g. as would be the case for flow and temperature measurement. Depending upon configuration, the block can function as a lead, lag, or both.
The block may also be used to implement some special initialization functions required by a control scheme.
In ControlCare Application Designer the Timer and Logic block (LL Block) is assigned the generic name Device Tag-LL-n . It can be found by expanding the appropriate device or Field Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 7-46.
IN
T
1 s + 1
G(s) =
T
2 s + 1
Man
Auto
OUT
LEAD_TIME LAG_TIME
FOLLOW
Fig. 7-46: Schematic diagram of Lead-Lag block
7.12.1 Functional description
The LEAD_TIME and LAG_TIME parameters are configured to obtain the desired input/output relationship.
• LAG_TIME specifies the time constant for the block. Based on a step change to the input this is the time to reach 63.2% of the final value. As a rule of thumb, it requires five time constants to reach the final value based on a first order function applied to the input.
• LEAD_TIME specifies the gain or impulse applied to the input parameter.
• FOLLOW causes the block to perform tracking functions.
When FOLLOW is true, it forces OUT to track IN .
The generalized form of the equation describing the action is as follows:
=
T
-------------------
T
2
Where: G(s) Gain
T
1
= Lead time constant
T
2
= Lag time constant
Endress+Hauser 179
7 Calculation and Logic Blocks
Application examples
ControlCare Application Designer: Function Blocks
In the following applications, the initial input signal is IN = 10. This input receives a positive step change equal to 10% at a time of t = 5s. At t = 20s, the input receives a negative step change equal to 10%. Depending upon the lead lag settings, the action is as follows :
1) LEAD_TIME = 0 and LAG_TIME = 5
%
IN
OUT
20
10
63.2%
5 10 15 20 25 30 T (s)
Fig. 7-47: Example with Lead_TIME = 0 and LAG_TIME = 5
2) LEAD_TIME = 5 and LAG_TIME = 0
%
70
IN
Momentary peak (Gain = 5 x 10%)
OUT
20
10
–10
–40
5 10 15 20 25 30 T (s)
Momentary valley (Gain = 5 x –10%)
Fig. 7-48: Example with Lead_TIME = 5 and LAG_TIME = 0
180 Endress+Hauser
ControlCare Application Designer: Function Blocks
3) LEAD_TIME = 5 and LAG_TIME = 10
%
7 Calculation and Logic Blocks
IN
OUT
20
10
63.2%
5 10 15 20 25 30 T (s)
Fig. 7-49: Example with Lead_TIME = 5 and LAG_TIME = 10
4) LEAD_TIME = 10, LAG_TIME = 5
%
IN
OUT
20
10
5 10 15 20 25 30 T (s)
Fig. 7-50: Example with Lead_TIME = 10 and LAG_TIME = 5
5) LEAD_TIME = 10, LAG_TIME = 5, FOLLOW = TRUE
%
Gain = 11/6 x 10% OUT
IN
20
10
Gain = 11/6 x –10%
5 10 15 20 25 30 T (s)
Fig. 7-51: Example with Lead_TIME = 10 and LAG_TIME = 5, FOLLOW = TRUE
Endress+Hauser 181
7 Calculation and Logic Blocks ControlCare Application Designer: Function Blocks
Control strategy: feedforward with lead/lag
7.12.2 Block configuration
Fig. 7-52 shows an example for feedforward control. The temperature of product leaving a reactor vessel is controlled using a temperature measurement to manipulate the control valve in the heating stream. The temperature of the feed is a disturbance variable, which is fed forward to the control loop. Lead/lag is used to compensate for a change in feed temperature.
Feed
TT
100
Product
TT
101
CV
103
TCV
102
Feedforward
Heating stream
Fig. 7-52: Feedforward control application for product temperature
Fig. 7-53 shows the control strategy together with the links that must be made for the application shown in Fig. 7-52.
TT100
AI
TT101
AI
OUT
IN
OUT
OUT
LL
FF_VAL
IN
BKCAL_IN
PID
OUT CAS_IN
TCV102
AO
OUT
BKCAL_OUT
CV103
Block configuration: safety interlock
Fig. 7-53: Links to be made for Lead/Lag block for control strategy described above
The Lead/Lag block is configured for the strategy in Fig 7-53 as follows:
Parameter
MODE_BLK.Target
LAG_TIME
LEAD_TIME
BAL_TIME
Action
Set the target mode of the block to Auto
Lag time constant for the block
Lead time constant for the block
Time in seconds allowed to balance OUT changes as a result of a change from Auto to Man
Option/Value
Auto e.g. 5 e.g.10
10 (s)
Note
• The values for LAG_TIME and LEAD_TIME in the table should not be taken as being realistic for the application above. The user must determine these by calculating the dynamic compensation and tune them be observing the effects on the loop.
182 Endress+Hauser
ControlCare Application Designer: Function Blocks
Mode
Status
Block errors
Lead-Lag block
7 Calculation and Logic Blocks
7.12.3 Block operation
The block normally operates in Auto mode.
When MODE_BLK.Target
is set to Man, the block output OUT can be manipulated on-line. If the
BAL_TIME parameter is not configured (=0), the transition from the written value (Man) to the calculated value (Auto) will be done with bump. A bumpless transfer can be made by entering an appropriate value, in seconds, in BAL_TIME .
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
Operation can be checked on-line by viewing a number of parameters:
IN
OUT
Value and status of analog input signal
Value and status of output signal
The significance of the output status is indicated below.
OUT status
Good
Uncertain
Bad
Meaning
• Normal operation as configured
• Input has "Uncertain" status and STATUS_OPTS "Use Uncertian as Good" is not set
• Block in Man and STATUS_OPTS "Uncertain if Man" set
• Block out of service
• Inputs has "Bad" status
Block errors are indicated in the BLOCK_ERR parameter
Condition
Out-of-Service
Reason
• MODE_BLK.Target currently set to OOS
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
OUT
OUT_RANGE
GRANT_DENY
STATUS_OPTS
IN
FOLLOW
LAG_TIME
7.12.4 Block parameters
Parameter
LEAD_TIME
BAL_TIME
OUTAGE_LIM
UPDATE_EVT
BLOCK_ALM
Legend: RO = Read Only
Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
Positive
0
0
Description
See Chapter 2.3.4
Block mode, set MODE_BLK.Target to AUTO, CAS or RCAS
Block errors, see Chapter 6.1.9
Primary analog value calculated as a result of executing the function
Output range and units for HMI application
Access options, see Chapter 2.8.1
Status options, see Chapter 2.8.4 and Chapter 6.1.9
Value and status of analog input
Or Tracking input
• TRUE causes OUT to follow IN
Measure Specifies the lag time constant for the block.
– Based on a step change to the input this is the time to reach
63.2% of the final value.
RO
0
Specifies the lead time constant for the block.
Time in seconds allowed to balance OUT changes as a result of a change from Auto to Man
Not used
This alert is generated by any change to the static data.
Block alarms, see Chapter 2.9
Endress+Hauser 183
7 Calculation and Logic Blocks ControlCare Application Designer: Function Blocks
7.13 Output Signal Selector and Dynamic Limiter
The OSDL block can be used as either an output signal selector or dynamic limiter.
• As output selector, the cascade input may be routed to one of two outputs
• As dynamic limiter, the cascade input is transferred to both outputs, but is limited by the secondary input multiplied by a gain and a bias.
It is a customized block that is extremely useful for combustion control applications with double cross limits.
In ControlCare Application Designer the Output Selector and Dynamic Limiter block is assigned the generic name Device Tag-OSDL-n . It can be found by expanding the appropriate device or Field
Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 7-54.
Output Signal Selector
184
CAS_IN
OP_SELECT
IN
SETPOINT
OPERATOR ENTRY
HI_GAIN
HI_BIAS
LO_GAIN
LO_BIAS
SP
NOT_SEL_VAL NOT_SEL_VAL_1
OUT_TYPE
OUTPUT
SELECTOR
ALGORITHM
OSDL_OPTS
OUTPUT SELECTOR TYPE
GAIN
DYNAMIC
LIMITER
ALGORITHM
GAIN_1
IN_1
BKCAL_IN
BKCAL_IN_1
BACK
CALCULATING
BKCAL_OUT
OUT
OUT_1
Fig. 7-54: Schematic diagram of Output Signal Selector and Dynamic Limiter block
7.13.1 Functional description
The output signal selector and dynamic limiter block provides two different algorithms which are selected through the OSDL_TYPE parameter.
• As Output Selector the cascade input may be routed for one of two outputs based on the value of the OP_SELECT input parameter. The output not selected may be treated in two ways: it retains the last value when not selected or receives a internal value.
• As Dynamic Limiter the cascade input is transferred to both outputs, but it is limited by the secondary inputs multiplied by a gain and offset by a bias.
When the "Output Selector" option is selected in OSDL_TYPE , the setpoint value SP may be entered by an operator (Auto mode) or provided by a another function block through the CAS_IN parameter (Cas mode). The inputs IN and IN_1 are not used in this algorithm and their value and status is ignored.
OP_SELECT is a discrete input parameter that selects one of two outputs to receive the SP value:
• If OP_SELECT = "0", SP is passed on to the output OUT .
• If OP_SELECT = "1", SP is passed on to the output OUT_1 .
If the OP_SELECT status is not usable, the block changes to Auto, but the algorithm goes on working with the unusable value. Normally, SP is transferred to the selected output no matter what status it has. Therefore, an unusable value and status in the CAS_IN will be reflected to the selected output. The status of upper cascade initialization, however, is not copied to the selected output.
The non-selected output is handled in one of two ways. By default, the values contained in
NOT_SEL_VAL or NOT_SEL_VAL_1 are transferred to the outputs OUT and OUT_1 respectively. If the option “Keep last value if not selected” is selected in OSDL_OPTS , however, the non-selected output will retain the last value.
Endress+Hauser
ControlCare Application Designer: Function Blocks
OS status propagation
Dynamic Limiter
DL status propagation
Endress+Hauser
7 Calculation and Logic Blocks
Normally, the status of CAS_IN is propagated to the selected output. The status of the non-selected output is always "Uncertain" indicating to the downstream block that it is currently not selected.
The STATUS_OPTS parameter in the downstream block must be configured to deal with it.
If the block is in "Cas" mode and the input is "Bad" the block will be forced to "Auto" mode unless one of the IFS options in OSDL_OPTS has been set:
OSDL_OPS
Uncertain as Good
IFS if Bad CAS_IN
IFS only for selected value
Input status
Uncertain
Bad
Bad
Output status Remarks
Good Uncertain input status is treated as "Good"
Good IFS
Good IFS
IFS propagated to both outputs
IFS propagated to selected output only
By default, the status "GoodCascade, IFS" is propagated to both outputs when "IFS if Bad CAS_IN" is selected. If the “IFS only for selected output” option is selected in OSDL_OPTS , however, the fault state status will be propagated to selected output only.
If the downstream block of the selected output is not operating in cascade mode, the OSDL block will go to "Iman" mode and the status of BKCAL_OUT will change to "GoodCascade, Not Invited".
This forces the upstream block into "Iman" mode as well. The OSDL ignores the status of the downstream block connected to the non-selected output.
When the "Dynamic Limiter" option is selected in OSDL_TYPE , the outputs are the value of the
CAS_IN parameter limited by the following values:
• OUT :
High limit = HI_GAIN_1 * IN_1 + HI_BIAS_1
Low limit = LO_GAIN_1 * IN_1 - LO_BIAS_1
• OUT_1 :
High limit = HI_GAIN * IN + HI_BIAS
Low limit = LO_GAIN * IN - LO_BIAS
After limitation, the parameters GAIN and GAIN_1 are applied as gain to the outputs OUT and
OUT_1 respectively.
The normal mode of operation for the OSDL block as well the two downstream blocks is "Cas". If an input is "Bad" the block will be forced to "Auto" mode unless the IFS options in OSDL_OPTS have been set (multiple choices allowed).
OSDL_OPS
Uncertain as Good
IFS if Bad CAS_IN
IFS if Bad IN
IFS if Bad IN_1
Input status
Uncertain
Bad
Bad
Bad
Output status Remarks
Good Uncertain input status is treated as "Good"
Good IFS
Good IFS
Good IFS
IFS propagated to both outputs
IFS propagated to both outputs
IFS propagated to both outputs
The setpoint value SP is returned to the upper block through BKCAL_OUT by default. One of two alternatives can also be set in OSDL_OPTS :
OSDL_OPS
Use OUT for BKCAL_OUT
Remarks
The OUT value is returned to the upper block
Use OUT_1 for BKCAL_OUT The OUT_1 value is returned to the upper block
If one downstream block is not in cascade mode, indicated by not invited status (NI) on its
BKCAL_OUT , the OSDL block still continues in cascade mode. Only if both downstream blocks are not in cascade, does the block change to "Iman" mode. Its BKCAL_OUT output then changes to Not Invited (NI).
If the OSDL block is in "Iman" mode and the cascade is initialized with a Initialization Request (IR) by a downstream block, Initialization Acknowledge (IA) is transmitted to the downstream block via the appropriate output ( OUT or OUT_1 ). depending on the path initializing, the value BKCAL_IN or BKCAL_IN_1 is then passed on to BKCAL_OUT . The OSDL block remains in "Iman" mode until the downstream cascade is initialized. At this point OSDL block goes to "Auto" mode and sends an Initialization Request to the upstream block to initialize the cascade.
185
7 Calculation and Logic Blocks
Output Selector
ControlCare Application Designer: Function Blocks
After a downstream cascade initialization, the corresponding output must ramp from the last
BKCAL_IN value to the calculated value in BAL_TIME seconds. The required actions as a dynamic limiter algorithm are summarized in the following table:
Mode Target/Actual BKCAL_IN
Cas/Iman NI or IR
Cas/Cas
Cas/Cas
NI or IR
OK
BKCAL_IN1
NI or IR
OK
NI or IR
BKCAL_OUT Action
NI
OK
OK
BKCAL_OUT receives the CAS_IN value
BKCAL_OUT receives the CAS_IN value
Cas/Cas OK OK OK BKCAL_OUT receives the CAS_IN value
Legend: NI = .Not Invited, IR = Initialization Request, OK = Working in Cascade
7.13.2 Block configuration
Fig. 7-55 shows an application for the use of the OSDL block as an output selector. The application requires an equal percentage valve with a rangeability considerably in excess of that available with a standard control valve. To achieve this, two valves are chosen, a smaller one which has a Cv range of 2 to 60 and a large one with a Cv range of 20 to 500. Calculations show that the small valve should operate in the range 0% to 60% and the large valve in the range 40% to 100%.
At any value of the controller output only one valve should be open. As the controller output rises from 0%, the smaller value should open until just below 60%. At this point the large valve should open to approximately 33% and the smaller one close. As the controller output falls from 100%, the small valve should be closed and large valve should gradually close until the controller output is just above 40%. At this point the small valve opens to approx. 66% and the large valve closes.
FT
100
FC
101
CV
103
SMALL VALVE
LARGE VALVE
CV
104
1000
Only one valve open in this range
500
100
60
20
10
Operating range of small valve
Operating range of large valve
1
0
2
20 40 60
PID output %
80 100
Fig. 7-55: Increasing valve rangeability
This strategy is implemented using the OSDL Block as shown in Fig. 7-56. The valves CV103 and
CV104 are controlled by the flow rate measured at FT100 and the PID block. The AALM block monitors the output of the PID block against a HI limit of 60%. If the output value exceeds 60%, the OUT_D digital signal changes from false = "0" to true = "1". OP_SELECT follows, switching the control from AO_1 to AO_2, causing the small valve to close and the large valve to open.
If the ALARM_HYS parameter in the AALM block is set to 20%, OUT_D will remain true until the output falls below 60% - 20% = 40%. At this point the large valve closes and the small valve opens.
186 Endress+Hauser
ControlCare Application Designer: Function Blocks 7 Calculation and Logic Blocks
FT100
OUT
AI
PID
IN
OUT
FCV101
BKCAL_IN
Small valve
CAS_IN
BKCAL_OUT
AO_1
CV103
OUT
AALM
OUT
CAS_IN
OUT_D
OP_SELECT
OSDL
OUT_1
BKCAL_IN
BKCAL_IN_1
CV104
BKCAL_OUT
BKCAL_OUT
CAS_IN
AO_2
Large valve
Block configuration: output selector
Fig. 7-56: Links to be made for Output Selector and Dynamic Limiter block for control strategy described above
The AALM, ODSL and AO blocks are configured for the strategy in Fig 7-56 as follows:
Parameter Action Option/
Value
AALM block
MODE_BLK.Target
OUT_RANGE.EU_100
OUT_RANGE.EU_0
OUT_RANGE.UNITS_INDEX
PV_FTIME
ALARM_HYS
HI_LIM
ODSL block
MODE_BLK.Target
OUT_TYPE
OSDL_OPTS
BAL_TIME
Set the target mode of the block to Auto
Enter upper range limit for the input variables (HMI)
Enter lower range limit for input variables (HMI)
Enter unit of the input variables (HMI)
Auto e.g. 100 e.g. 0 e.g. %
Enter time constant in seconds for 1st. order damping e.g. 3
Enter alarm hysteresis in % of OUT_RANGE e.g. 20
Enter limit of HI alarm in engineering units e.g. 60
Set the target mode of the block to Auto
Mode in which the block operates
If required, block options for IFS,
Time in seconds allowed to balance OUT changes as a result of a change from Cas or Auto to Man
Value of OUT when not selected (= valve closed)
Value of OUT_1 when not selected (= valve closed)
Cas
Output Selector
IFS if Bad CAS_IN
10 (s)
NOT_VAL_SEL
NOT_VAL_SEL_1
AO blocks
MODE_BLK.Target
PV_SCALE.EU_100
PV_SCALE.EU_0
PV_SCALE.UNITS_INDEX
XD_SCALE.EU_100
XD_SCALE.EU_0
XD_SCALE.UNITS_INDEX
CHANNEL
Set the target mode of the block to Cas
Set PID output value equivalent to 100% valve travel
Set PID output value equivalent to 0% valve travel
Set units to %
Set transducer value equivalent to 100% valve travel
Set transducer value equivalent to 0% valve travel
Set units to %
Enter transducer channel number connected to block
0
%
1
60
0
%
100
0
0
AO_1
Cas
0
%
%
100
1
AO_2
Cas
100
40
Endress+Hauser 187
7 Calculation and Logic Blocks
Dynamic Limiter
ControlCare Application Designer: Function Blocks
Fig. 7-57 shows an application for the use of the OSDL block as a dynamic limiter. The control strategy is designed to keep the air-fuel ratio to a furnace burner strictly within predetermined limits.
A sudden change in load would require a corresponding change in air and fuel.
The master controller supplies setpoint values to the air and fuel flow controllers while it is stabilized. During a transition, the air flow determines the maximum upper and lower limits that the fuel flow cannot exceed. The same occurs for the air flow, whose limits are fixed by those of the fuel flow. In this way, even when there is a large shift in the master signal, the air/fuel ratio is maintained very close to the desired value. The “double cross limits” prevent that the fastest variable unbalances the desired ratio.
OIL
AIR
FT
100
TC
106
TT
105
CV
103
FT
101
CV
104
Furnace
Fig. 7-57: Double cross limits control of a furnace burner
This strategy is implemented using the OSDL Block as shown in Fig. 7-58. This generates the setpoint for the air and fuel controllers based on:
• the output of the master controller,
• air flow (Qa –> IN parameter)
• and fuel flow (Qc –> IN_1 parameter).
This configuration allows the:
• air flow setpoint to vary between (Qc-LO_BIAS) and (Qc+HI_BIAS)
• fuel flow setpoint to vary just between (Qa-LO_BIAS_1) and (Qa+HI_BIAS_1).
When the double crossed limit is interferred, an unexpected change in the consumption upsets the desired ratio. Similarly when there is a transient in the master signal of the air/fuel flow, the block it is able to maintain a value very close to the desired ratio.
188 Endress+Hauser
ControlCare Application Designer: Function Blocks
Block configuration: dynamic limiter
7 Calculation and Logic Blocks
AI_1
FT100 (Air flow)
AI_2
TT105
OUT
OUT
AI_3
OUT
FT101 (Oil Flow)
CAS_IN
IN
BKCAL_IN
PID_1
BKCAL_OUT
OUT
CAS_IN
BKCAL_OUT
AO_1
FCV107 CV103 (Air valve)
IN
PID_2
TC106
IN OUT
OUT
CAS_IN
BKCAL_OUT
BKCAL_IN
IN_1
OSDL
OUT_1
BKCAL_IN
BKCAL_IN_1
CAS_IN
FCV108 CV104 (Oil valve)
IN
PID_3
BKCAL_OUT
OUT
CAS_IN
AO_2
BKCAL_OUT
BKCAL_IN
Fig. 7-58: Links to be made for Output Selector and Dynamic Limiter block for control strategy described above
The ODSL block is configured for the strategy in Fig 7-58 as follows:
Parameter
MODE_BLK.Target
OUT_TYPE
OSDL_OPTS
HI_GAIN
HI_BIAS
LO_GAIN
LO_BIAS
HI_GAIN_1
HI_BIAS_1
LO_GAIN_1
LO_BIAS_1
GAIN
GAIN_1
BAL_TIME
Action
Set the target mode of the block to Cas
Mode in which the block operates
If required, block options for IFS,
Gain on OUT_1 high limit
Bias on OUT_1 high limit
Gain on OUT_1 low limit
Bias on OUT_1 low limit
Gain on OUT high limit
Bias on OUT high limit
Gain on OUT low limit
Bias on OUT low limit
Gain on OUT value
Gain on OUT_1 value
Time in seconds allowed to balance OUT changes as a result of a change from Cas or Auto to Man
1
2%
1
5%
1
5%
1
2%
Option/Value
Cas
Dynamic Limiter
IFS if Bad CAS_IN
IFS if Bad IN
IFS if Bad IN_1
1
1
10 (s)
Endress+Hauser 189
7 Calculation and Logic Blocks
Mode
Status
Block errors
ControlCare Application Designer: Function Blocks
7.13.3 Block operation
The block normally operates in "Cas" mode.
When the "Output Selector" option is selected in OSDL_TYPE the block may also operate in "Auto" mode. In this case the operator must set MODE_BLK.Target
to "Auto" and enter a setpoint SP .
The setpoint can be changed during operatioin without changing the block mode to OOS.
When MODE_BLK.Target
is set to "Man", the block outputs OUT and OUT_1 can be manipulated. If the BAL_TIME parameter is not configured (=0), the transition from the written value (Man) to SP (Auto) or CAS_IN value (Cas) will be done with bump. A bumpless transfer can be made by entering an appropriate value, in seconds, in BAL_TIME .
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
Operation can be checked on-line by viewing a number of parameters:
CAS_IN
SP
IN
IN_1
OUT
OUT_1
Value and status of setpoint supplied by upstream block
Value and status of operator entered setpoint
Value and status of analog input signal
Value and status of analog input signal 1
Value and status of output signal
Value and status of output signal 1
The significance of the output status is indicated below.
OUT/OUT_1 status
Good
Uncertain
Bad
Meaning
• Normal operation as configured
• Uncertain input but OSDL_OPTS "Uncertain as Good" set
• Bad input but IFS options set
• Block operating normally as Output Selector, but output currently not selected
• Block out of service
• One or more inputs has "Bad" status and IFS not set (block goes to Auto)
Block errors are indicated in the BLOCK_ERR parameter
Condition
Out-of-Service
Block configuration error
Reason
• MODE_BLK.Target currently set to OOS
• OUT_TYPE has an invalid value
190 Endress+Hauser
ControlCare Application Designer: Function Blocks
Output Selector and
Dynamic Limiter block
7 Calculation and Logic Blocks
7.13.4 Block parameters
Parameter
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
CAS_IN
SP
IN
IN_1
OP_SELECT
OUT
OUT_1
GRANT_DENY
OSDL_TYPE
OSDL_OPTS
HI_GAIN
HI_BIAS
LO_GAIN
LO_BIAS
HI_GAIN_1
HI_BIAS_1
LO_GAIN_1
LO_BIAS_1
GAIN
GAIN_1
BKCAL_IN
BKCAL_IN_1
BKCAL_OUT
BAL_TIME
NOT_SEL_VAL
NOT_SEL_VAL_1
UPDATE_EVT
BLOCK_ALM
Legend: RO = Read Only
Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
RO
Description
See Chapter 2.3.4
0 - 4
Positive
Positive
Positive
Positive
Positive
0
0
0
0
1.1
0
0.9
0
1.1
0
0.9
1
1
0
Block mode, set MODE_BLK.Target to AUTO, CAS or RCAS
Block errors, see Chapter 6.1.9
Setpoint used by block on CAS mode
Setpoint used by the block in AUTO mode
Primary input value of the block
Secondary input value of block
Operator adjustable parameter to force a given input to be used
Primary output value as a result of executing the block
Secondary output value as a result of executing the block
Access options, see Chapter 2.8.1
Algorithm to be used by the block
• Invalid value (default)
• Output Selector
• Dynamic Limiter
Status options for block, see also Chapter 2.8.4
Gain used for high limit of OUT_1 (Dynamic Limiter)
Bias used for high limit of OUT_1 (Dynamic Limiter)
Gain used for low limit of OUT_1 (Dynamic Limiter)
Bias used for low limit of OUT_1 (Dynamic Limiter)
Gain used for high limit of OUT (Dynamic Limiter)
Bias used for high limit of OUT (Dynamic Limiter)
Gain used for low limit of OUT (Dynamic Limiter)
Bias used for low limit of OUT (Dynamic Limiter)
Gain applied to OUT after limiting (Dynamic Limiter)
Gain applied to OUT after limiting (Dynamic Limiter)
Feedback from BKCAL_OUT of a downstream block
Feedback from BKCAL_OUT of a downstream block
Feedback for BKCAL_IN of an upstream block.
Time allowed to balance OUT changes as a result of a change from Auto, Cas or Rcas to Man
Value of OUT when not selected (Output Selector)
Value of OUT_1 when not selected (Output Selector)
This alert is generated by any change to the static data.
Block alarms, see Chapter 2.9
Endress+Hauser 191
7 Calculation and Logic Blocks ControlCare Application Designer: Function Blocks
7.14 Constant
The Constant block generates constant values for use as inputs parameters to other blocks. Each
Constant block allows up to six analog values (floating point) and two discrete values (0, 1) to be simulated.
In ControlCare Application Designer the Constant block is assigned the generic name Device Tag-
CT-n . It can be found by expanding the appropriate device or Field Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 7-59.
CT_VAL_1
CT_VAL_2
CT_VAL_3
CT_VAL_4
CT_VAL_5
CT_VAL_6
CT_VAL_D1
CT_VAL_D2
MANUAL
AUTO
MANUAL
AUTO
MANUAL
AUTO
MANUAL
AUTO
MANUAL
AUTO
MANUAL
AUTO
MANUAL
AUTO
MANUAL
AUTO
MODE
Fig. 7-59: Schematic diagram of Constant block
7.14.1 Functional description
The Constant block allows the entry of
• up to six analogue values in CT_VAL_1 to CT_VAL_6
• as well as two discrete values in CT_VAL_D1 and CT_VAL_D2 .
The inputs are connected to the
• outputs OUT_1 to OUT_6
• and OUT_D1 and OUT_D2 respectively.
The outputs are connected to other downstream blocks as required.
OUT_1
OUT_2
OUT_3
OUT_4
OUT_5
OUT_6
OUT_D1
OUT_D2
7.14.2 Block configuration
The constant block may be used for a number of purposes, e.g. for providing setpoints and tracking values to PID Control or Analog Alarm blocks. Fig. 7-23 in Chapter 7.6.2 shows an example of its use in a simple temperature control application. Similarly, it may be used to supply a digital switching signal, e.g. to stop or control the execution of a a variety of function blocks.
The block is configured by simply entering the desired value into one of the constant parameters, e.g. for a setpoint temperature of 300°C at OUT_1 and a discrete signal "1" at OUT_D1 the following entries are made. Default value for unconfigured inputs is "0":
Parameter
MODE BLOCK/TARGET
CT_VAL_1
CT_VAL_D1
Function
Normal operating mode of block
Value to be output as OUT_1 by the constant block
Value to be output as OUT_D1 by the constant block
Value
Auto
300
1
192 Endress+Hauser
ControlCare Application Designer: Function Blocks
Mode
Status
Block errors
Constant block
7 Calculation and Logic Blocks
7.14.3 Block operation
The block normally operates in "Auto" mode.
When MODE_BLK.Target
is set to "Man", the block outputs OUT_1 to OUT_6 as well as
OUT_D1 and OUT_D2 can be manipulated.
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
Operation can be checked on-line by viewing a number of parameters:
OUT_1 to OUT_6
OUT_D1, OUT_D2
Value and status of corresponding analog output signal
Value and status of corresponding discrete signal
The significance of the output status is indicated below.
OUT/OUT_1 status
Good
Bad
Meaning
• Normal operation as configured
• Block out of service
Block errors are indicated in the BLOCK_ERR parameter
Condition
Out-of-Service
Reason
• MODE_BLK.Target currently set to OOS
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
OUT_1
OUT_2
OUT_3
OUT_4
OUT_5
OUT_6
OUT_D1
OUT_D2
CT_VAL_1
CT_VAL_2
CT_VAL_3
CT_VAL_4
CT_VAL_5
CT_VAL_6
CT_VAL_D1
CT_VAL_D2
UPDATE_EVT
BLOCK_ALM
Legend: RO = Read Only
7.14.4 Block parameters
Parameter Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
Description
See Chapter 2.3.4
0
0
0
0
0
0
0
0
Block mode, set MODE_BLK.Target to AUTO, CAS or RCAS
Block errors, see Chapter 6.1.9
Output value generated from CT_VAL_1
Output value generated from CT_VAL_2
Output value generated from CT_VAL_3
Output value generated from CT_VAL_4
Output value generated from CT_VAL_5
Output value generated from CT_VAL_6
Output value generated from CT_VAL_D1
Output value generated from CT_VAL_D2
Constant value connected to OUT_1
Constant value connected to OUT_2
Constant value connected to OUT_3
Constant value connected to OUT_4
Constant value connected to OUT_5
Constant value connected to OUT_6
Constant value connected to OUT_D1
Constant value connected to OUT_D2
This alert is generated by any change to the static data.
Block alarms, see Chapter 2.9
Endress+Hauser 193
7 Calculation and Logic Blocks ControlCare Application Designer: Function Blocks
7.15 Constant and Contained RW
The Constant and Contained Read/Write block has two functions:
• generating constant values to use as inputs parameters to other blocks. In this case, it has exactly the same function as the constant block, see Chapter 7.14.
• reading from or writing to contained parameters of blocks being executed within the device from which it originates.
In ControlCare Application Designer the Constant and Contained RW block is assigned the generic name Device Tag-CTRW-n . It can be found by expanding the appropriate device or Field
Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 7-59.
Constant generator
Contained Read/Write
IN_1
DISABLE_1
IN_2
DISABLE_2
IN_D1
DISABLE_D1
IN_D2
DISABLE_D2
CONSTANT
VALUE &
STATUS
CONTAINED
PARAMETER
LOC_OUT
LOC_OUT_D
Fig. 7-60: Schematic diagram of Constant and Contained RW block
OUT_1
OUT_2
OUT_3
OUT_4
OUT_5
OUT_6
OUT_D1
OUT_D2
OUT_D3
OUT_D4
OUT_D5
OUT_D6
7.15.1 Functional description
The Constant block allows the entry of
• up to four analogue values in CT_VAL_1 to CT_VAL_4
• as well as up to four discrete values in CT_VAL_D1 to CT_VAL_D4 .
The inputs are connected to the
• outputs OUT_1 to OUT_4
• and OUT_D1 to OUT_D4 respectively.
The outputs are connected to other downstream blocks as required.
If the outputs OUT_5 , OUT_6 , OUT_D5 and OUT_D6 are not configured for read/write operation, they are also linked to the values in CT_VAL_5 , CT_VAL_6 , CT_VAL_D5 and
CT_VAL_D6 .
Contained parameters of other blocks can be overwritten or read when the block is in Auto mode.
The contained parameter is addressed through the LOC_xxx parameter which comprises the elements below (index and subindex can be read from the Offline Characterization window):
Element name
BLOCK_TAG_xxx
INDEX_:RELATIVE_xxx
SUB_INDEX_xxx
Data type
VisibleString (32)
Unsigned16
Unsigned8
2
1
Size Description
32 Tag of the block containing the contained parameter
(case sensitive!)
Relative index of contained parameter (= offset)
Subindex of structured parameter, counted from 1.
• Simple parameters: no entry is required
• Structured parameters: number of structure element
• Bitstrings: byte of the parameter to be considered.
194 Endress+Hauser
ControlCare Application Designer: Function Blocks 7 Calculation and Logic Blocks
For example, to address IN_1 , the parameters BLOCK_TAG_IN1 , INDEX_RELATIVE_IN1 and for a structured parameter or bit string SUB_INDEX_IN1 must be configured.
The input/output is considered to be not configured when:
• the parameter BLOCK_TAG_xxx is blank or
• INDEX_RELATIVE_xxx and SUB_INDEX_xxx are equal to zero.
In this case, the constant value CT_VAL_xxx is routed to the corresponding output.
If there is a configuration error in the contained parameter, the correspondent bit of the input/ output in CONFIG_STATUS will be set and the BLOCK_ERR will indicate “Configuration Error”.
Reading or writing is not supported in all parameter types. The table below summarizes the operations supported by the block:
Parameter
Input/Output
IN_1,
IN_2
IN_D1,
IN_D2
OUT_5,
OUT_6
OUT_D5,
OUT_D6
Data type
Float
Unsigned8
Float
Unsigned8*
Direction
From
IN_1,
IN_2
IN_D1,
IN_D2
Block parameter
Block parameter
To
Any other block parameter
Any other block parameter
OUT_5,
OUT_6
OUT_D5,
OUT_D6
Data type of contained parameter
Note 1: For data types with "*" the block cuts the values out of the range of the correspondent type:
• Unsigned8/Bitstring: 0 to 255
• Integer8:
• Boolean:
-127 to +127
0 or 1
• Unsigned16:
• Integer16:
0 to 65535
-32767 to +32767
Note 2: For the BitString type, the Subindex identifies the correspondent Byte.
Note 3: The reading or writing in contained parameters are not supported in the same block Constant.
Boolean
Float
Integer8
Integer16
Integer32
Unsigned8
Unsigned16
Unsigned32
Bitstring
Boolean
Float
Integer8
Integer16
Integer32
Unsigned8
Unsigned16
Unsigned32
Bitstring
Boolean*
Float
Integer8*
Integer16*
Integer32
Unsigned8*
Unsigned16*
Unsigned32
Bitstring*
Boolean
Float
Integer8
Integer16
Integer32
Unsigned8
Unsigned16
Unsigned32
Bitstring*
Endress+Hauser 195
7 Calculation and Logic Blocks ControlCare Application Designer: Function Blocks
Writing to contained parameters
Reading from contained parameters
Constant generator
When the block is in Auto mode, the value of the IN_xx parameter is written into the contained parameter addressed by the LOC_xxx parameters according to the following table:
Parameter Value
IN_x >DEAD_BAND_x or
< DEAD_BAND_x
IN_x,
IN_x
>DEAD_BAND_x or
< DEAD_BAND_x
–
IN_x
IN_Dx
IN_Dx,
IN_Dx
IN_Dx
Status
Good
Uncertain
–
Changes from 0 to 1 or changes from 1 to 0
Changes from 0 to 1 or changes from 1 to 0
Remains the same
–
Good,
Uncertain
Bad
Good
Uncertain
Good,
Uncertain
Bad
DISABLE_xx Action
FALSE (= "0") Value written to contained parameter
FALSE (= "0") If STATUS_OPTS "Use Uncertain as Good" is set, value written to contained parameter
TRUE (="1") No write
– No write
FALSE (= "0") Value written to contained parameter
FALSE (= "0") If STATUS_OPTS "Use Uncertain as Good" is set, value written to contained parameter
TRUE (="1") No write
– No write
To avoid cyclical writing in static parameters with the resulting cyclical increment of the ST_REV and generation of an event by UPDATE_EVT two mechanisms are provided:
• For the IN_x inputs, DEAD_BAND_x allows a band either side of the current value of the contained parameter to be defined for which there shall be no change of the parameter. If
DEAD_BAND_X is set to zero, the contained value will be overwritten every time the block executes, provided the other conditions are met.
• For the IN_Dx inputs, a value is written to the contained parameter only when there is a change in condition from FALSE (= "0") to TRUE (="1") or vica versa.
If the write to the desired contained parameter block fails, the input concerned appears in the
BAD_STATUS parameter.
When the block is in Auto mode, the value of the contained parameter addressed by the LOC_xxx parameters is read to the OUT_xx parameter according to the following table.
Parameter Value
OUT_x
OUT_x,
OUT_x
OUT_Dx
OUT_Dx,
Contained value
Contained value
CT_VAL_x
Contained value
Contained value
Status
GoodNonCascade
BadNoComm
CT_STATUS_x
GoodNonCascade
BadNoComm
Action
Value read from contained parameter
Value could not be read from contained parameter
No read: BLOCK_TAG_OUT_x not configured or
INDEX_RELATIVE_x and SUB_INDEX_x = zero
Value read from contained parameter
Value could not be read from contained parameter
OUT_Dx CT_VAL_x CT_STATUS_x No read: BLOCK_TAG_OUT_x not configured or
INDEX_RELATIVE_x and SUB_INDEX_x = zero
Note: the outputs concerned are OUT_ 5, OUT_6, OUT_D5 and OUT_D6
If the read from the desired contained parameter block fails, the output concerned appears in the
BAD_STATUS parameter.
7.15.2 Block configuration
The constant block may be used for a number of purposes, e.g. for providing setpoints and tracking values to PID Control or Analog Alarm blocks. Fig. 7-23 in Chapter 7.6.2 shows an example of its use in a simple temperature control application. Similarly, it may be used to supply a digital switching signal, e.g. to stop or control the execution of a a variety of function blocks. Chapter
7.14.2 contains an example of the block configuration for this example.
196 Endress+Hauser
ControlCare Application Designer: Function Blocks
Writing to contained parameters
7 Calculation and Logic Blocks
A write to a contained parameter might be the necessary to automatically override the output of a
PID block during start-up. For example, it might be desirable to heat quickly until a certain temperature is reached and then control normally. The conditions for this might be:
• PID block: PV_SCALE.EU_100 = 100; PV_SCALE:EU_0 = 0; PV_SCALE.UNIT_INDEX = °C
• Setpoint temperature for start up 100°C
• Setpoint temperature for normal operation 70°C
• Start of normal operation T > 60°C
• Dead band ±15°C
The output from the temperature AI block is checked for HI_LIM = 60°C and LO_LIM = 60°C by two analog alarm blocks. When the heating is started up, the temperature is less than 60°C, so that
AALM_1.OUT_ALM = FALSE and AALM_2.OUT_ALM = TRUE. Under these conditions, the setpoint provided by OUT_1 (= 100°C) of the CTRW block is used in the PID block. When the temperature reaches 60°C, AALM_1.OUT_ALM = TRUE and AALM_2.OUT_ALM = FALSE.
Under these conditions, the setpoint provided by OUT_2 (= 70°C) of the CTRW block is used in the PID block. The dead band ensures that the setpoint is only changed once, and that there is no jitter around the switching point. Please note that this example does not consider what happens on shut down.
temperature measuring device
AI e.g.
TT100-AI-1
OUT
IN
HI_LIM
OUT
AALM_1
OUT_ALM
DISABLE_1 DISABLE_2
IN
OUT_ALM
LO_LIM
OUT
AALM_2
IN e.g.
PID
TC101-PID-1
SP
OUT
IN_1
IN_2
CTRW
OUT_1
OUT_2
OUT_1 = 100°C
OUT_2 = 70°C
Block configuration
Endress+Hauser
Fig. 7-61: Links to be made in the Constant and Contained RW block for the strategy above
The Analog Alarm and CTRW blocks are configured as follows for the above applications:
Parameter
Block AALM_1
MODE_BLK.Target
PV_FTIME
ALARM_HYS
HI_LIM
Block AALM_2
MODE_BLK.Target
PV_FTIME
ALARM_HYS
LO_LIM
Block CTRW
MODE_BLK.Target
CT_VAL_1
CT_VAL_2
BLK_TAG_IN1
INDEX_RELATIVE_IN1
DEAD_BAND_1
BLK_TAG_IN2
INDEX_RELATIVE_IN2
DEAD_BAND_2
Action
Set the target mode of the block to Auto Auto
Enter time constant in seconds for 1st. order damping e.g. 3
Enter alarm hysteresis in % of OUT_RANGE
Enter limit of HI alarm in engineering units e.g. 0 e.g. 60
Set the target mode of the block to Auto Auto
Enter time constant in seconds for 1st. order damping e.g. 3
Enter alarm hysteresis in % of OUT_RANGE
Enter limit of LO alarm in engineering unit e.g. 0 e.g. 60
Set the target mode of the block to Auto
Value output at OUT_1 in Auto mode
Value output at OUT_2 in Auto mode
Block tag of PID block as found in control strategy
The offset of the SP parameter in the PID block
Dead band associatted with IN_1 in same units
Block tag of PID block as found in control strategy
The offset of the SP parameter in the PID block
Dead band associated with IN_2 in same units
Option/Value
Auto
100
60 e.g. TC101-PID-1
8
15 e.g. TC101-PID-1
8
15
197
7 Calculation and Logic Blocks ControlCare Application Designer: Function Blocks
Reading from contained parameters
A possible application for reading a contained parameter would be to read the value of the
TIME_POS_T (TIME_POS_T.VALUE) parameter in the Setpoint Ramp Generator block and use this to initiate another control action at a specific time in the ramp cycle. Fig 7-62 shows the links to be made for such an application.
e.g.
FC101-SPG-1
SPG
TIME_POS_T
CTRW
OUT_5 (= TIME_POS_T)
IN_1
HY_MD_IO
Block configuration
Mode
Status
Block errors
Fig. 7-62: Links to be made in the Constant and Contained RW block for the strategy above
The CTRW block is configured as follows for the above application:
Parameter
MODE_BLK.Target
BLK_TAG_OUT_5
INDEX_RELATIVE_OUT_5
SUB_INDEX_OUT_5
Action
Set the target mode of the block to Auto
Option/Value
Auto
Block tag of PID block as found in control strategy e.g. FC101-SPG-1
Offset of the TIME_POS_T parameter in the SPG block 22
Subindex of the VALUE part of TIME_POS_T 2
7.15.3 Block operation
The block normally operates in "Auto" mode.
When MODE_BLK.Target
is set to "Man", the block outputs OUT_1 to OUT_6 as well as
OUT_D1 to OUT_D6 can be manipulated.
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
Operation can be checked on-line by viewing a number of parameters:
IN_1 to IN_4
OUT_1 to OUT_6
Value and status of corresponding contained parameter
Value and status of corresponding analog output signal or contained parameter
OUT_D1 to OUT_D6 Value and status of corresponding discrete signal or contained parameter
The significance of the output status is indicated below.
OUT/OUT_1 status
Good
Bad
Meaning
• Normal operation as configured; where appropriate, contained parameter could be read
• Block out of service or where appropriate, contained parameter could not be read
Block errors are indicated in the BLOCK_ERR parameter
Condition
Out-of-Service
Block configuration error
Reason
• MODE_BLK.Target currently set to OOS
• BLOCK_TAG_xxx has an invalid value
• INDEX_RELATIVE_xxx has an invalid value
• SUB_INDEX-xxx has an invalid value
• DEAD_BAND_xxx has an invalid value
198 Endress+Hauser
ControlCare Application Designer: Function Blocks
Constant and
Contained RW block
Endress+Hauser
7 Calculation and Logic Blocks
CT_STATUS_5
CT_STATUS_6
CT_STATUS_D1
CT_STATUS_D2
CT_STATUS_D3
CT_STATUS_D4
CT_STATUS_D5
CT_STATUS_D6
OUT_D3
OUT_D4
OUT_D5
OUT_D6
IN_1
DISABLE_1
BLK_TAG_IN1
INDEX_RELATIVE_IN1
SUB_INDEX_IN1
DEAD_BAND_1
IN_1
DISABLE_2
BLK_TAG_IN2
INDEX_RELATIVE_IN2
CT_VAL_3
CT_VAL_4
CT_VAL_5
CT_VAL_6
CT_VAL_D1
CT_VAL_D2
UPDATE_EVT
BLOCK_ALM
CT_VAL_D3
CT_VAL_D4
CT_VAL_D5
CT_VAL_D6
CT_STATUS_1
CT_STATUS_2
CT_STATUS_3
CT_STATUS_4
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
OUT_1
OUT_2
OUT_3
OUT_4
OUT_5
OUT_6
OUT_D1
OUT_D2
CT_VAL_1
CT_VAL_2
7.15.4 Block parameters
Parameter Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
Description
See Chapter 2.3.4
Block mode, set MODE_BLK.Target to AUTO, CAS or RCAS
Block errors, see Chapter 6.1.9
Output value generated from CT_VAL_1
Output value generated from CT_VAL_2
Output value generated from CT_VAL_3
Output value generated from CT_VAL_4
Output value generated from CT_VAL_5/contained parameter
Output value generated from CT_VAL_6/contained parameter
0
0
0
0
0
0
0
0
Output value generated from CT_VAL_D1
Output value generated from CT_VAL_D2
Constant value connected to OUT_1
Constant value connected to OUT_2
Constant value connected to OUT_3
Constant value connected to OUT_4
Constant value connected to OUT_5
Constant value connected to OUT_6
0
0
0
0
Constant value connected to OUT_D1
Constant value connected to OUT_D2
This alert is generated by any change to the static data.
Block alarms, see Chapter 2.9
Constant value connected to OUT_D3
Constant value connected to OUT_D5
Constant value connected to OUT_D5
Constant value connected to OUT_D6
GoodNC Status of constant value connected to OUT_1, default "Good"
GoodNC Status of constant value connected to OUT_2, default "Good"
GoodNC Status of constant value connected to OUT_3, default "Good"
GoodNC Status of constant value connected to OUT_4, default "Good"
GoodNC Status of constant value connected to OUT_5, default "Good"
GoodNC Status of constant value connected to OUT_6, default "Good"
GoodNC Status of constant value connected to OUT_D1, default "Good"
GoodNC Status of constant value connected to OUT_D2, default "Good"
GoodNC Status of constant value connected to OUT_D3, default "Good"
GoodNC Status of constant value connected to OUT_D4, default "Good"
GoodNC Status of constant value connected to OUT_D5, default "Good"
GoodNC Status of constant value connected to OUT_D6, default "Good" blank
0
0
1.0
Output value generated from CT_VAL_D3
Output value generated from CT_VAL_D4
Output value generated from CT_VAL_D5/contnd parameter
Output value generated from CT_VAL_D6/contnd parameter
Input value and status to be written to contained parameter
Discrete signal controlling IN_1 write to contained parameter
Tag of block with contained parameter (case sensitive!)
Offset of contained parameter (see Offline Configuration) blank
0
Subindex of contained parameter (see Offline Configuration)
Dead band associated with IN_1 in same units
Input value and status to be written to contained parameter
Discrete signal controlling IN_2 write to contained parameter
Tag of block with contained parameter (case sensitive!)
Offset of contained parameter (see Offline Configuration)
199
7 Calculation and Logic Blocks ControlCare Application Designer: Function Blocks
Parameter
SUB_INDEX_IN2
DEAD_BAND_2
IN_D1
DISABLE_D1
BLK_TAG_IND11
INDEX_RELATIVE_IN_D1
SUB_INDEX_IN_D1
IN_D2
DISABLE_D2
BLK_TAG_IN_D2
INDEX_RELATIVE_IN_D2
SUB_INDEX_IN_D2
OUT_5
BLK_TAG_OUT_5
INDEX_RELATIVE_OUT_5
SUB_INDEX_OUT_5
OUT_6
BLK_TAG_OUT_6
INDEX_RELATIVE_OUT_6
SUB_INDEX_OUT_6
OUT_D5
BLK_TAG_OUT_D5
INDEX_RELATIVE_OUT_D5
SUB_INDEX_OUT_D5
OUT_D6
BLK_TAG_OUT_D6
INDEX_RELATIVE_OUT_D6
SUB_INDEX_OUT_D6
BAD_OPTS
CONFIG_STATUS
STATUS_OPTS
Legend: RO = Read Only
Valid range/
Options
Default value
Description
0
1.0
blank
0
0 blank
0
0 blank
0
0 blank
0
0 blank
0
0 blank
0
0
0
Subindex of contained parameter (see Offline Configuration)
Dead band associated with IN_2 in same units
Discrete value and status to be written to contained parameter
Discrete signal controlling IN_D1 write to contained parameter
Tag of block with contained parameter (case sensitive!)
Offset of contained parameter (see Offline Configuration)
Subindex of contained parameter (see Offline Configuration)
Discrete value and status to be written to contained parameter
Discrete signal controlling IN_D2 write to contained parameter
Tag of block with contained parameter (case sensitive!)
Offset of contained parameter (see Offline Configuration)
Subindex of contained parameter (see Offline Configuration)
Value and status read from contained parameter
Tag of block with contained parameter (case sensitive!)
Offset of contained parameter (see Offline Configuration)
Subindex of contained parameter (see Offline Configuration)
Value and status read from contained parameter
Tag of block with contained parameter (case sensitive!)
Offset of contained parameter (see Offline Configuration)
Subindex of contained parameter (see Offline Configuration)
Discrete value and status read from contained parameter
Tag of block with contained parameter (case sensitive!)
Offset of contained parameter (see Offline Configuration)
Subindex of contained parameter (see Offline Configuration)
Discrete value and status read from contained parameter
Tag of block with contained parameter (case sensitive!)
Offset of contained parameter (see Offline Configuration)
Subindex of contained parameter (see Offline Configuration)
Indicates contained parameter that cannot be read
• 0: IN_1
• 1: IN_2
• 2: IN_D1
• 3: IN_D2
• 4: OUT_5
• 5: OUT_6
• 6: OUT_D5
• 7: OUT_D6
Indicates contained parameter input with configuration error
• 0: IN_1
• 1: IN_2
• 2: IN_D1
• 3: IN_D2
• 4: OUT_5
• 5: OUT_6
• 6: OUT_D5
• 7: OUT_D6
Status options, see Chapter 2.8.4
200 Endress+Hauser
ControlCare Application Designer: Function Blocks 7 Calculation and Logic Blocks
7.16 Flip-flop and Edge Trigger
The Flip-flop and Edge Trigger block acts as a logic element within a control strategy, passing on a discrete signal to downstream blocks, the value of which is dependent upon the discrete signals at two or more block inputs. It can be configured to work as a:
• SR flip-flop
• RS flip-flop
• D-latch
• Rising edge trigger
• Falling edge trigger
• Bi-directional edge trigger
In ControlCare Application Designer the Flip-flop and Edge Trigger block is assigned the generic name Device Tag-FFET-n . It can be found by expanding the appropriate device or Field Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 7-60.
DISC_OP = SR flip-flop
RESET_IN
SET_IN
IN_D1
IN_D2
L
H
L
H
R
L
L
H
H
SR RS
Qn-1
H
L
H
Qn-1
H
L
L
SR_FLIP_FLOP
IN_D1
L
H
X
IN_D2
H, L,
Q
L
H
Qn-1
D_LATCH
IN_D1
RISING
FALLING
BI-DIRECTIONAL
EDGE TRIGGER
DISC_OP
OUT_D
Fig. 7-63: Schematic diagram of Flip-flop and Edge Trigger block
7.16.1 Functional description
The operating mode of the Flip-flp and Edge Trigger block is determined by the option selected in the parameter DISC_OP . There are six possible modes of operation which are described below.
The SR flip-flop (or latch) generates a discrete output value OUT_D based on the NAND logic of the SET_IN (S) and RESET_IN (R) discrete inputs.
• If the S and R inputs are both low, OUT_D is maintained at a constant state.
• If S is pulsed high while R is held low, then OUT_D is forced high, and stays high when S returns to low.
• Similarly, if R is pulsed high while S is held low, then OUT_D is forced low, and stays low when R returns to low.
• The combination R high and S high forces OUT_D to high.
SET_IN
FALSE (= 0)
FALSE (= 0)
TRUE (=1)
TRUE (=1)
RESET_IN
FALSE (= 0)
TRUE (=1)
FALSE (= 0)
TRUE (=1)
OUT_D
Keep last state
FALSE (= 0)
TRUE (=1)
TRUE (=1)
Endress+Hauser 201
7 Calculation and Logic Blocks
DISC_OP = RS flip-flop
ControlCare Application Designer: Function Blocks
The SR flip-flop can be used in applications requiring a continuous TRUE condition that is to be activated by a momentary switch and where a set always produces a TRUE signal.
macrocycle
SET_IN
OUT_D
TRUE
FALSE
RESET_IN
TRUE
FALSE
TRUE
FALSE time
Fig. 7-64: Output of SR flip-flop as a function of SET_IN and RESET_IN inputs
The RS flip-flop (or latch) generates a discrete output value OUT_D based on the NOR logic of the
SET_IN (S) and RESET_IN (R) discrete inputs.
• If the S and R inputs are both low, OUT_D is maintained at the last state.
• If S is pulsed high while R is held low, then OUT_D is forced high, and stays high when S returns to low.
• Similarly, if R is pulsed high while S is held low, then OUT_D is forced low, and stays low when R returns to low.
• The combination R high and S high forces OUT_D to low.
SET_IN
FALSE (= 0)
FALSE (= 0)
TRUE (=1)
TRUE (=1)
RESET_IN
FALSE (= 0)
TRUE (=1)
FALSE (= 0)
TRUE (=1)
OUT_D (RS flip-flop
Keep last state
State = FALSE (= 0)
State = TRUE (=1)
State = FALSE (= 0)
The RS flip-flop can be used in applications requiring a continuous TRUE condition that is to be activated by a momentary switch and where a reset always produces a FALSE signal.
macrocycle
SET_IN
OUT_D
TRUE
FALSE
RESET_IN
TRUE
FALSE
TRUE
FALSE time
Fig. 7-65: Output of RS flip-flop as a function of SET_IN and RESET_IN inputs
202 Endress+Hauser
ControlCare Application Designer: Function Blocks 7 Calculation and Logic Blocks
DISC_OP = D-latch
DISC_OP = Rising edge
The D-latch option uses the two discrete inputs IN_D1 and IN_D2 .
• When IN_D1 rises, IN_D 2 inverts.
• When IN_D1 is steady or falls, IN_D2 keeps the last state (latches)
IN_D1
Rising (0 to 1)
Rising (0 to 1)
0, 1 or Falling (1 to 0)
IN_D2
1
0
0 or 1
OUT_D (D-latch)
0
1
Keep state
The D-latch can be used in applications where a momentary switch or timing pulse is to be used to start and stop the equipment: macrocycle
IN_D1
IN_D2
OUT_D
TRUE
FALSE
TRUE
FALSE
TRUE
FALSE time
Fig. 7-66: Output of D-latch as a function of IN_D1 and IN_D2 inputs
The rising or positive edge trigger uses the discrete input IN_D1 . When there is a change of IN_D1 from 0 to 1, the output at OUT_D is set high. OUT_D is set low on the next execution of the block.
IN_D1
Rising
Falling
No transition
0
0
OUT_D (rising edge)
1
The positive edge trigger can be used, e.g. to activaate a machine starter when a valve opens.
macrocycle
IN_D1
OUT_D
TRUE
FALSE
TRUE
FALSE time
Fig. 7-67: Output of positive edge trigger as a function of IN_D1
Endress+Hauser 203
7 Calculation and Logic Blocks ControlCare Application Designer: Function Blocks
DISC_OP = Falling edge The falling of negative edge trigger uses the discrete input IN_D1 . When there is a change of IN_D1 from 1 to 0, the output at OUT_D is set high. OUT_D is set low on the next execution of the block.
IN_D1
Rising
Falling
No transition
1
0
OUT_D (falling edge)
0
The negative edge trigger can be used, e.g. to start actions associated with the shutdown of a machine.
DISC_OP = Bi-directional macrocycle
IN_D1
OUT_D
TRUE
FALSE
TRUE
FALSE time
Fig. 7-68: Output of negative edge trigger as a function of IN_D1
The bidirectional edge trigger functions uses the discrete input IN_D1 . When there is a change of
IN_D1 from 0 to 1 or from 1 to 0, OUT_D is set high. If there is no transition on the next execution of the block, OUT_D is set low..
IN_D1
Rising
Falling
No transition
1
0
OUT_D (bidirectional)
1
The bi-directional edge trigger can be used, e.g. to start actions associated with both the start-up and the shutdown of a machine.
Status propagation macrocycle
IN_D1
OUT_D
TRUE
FALSE
TRUE
FALSE time
Fig. 7-69: Output of bi-directional edge trigger as a function of IN_D1
The block checks the status of the inputs before processing them. The table below summarizes the status of OUT under various conditions. ..
STATUS_OPTS
–
–
Use Uncertain as Good
–
IN status
Good
Uncertain
Uncertain
Bad
OUT status
Good
Bad
Good
Bad
Remarks
Block executed
Block not executed
Block executed
Block not executed
204 Endress+Hauser
ControlCare Application Designer: Function Blocks
RS Flip-flop
Block configuration
D-latch
7 Calculation and Logic Blocks
7.16.2 Block configuration
Note
• When using momentary switches and pushbuttons in connection with digital input modules, the period for which the change in state exists must exceed the macrocycle of the control strategy, otherwise it is possible that the change will not be sensed by the controller.
• The same applies to momentary clicks on HMI pushbuttons
The SR flip-flop and RS flip-flop can be used in applications requiring a continuous TRUE condition that is to be activated by a momentary switch. They differ only in their behaviour when both
SET_IN and RESET_IN inputs are true. For the SR flip-flop the output is forced to TRUE, for the
RS flip-flop it is forced to FALSE.
Fig. 7-70 shows a control strategy for a simple pump control application. The SET_IN and
RESET_IN signals are connected to pushbuttons at the DI-1 and DI-2 inputs of a SFC432 voltage input/relay output module via a Multiple Discrete Input block. OUT_D is connected to the pump motor the at the DO-1 output via a Multiple Discrete Output block. For this example it is assumed that the SFC432 module is located at Slot 0 of the rack with address 1.
SET
RESET
DI-1
DI-2
MDI
Channel = 1009
OUT_D1
SET_IN
OUT_D2
RESET_IN
FFET
OUT_D
DISC_OP = RS flip-flop
IN_D1 MDO
Channel = 1019
DO-1 Pump motor
Fig. 7-70: Links to be made to the Flip-flop and Edge Trigger block for the above strategy.
The MDO, FFET and MDI blocks are configured as follows for the above applications:
Parameter
Block MDI
MODE_BLK.Target
CHANNEL
Block FFET
MODE_BLK.Target
DISC_OP
Block CTRW
MODE_BLK.Target
CHANNEL
Action
Set the target mode of the block to Auto
Rack + Slot + Group + 9
Set the target mode of the block to Auto
Block execution mode
Set the target mode of the block to Auto
Rack + Slot + Group + 9
Option/Value
Auto
1009
Auto
RS flip-flop
Auto
1019
The D-latch can be used in applications where a momentary switch or timing pulse is to be used to start and stop the equipment. Since the output is the inverse of the signal IN_D2, it also offers itself as an interlock solution.
Fig. 7-71 shows a control strategy for a pump start-up with interlock for dry running. The IN_D1 signal is connected to pushbuttons at the DI-1 input of a SFC432 voltage input/relay output module via a Multiple Discrete Input block. IN_D2 is connected to a level limit switch at DI-2 that is set to signal TRUE when it is uncovered and FALSE when it is covered. OUT_D is connected to the pump motor the at the DO-1 output via a Multiple Discrete Output block. For this example it is assumed that the SFC432 module is located at Slot 0 of the rack with address 1.
When the pushbutton is pressed and the level limit switch is covered, the FALSE state of the switch results in a TRUE state for the pump motor, which starts up. If the switch is not covered, i.e. there is a danger of dry running, the TRUE state of the switch results in a FALSE state for the motor, which cannot be started.
This interlock works on start up only. Should the liquid level fall below the limit switch during operation of the motor, this will not be signalled.
Endress+Hauser 205
7 Calculation and Logic Blocks ControlCare Application Designer: Function Blocks
PB1
LSL
DI-1
DI-2
MDI
Channel = 1009
OUT_D1
IN_D1
OUT_D2
IN_D2
FFET
OUT_D
DISC_OP = D-latch
IN_D1 MDO
Channel = 1019
DO-1 Pump motor
Block configuration
Fig. 7-71: Links to be made to the Flip-flop and Edge Trigger block for the above strategy
The MDO, FFET and MDI blocks are configured as follows for the above application:
Parameter
Block MDI
MODE_BLK.Target
CHANNEL
Block FFET
MODE_BLK.Target
DISC_OP
Block CTRW
MODE_BLK.Target
CHANNEL
Action
Set the target mode of the block to Auto
Rack + Slot + Group + 9
Set the target mode of the block to Auto
Block execution mode
Set the target mode of the block to Auto
Rack + Slot + Group + 9
Option/Value
Auto
1009
Auto
D-latch
Auto
1019
Bi-directional edge trigger In the case of the bi-directional edge trigger, a change from both FALSE to TRUE and TRUE to
FALSE at IN_D triggers a change from FALSE to TRUE at OUT_D . This signal can be used to trigger a actions required at the start and the shutdown of plant equipment.
Fig. 7-72 shows a control strategy for the start-up and shutdown of a conveyor based on the starting and shutdown of an upstream conveyor. The checkback signal from the motor starter of the upstream conveyor is used start and stop the downstream conveyor, which requires a continuous
TRUE signal to start and a FALSE signal to stop. This is produced by the output of the bi-directional trigger acting on the checkback signal from the second motor in a second FFET block operating as a D-latch. The checkback signals are wired to inputs DI-3 and DI-4 of the SFC432, the motor starter to output DO-4. The interfaces between the input signals and output signals are provided by the
MDI and MDO blocks respectively.
Checkback MO1
DI-3
Checkback MO2
DI-4
MDI
Channel = 1009
OUT_D3
OUT_D4
IN_D1 FFET_1
OUT_D
DISC_OP = Bi-directional edge
OUT_D
IN_D1 FFET_2
IN_D2
DISC_OP = D-latch
IN_D4 MDO
Channel = 1019
DO-4
Motor starter
Fig. 7-72: Links to be made to the Flip-flop and Edge Trigger block for the above strategy
206 Endress+Hauser
ControlCare Application Designer: Function Blocks
Block configuration
Mode
Status
Block errors
7 Calculation and Logic Blocks
The MDO, FFET and MDI blocks are configured as follows for the above application:
Action Option/Value Parameter
Block MDI
MODE_BLK.Target
CHANNEL
Block FFET1
MODE_BLK.Target
DISC_OP
Block FFET2
MODE_BLK.Target
DISC_OP
Block MDO
MODE_BLK.Target
CHANNEL
Set the target mode of the block to Auto
Rack + Slot + Group + 9
Set the target mode of the block to Auto
Block execution mode
Set the target mode of the block to Auto
Block execution mode
Set the target mode of the block to Auto
Rack + Slot + Group + 9
Auto
1009
Auto
Bi-directional edge
Auto
D-latch
Auto
1019
7.16.3 Block operation
The block normally operates in "Auto" mode.
When MODE_BLK.Target
is set to "Man", the OUT_D can be manipulated.
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
Operation can be checked on-line by viewing a number of parameters:
IN_D1
IN_D2
SET_IN
RESET_IN
OUT_D
Value and status of input 1 supplied by upstream block
Value and status of input 2 supplied by upstream block
Value and status of set input of RS flip-flop or SR flip-flop supplied by upstream block
Value and status of reset input of RS flip-flop or SR flip-flop supplied by upstream block
Value and status of corresponding discrete output signal
The significance of the output status is indicated below.
OUT/OUT_1 status
Good
Uncertain
Bad
Meaning
• Normal operation as configured
• Uncertain input but STATUS_OPTS "Use Uncertain as Good" selected
• Block operating in Man mode
• Block out of service
Block errors are indicated in the BLOCK_ERR parameter
Condition
Out-of-Service
Reason
• MODE_BLK.Target currently set to OOS
Endress+Hauser 207
7 Calculation and Logic Blocks ControlCare Application Designer: Function Blocks
Flip-flop and Edge Trigger block
7.16.4 Block parameters
Parameter
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
DISC_OP
STATUS_OPTS
IN_D1
IN_D2
SET_IN
RESET_IN
OUT_D
UPDATE_EVT
BLOCK_ALM
Legend: RO = Read Only
Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
0 - 5
Description
See Chapter 2.3.4
Block mode, set MODE_BLK.Target to AUTO, CAS or RCAS
Block errors, see Chapter 6.1.9
Discrete operation selector
• 0: SR flip-flop
• 1: RS flip-flop
• 2: D-.latch
• 3: rising edge
• 4: falling edge
• 5: bi-diectional edge
Status options
• Use Uncertain as Good
Input value and status of discrete input 1
Input value and status of discrete input 2
Input value and status of set discrete input
Input value and status of reset discrete input
Discrete value and status as a result of executing the block
This alert is generated by any change to the static data.
Block alarms, see Chapter 2.9
208 Endress+Hauser
ControlCare Application Designer: Function Blocks 7 Calculation and Logic Blocks
7.17 Advanced Equations
The Advanced Equations block has been designed to support specific calculations relevant to process engineering.
In ControlCare Application Designer the Advanced Equations block is assigned the generic name
Device Tag-AEQU-n . It can be found by expanding the appropriate device or Field Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 7-73.
IN_1
IN_2
IN_3
IN_4
IN_D1
IN_D2
EQUATION
CALCULATION
EQ_TYPE
OUT
OUT_1
OUT_2
OUT_D1
Fig. 7-73: Schematic diagram of Advanced Equations block
7.17.1 Functional description
The Advanced Equations block provides calculation of the following functions based on the value of the IN_1 and in the case of dew point temperature IN_2 :
• Natural logaritm, ln x
• Logarithm to the base 10, log x
• e to the power x, Exp x
• Dew point temperature
The type of equation used is selected by the parameter EQ_TYPE . The result of the calculation is published at OUT and in case of dew point temperature, OUT_1 and OUT_2 . All other input parameters in the block are not used, with the exception of OUT_HI_LIM and OUT_LO_LIM , which may be used to limit the output. The table below summarizes the configuration for the various options.
1
2
EQ_TYPE Parameter Description
0 ln x Natural logarithm
3 log x exp x
Dew point temperature
Logarithm to the base 10 e to the power x
Dewpoint temperature °F
Inputs
IN_1 = x
IN_1 = x
IN_1 = x
IN_1 = dry bulb temperature °F
IN_2 = relative humidity %
Outputs
OUT = ln x
OUT = log x
OUT = exp x
OUT = dewpoint temperature
OUT_1 = water vapour saturation pressure (psia)
OUT_2 = water vapour pressure (pw)
255 Special
7.17.2 Block configuration
The parameter MODE_BLK.Target must be set to Auto. If required, limits can be set on the OUT value with the parameters OUT_HI_LIM and OUT_LO_LIM .
Endress+Hauser 209
7 Calculation and Logic Blocks ControlCare Application Designer: Function Blocks
Mode
Status
Block errors
7.17.3 Block operation
The block normally operates in "Auto" mode.
When MODE_BLK.Target
is set to "Man", the block outputs OUT , OUT_1 and OUT_2 can be manipulated depending upon EQ_TYPE .
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
Operation can be checked on-line by viewing a number of parameters:
IN_1, IN_1 Value and status of corresponding input signal
OUT, OUT_1, OUT_2 Value and status of corresponding analog output signal
The significance of the output status is indicated below.
Output status
Good
Bad
Meaning
• Normal operation as configured
• Block out of service
Block errors are indicated in the BLOCK_ERR parameter
Condition
Out-of-Service
Block Configuration Error
Reason
• MODE_BLK.Target currently set to OOS
• Abnormal result of calculation (+/- INF, NaN)
Advanced Equations block
7.17.4 Block parameters
Parameter
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
EQ_TYPE
IN_1
IN_2
IN_3, IN_4
IN_D1, IN_D2
OUT_1
OUT_D1
OUT_2
OUT_3
CT_VAL_1 - CT_VAL_6
CT_VAL_D1, CT_VAL_D2
OUT_HI_LIM
OUT_LO_LIM
BLOCK_ALM
Legend: RO = Read Only
Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
0-3, 255 0
Description
See Chapter 2.3.4
0
Block mode, set MODE_BLK.Target to AUTO, CAS or RCAS
Block errors, see Chapter 6.1.9
Selection of equation to be used:
• 0: ln x
• 1: log x
• 2: exp x
• 3: dew point
• 255: reserved (currently no function)
• EQ_TYPE = 0, 1, 2: input value for equation;
• EQ_TYPE = 3: dry bulb temperature °F
• EQ_TYPE = 3: relative humidity %
Input values, not used
Discrete input values, not used
• EQ_TYPE = 0, 1, 2: result of executing block;
• EQ_TYPE = 3: dewpoint temperature °F
Discrete output value, not used
• EQ_TYPE = 3: saturation pressure water vapour (psia)
• EQ_TYPE = 3: pressure water vapour (pw)
Not used
Not used
HI limit for OUT value
LO limit for OUT value
Block alarms, see Chapter 2.9
210 Endress+Hauser
ControlCare Application Designer: Function Blocks 7 Calculation and Logic Blocks
7.18 Density
The Density block has an algorithm to calculate density in various engineering units, e.g. °Plato,
°Brix, TC and °INPM.
In ControlCare Application Designer the Density block is assigned the generic name Device Tag-
DENS-n . It can be found by expanding the appropriate device or Field Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 7-74.
IN_1
PRESSURE
UNITS
HEIGHT
GRAVITY
F1
F2
DENSITY
CALCULATION
NUM_SAMPLES
TEMPERATURE
COMPENSATION
NUM_AVERAGE
MAN
DENS_UNITS
AVERAGE
CALCULATION
AUTO
IN_2
IN_3
RESET_IN
T
MAN
UNITS
CONVERSION
AUTO
OUT_HI_LIM
OUT_LO_LIM
MAN
OUT_SCALE
ALARM
HI/LO
AUTO
DENS_OUT
OUT
OUT_D1
Fig. 7-74: Schematic diagram of Density block
7.18.1 Functional description
The Density block calculates the density of a liquid based on the pressure measured at two points within the tank with a known difference in height, DEN_HEIGHT .
DEN_HEIGHT
LH RESET_IN: e.g. limit switch
P2 IN_2: Pressure transmitter 2
T IN_3: Temperature transmitter
P1 IN_1: Pressure transmitter 1
Fig. 7-75: Arrangement of pressure and temperature transmitters for density measurement
The input parameters are as follows:
• IN_1 is the pressure measured by the lower transmitter
• IN_2 is the pressure measured by the higher transmitter
• IN_3 is the temperature in °C measured by the temperature transmitter
The calculation is made using the average from several pressure transmitter samples, whereby the number of the samples is determined by the NUM_SAMPLES parameter. When RESET_IN is true
(= 1), the average calculation is reset. This allows the calculation to be automatically reset by a level limit switch when the vessel is filled and pressure transmitter is covered or by operator intervention from the HMI.
Endress+Hauser 211
7 Calculation and Logic Blocks
Valid pressure units
ControlCare Application Designer: Function Blocks
The density is in g/cm
3
is calculated as follows:
D = f P1 P2 where: f is a conversion factor to transform the formula coefficients to the same units
P1 is the average pressure measured at IN_1
P2 is the average pressure measured at IN_2
DEN_HEIGHT is the distance between the two measuring points in the same units as the pressure measurement
GRAVITY is the acceleration due to gravity in m/s
2
The average pressure is calculated in a rolling buffer as follows:
Pi = n
INi j = 1 n where: Pi is the average pressure
INi is the pressure measured at IN_i at sample j n is the number of samples NUM_SAMPLES
The temperature is compensated as part of the the density calculation. The output DENS_OUT is the compensated density in units of g/cm
3
. The OUT parameter is the compensated density in the engineering units selected by EU_SEL parameter.
The density block allows limits to be placed on the OUT ouput. If the density exceeds HI_LIM or drops below LO_LIM an alarm is indicated in HI_ALM or LO_ALM and the output OUT_D is set to true. The alarm is disabled when one or both of the limit parameters are set to
±
INF
When RESET_IN changes from false to true, the density block, including the previous density, the rolling buffer and all outputs of the block, is reset. The status is taken from the last cycle.
The following units can be selected for use by the block
1141
1144
1145
1148
1147
1151
1150
1154
1156
1158
Index
1130
1133
1132
1137
1138
1139
1140
Pressure unit
Pa
KPa
MPa bar millibar torr atm psi g/cm
2 kg/cm
2 in H
2
O in H
2
0 at 4 °C mm H
2
O mm H
2
0 at 4 °C ft H
2
O in Hg mm Hg in mm mm ft in cm cm in in mm cm cm mm cm
HEIGHT unit m m m
For an accurate density measurement, the distance between the two pressure transmitters must be measured with an accuracy of
±
1 mm. The corresponding number of decimal places must be used when entering the HEIGHT parameter in metres, centimetres, feet or inches.
212 Endress+Hauser
ControlCare Application Designer: Function Blocks
Status propagation
Control strategy
Block configuration
Endress+Hauser
7 Calculation and Logic Blocks
The primary input status of IN_1 and IN_2 is propagated to the outputs. If the status becomes bad or it becomes uncertain and option “Use Uncertain as Good” in STATUS_OPTS is not set, the block mode will be forced to Man and the algorithm stops the calculation.
If the secondary input IN_3 is unusable, the algorithm uses the last usable value and the output status will be Uncertain. A bad status in RESET_IN input does not stop the algorithm.
If target mode is Man then the output status is Good.Block configuration
The parameter MODE_BLK.Target must be set to Auto. If required, limits can be set on the OUT value with the parameters OUT_HI_LIM and OUT_LO_LIM .
7.18.2 Block configuration
Fig. 7-76 shows a control strategy for an extract measurement in a beer tank. The input to the block is provided by three analog input blocks for the continuous temperature and pressure measurements and a multiple discrete input block connected to the level switch. A matched pair of pressure transmitters with a measuring range of 0 - 5000 mbar is to be used, the distance between the mounting points being 1750 mm.
The density is to be measured in °Plato, and a signal is to be given to the operator when the measured value drops below 3.00. To this end, the OUT value is limited, and the OUT_D signal is used to actuate a visual alert via a multiple discrete output block.
The connection to both the limit switch and the visual alarm is made with a ControlCare SFC432
I/O module located in Rack 1, Slot 0.
pressure transmitter 1
AI_1
OUT pressure transmitter 2
AI_2
OUT
IN_1
IN_2
IN_3
RESET_IN
DENS_OUT
DENS
OUT
OUT_D
HI_LIM
LOW_LIM g/cm3
°Plato
HMI
IN_D1 MDO DO-1 Lamp temperature transmitter
AI_3
OUT
Channel = 1019
LH limit switch
DI-1
MDI
OUT_D1
Channel = 1009
Fig. 7-76: Control strategy for extract measurement in beeer
The MDO, AI, DENS and MDI blocks are configured as follows for the above application:
Parameter
Block AI_1
Block AI_2
MODE_BLK.Target
XD_SCALE.EU_100
XD_SCALE.EU_0
XD_SCALE.UNIT_INDEX
OUT_SCALE.EU_100
OUT_SCALE.EU_0
OUT_SCALE.UNIT_INDEX
Action
Set the target mode of the block to Auto
Input scaling, upper range value
Input scaling, lower range value
Input scaling, engineering units
Input scaling, upper range value
Input scaling, lower range value
Input scaling, engineering units
Option/Value
Auto
0
5000 mbar
0
5000 mbar
213
7 Calculation and Logic Blocks
Mode
Status
Block errors
ControlCare Application Designer: Function Blocks
Parameter
Block AI_3
MODE_BLK.Target
XD_SCALE.EU_100
XD_SCALE.EU_0
XD_SCALE.UNIT_INDEX
OUT_SCALE.EU_100
OUT_SCALE.EU_0
OUT_SCALE.UNIT_INDEX
Block MDI
MODE_BLK.Target
CHANNEL
Block DENS
MODE_BLK.Target
OUT_SCALE.EU_100
OUT_SCALE.EU_0
OUT_SCALE.UNIT_INDEX
EU_SEL
PRESSURE_UNITS
DEN_HEIGHT
LO_PRI
LO_LIM
Block MDO
MODE_BLK.Target
CHANNEL
Action
Set the target mode of the block to Auto
Input scaling, upper range value
Input scaling, lower range value
Input scaling, engineering units
Input scaling, upper range value
Input scaling, lower range value
Input scaling, engineering units
Set the target mode of the block to Auto
Rack + Slot + Group + 9
Set the target mode of the block to Auto
Input scaling, upper range value
Input scaling, lower range value
Input scaling, engineering units (for HMI)
Select engineering units for OUT value
Select pressure unit output by trnsmitters
Distance between the pressure transmitters in the same units as the pressure measurement
Prioritiy of LO_LIM alarm
Value of lower limit in units of OUT
1
3
Auto
20
0
Plato Degree
Plato Degree mbar
175.0 (cm)
Set the target mode of the block to Auto
Rack + Slot + Group + 9
Auto
1019
Option/Value
Auto
-200
600
°C
-200
600
°C
Auto
1009
7.18.3 Block operation
The block normally operates in "Auto" mode.
When MODE_BLK.Target
is set to "Man", the block outputs OUT , OUT_1 and OUT_2 can be manipulated depending upon EQ_TYPE .
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
Operation can be checked on-line by viewing a number of parameters:
IN_1, IN_1 Value and status of corresponding input signal
OUT, OUT_1, OUT_2 Value and status of corresponding analog output signal
The significance of the output status is indicated below.
Output status
Good
Bad
Meaning
• Normal operation as configured
• Block out of service
Block errors are indicated in the BLOCK_ERR parameter
Condition
Out-of-Service
Reason
• MODE_BLK.Target currently set to OOS
214 Endress+Hauser
ControlCare Application Designer: Function Blocks
Density block
7 Calculation and Logic Blocks
GRANT_DENY
STATUS_OPTS
IN_1
IN_2
IN_3
PRESSURE_UNITS
DEN_HEIGHT
GRAVITY
NUM_SAMPLES
NUM_AVERAGES
DENS_OUT
DENS_UN ITS
OUT_D
RESET_IN
OUT_HI_LIM
OUT_LO_LIM
UPDATE_EVT
BLOCK_ALM
ALARM_SUM
ACK_OPTION
7.18.4 Block parameters
Parameter
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
OUT
OUT_SCALE
EU_SEL
ALARM_HYS
HI_PRI
HI_LIM
LO_PRI
LO_LIM
HI_ALM
LO_ALM
Legend: RO = Read Only
Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
0 - 3
0, 1
0
0
0
0
Description
See Chapter 2.3.4
Block mode, set MODE_BLK.Target to AUTO, CAS or RCAS
Block errors, see Chapter 6.1.9
Value output after execution of the block
Scaling of output value
Select engineering units for OUT value
• 0: Plato Degree
• 1: Brix
• 2: TC
• 3: INPM
Access options, see Chapter 2.8.1
Status options
• Use Uncertain as Good
Input value and status of pressure transmitter 1
Input value and status of pressure transmitter 2
Input value and status of temperature transmitter (°C)
Selection of pressure unit used by pressure transmitters 1 and 2 see table g/cm
2 positive positive
1000
9.80665
1 - 1000 10
Distance between the pressure transmitters in the same units as the pressure measurement, see table
Acceleration due to gravity in m/s
Number of samples per average
2
1 - 30
RO
10 g/cm
2
Number of averages in rolling buffer
Density in g/cm
2
compensated for temperature
Units of DENS_OUT for HMI (always g/cm
2
)
RO
100
0
Discrete output indicating limit alarm
Discrete input for resetting the density calculation and buffer
Upper limit for OUT value, above which the status is "Limited"
Lower limit for OUT value, below which the status is "Limited"
Alert generated by any change to the static data.
Block alarms, see Chapter 2.9
Alarm summary, see Chapter 2.9
See Chapter 2.9
• 0: Auto ACK Disable
• 1: Auto ACK Enable
0 to 50 % 0.5%
0 to 15
0 to 15
+INF
-INF
Alarm hysteresis in % of OUT_SCALE, see Chapter 2.9
Priority of the HI alarm, see Chapter 2.9
Setting of HI alarm in engineering units, see Chapter 2.9.
Priority of the LO alarm, see Chapter 2.9.
Setting of LO alarm in engineering units, see Chapter 2.9.
Status of HI alarm and its associated time stamp.
Status of LO alarm and its associated time stamp.
Endress+Hauser 215
7 Calculation and Logic Blocks ControlCare Application Designer: Function Blocks
7.19 Hybrid with Analog I/O
The Hybrid Analog I/O block allows freely programmable logical seqences and calculations to be performed with in a strategy based on analog input values. After execution of the block, the results are presented as analog output values.
In ControlCare Application Designer the Hybrid Analog I/O block is assigned the generic name
Device Tag-HY-MA-IO-n . It can be found by expanding the appropriate device or Field Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 7-77.
IN_5
IN_6
IN_7
IN_8
IN_1
IN_2
IN_3
IN_4
IN_9
IN_10
IN_11
IN_12
IN_13
IN_14
IN_15
IN_16
LF
analog I/Os
LP
IO
LD
IF Q=F THEN
ST
ELSEIF
S2
FILL
S1
SFC
EMPTY
S5
STIR
LD PStart
IL
CAL Tseq
IEC 61131-3 custom
OUT_1
OUT_2
OUT_3
OUT_4
OUT_5
OUT_6
OUT_7
OUT_8
OUT_9
OUT_10
OUT_11
OUT_12
OUT_13
OUT_14
OUT_15
OUT_16
EXEC_ALM
Fig. 7-77: Schematic diagram of Analog I/O hybrid block
216 Endress+Hauser
ControlCare Application Designer: Function Blocks
Block execution
Status propagation
7 Calculation and Logic Blocks
7.19.1 Functional description
The Hybrid Analog I/O block is created in Application Designer and programmed in OpenPCS. The programming of the block is described in the IEC 61131-3 Tutorials BA038S/04/en (Ladder Logic) and BA056S/04/en (Structured Text).
The block allows up to sixteen analog signals IN_1 to IN_16 to be used as inputs to a control routine that has been programmed in a IEC 61131-3 function block language. The result of executing the routine is output at up to eight outputs OUT_1 to OUT_16 .
Note
• For ControlCare Versions <2.04.xx, the Analog Hybrid block has only eight inputs and outputs
The parameter EXEC_TIME_TARGET allows a target execution time to be set for the block, default value is 10 ms. This is normally set after observation of the actual execution time in
EXEC_TIME_ACTUAL . Details of the block execution can be found by expanding the parameter
EXEC_DETAILS :
Parameter
EXECUTIONS
EXCEEDINGS
RATIO
START_DATE
EXEC_ERROR
ALM_SEL
Meaning
No of executions of the block to since the block was put into the current mode
No of times the execution of the block took longer than target execution time
Ratio of executions within permitted time to number exceeding permitted time
Date and time when block was last set to Auto (not used)
IEC 61311 execution error; "0" if no error, see description
Selects which IEC 61131 execution alarm causes EXEC_ERROR to be set
• Select from the list of EXEC_ERROR options offered
• Multiple choices are allowed
The EXEC_ERROR parameter indicates the current execution error as follows:
Error
None
OOS
Runtime stopped
Program error
Time exceeded
Endless loop
Trigger error
HYB table error
Link pointer error
PI error
PB error
LOC error
MB error
Bit value Description
0x0000 IEC 61131 program is running as expected.
0x0001 IEC 61131 program is not running because the target block mode is OOS
0x0002 IEC 61131 runtime state is not running
– Set runtime state to running in OpenPCS.
0x0004 IEC 61131 program is not available.
– Has to be downloaded in OpenPCS.
– Interrupt name of the IEC1131 program does not match the hybrid block tag.
0x0008 Execution of the IEC1131 program has taken longer than the permitted three times in a row.
0x0010 IEC 61131 program has been in an endless loop and was stopped
0x0020 The interrupt trigger is not valid
0x0040 The hybrid FB IEC program mapping table is invalid
0x0080 No IO links configured or at least one of the pointers to the linkable IO's is not valid
• Make/check the links in the I/O mapping tool
0x0100 Not used
0x0200 Not used
0x0400 Not used
0x0800 Not used
EXEC_ALM is set if there is a program execution error, and clears automically when the error no longer exists.
The parameter HYB_STATUS_OPS determines the status to be used with the output parameters.
When the option "Set Outputs to Good Non Cascade" is selected, all outputs carry the status
"GoodNonCascade:NonSpecific:NotLimited" when the block is in Auto, otherwise they are Bad. If no option is selected, the status is bad by default but can be handled within the IEC 61131 program.
Endress+Hauser 217
7 Calculation and Logic Blocks
Mode
Status
Block errors
Analog Hybrid block
ControlCare Application Designer: Function Blocks
7.19.2 Block operation
The block normally operates in "Auto" mode. If the IEC 61131 program fails to execute, the block mode is automatically set to OOS (Out of Service).
When MODE_BLK.Target
is set to "Man", the IEC 61131 program is not executed and the last good value with status is retained. The block outputs can be manipulated in OpenPCS.
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
Operation can be checked on-line by viewing a number of parameters:
IN_1 to IN_8
OUT_1 to OUT_8
Value and status of corresponding input signal
Value and status of corresponding analog output signal
The significance of the output status is indicated below.
Output status
Good
Bad
Meaning
• Normal operation as configured
• Block out of servic
• IEC 61131 program not running, see EXEC_ERROR in EXEC_DETAILS
Block errors are indicated in the BLOCK_ERR parameter
Condition
Out-of-Service
Reason
• MODE_BLK.Target currently set to OOS
• IEC 61131 execution error, see EXEC_ERROR in EXEC_DETAILS
7.19.3 Block parameters
Parameter
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
PI_POINTER
CONTENTS_REV
EXEC_TIME_TARGET
EXEC_TIME_ACTUAL
IO_RESPONSE_TIME
HYB_STATUS_OPS
EXEC_DETAILS
BLK_ALM
EXEC_ALM
IN_1 ... IN_16
OUT_1 ... OUT_16
Legend: RO = Read Only
Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
Description
See Chapter 2.3.4
0 - 300
RO
RO
10
0
Block mode, set MODE_BLK.Target to AUTO
Block errors, see Chapter 6.1.9
Indicates IEC 61131 index, 0 when not running
Not used
Permitted execution time of block in milliseconds
– Must be consistent with value used for FF schedule calculation.
Current execution time of block in milliseconds
Worst case IO response time which includes the interval of the input scan plus the measured time for reading the inputs, executing the IEC61131 program and writing the outputs.
Hybrid block status options
• 0: Bad, status handled by IEC 61131 program
• 1: Set Outputs to Good Non Cascade
Details of block execution, see Chapter 7.19.1
Block alarms, see Chapter 2.9
Indicates presence of programm execution error
Value and status of IN_1 ... IN_16
Value and status of OUT_1 ... OUT_16 as result of executing block
218 Endress+Hauser
ControlCare Application Designer: Function Blocks 7 Calculation and Logic Blocks
7.20 Hybrid with Discrete I/O
The Hybrid Discrete I/O block allows freely programmable logical seqences and calculations to be performed with in a strategy based on analog input values. After execution of the block, the results are presented as analog output values.
In ControlCare Application Designer the Hybrid Discrete I/O block is assigned the generic name
Device Tag-HY-MD-IO-n . It can be found by expanding the appropriate device or Field Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 7-78.
IN_D1
IN_D2
IN_D11
IN_D12
IN_D13
IN_D14
IN_D15
IN_D16
IN_D17
IN_D18
IN_D19
IN_D20
IN_D21
IN_D22
IN_D23
IN_D24
IN_D3
IN_D4
IN_D5
IN_D6
IN_D7
IN_D8
IN_D9
IN_D10
LF
discrete I/Os
LP
IO
LD
IF Q=F THEN
ST
ELSEIF
S2
FILL
S1
SFC
EMPTY
S5
STIR
LD PStart
IL
CAL Tseq
IEC 61131-3 custom
OUT_D1
OUT_D2
OUT_D3
OUT_D4
OUT_D5
OUT_D6
OUT_D7
OUT_D8
OUT_D9
OUT_D10
OUT_D11
OUT_D12
OUT_D13
OUT_D14
OUT_D15
OUT_D16
OUT_D17
OUT_D28
OUT_D19
OUT_D20
OUT_D21
OUT_D22
OUT_D23
OUT_D24
EXEC_ALM
Fig. 7-78: Schematic diagram of Discrete I/O hybrid block
Endress+Hauser 219
7 Calculation and Logic Blocks
Block execution
Status propagation
ControlCare Application Designer: Function Blocks
7.20.1 Functional description
The Hybrid Discrete I/O block is created in Application Designer and programmed in OpenPCS.
The programming of the block is described in the IEC 61131-3 Tutorials BA038S/04/en (Ladder
Logic) and BA056S/04/en (Structured Text).
The block allows up to 24 discrete signals IN_D1 to IN_D24 to be used as inputs to a control routine that has been programmed in a IEC 61131-3 function block language. The result of executing the routine is output at up to 24 discrete outputs OUT_D1 to OUT_D24 .
Note
• For ControlCare Versions <2.04.xx, the Discrete Hybrid block has only 16 inputs and outputs
The parameter EXEC_TIME_TARGET allows a target execution time to be set for the block, default value is 10 ms. This is normally set after observation of the actual execution time in
EXEC_TIME_ACTUAL . Details of the block execution can be found by expanding the parameter
EXEC_DETAILS :
Parameter
EXECUTIONS
EXCEEDINGS
RATIO
START_DATE
EXEC_ERROR
ALM_SEL
Meaning
No of executions of the block to since the block was put into the current mode
No of times the execution of the block took longer than target execution time
Ratio of executions within permitted time to number exceeding permitted time
Date and time when block was last set to Auto (not used)
IEC 61311 execution error; "0" if no error, see description
Selects which IEC 61131 execution alarm causes EXEC_ERROR to be set
• Select from the list of EXEC_ERROR options offered
• Multiple choices are allowed
The EXEC_ERROR parameter indicates the current execution error as follows:
Error
None
OOS
Runtime stopped
Program error
Time exceeded
Endless loop
Trigger error
HYB table error
Link pointer error
PI error
PB error
LOC error
MB error
Bit value Description
0x0000 IEC 61131 program is running as expected.
0x0001 IEC 61131 program is not running because the target block mode is OOS
0x0002 IEC 61131 runtime state is not running
– Set runtime state to running in OpenPCS.
0x0004 IEC 61131 program is not available.
– Has to be downloaded in OpenPCS.
– Interrupt name of the IEC1131 program does not match the hybrid block tag.
0x0008 Execution of the IEC1131 program has taken longer than the permitted three times in a row.
0x0010 IEC 61131 program has been in an endless loop and was stopped
0x0020 The interrupt trigger is not valid
0x0040 The hybrid FB IEC program mapping table is invalid
0x0080 No IO links configured or at least one of the pointers to the linkable IO's is not valid
• Make/check the links in the I/O mapping tool
0x0100 Not used
0x0200 Not used
0x0400 Not used
0x0800 Not used
EXEC_ALM is set if there is a program execution error, and clears automically when the error no longer exists.
The parameter HYB_STATUS_OPS determines the status to be used with the output parameters.
When the option "Set Outputs to Good Non Cascade" is selected, all outputs carry the status
"GoodNonCascade:NonSpecific:NotLimited" when the block is in Auto, otherwise they are Bad. If no option is selected, the status is bad by default but can be handled within the IEC 61131 program.
220 Endress+Hauser
ControlCare Application Designer: Function Blocks
Mode
Status
Block errors
Discrete Hybrid block
7 Calculation and Logic Blocks
7.20.2 Block operation
The block normally operates in "Auto" mode. If the IEC 61131 program fails to execute, the block mode is automatically set to OOS (Out of Service).
When MODE_BLK.Target
is set to "Man", the IEC 61131 program is not executed and the last good value with status is retained. The block outputs can be manipulated in OpenPCS.
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
Operation can be checked on-line by viewing a number of parameters:
IN_D1 to IN_D24 Value and status of corresponding input signal
OUT_D1 to OUT_D24 Value and status of corresponding analog output signal
The significance of the output status is indicated below.
Output status
Good
Bad
Meaning
• Normal operation as configured
• Block out of service
• IEC 61131 program not running, see EXEC_ERROR in EXEC_DETAILS
Block errors are indicated in the BLOCK_ERR parameter
Condition
Out-of-Service
Reason
• MODE_BLK.Target currently set to OOS
• IEC 61131 execution error, see EXEC_ERROR in EXEC_DETAILS
7.20.3 Block parameters
Parameter
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
PI_POINTER
CONTENTS_REV
EXEC_TIME_TARGET
EXEC_TIME_ACTUAL
IO_RESPONSE_TIME
HYB_STATUS_OPS
EXEC_DETAILS
BLK_ALM
EXEC_ALM
IN_D1 ... IN_D24
OUT_D1 ... OUT_D24
Legend: RO = Read Only
Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
Description
See Chapter 2.3.4
0 - 300
RO
RO
10
0
Block mode, set MODE_BLK.Target to AUTO
Block errors, see Chapter 6.1.9
Indicates IEC 61131 index, 0 when not running
Not used
Permitted execution time of block in milliseconds
– Must be consistent with value used for FF schedule calculation.
Current execution time of block in milliseconds
Worst case IO response time which includes the interval of the input scan plus the measured time for reading the inputs, executing the IEC61131 program and writing the outputs.
Hybrid block status options
• 0: Bad, status handled by IEC 61131 program
• 1: Set Outputs to Good Non Cascade
Details of block execution, see Chapter 7.19.1
Block alarms, see Chapter 2.9
Indicates presence of programm execution error
Value and status of IN_D1 ... IN_D24
Value and status of OUT_D1 ... OUT_D24 as result of executing block
Endress+Hauser 221
7 Calculation and Logic Blocks ControlCare Application Designer: Function Blocks
7.21 Hybrid with Embedded I/O
The Hybrid Embedded I/O block allows freely programmable logical seqences and calculations to be performed with in a strategy based on analog and discrete input values. After execution of the block, the results are presented as analog and discrete output values.
In ControlCare Application Designer the Hybrid Discrete I/O block is assigned the generic name
Device Tag-HY-EMB-IO-n . It can be found by expanding the appropriate device or Field
Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 7-79.
Note
• The Hybrid Embedded I/O block replaces the Hybrid Mixed I/O block of previous ControlCare versions (< 2.04.xx, Device Tag-HY-MAD-IO-n). On updating a project, any mixed block is automatically updated to an embedded block.
IN_D6
IN_D7
IN_D8
IN_D9
IN_D10
IN_D11
IN_D12
IN_D13
IN_D14
IN_D15
IN_7
IN_8
IN_D1
IN_D2
IN_D3
IN_D4
IN_D5
IN_1
IN_2
IN_3
IN_4
IN_5
IN_6
IN_D16
analog and discrete I/Os
LF
LP
IO
LD
IF Q=F THEN
ST
ELSEIF
S2
FILL
SFC
S1
EMPTY
S5
STIR
LD PStart
IL
CAL Tseq
IEC 61131-3 custom
with embedded
Local I/O access
PROFIBUS I/O access
MODBUS I/O access
OUT_1
OUT_2
OUT_3
OUT_4
OUT_5
OUT_6
OUT_7
OUT_8
OUT_D1
OUT_D2
OUT_D3
OUT_D4
OUT_D5
OUT_D6
OUT_D7
OUT_D8
OUT_D9
OUT_D10
OUT_D11
OUT_D12
OUT_D13
OUT_D14
OUT_D15
OUT_D16
EXEC_ALM
Fig. 7-79: Schematic diagram of Embedded I/O hybrid block
222 Endress+Hauser
ControlCare Application Designer: Function Blocks
Block execution
Status propagation
7 Calculation and Logic Blocks
7.21.1 Functional description
The Hybrid Embedded I/O block is created in Application Designer and programmed in OpenPCS.
The configuration and programming of the block is described in the I/O mapping tool Tutorial
BA032S/04/en.
The block allows up to eight analog signals IN_1 to IN_8 and sixteen discrete signals IN_D1 to
IN_D16 to be used as inputs to a control routine that has been programmed in a IEC 61131-3 function block language. The result of executing the routine is output at up to eight analog outputs
OUT_1 to OUT_8 and sixteen discrete outputs OUT_D1 to OUT_D16 .
The parameters FS_VALUE_DISCRETE and FS_VALUE_ANALOG allow all local and linkable outputs to be forced to a universal failsafe discrete or analog value when the block fails.
The parameter EXEC_TIME_TARGET allows a target execution time to be set for the block, default value is 10 ms. This is normally set after observation of the actual execution time in
EXEC_TIME_ACTUAL . Details of the block execution can be found by expanding the parameter
EXEC_DETAILS :
Parameter
EXECUTIONS
EXCEEDINGS
RATIO
START_DATE
EXEC_ERROR
ALM_SEL
Meaning
No of executions of the block to since the block was put into the current mode
No of times the execution of the block took longer than target execution time
Ratio of executions within permitted time to number exceeding permitted time
Date and time when block was last set to Auto (not used)
IEC 61311 execution error; "0" if no error, see description
Selects which IEC 61131 execution alarm causes EXEC_ERROR to be set
• Select from the list of EXEC_ERROR options offered
• Multiple choices are allowed
The EXEC_ERROR parameter indicates the current execution error as follows:
Error
None
OOS
Runtime stopped
Program error
Time exceeded
Endless loop
Trigger error
HYB table error
Link pointer error
PI error
PB error
LOC error
MB error
Bit value Description
0x0000 IEC 61131 program is running as expected.
0x0001 IEC 61131 program is not running because the target block mode is OOS
0x0002 IEC 61131 runtime state is not running
– Set runtime state to running in OpenPCS.
0x0004 IEC 61131 program is not available.
– Has to be downloaded in OpenPCS.
– Interrupt name of the IEC1131 program does not match the hybrid block tag.
0x0008 Execution of the IEC1131 program has taken longer than the permitted three times in a row.
0x0010 IEC 61131 program has been in an endless loop and was stopped
0x0020 The interrupt trigger is not valid
0x0040 The hybrid FB IEC program mapping table is invalid
0x0080 No IO links configured or at least one of the pointers to the linkable IO's is not valid
• Make/check the links in the I/O mapping tool
0x0100 Process image for local and PROFIBUS IO's is invalid
0x0200 At least one of the assigned PROFIBUS points has a problem
• Check in the PROFIBUS Configurator and PROFIBUS Mapping Tool
0x0400 At least one of the assigned Local I/O points has a problem
• Check in I/O Mapping Tool
0x0800 At least one of the assigned Modbus points has a problem
• Check in I/O Mapping Tool
EXEC_ALM is set if there is a program execution error, and clears automically when the error no longer exists.
The parameter HYB_STATUS_OPS determines the status to be used with the output parameters.
When the option "Set Outputs to Good Non Cascade" is selected, all outputs carry the status
"GoodNonCascade:NonSpecific:NotLimited" when the block is in Auto, otherwise they are Bad. If no option is selected, the status is bad by default but can be handled within the IEC 61131 program.
Endress+Hauser 223
7 Calculation and Logic Blocks
Mode
Status
Block errors
ControlCare Application Designer: Function Blocks
7.21.2 Block operation
The block normally operates in "Auto" mode. If the IEC 61131 program fails to execute, the block mode is automatically set to OOS (Out of Service).
When MODE_BLK.Target
is set to "Man", the IEC 61131 program is not executed and the last good value with status is retained. The block outputs can be manipulated in OpenPCS.
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
Operation can be checked on-line by viewing a number of parameters:
IN_1 to IN_8
IN_D1 to IN_D16
Value and status of corresponding analog input signal
Value and status of corresponding discrete input signal
OUT_1 to OUT_8 Value and status of corresponding analog output signal
OUT_D1 to OUT_D16 Value and status of corresponding discrete output signal
LOCAL_IO_STATUS Indicates read/write errors for local IOs assigned to the block
PROFIBUS_IO_STATUS Indicates read/write errors for PROFIBUS IOs assigned to the block
LOCAL_IO_STAT_R0 ...
LOCAL_IO_STAT_R14
Indicates the status of each local IO group
Possible read/write statuses in LOCAL_IO_STATUS and PROFIBUS_IO_STATUS are:
Error
Inputs not used
Bit value Description
0x0001 No local inputs assigned to this block or IO configuration not yet downloaded to
IEC 61131 runtime
Outputs not used
Read error
Write error
Inputs OK
Outputs OK
0x0002 No local outputs assigned to this block or IO configuration not yet downloaded to
IEC 61131 runtime
0x0004
0x0008
0x0010
0x0020
One of the assigned PROFIBUS inputs has a read error
One of the assigned PROFIBUS outputs has a write error
All assigned inputs of the block are in order
All assigned outputs of the block are in order
OpenPCS Dwl needed 0x0040 An OpenPCS download is required to initialize the IO tables
Possible read/write statuses in LOCAL_IO_STAT_R0 ... LOCAL_IO_STAT_R14 are:
Error
Not used
OK
Wrong PI
No config
Invalid pData
Wrong module
Multiple used
Unplugged
Bit value Description
0x01 Group not assigned to this block
0x02
0x04
Group assigned and working as expected
Process image does not match the IO configuration
0x08
0x10
0x20
0x40
0x80
Group not configured in OpenPCS
No memeory in the local IO PI in HeapX
Module present does not correspond to that configured
Output group used by more than one output block
IO module assigned to this group is no longer present
The significance of the output status is indicated below.
Output status
Good
Bad
Meaning
• Normal operation as configured
• Block out of service
• IEC 61131 program not running, , see EXEC_ERROR in EXEC_DETAILS
Block errors are indicated in the BLOCK_ERR parameter
Condition
Out-of-Service
Reason
• MODE_BLK.Target currently set to OOS
• IEC 61131 execution error, see EXEC_ERROR in EXEC_DETAILS
224 Endress+Hauser
ControlCare Application Designer: Function Blocks 7 Calculation and Logic Blocks
7.21.3 Block parameters
Parameter
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
PI_POINTER
CONTENTS_REV
EXEC_TIME_TARGET
EXEC_TIME_ACTUAL
IO_RESPONSE_TIME
HYB_STATUS_OPS
EXEC_DETAILS
BLK_ALM
EXEC_ALM
LOCAL_IO_STATUS
PROFIBUS_IO_STATUS
LOC_IO
PB_IN
PB_OUT
FS_VALUE_DISCRETE
FS_VALUE_ANALOG
IN_1 ... IN_8
OUT_1 ... OUT_8
IN_D1 ... IN_D16
OUT_D1 ... OUT_D16
LOCAL_IO_STAT_R0 ...
LOCAL_IO_STAT_R14
Legend: RO = Read Only
Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
Description
See Chapter 2.3.4
0 - 300
RO
RO
10
0
Block mode, set MODE_BLK.Target to AUTO
Block errors, see Chapter 6.1.9
Indicates IEC 61131 index, 0 when not running
Not used
Permitted execution time of block in milliseconds
– Must be consistent with value used for FF schedule calculation.
Current execution time of block in milliseconds
Worst case IO response time which includes the interval of the input scan plus the measured time for reading the inputs, executing the IEC61131 program and writing the outputs.
Hybrid block status options
• 0: Bad, status handled by IEC 61131 program
• 1: Set Outputs to Good Non Cascade
Details of block execution, see Chapter 7.21.1
Block alarms, see Chapter 2.9
Indicates presence of programm execution error
Indicates read/write errors for local IOs assigned to the block.
• Not used: no local IO modules assigned to block
• OK: local IO assigned and working properly
• Other: see Chapter 7.21.2
Indicates read/write errors for PROFIBUS IOs assigned to the block.
• Not used: no PROFIBUS IO assigned to block
• OK: PROFIBUS IO ssigned and working properly
• Other: see Chapter 7.21.2
Indicates how the IO modules have been assigned to the block.
• Rx: Local I/O rack number
• SyGz: Slot(s) and group(s) in associated rack that have been assigned to the block
• Not used: no points are used from associated rack
Indicates which sections of the Profibus input image have been assigned to this block.
• BEGIN_x: start of the image section
• END_x: End of the image section"
Indicates which sections of the Profibus output image have been assigned to this block.
• BEGIN_x: start of the image section
• END_x: End of the image section"
Failsafe value for all local and linkable discrete outputs
Failsafe value for all local and linkable analogue outputs
Value and status of IN_1 ... IN_8
Value and status of OUT_1 ... OUT_8 as result of executing block
Value and status of IN_D1 ... IN_D16
Value and status of OUT_D1 ... out_d!& as result of executing block
Indicates the status of each local IO group
• See Chapter 2.21.2
Endress+Hauser 225
8 Output Blocks
Setpoint
Scaling
226
ControlCare Application Designer: Function Blocks
8 Output Blocks
8.1
Analog Output
The Analog Output block receives a setpoint value from an upstream function block or higher level process control system and, after scaling, outputs a signal to a downstream transducer block through an internal channel reference. It is used by instruments that act as output elements in a control loop such as valves, actuators, positioners and the SFC446 analog output module.
In ControlCare Application Designer the Analog Output block is assigned the generic name Device
Tag-AO-n . It can be found by expanding the appropriate device or Field Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 8-1.
CAS_IN
SE
RCAS_IN
SP
SELECTOR
SP
FAILSAFE
ACTIVE
PV_SCALE
XD_SCALE
MANUAL
AUTO
FSTATE_VAL
PV
SP
SIMULATE
CHANNEL
(RRSGP)
SP LIMITS
OPERATOR
ENTRY
XD_SCALE
PV_SCALE
IO_OPTS
READ_BACK
OUT
To module
SFC446 or actuator
BKCAL_OUT
Fig. 8-1: Schematic diagram of Analog Output block
8.1.1
Functional description
Depending upon the setting of the MODE_BLK.Target parameter, the Analog Output block receives its setpoint value from the operator, an upstream block or a remote process control system.
MODE_BLK.Target
Auto
Cas
Rcas
Setpoint
SP
CAS_IN
RCAS_IN
Remarks
Sepoint value is constant and is entered manually by the operator.
Setpoint value originates from an upstream block
Setpoint valueoriginates from a supervisory host
On a change in setpoint, the parameters SP_RATE_DN and SP_RATE_UP determine the downward and upward ramp rate at which a change is made from the old to the new value. If the ramp rate is set to zero, there is a step change in the setpoint.
SP_HI_LIM and SP_LO_LIM determine the valid range of setpoint operator entries that can be used with the block. They apply in Auto only, unless the option "Obey SP limits if CAS or RCAS" is selected in CONTROL_OPTS . If the setpoint exceeds the limits, the corresponding value
SP_HI_LIM or SP_LO_LIM is used as setpoint and the output status quality becomes "Limited".
PV_SCALE is used to convert the input signal (setpoint) to percent of span.
• EU_100 is the upper range limit of the input signal, e.g. 100
• EU_0 is the lower range limit of the input signal, e.g. 0
• UNIT_INDEX is the unit of the input signal, e.g. %
• DECIMAL is the number of figures behind the decimal point for displays
Endress+Hauser
ControlCare Application Designer: Function Blocks
Output
Fault state
Mode shedding
Setpoint tracking
Simulation
Status propagation
8 Output Blocks
XD_SCALE is used to convert percent of span to the engineering units used by the hardware.
• EU_100 is the upper range limit of the output signal, e.g. 20
• EU_0 is the lower range limit of the output signal, e.g. 4
• UNIT_INDEX is the unit of the output signal, e.g. mA
• DECIMAL is the number of figures behind the decimal point for displays
This allows portions of the setpoint span to cause full span movement of the output. If the "Increase to close" option is selected in IO_OPTS , the output signal is inverted and a rise in setpoint causes a fall in output value.
When the block is operating in Cas, Rcas or Auto mode, the value obtained after block execution is placed in OUT . The same value is transmitted to the transducer through an internal channel reference given by the CHANNEL parameter, see Chapter 5.1.
If the transducer hardware supports a readback value, such as valve position, that value is run backwards through the XD scaling to act as the PV for the block. If not supported, READBACK is generated from OUT .
The current setpoint value and status is communicated to an upstream block by the BKCAL_OUT parameter. If the option "PV for BKCAL_OUT" is selected in IO_OPTS , then the PV will be transmitted instead of the setpoint.
When the block is operating in Rcas mode, RCAS_OUT carries the block setpoint and status after ramping for output to a supervisory host as back calculation and to allow action to be taken under limiting conditions or mode change.
By default, the last valid value is held if a fault state is detected.
If the "Fault state to value" option is selected in IO_OPTS , OUT will assume the value entered in
FSTATE_VAL when a fault condition exists longer than defined in the parameter FSTATE_TIME or when the option "Fault State" is selected the the resource block parameter SET_FSTATE . This ensures that the hardware connected to the block fails to safe, see Chapter 2.7.
When the option "Fault state restart" in IO_OPTS is selected, FSTATE_VAL will also be used on restart.
SHED_OPT allows the behaviour of the block to be determined after a change in mode, e.g. forced by the system or through operator intervention. "Normal return" options allow the block to recover automatically to target mode, for "No return" options, the operator must enter the target mode manually.
IO_OPTS also allows the setpoint to track PV or an input value when the the target mode is Auto and this changes to Man or LO. Possible behaviour is "SP tracks PV when Man", "SP tracks PV when
LO", "SP tracks RCAS or CAS when Man or LO"
The block supports simulation, see Chapter 2.10. The parameter group SIMULATE is used to specify the output value (setpoint value and status), transducer value (PV value and status) and to enable/disable simulation, provided the associated jumper on the I/O board is set, see Chapter 3.2.
When simulation is active in the Analog Output block, BLOCK_ERROR flags "Simulation Active".
The status of OUT can assume the following values:
GoodCascade
Bad
The output value OUT is valid and can be used for further processing
The output value OUT is invalid.
• Operating mode OOS
• Input status bad
If the "Propagate Fault Bkwd" option in STATUS_OPTS is selected, the BKCAL_OUT and
RCAS_OUT status carries the current OUT status to an upstream block or supervisory system.
Endress+Hauser 227
8 Output Blocks
Current output
Voltage output
DIP switch OFF
= range end 5V
Voltage output
DIP switch ON
= range end 10V
ControlCare Application Designer: Function Blocks
8.1.2
Output configuration for SFC446
The AO block uses the OUT value to force electrical signals as shown in Tables 8-1 to 8-3 below.
The type of output is determined by the wiring (current or voltage) and DIP switch (Range end value
5 DC or 10 VDC), see BA021S/04/en Chapter 3.5.1
The parameters XD_SCALE.EU_100
and XD_SCALE.EU_0
set the range end values of the current signal output of the module. This is normally a standard 0 mA to 20 mA/4 mA to 20 mA signal, but other ranges within these limits are possible. The current output is independent of the setting of the Voltage Range DIP switch on the module and is directly proportional to the
OUT value.
XD_SCALE
EU_100
EU_0
Unit
Range 0 mA to 20 mA
Value Output
20
0 mA
20 mA
0 mA
–
Range 4 mA to 20 mA
Value Output
20
4 mA
20 mA
4 mA
–
Tab. 8-1: Current output of SFC446 module as a function of the XD_SCALE settings
The parameters XD_SCALE.EU_100
and XD_SCALE.EU_0
set the range end values of the voltage signal output of the module. This is normally a standard 1V to 5 V/-5 V to +5 V signal, but other ranges within these limits are possible. The voltage output is dependent of the setting of the
Voltage Range DIP switch on the module and is directly proportional to the OUT value.
XD_SCALE
EU_100
EU_0
Unit
5
1
Range 1 V to 5 V
Value Output
V
5 VDC
1 VDC
–
Range –5 V to +5 V
Value Output
5
–5
V
5 VDC
–5 VDC
–
Tab. 8-2: Voltage output of SFC446 module with DIP swich OFF as a function of the XD_SCALE settings
The parameters XD_SCALE.EU_100
and XD.SCALE_EU_0
set the range end values of the voltage signal output of the module. This is normally a standard 2V to 10 V/-10 V to +10 V signal, but other ranges within these limits are possible. The voltage output is dependent of the setting of the Voltage Range DIP switch on the module and is directly proportional to the OUT value. The readback and OUT value reflect the XD_SCALE entries, not the voltage that can be measured at the output
XD_SCALE
EU_100
EU_0
Unit
5
1
Range 2 V to 10 V
Value Output
V
10 VDC
2 VDC
–
Range –10V to +10V
Value
5
–5
V
Output
10 VDC
–10 VDC
–
Tab. 8-3: Voltage output of SFC446 module with DIP swich ON as a function of the XD_SCALE settings
228 Endress+Hauser
ControlCare Application Designer: Function Blocks 8 Output Blocks
8.1.3
Block configuration
Fig. 8-2 shows an example of basic closed-loop control which uses the Analog Output block. A measurement of flow upstream of a valve ensures a constant flow rate downstream of a valve, by causing the valve to open and close. The valve is operated by an analog electrical positioner which operates across a span of 4 mA to 20 mA, 4 mA being closed and 20 mA being fully open. The connection to the controller is made via output AO-0 (terminals 2A, 3A) of a SFC446 Analog Output module, which is to be found in Rack 2, Slot 2 of the controller backplane.
CV
102
FCV
101
PID control
FT
100
Block configuration
Fig. 8-2: Example of closed-loop control
Fig. 8-3 shows the control strategy together with links that must be made between the blocks.
AI
OUT IN
BKCAL_IN
PID
OUT CAS_IN
AO
CHANNEL AO-1
Positioner
FT100 FCV101 CV102
BKCAL_OUT
Fig. 8-3: Links required for basic closed-loop control
It is assumed that PID block has been configured as described in Chapter 6.1 to give an OUT value in the range 0% to 100%. This becomes the value of CAS_IN and must be scaled using XD_SCALE and PV_SCALE to provide a value between 4 mA and 20 mA to the transducer block.
Before the AO block is configured, however, the HC transducer block of the controller must be configured to recognise the SFC446 analog output module
Parameter
Controller HC block
MODE_BLK.Target
IO_TYPE_R2.SLOT_2
AO block
MODE_BLK.Target
PV_SCALE.EU_100
PV_SCALE.EU_0
PV_SCALE.UNITS_INDEX
XD_SCALE/EU_100
XD_SCALE/EU_0
XD_SCALE/UNITS_INDEX
SP_RATE_DN
SP_RATE_UP
CHANNEL
FSTATE_VAL
FSTATE_TIME
SHED_OPT
Function
Normal operating mode of block
Declaration of SFC446 module in HC block
Example value
Auto
4-Analog Output
Normal operating mode of block
Upper range limit for process variable
Lower range limit for process variable
Unit of process variable
Upper range limit for transducer variable
Lower range limit for transducer variable
Unit of transducer variable
Rate of change from old to new, higher SP
Rate of change from old to new, lower SP
Rack + Slot + Group + Point
Cas
100
0
%
20
4 mA
5
5
2200
Fail-to-safe value for OUT (= closed)
Time that elapses before fault state is activated
4
5 (s)
Target mode and recovery behaviour on change of mode NormalShed_
NormalReturn
Endress+Hauser 229
8 Output Blocks
Mode
Status
Block errors
ControlCare Application Designer: Function Blocks
8.1.4
Block operation
The block normally operates in "Auto", "Cas" or "RCas" mode, depending on the origin of the setpoint, see Chapter 8.1.1.
When MODE_BLK.Target
is set to "Man", the block output OUT can be manipulated.
The setpoint value SP can be changed when the block is in Auto. If other parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of
Service). A parameter change is then downloaded directly to the controller.
The block assumes Local override (LO) when a fault state has been detected and the corresponding function has been configured. The OUT value then corresponds to FSTATE_VAL .
Iman is temporarily assumed during a cascade loop reset initiated by an upstream block.
Operation can be checked on-line by viewing a number of parameters:
SP, CAS_IN, RCAS_IN Value and status of setpoint set by operator, upstream block or supervisor system respectively
OUT The primary analog value calculated as a result of executing the function.
The block output and status provided to an upstream block or host for back calculation BKCAL_OUT
RCAS_OUT
READBACK Readback of the actual analog valve or other actuator position, in the transducer state.
The significance of the output status is indicated below.
Output status
GoodCascade
Bad
Meaning
• Normal operation as configured
• Input to block Bad
• Block out of service
Block errors are indicated in the BLOCK_ERR parameter
Condition
Block Configuration Error
Simulate Active
Device Fault State Set
Output Failure
Out-of-Service
Reason
• Invalid SHED_OPT value
• Invalid CHANNEL value
– value not supported by transducer block
– value not compatible with configuration in Controller HC block
• XD_SCALE range or value not supported by transducer block
• Transducer block out of service
• Simulation enabled in block
• FAULT_STATE is active (Local override)
• Associated I/O module has failed
• MODE_BLK.Target currently set to OOS
230 Endress+Hauser
ControlCare Application Designer: Function Blocks 8 Output Blocks
8.1.5
Block parameters
Parameter
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
PV
SP
OUT
SIMULATE
PV_SCALE
XD_SCALE
GRANT_DENY
IO_OPTS
STATUS_OPTS
READBACK
CAS_IN
SP_RATE_DN
SP_RATE_UP
SP_HI_LIM
SP_LO_LIM
CHANNEL
FSTATE_TIME
FSAFE_VAL
BKCAL_OUT
RCAS_IN
SHED_OPT
RCAS_OUT
UPDATE_EVT
BLOCK_ALM
Legend: RO = Read Only
Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
RO
Positive
Positive
1 - 8
Description/Action
See Chapter 2.3.4
Block mode, set to MODE_BLK.Target to Cas
Block errors, see Chapter 5.2.3
Process value used in executing the block
Setpoint used by the block in AUTO mode (PV_SCALE ± 10%)
Output value calculated as a result of executing the block
0
0
0
0
Disable See Chapter 5.2.2, Enable/Disable options:
• Disable
• Active
0-100% PV value scaling to to % of range
0-100% Transducer value scaling to required engineering units
Access options, see Chapter 2.8.1
I/O options, see Chapter 2.8.2 and Chapter 5.2.1
Status options, see Chapter 2.8.4 and Chapter 5.2.2
Value sent back by actuator indicating current position
Setpoint used by the block in CAS mode
Ramp rate for positive setpoint change in PV units/s +INF
+INF
100
0
0
Ramp rate for negative setpoint change in PV units/s
High limit for setpoint limiting (PV_SCALE ± 10%)
Low limit for setpoint limiting (PV_SCALE ± 10%)
The number of the logical hardware channel to the transducer that is connected to this I/O block, see Chapter 5.1.
0
0
Time iin seconds to ignore a new fault state conditioin
Sets value for IO_OPTS option Fault State to Value
Feedback for BKCAL_IN of an upstream block.
Setpoint used by the block in RCAS mode (from host)
Mode shedding options, see Chapter 6.1.6
Setpoint and status for host back calculation in RCAS mode
This alert is generated by any change to the static data.
Block alarms, see Chapter 2.9
Endress+Hauser 231
8 Output Blocks
Setpoint
Optional invert
Output
232
ControlCare Application Designer: Function Blocks
8.2
Discrete Output
The Discrete Output block receives a discrete setpoint value from an upstream function block or higher level process control system and, after possible inversion, outputs a signal to a downstream transducer block through an internal channel reference. It is used by instruments that act as discrete output elements in a control loop such as on-off valves or in connection with the ControlCare
Discrete Output modules SFC428, SFC432, SFC435 or SFC438.
In ControlCare Application Designer the Discrete Output block is assigned the generic name
Device Tag-DO-n . It can be found by expanding the appropriate device or Field Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 8-4.
CAS_IN_D
SETPOINT OPTIONAL
INVERT
OUTPUT
BKCAL_OUT_D
To module
SFC428
SFC432
SFC435
SFC438
OUT_D
MODE
SHED_OPT
SP_D PV_D
OPTIONAL
INVERT
FSTATE_TIME
FSTATE_VAL_D
SIMULATE_D
READBACK_D
CHANNEL
(RRSGP)
Fig. 8-4: Schematic diagram of the Discrete Output block
8.2.1
Functional description
Depending upon the setting of the MODE_BLK.Target parameter, the Discrete Output block receives its setpoint value from the operator, an upstream block or a remote process control system.
MODE_BLK.Target
Auto
Cas
Rcas
Setpoint
SP_D
CAS_IN_D
RCAS_IN_D
Remarks
Sepoint value is constant and is entered manually by the operator.
Setpoint value originates from an upstream block
Setpoint valueoriginates from a supervisory host
The "Invert" option in the parameter group IO_OPTS inverts the input signal by placing a boolean
NOT between the setpoint ( SP_D , CAS_IN_D , RCAS_IN_D ) and the output OUT_D .
False
True
A discrete value of zero (0) is considered to be a logical zero (0), and a non-zero discrete value a logical one (1)
A discrete value of zero (0) is considered to be a logical one (1), and a non-zero discrete value a logical zero (0)
The XD_STATE value indicates the true on/off state of the connected hardware
When the block is operating in Cas, Rcas or Auto mode, the value obtained after block execution is placed in OUT_D . The same value is transmitted to the transducer through an internal channel reference given by the CHANNEL parameter, see Chapter 5.1.
If the transducer hardware supports a readback value, such as valve position, that value is run backwards through the inversion to act as the PV_D for the block. If not supported,
READBACK_D is generated from OUT_D .
The current setpoint value and status is communicated to an upstream block by the
BKCAL_OUT_D parameter. If the option "PV for BKCAL_OUT" is selected in IO_OPTS , then
PV_D will be transmitted instead of the setpoint.
Endress+Hauser
ControlCare Application Designer: Function Blocks
Fault state
Mode shedding
Setpoint tracking
Simulation
Status propagation
8 Output Blocks
When the block is operating in Rcas mode, RCAS_OUT_D carries the block setpoint and status after ramping for output to a supervisory host as back calculation and to allow action to be taken under limiting conditions or mode change.
By default, the last valid value is held if a fault state is detected.
If the "Fault state to value" option is selected in IO_OPTS , OUT_D will assume the value entered in FSTATE_VAL_D when a fault condition exists longer than defined in the parameter
FSTATE_TIME or when the option "Fault State" is selected the the resource block parameter
SET_FSTATE . This ensures that the hardware connected to the block fails to safe, see Chapter 2.7.
When the option "Fault state restart" in IO_OPTS is selected, FSTATE_VAL_D will also be used on restart.
SHED_OPT allows the behaviour of the block to be determined after a change in mode, e.g. forced by the system or through operator intervention. "Normal return" options allow the block to recover automatically to target mode, for "No return" options, the operator must enter the target mode manually.
IO_OPTS also allows the setpoint to track PV_D or an input value when the the target mode is
Auto and this changes to Man or LO. Possible behaviour is "SP tracks PV when Man", "SP tracks PV when LO", "SP tracks RCAS or CAS when Man or LO"
The block supports simulation, see Chapter 2.10. The parameter group SIMULATE_D is used to specify the output value (setpoint value and status), transducer value (PV value and status) and to enable/disable simulation, provided the associated jumper on the I/O board is set, see Chapter 3.2.
When simulation is active in the Analog Output block, BLOCK_ERROR flags "Simulation Active".
The status of OUT can assume the following values:
GoodCascade
Bad
The output value OUT_D is valid and can be used for further processing
The output value OUT_D is invalid.
• Operating mode OOS
• Input status bad
If the "Propagate Fault Bkwd" option in STATUS_OPTS is selected, the BKCAL_OUT_D and
RCAS_OUT_D status carries the current OUT_D status to an upstream block or supervisory system.
8.2.2
Output configuration for SFC428, SFC432, SFC435, SFC438
The DO block forces the output signals as shown in Table 8-4. NO (Normally open) and NC
(normally closed) is the state of the relay when no power is applied to the module.
OUT_D Signal
0
1
FALSE
TRUE
NO Relay
SFC428, SFC432, SFC438
Open
Closed
NC Relay
SFC435, SFC438
Closed
Open
Tab. 8-4: Relay status of the output module as a function of OUT_D
Endress+Hauser 233
8 Output Blocks
Block configuration
ControlCare Application Designer: Function Blocks
8.2.3
Block configuration
Fig. 8-5 shows an example of on-off control of process tank level that uses the Discrete Output block. The level in a process tank with random inflow is controlled by opening and closing the outlet valve (LV100) based on the level sensed in the tank by the level switch (LSH100). The level switch outputs a true signal when it is covered with liquid; the valve is operated by a solenoid and is open when this is activated. The connection to the controller is made via input DI-0 and output DO-1 of a SFC432 Voltage Input and NO Relay Output module, which is to be found in Rack 1, Slot 3 of the controller backplane.
Feed In
LSH
100
Process
Tank
LV
100
S
Feed Out
Fig. 8-5: Example of on-off control of process tank level
Fig. 8-6 shows the control strategy together with links that must be made between the blocks.
LSH100
DI-0 channel
DI
OUT_D
CAS_IN_D
DO channel DO-1
Solenoid
LSH100 LV100
Fig. 8-6: Links required for basic closed-loop control
Before the DI and DO blocks are configured, the HC transducer block of the controller must be configured to recognise the SFC432 Voltage Input and NO Relay Output module
Function Example value Parameter
Controller HC block
MODE_BLK.Target
IO_TYPE_R1.SLOT_3
DI block
MODE_BLK.Target
CHANNEL
DO block
MODE_BLK.Target
CHANNEL
FSTATE_VAL_D
FSTATE_TIME
SHED_OPT
Normal operating mode of block
Declaration of SFC432 module in HC block
Normal operating mode of block
Rack + Slot + Group + Point
Auto
8-DiscIn 4-DiscOut
Auto
1300
Normal operating mode of block
Rack + Slot + Group + Point
Cas
1310
Fail-to-safe value for OUT_D (= open, prevents overspill)
Time that elapses before fault state is activated
1
5 (s)
Target mode and recovery behaviour on change of mode NormalShed_
NormalReturn
234 Endress+Hauser
ControlCare Application Designer: Function Blocks
Mode
Status
Block errors
8 Output Blocks
8.2.4
Block operation
The block normally operates in "Auto", "Cas" or "RCas" mode, depending on the origin of the setpoint, see Chapter 8.2.1.
When MODE_BLK.Target
is set to "Man", the block output OUT can be manipulated.
The setpoint value SP_D can be changed when the block is in Auto. If other parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of
Service). A parameter change is then downloaded directly to the controller.
The block assumes Local override (LO) when a fault state has been detected and the corresponding function has been configured. The OUT_D value then corresponds to FSTATE_VAL_D .
Iman is assumed when there is no path to the final control element.
Operation can be checked on-line by viewing a number of parameters:
SP_D, CAS_IN_D,
RCAS_IN_D
OUT
BKCAL_OUT_D
RCAS_OUT_D
READBACK_D
Value and status of setpoint set by operator, upstream block or supervisor system respectively
The primary discrete value calculated as a result of executing the function.
The block output and status provided to an upstream block or host for back calculation
Readback of the actual valve or actuator position, in the transducer state.
The significance of the output status is indicated below.
Output status
GoodCascade
Bad
Meaning
• Normal operation as configured
• Input to block Bad
• Block out of service
Block errors are indicated in the BLOCK_ERR parameter
Condition
Block Configuration Error
Simulate Active
Device Fault State Set
Output Failure
Out-of-Service
Reason
• Invalid SHED_OPT value
• Invalid CHANNEL value
– value not supported by transducer block
– value not compatible with configuration in Controller HC block
• Simulation enabled in block
• FAULT_STATE is active (Local override)
• Associated I/O module has failed
• MODE_BLK.Target currently set to OOS
Endress+Hauser 235
8 Output Blocks ControlCare Application Designer: Function Blocks
8.2.5
Block parameters
Parameter
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
PV_D
SP_D
OUT
SIMULATE_D
PV_STATE
XD_STATE
GRANT_DENY
IO_OPTS
STATUS_OPTS
READBACK_D
CAS_IN_D
CHANNEL
FSTATE_TIME
FSTATE_VAL_D
BKCAL_OUT_D
RCAS_IN_D
SHED_OPT
RCAS_OUT_D
UPDATE_EVT
BLOCK_ALM
Legend: RO = Read Only
Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
RO
1 - 8
Description/Action
See Chapter 2.3.4
Block mode, set to MODE_BLK.Target to Cas
Block errors, see Chapter 5.2.3
Process value used in executing the block
Setpoint used by the block in AUTO mode (PV_SCALE ± 10%)
Output value calculated as a result of executing the block
0
0
0
0
Disable See Chapter 5.2.2, Enable/Disable options:
• Disable
• Active
0-100% Discrete PV value
0-100% Discrete transducer value
Access options, see Chapter 2.8.1
I/O options, see Chapter 2.8.2 and Chapter 5.2.1
Status options, see Chapter 2.8.4 and Chapter 5.2.2
Value sent back by actuator indicating current position
0
0
0
Setpoint used by the block in CAS mode
The number of the logical hardware channel to the transducer that is connected to this I/O block, see Chapter 5.1.
Time iin seconds to ignore a new fault state conditioin
Sets value for IO_OPTS option Fault State to Value
Feedback for BKCAL_IN of an upstream block.
Setpoint used by the block in RCAS mode (from host)
Mode shedding options, see Chapter 6.1.6
Setpoint and status for host back calculation in RCAS mode
This alert is generated by any change to the static data.
Block alarms, see Chapter 2.9
236 Endress+Hauser
ControlCare Application Designer: Function Blocks
Fault state
8 Output Blocks
8.3
Multiple Analog Output
The Multiple Analog Output block receives up to eight analog input values from upstream function blocks and outputs up to eight signals through an internal channel reference an analog output module. This forces a voltage or current output signal proportional to the input value. In the case of the SFC446 analog output module only the first four inputs are used.
In ControlCare Application Designer the Multiple Analog Output block is assigned the generic name
Device Tag-MAO-n . It can be found by expanding the appropriate device or Field Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 8-7.
IN_x
FSTATE_VALx
FAILSAFE
ACTIVE
CHANNEL
RRSG
9
To module
SFC446
IN_1
IN_2
IN_3
IN_4
IN_5
IN_6
IN_7
IN_8
SELECTOR
FSTATE_VAL 1/8
Fig. 8-7: Schematic diagram of the Multiple Analog Output block
8.3.1
Functional description
The Multipler Analog Output block forces up to eight electrical output signals between 0 mA and
20 mA, –5 VDC and 5 VDC or –10 VDC to 10 VDC depending upon the wiring and the DIP switch setting of the connected SFC446 module as well as the value range of the input signal. There are no scaling, limiting or tracking functions. The output current or voltage of Point x is directly proportional to the IN_x value, see Table 8-5.)
IN_x
100 %
0 %
-25%
-150%
Current
20 mA
4 mA
0 mA
N/A
Voltage (DIP switch OFF) Voltage (DIP switch ON)
5 VDC 10 VDC
1 VDC
0 VDC
–5 VDC
2 VDC
0 VDC
–10 VDC
Tab. 8-5: Current and voltage output of SFC446 module as a function of configuration and input signal
When the block is operating in Auto mode, the value obtained after block execution is transmitted to the transducer through an internal channel reference given by the CHANNEL parameter, see
Chapter 5.1.
By default, the last valid value is held if a fault state is detected.
If the "Fault state to value x" option is selected in MO_OPTS , the output will force a signal proportional to the value entered in FSTATE_VALx when a fault condition exists longer than defined in the parameter FSTATE_TIME or when the option "Fault State" is selected the the resource block parameter SET_FSTATE . This ensures that the hardware connected to the block fails to safe, see Chapter 2.7.
When the option "Use fault state value on restart x" in MO_OPTS is selected, FSTATE_VALx will also be used on restart.
Endress+Hauser 237
8 Output Blocks
Output module
Block configuration
ControlCare Application Designer: Function Blocks
8.3.2
Block configuration
Fig. 8-8 shows an example of a control strategy using the Multiple Analog Output block. Currently the only analog output module available, the SFC446, has four outputs which can be wired as current or voltage outputs depending on which terminals are used.
The four input values IN_1 to IN_4 are connected to the OUT outputs of upstream blocks. These are scaled to 0% to 100%, –25% to +100% or –150% to +100%, depending upon the output signal range required at the SFC446 module, see Table 8-5. The relationship between input signal to output in the SFC446 is as follows:
• IN_1 drives the AO-0 output
• IN_2 drives the AO-1 output
• IN_3 drives the AO-2 output
• IN_4 drives the AO-3 output
For the configuration example it is assumed that the SFC446 module is at Rack 2, Slot 0 of the controller backplane.
OUT
OUT_SCALE in percentage of span
OUT
OUT
OUT
IN_1
IN_2
IN_3
IN_4
MAO channel
4B
5B
6B
7B
2A
3A
8A
9A
AO-0 (mA)
AO-1 (V)
AO-2 (V)
AO-3 (mA)
Fig. 8-8: Example of links required for Multiple Analog Output block used with the SFC446
Before the MDO block is configured, the HC transducer block of the controller must be configured to recognise the SFC446 Analog Output module
Parameter
Controller HC block
MODE_BLK.Target
IO_TYPE_R2.SLOT_0
MDO block
MODE_BLK.Target
CHANNEL
FSTATE_TIME
FSTATE_VAL1
FSTATE_VAL2
FSTATE_VAL3
FSTATE_VAL4
Function
Normal operating mode of block
Declaration of SFC446 module in HC block
Normal operating mode of block
Rack + Slot + Group + 9
Time that elapses before fault state is activated
Fail-to-safe value for AO-0 (= IN_1)
Fail-to-safe value for AO-1 (= IN_2)
Fail-to-safe value for AO-2 (= IN_3)
Fail-to-safe value for AO-3 (= IN_4)
Example value
Auto
4-Analog Output
Auto
2009
5 (s) e.g.0
e.g.0
e.g.100
e.g.0
238 Endress+Hauser
ControlCare Application Designer: Function Blocks
Use in control loops
8 Output Blocks
Fig 8-9 shows the use of the Multiple Discrete Output block in a control loop. In order that the PID can work, it has to receive a BKCAL_IN signal, which is not provided by the MAO block. This is achieved by linking OUT signal of the PID block to the BKCAL_IN signal of the same block.
FT100
AI
OUT IN
BKCAL_IN
PID
OUT IN_1
FCV101
MAO
CV102
CHANNEL AO-1
Positioner
Block configuration
Mode
Status
Block errors
Fig. 8-9: Use of MAO block in control loops
Before the MDO block is configured, the HC transducer block of the controller must be configured to recognise the SFC446 Analog Output module
Function Example value Parameter
Controller HC block
MODE_BLK.Target
IO_TYPE_R2.SLOT_0
MDO block
MODE_BLK.Target
CHANNEL
FSTATE_TIME
FSTATE_VAL1
Normal operating mode of block
Declaration of SFC446 module in HC block
Normal operating mode of block
Rack + Slot + Group + 9
Time that elapses before fault state is activated
Fail-to-safe value for AO-0 (= IN_1)
Auto
4-Analog Output
Auto
2009
5 (s) e.g.0
8.3.3
Block operation
The block normally operates in "Auto" mode. Manual mode "Man" is implemented, but only for the recovery from OOS and LO to Auto.
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
The block assumes Local override (LO) when a fault state has been detected and the corresponding function has been configured. The output value then corresponds to FSTATE_VALx . The
FSTATE_STATUS parameter indicates which outputs are using fault state values.
Operation can be checked on-line by viewing the IN_x parameter
As there is no linkable output, there is also no status handling.
Block errors are indicated in the BLOCK_ERR parameter
Condition
Block Configuration Error
Device Fault State Set
Output Failure
Out-of-Service
Reason
• Invalid CHANNEL value
– value not supported by transducer block
– value not compatible with configuration in Controller HC block
• FAULT_STATE is active (Local override)
• Associated I/O module has failed
• MODE_BLK.Target currently set to OOS
Endress+Hauser 239
8 Output Blocks ControlCare Application Designer: Function Blocks
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
CHANNEL
IN_1
IN_2
IN_3
IN_4
IN_5
IN_6
IN_7
IN_8
MO_OPTS
8.3.4
Block parameters
Parameter
FSTATE_TIME
FSTATE_VAL1
FSTATE_VAL2
FSTATE_VAL3
FSTATE_VAL4
FSTATE_VAL5
FSTATE_VAL6
FSTATE_VAL7
FSTATE_VAL8
FSTATE_STATUS
UPDATE_EVT
BLOCK_ALM
Legend: RO = Read Only
RO
RO
RO
RO
RO
RO
RO
RO
Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
0
Description/Action
See Chapter 2.3.4
0
0
0
0
0
0
0
0
0
Block mode, set to MODE_BLK.Target to Cas
Block errors, see Chapter 5.2.3
The number of the logical hardware channel to the transducer that is connected to this I/O block, see Chapter 5.1.
Value and status of input signal 1
Value and status of input signal 2
Value and status of input signal 3
Value and status of input signal 4
Value and status of input signal 5
Value and status of input signal 6
Value and status of input signal 7
Value and status of input signal 8
Selects fail safe vlues and type to be output on block failure
• Faultstate to value x: block outputs FSAFE_VALx on fault
• Use fault state value on restart x: block outputs
FSAFE_VALx on restart
Time iin seconds to ignore a new fault state conditioin
Fail-to-safe value for IN_1
Fail-to-safe value for IN_2
Fail-to-safe value for IN_3
Fail-to-safe value for IN_4
Fail-to-safe value for IN_5
Fail-to-safe value for IN_6
Fail-to-safe value for IN_7
Fail-to-safe value for IN_8
Indicates which failsafe values are active
This alert is generated by any change to the static data.
Block alarms, see Chapter 2.9
240 Endress+Hauser
ControlCare Application Designer: Function Blocks
Fault state
8 Output Blocks
8.4
Multiple Discrete Output
The Multiple Discrete Output block receives up to eight discrete input values from upstream function blocks and outputs up to eight discrete ignals through an internal channel reference to a
SFC428, SFC432, SFC435 or SFC438 discrete output module. If signal inversion is required, the
Discrete Output block must be used.
In ControlCare Application Designer the Multiple Discrete Output block is assigned the generic name Device Tag-MDO-n . It can be found by expanding the appropriate device or Field Controller leaf in the fieldbus or process cell window and appears as shown in Fig. 8-10.
IN_D1
IN_D2
IN_D3
IN_D4
IN_D5
IN_D6
IN_D7
IN_D8
SELECTOR
IN_Dx
FSTATE_VAL_Dx
FAILSAFE
ACTIVE
CHANNEL
RRSG 9
To modules
SFC428
SFC432
SFC435
SFC438
FSTATE_VAL 1/8
Fig. 8-10: Schematic diagram of Multiple Discrete Output block
8.4.1
Functional description
The Multiple Discrete Output block forces the electrical outputs of the connected relay output module SFC428, SFC432, SFC435 or SFC438 to "True/1" or "False/0" according to the value of
IN_Dx , which must be "0" or "1". The relay status is as shown in Table 8-6. NO (Normally open) and NC (normally closed) is the state of the relay when no power is applied to the module.:
IN_Dx Signal
0
1
FALSE
TRUE
NO Relay
SFC428, SFC432, SFC438
Open
Closed
NC Relay
SFC435, SFC438
Closed
Open
Tab. 8-6: Relay status of the output module as a function of IN_Dx
When the block is operating in Auto mode, the value obtained after block execution is transmitted to the transducer through an internal channel reference given by the CHANNEL parameter, see
Chapter 5.1.
By default, the last valid value is held if a fault state is detected.
If the "Fault state to value x" option is selected in MO_OPTS , the output will force a signal proportional to the value entered in FSTATE_VALx when a fault condition exists longer than defined in the parameter FSTATE_TIME or when the option "Fault State" is selected the the resource block parameter SET_FSTATE . This ensures that the hardware connected to the block fails to safe, see Chapter 2.7.
When the option "Use fault state value on restart x" in MO_OPTS is selected, FSTATE_VALx will also be used on restart.
Endress+Hauser 241
8 Output Blocks
Output module
Block configuration
Mode
242
ControlCare Application Designer: Function Blocks
8.4.2
Block configuration
Fig. 8-11 shows an example of a control strategy using the Multiple Discrete Output block and the
SFC438 module. This has eight voltage inputs and four output relays, two NO and two NC. In this case, and in the cases of the SFC432 (four NO relays) and SFC435 (four NC relays) only the first four inputs are used:
• IN_D1 drives the DO-1 output
• IN_D2 drives the DO-2 output
• IN_D3 drives the DO-3 output
• IN_D4 drives the DO-4 output
The SFC428 high density relay module has 16 NO relays and requires two MDO blocks, one for each relay group. All eight inputs can be used:
• IN_D1 drives the DO-0 output
• IN_D2 drives the DO-1 output
• ...
• IN_D8 drives the DO-7 output
For the configuration example it is assumed that the SFC438 module is at Rack 3, Slot 3 of the controller backplane.
OUT_D
False “0” or
True “1”
OUT_D
OUT_D
IN_D1
IN_D2
OUT_D
IN_D3
OUT_D
IN_D4
MDO channel
6B
7B
8B
9B
2B
3B
4B
5B
DO-1 (NO)
DO-2 (NO)
DO-3 (NC)
DO-4 (NC)
Fig. 8-11: Example of links required for Multiple Discrete Output block used with the SFC438
Before the MDO block is configured, the HC transducer block of the controller must be configured to recognise the SFC446 Analog Output module
Parameter
Controller HC block
MODE_BLK.Target
IO_TYPE_R3.SLOT_3
MDO block
MODE_BLK.Target
CHANNEL
FSTATE_TIME
FSTATE_VAL_D1
FSTATE_VAL_D2
FSTATE_VAL_D3
FSTATE_VAL_D4
Function
Normal operating mode of block
Declaration of SFC446 module in HC block
Normal operating mode of block
Rack + Slot + Group + 9
Time that elapses before fault state is activated
Fail-to-safe value for AO-0 (= IN_1)
Fail-to-safe value for AO-1 (= IN_2)
Fail-to-safe value for AO-2 (= IN_3)
Fail-to-safe value for AO-3 (= IN_4)
Example value
Auto
8-DiscIn 4-DiscOut
Auto
3319
5 (s) e.g.0
e.g.0
e.g.1
e.g.1
8.4.3
Block operation
The block normally operates in "Auto" mode. Manual mode "Man" is implemented, but only for the recovery from OOS and LO to Auto.
If parameters are to be changed while the block is online, MODE_BLK.Target
must be temporarily set to OOS (Out of Service). A parameter change is then downloaded directly to the controller.
The block assumes Local override (LO) when a fault state has been detected and the corresponding function has been configured. The output value then corresponds to FSTATE_VAL_Dx . The
FSTATE_STATUS parameter indicates which outputs are using fault state values.
Endress+Hauser
ControlCare Application Designer: Function Blocks
Status
Block errors
8 Output Blocks
Operation can be checked on-line by viewing the IN_Dx parameter
As there is no linkable output, there is also no status handling.
Block errors are indicated in the BLOCK_ERR parameter
Condition
Block Configuration Error
Device Fault State Set
Output Failure
Out-of-Service
Reason
• Invalid CHANNEL value
– value not supported by transducer block
– value not compatible with configuration in Controller HC block
• FAULT_STATE is active (Local override)
• Associated I/O module has failed
• MODE_BLK.Target currently set to OOS
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
CHANNEL
IN_D1
IN_D2
IN_D3
IN_D4
IN_D5
IN_D6
IN_D7
IN_D8
MO_OPTS
8.4.4
Block parameters
Parameter
FSTATE_TIME
FSTATE_VAL_D1
FSTATE_VAL_D2
FSTATE_VAL_D3
FSTATE_VAL_D4
FSTATE_VAL_D5
FSTATE_VAL_D6
FSTATE_VAL_D7
FSTATE_VAL_D8
FSTATE_STATUS
UPDATE_EVT
BLOCK_ALM
Legend: RO = Read Only
RO
RO
RO
RO
RO
RO
RO
RO
Valid range/
Options
Default value
0
1 to 255 0
0 blanks
O/S
RO
0
Description/Action
See Chapter 2.3.4
0
0
0
0
0
0
0
0
0
Block mode, set to MODE_BLK.Target to Cas
Block errors, see Chapter 5.2.3
The number of the logical hardware channel to the transducer that is connected to this I/O block, see Chapter 5.1.
Value and status of input signal 1
Value and status of input signal 2
Value and status of input signal 3
Value and status of input signal 4
Value and status of input signal 5
Value and status of input signal 6
Value and status of input signal 7
Value and status of input signal 8
Selects fail safe vlues and type to be output on block failure
• Faultstate to value x: block outputs FSAFE_VALx on fault
• Use fault state value on restart x: block outputs
FSAFE_VALx on restart
Time iin seconds to ignore a new fault state conditioin
Fail-to-safe value for IN_1D
Fail-to-safe value for IN_D2
Fail-to-safe value for IN_D3
Fail-to-safe value for IN_D4
Fail-to-safe value for IN_D5
Fail-to-safe value for IN_D6
Fail-to-safe value for IN_D7
Fail-to-safe value for IN_D8
Indicates which failsafe values are active
This alert is generated by any change to the static data.
Block alarms, see Chapter 2.9
Endress+Hauser 243
9 PROFIBUS Blocks ControlCare Application Designer: Function Blocks
9 PROFIBUS Blocks
The PROFIBUS Field Controller SFC173, PROFIBUS-DP devices and PROFIBUS-PA devices are modelled in ControlCare Application using a number of PROFIBUS function blocks. In contrast to
Foundation Fieldbus devices, however, these blocks are normally not configured within Application
Designer. Instead, PROFIBUS Configurator is used to set up the network and configure the Field
Controller and slave devices. The results are then mapped to the PROFIBUS function blocks.
The block configuration of every PROFIBUS function block can be viewed in the Online and Offline
Characterization dialogues. Changes to the PROFIBUS parameters, however, must be made in
PROFIBUS Configurator and not in the parameter block.
The function blocks provided are as follows:
Special Function Block types:
• PROFIBUS Transducer block (PBTrd)
Function Block types for accessing cyclic PROFIBUS I/O data:
• PROFIBUS Analog Input for one analog process value
• PROFIBUS Multiple Analog Input for up to four analog process values
• PROFIBUS Digital Input for one discrete process value
• PROFIBUS Multiple Discrete Input for up to eight discrete process values
• PROFIBUS Totalizer for one totalizer value
• PROFIBUS Analog Output for one analogue process value
• PROFIBUS Multiple Analog Output for up to four analog process values
• PROFIBUS Discrete Output for one discrete process value
• PROFIBUS Multiple Discrete Output for up to 8 discrete process values
In addition to the above blocks, the PROFIBUS Field Controller contains a set of standard
Foundation Fieldbus blocks which can be used and configured as normal.
In this chapter, only the blocks together with their schematics and parameters are described. The actual use of a block, including links to be made can be taken from the corresponding block description in Chapters 4 to 8.
244 Endress+Hauser
ControlCare Application Designer: Function Blocks 9 PROFIBUS Blocks
9.1
General description
9.1.1
Accessing cyclic PROFIBUS I/O data
PROFIBUS input and output function blocks exchange their values with the PROFIBUS master via the Process Image (PI) which has two sections:
• Process Image Output Data and
• Process Image Input Data.
The PI is a byte array which size depends on the size of the dual port memory. A process value within the PI is selected by an offset. The size of the representing variable can be derived from its datatype. The datatype is given by the user manual for the device which provides/expects the process value.
The Process Image is set up automatically when a device is added to a project in PROFIBUS
Configurator and has been mapped by the PROFIBUS Mapping tool. The device GSD file is used in this process.
Process Image Output Data
PI_OUT_VAL_OFFSET
Length derived from
PB_DATATYPE
PI_OUT_STATUS_OFFSET
FB_Application
PROFIBUS Network
Output Devices
Endress+Hauser
Fig. 9-1: Schematic diagram of the Process Image Output Data
Process Image Input Data
PI_INP_VAL_OFFSET
Length derived from
PB_DATATYPE
PI_INP_STATUS_OFFSET
FB_Application
PROFIBUS Network
Output Devices
Fig. 9-2: Schematic diagram of the Process Image Input Data
245
9 PROFIBUS Blocks
Configuration
Time
Cascade loops
ControlCare Application Designer: Function Blocks
9.1.2
Failsafe/Fault state mechanism
The FailSafe mechanism implemented in the PROFIBUS output function blocks has a similar behavior to the Fault State mechanism present in the standard FF output function blocks and ensures that a loop fails to safe should a parameter go bad or not be propagated. There are, however, some differences which have been realized in order to facilitate the user comprehension and configuration.
It is possible to configure the parameters Mode, Status, Value and Time for each input independently in the Online or Offline Characterization dialogue. The parameters have been implemented in the various blocks as follows :
Function Block
Mode PA_AO
PA_DO
PA_MAO
PA_MDO
Parameter
FAILSAFE_MODE
FS_MODE
Status
Value
Time
PA_AO
PA_DO
PA_MAO
PA_MDO
FAILSAFE_STATUS
FS_STATUS
PA_AO
PA_DO
FAILSAFE_AVALUE
FAILSAFE_DVALUE
PA_MAO FS_AVALUE
PA_MDO FS_DVALUE
FAILSAFE_TIME PA_AO
PA_DO
PA_MAO
PA_MDO
FS_TIME
Description/Action
Sets the operating mode of the failsafe function:
• Disable: the FailSafe mechanism will not be used, even in case of loop failure
• Get FS Data: the values present in the failsafe status and value parameters will be used at the input of the function block in case of loop failure
• Get Last Data: the last good status and value present in the input of the function block will be reused at the same input of the function block in case of loop failure
Status copied to the status parameter of the input of the function block in case of loop failure, provided the option "Get
FS Data" is set in the FailSafe parameter "Mode"
Value copied to the value parameter of the input of the function block in case of loop failure, provided the option "Get FS
Data" is set in the FailSafe parameter "Mode"
Delay (in seconds) before the FailSafe mechanism becomes active. It is used in case of loop failure, provided the option
"Get FS Data" or "Get Last Data" has benn set in the FailSafe parameter "Mode"
The failsafe time parameter functions as follows. If the parameter "Mode" is set to "Get FS Data", the FailSafe "Status" and "Value" will be used in case of loop failure. If the project designer wants the FailSafe mechanism hold the last good value and status in the input of the function block for 10 seconds before entering failsafe mode, the parameter "Time" must be set to 10. On loop failure, the system will now wait 10 seconds before entering failsafe mode. If the control loop recovers before the 10 seconds have elapsed, the FailSafe mechanism remains on hold and the FailSafe values are not applied.
The failsafe mechanism behaves in a special manner for cascade loops. For example, assume that in a PA_AO function block the "Mode" parameter is set to "Get Last Data", the "Time" parameter is set to 10 and this function block is part of a PID loop. Before a failure condition, the input of this PA_AO block receives a status equal to "Good_Cascade" and a constant value equal to 20 from an external link.
Now assume that the external link breaks. The FailSafe mechanism is activated, holds the value 20 in the value parameter of the input of the PA_AO block, sets a specific bit of the last good status, changing it to "Good_Cascade:InitiateFaultState", and holds this status in the status parameter of the input of the PA_AO block for 10 seconds. If the system does not recover after 10 seconds, the status parameter of the input of the PA_AO block is changed to "Good_Cascade:FaultStateActive".
The FailSafe status and value are now applied at the input of the PA_AO block until the external link is recovered. This special behavior is important because there are some PROFIBUS field devices can use the "Fault State" information present in the status to activate their own FailSafe rules.
246 Endress+Hauser
ControlCare Application Designer: Function Blocks 9 PROFIBUS Blocks
SETPOINT and CAS_IN The function blocks PA_AO and PA_DO also exhibit special behaviour regarding the inputs
"SETPOINT" and "RCAS_IN". As these function blocks have 2 inputs but just one set of FailSafe parameters. For this reason when the "SETPOINT" input is configured, the FailSafe mechanism is applied to it. Otherwise, when only the RCAS_IN is configured as input, the FailSafe mechanism is applied only to it.
Block
PA_AO
Parameter
SETPOINT
PA_DO
RCAS_IN
SETPOINT
RCAS_IN
Failsafe parameters
Apply when AO_MODE_SEL is set to
• "Only SP",
• "SP, CHECK_BACK",
• "SP, READBACK, POS_D",
• "SP, READBACK, POS_D, CHECK_BACK" or
• "SP, READBACK, POS_D, RCAS_IN, RCAS_OUT, CHECK_BACK"
Apply when AO_MODE_SEL is set to
• "RCAS_IN, RCAS_OUT" or
• "RCAS_IN, RCAS_OUT, CHECK_BACK".
Apply when DO_MODE_SEL is set to
• "Only SP_D",
• "SP_D, CHECK_BACK",
• "SP, READBACK_D, CHECK_BACK" or
• "SP_D, READBACK_D, RCAS_IN_D, RCAS_OUT_D, CHECK_BACK".
Apply when DO_MODE_SEL is set to
• RCAS_IN_D, RCAS_OUT_D" or
• "RCAS_IN_D, RCAS_OUT_D, CHECK_BACK".
Note!
• The options in AO_MODE_SEL and DO_MOD_SEL are automatically set during the configuration of the device in PROFIBUS Configurator and reflect the attributes of the selected
GSD module.
• These parameters may not be changed in the Online or Offline Charaterization dialogue
9.1.3
Configuring PROFIBUS input and output values
PROFIBUS function blocks do not have a CHANNEL parameter to select the process variable to be used. Instead blocks are created for each of the process variables selected during device configuration in PROFIBUS Configurator, see Chapters 3.8 and 3.9 of the Profibus Tutorial,
BA036S/04/en.
In the Slave Configuration dialogue of PROFIBUS Configurator, the blocks offered by the device are to be seen in the middle of the workspace. The blocks are assigned to slots in by selecting the one required and pressing the Append Module button. The block then appears in the lower workspace.
The designation of the blocks depends on the device GSD. Some use the generic block names, e.g.
"AI" others specific variables, e.g. "Temperature". Some devices require that the blocks are assigned to specific slots. The FREE SPACE/EMPTY_MODULE parameter is used to ensure that the block is assigned to the correct slot, i.e. if variables 1 and 5 are required, the configuration AI, FREE SPACE,
FREE SPACE, FREE SPACE, AI must be created in PROFIBUS Configurator. The blocks offered by a device together with the associated slots can be taken from the device manual.
On completion, the configuration is by Application Designer. Normally, the mapping proceeds automatically and must only be confirmed by the user. In the case of Remote I/Os, however, the user must know the data format of the input or output value, in particular, how the status is transmitted.
After confirmation of the mapping Application Designer creates the required blocks and assigns the generic names Device Tag PB-XX-1 , Device Tag PB-XX-2 , etc.
Endress+Hauser 247
9 PROFIBUS Blocks
Block parameters
248
ControlCare Application Designer: Function Blocks
9.2
PROFIBUS Transducer
When a "New Gateway" is selected in the HSE Network, a PROFIBUS transducer block is created for SFC173 PROFIBUS Field Controller. In ControlCare Application Designer the block is assigned the generic name Device Tag-PBTRD-n and can be found by expanding the controller leaf in the
Profibus or process cell window.
The table below lists the parameters to be found in the PROFIBUS transducer block, whereby:
• The parameters PB_NUM_SEL to PB_DEVICE_CLASS mirror the information contained in the PROFIBUS live list.
• The parameters from PB_DIAG_AVAILABLE to PB_DATA_CONTROL_TIME mirror the
PROFIBUS master configuration which is created in PROFIBUS Configurator.
• The parameters from PB_ALARM_MAX to PB_TIMEOUT_COUNT mirror the protocol diagnostic interface between the application and the PROFIBUS master. They show the global bus states and the states of managed slave stations.
Note!
• The live list should not be read with the aid of the PBTRD block but by clicking on the PROFIBUS node in Application Designer
Parameter
ST_VER
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
PB_COMMAND_REQ
PB_COMMAND_RSP
PB_NUM_LINKS
PB_LINK_SEL
PB_LINK_ID
PB_LINK_ID_REV
PB_NUM_DEV
PB_DEV_SEL
PB_DEVICE_ID
PB_DEVICE_TAG
PB_DEVICE_ADDR
PB_DEVICE_MANF
PB_DEVICE_MODEL_NAME
PB_DEVICE_CLASS
Valid range/
Options
Default value
0 to 255 0
1 to 255 1
0 blanks
TARGET O/S
0 to 15
RO blanks
Description/Action
See Chapter 2.3.4
RO
RO
0 - 3
RO
RO
RO
0 - 3
RO
RO
RO
RO
RO
0 - 3 blanks
0
0
0
0
0 blanks blanks
0 blanks blanks
Block mode, set to Auto
Block errors, see Chapter 5.2.3
Profibus Command Request: Host writes the ID of the command to by executed by the SFC173 to this parameter
Profibus Command Response: Host reads the response to the last command written to the Profibus Command Request parameter from this parameter
Number of links supported by the SFC173.
Selects the PROFIBUS link, the live list information of which is to be displayed in parameters PB_LINK_ID to PB_DEV_SEL
• 0: First
• 1: Next
• 2: Previous
• 3: Last
ID of PROFIBUS selected PB_LINK_SEL
Live list revision of current PROFIBUS
Number of devices: Number of devices in the live list
Selects the PROFIBUS device, the live list information of which is to be displayed in parameters PB_DEVICE_ID to
PB_DEVICE_CLASS
• 0: First
• 1: Next
• 2: Previous
• 3: Last
ID of device selected in PB_DEV_SEL
Tag of device selected in PB_DEV_SEL
Address of device selected in PB_DEV_SEL.
Device Manufacturer: Manufacturer of device selected in
PB_DEV_SEL
Model name of device selected in PB_DEV_SEL.
Device class of device selected in PB_DEV_SEL
• 0: Active PB Master
• 1: Backup PB Master
• 2: PA Slave
• 3: DP Slave
Endress+Hauser
ControlCare Application Designer: Function Blocks 9 PROFIBUS Blocks
Parameter
PB_DIAG_AVAILABLE
PB_DEVICE_REVISION
PB_MASTER_ADDR
PB_BAUDRATE
PB_TSL
PB_MIN_TSDR
PB_MAX_TSDR
PB_TQUI
PB_TSET
PB_TTR
PB_GAP
PB_HSA
PB_MAX_RETRY_LIM
PB_BP_FLAG
PB_MIN_SLAVE_INTV
PB_POLL_TO
PB_DATA_CONTROL_TIME
PB_ALARM_MAX
PB_MAX_USER_GLOBAL_
CONTROL
PB_MASTER_STATE
Valid range/
Options
0, 1 0
Default value
Description/Action
0...125
0 - 9
1 - 216
1 - 216
7 - 32 blanks
RO
Indicates whether device displays diagnostic data
• 0: 'No'
• 1: 'Yes'
Indicates the software revision of a device.
Indicates node address of the PROFIBUS Master
Sets baudrate for PROFIBUS network:
0: 9600 Baud
1: 19.2 kBd
2: 93.75 kBd
3: 187.5 kBd
4: 500 kBd
6: 1.5 MBd
7: 3.0 MBd
8: 6.0 MBd
9: 12.0 MBd
Note: 45,45 kBd (Siemens link) and 31,25 kBd (requires coupler) are not supported
PROFIBUS Slot Time
PROFIBUS Min Station Delay
PROFIBUS Max Station Delay
PROFIBUS Quiet Time
PROFIBUS Setup Time
PROFIBUS Target Rotation Time
PROFIBUS GAP Update Factor
PROFIBUS Highest Station Address
PROFIBUS Max Retry Limit
PROFIBUS Bp Flag:
– SFC173 supports only Bit7: Error_Action_Flag
PROFIBUS Min Slave Interval
Specifies the smallest allowed period of time between two consecutive DPslave poll cycles. This ensures that the sequence of cyclic service requests from the DPmaster (Class 1) can be handled by the DP-slave. This period of time will be complied by the DP-master (Class 1) for every cyclic Master-slave service except for the Global Control service.
PROFIBUS Poll Timeout
Specifies the maximum period of time needed to get the response
PROFIBUS Data Control Time
Specifies the maximum period of time for an Data Exchange with every activated DP-slave. This Time is used for sending out the Global Control cyclically
Maximum number of alarms per DP-slave that can be handled by the DP-master.
Maximum number of Global Control requests that may be started by the user at the same time
Current state of PROFIBUS master
• 0x0: OFFLINE
• 0x40: STOP
• 0x80: CLEAR
• 0xC0: OPERATE
Endress+Hauser 249
9 PROFIBUS Blocks ControlCare Application Designer: Function Blocks
Parameter
PB_PROTOCOL_STATE_BITS
PB_ERROR_REMOTE_ADR
PB_ERROR_EVENT
PB_BUSERROR_COUNT
PB_TIMEOUT_COUNT
PB_SLAVE_CFG_STATE
PB_SLAVE_STATE
Valid range/
Options
Default value
Description/Action
Current state of PROFIBUS Protocol
• 0: CONTROL-ERROR
Parameterization error
• 1: AUTO-CLEAR-ERROR
Master stopped the communication to all slaves and reached the auto-clear end state
• 2: NON-EXCHANGE-ERROR
At least one slave has not reached the data exchange state and no process data are exchanged with it.
• 3: FATAL-ERROR
Bus error, no further bus communication is possible.
• 4: EVENT-ERROR
Master has detected bus short circuits. The number of detected events is fixed in the parameter
• 5: PROFIBUS Bus Error Count
Indicates number of bus errors since application started
• 6: HOST-NOT-READY_NOTIF.
Indicates whether host application is operative (bit not set)
• 7: TIMEOUT-ERROR
Communication timeout detected; indicates bus malfunction
Station address of error in PB_PROTOCOL_STATE_BITS
Error number of error in PB_PROTOCOL_STATE_BITS
See PROFIBUS COnfigurator online help
Counter inducating number of serious bus malfunctions
Counter inducating number of telegram rejections due to serious bus malfunctions
Current configuration state of slave in master
– '1', slave configured in the master and serviced in its states.
– '0', slave not configured in the master
Current state of each slave station when master running in
OPERATE state
– '1', slave and master are exchanging their I/O data.
– '0', slave and master are not exchanging their I/O data.
Notes on table: RO - Read only
250 Endress+Hauser
ControlCare Application Designer: Function Blocks 9 PROFIBUS Blocks
9.3
PROFIBUS Analog Input
The PROFIBUS Analog Input block provides a single analog output and is created in PROFIBUS
Configurator when a measuring device, e.g. Cerabar M, is selected that is compliant with the
PROFIBUS PA profile and uses the appropriate GSD. Application Designer maps the slave configuration and creates the blocks Device Tag PA-AI-1 , Device Tag PA-AI-2 , etc, according to the number of input variables selected.
Status
Block errors
Endress+Hauser
OUT
PROFIBUS
Process Image Input Data
PROFIBUS Slave
MODE
Fig. 9-3: Schematic diagram of the PROFIBUS Analog Input
9.3.1
Functional description
The PROFIBUS Analog Input block provides an output OUT of one process variable according to
PROFIBUS PA Profile 3.0, represneted in the GSD by Identifier Byte 0x94 (5 Bytes: 4 bytes value in IEEE754 coding plus one byte status showing the PA-status) or the extended identifier format
0x42,0x84, 0x08, 0x05.
9.3.2
Block operation
The PROFIBUS Analog Input block normally operates in Auto mode.
If MODE_BLK.Target
is set to Man, the OUT value and status can be overwritten.
The block can also be put out of service (OOS).
Status
GoodNC: NonSpecific
Bad:NoCommunication, Last Usable Value
Bad:NoCommunication, No Usable Value
Bad:Out of Service
Meaning
• Block operating correctly, OUT value valid
• No PROFIBUS communication, last valid OUT value used
• No PROFIBUS communication, no valid value (OUT = 0)
• Block currently out of service
Block errors are indicated in the BLOCK_ERR parameter
Condition
Output Failure
Out-of-Service
Reason
• No PROFIBUS communication or device failure
• MODE_BLK.Target currently set to OOS
9.3.3
Block parameters
Parameterl
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
OUT
PI_INP_VAL_OFFSET
PI_INP_STATUS_OFFSET
Valid
Range
Default
Value
0 - 65535 0
Spaces
0 - 65535 0
0 - 255 0
Description
See Chapter 2.3.4.
RO
RO
0.0
–
–
Block mode, set to Auto
Block errors, see Chapter 5.2.3
Value and status of the block output
Indicates the position in the process image of OUT value
Indicates the position in the process image of OUT status
251
9 PROFIBUS Blocks
Scaling
OUT Status
ControlCare Application Designer: Function Blocks
9.4
PROFIBUS Multiple Analog Input
The PROFIBUS Multiple Analog Input block provides up to four analog outputs and is created in
PROFIBUS Configurator when an analog or temperature input module of a PROFIBUS Remote I/O is selected. Application Designer maps the module and creates the block Device Tag DP-MAI-1 .
The number of blocks created depends on the hardware mapped in PROFIBUS Configurator.
PROFIBUS
Process
Image
Input Data
Range and
Data Type
Conversion
OUT_1
OUT_2
OUT_3
OUT_4
PROFIBUS
Slave(s)
MODE
Fig. 9-4: Schematic diagram of the PROFIBUS Multiple Analog Input (DP_MAI) block
9.4.1
Functional description
The PROFIBUS Multiple Analog Input block provides four outputs OUT_x to downstream blocks.
The SCALE_LOC_OUT_x parameter expands to show information about the conversion and allows the individual scaling of each OUT_x value.
The scaling parameters FROM_EU_0% , FROM_EU_100% , TO_EU_0% , TO_EU_100% must be set by the user to scale the input from the remote I/O to the desired OUT_x engineering units, see Fig. 9-5.
Scaled value
(OUT_x) to_EU_100% to_EU_0% from_EU_0% from_EU_100% Raw value (transducer)
Fig. 9-5: Scaling of raw value to OUT_x value engineering units
The OUT signal must always have a valid status. In the case of remote I/Os that do not provide values with status, a status must be entered at STATUS_SUBSTITUTION _VAL . The default value 0x80 is "Good:NonCascade, NonLimited". Remote I/Os requiring this procedure are indicated in STATUS_DETAILS by the text "STATUS_NA_SUBST_VAL", see Chapter 9.4.4.
The parameter STATUS_DETAILS in SCALE_LOC_OUT_x specifies how the slave offers the status of the process value to the process image. This parameter must be set by the user, e.g. with the help of the mapping tool.
252 Endress+Hauser
ControlCare Application Designer: Function Blocks
Status
Block errors
9 PROFIBUS Blocks
9.4.2
Block Configuration
It is assumed that a Pt100 thermocouple is connected to the first point of the Remote I/O. The temperature range –150°C to +600°C is represented by the Remote I/O as a range 0 to 8000.
The second third and fourth points of the analog inputs are connected to a pressure device with a range 0 mbar to 2000 mbar, a level device with a range 0% to 100% and a flow device with a range
0 l/min to 500 lImin. These outputs must also be scaled to the same Remote I/O range.
The DP_MAI block must be configured as follows: f
Parameter
MODE_BLK.Target
SCALE_LOC_OUT_1
FROM_EU_0
FROM_EU_100
TO_EU_0
TO_EU_100
SCALE_LOC_OUT_2
FROM_EU_0
FROM_EU_100
TO_EU_0
TO_EU_100
SCALE_LOC_OUT_3
FROM_EU_0
FROM_EU_100
TO_EU_0
TO_EU_100
SCALE_LOC_OUT_4
FROM_EU_0
FROM_EU_100
TO_EU_0
TO_EU_100
Function
Normal operating mode of block
Lower range limit of input signal
Upper range limit of input signal
Lower range limit of OUT_1
Upper range limit of OUT_1
Lower range limit of input signal
Upper range limit of input signal
Lower range limit of OUT_2
Upper range limit of OUT_2
Lower range limit of input signal
Upper range limit of input signal
Lower range limit of OUT_3
Upper range limit of OUT_3
Lower range limit of input signal
Upper range limit of input signal
Lower range limit of OUT_4
Upper range limit of OUT_4
0
8000
0
100
0
8000
0
500
Example value
Auto
0
8000
–150
600
0
8000
0
2000
9.4.3
Block operation
The PROFIBUS Analog Input block normally operates in Auto mode.
If MODE_BLK.Target
is set to Man, the OUT value and status can be overwritten.
The block can also be put out of service (OOS).
Status
GoodNC:xxx
Bad:NoCommunication, Last Usable Value
Bad:NoCommunication, No Usable Value
Bad:Out of Service
Meaning
• Block operating correctly, OUT value valid
• No PROFIBUS communication, last valid OUT value used
• No PROFIBUS communication, no valid value (OUT = 0)
• Block currently out of service
Block errors are indicated in the BLOCK_ERR parameter
Condition
Output Failure
Out-of-Service
Reason
• No PROFIBUS communication or device failure
• MODE_BLK.Target currently set to OOS
Endress+Hauser 253
9 PROFIBUS Blocks
SCALE_LOC_OUT_x
ControlCare Application Designer: Function Blocks
9.4.4
Block parameters
.
Parameter
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
OUT_1
SCALE_LOC_OUT_1
OUT_2
SCALE_LOC_OUT_2
OUT_3
SCALE_LOC_OUT_3
OUT_4
SCALE_LOC_OUT_4
Valid
Range
Default
Value
0 -65535 0
Spaces
0 - 65535 0
0 - 255 0
Description
See Chapter 2.3.4.
Block mode, set to Auto
Block errors, see Chapter 5.2.3
Value and status of the block output OUT_1
Conversion and scaling of OUT_1
Value and status of the block output OUT_2
Conversion and scaling of OUT_2
Value and status of the block output OUT_3
Conversion and scaling of OUT_3
Value and status of the block output OUT_4
Conversion and scaling of OUT_4
Parameter
ACTIVE_FLAG
PB_DATATYPE
PI_INP_VAL_OFFSET
FROM_EU_0
FROM_EU_100
TO_EU_0
TO_EU_100
STATUS_DETAILS
STATUS_SUBSTITUTION_VAL
PI_INP_STATUS_OFFSET
PV_TAG
RO
Valid
Range
2 ... 14
0.0
1.0
0.0
1.0
Default
Value
Description
Disabled Flags whether OUT_x value has been refreshed
• Disable: OUT_x value not refreshed
• Enabled: OUT_x value refreshed
8 Profibus data type as communicated over PROFIBUS
• 2: Integer8
• 3: Integer16
• 4: Integer32
• 5: Unsigned8
• 6: Unsigned16
• 7: Unsigned32
• 8: Floating Point
• 9: Reserved:
• 10: Integer16 in Little Endian format
• 11: Integer32 in Little Endian format
• 12: Unsigned16 in Little Endian format
• 13:> Unsigned32 in Little Endian format
• 14: Floating Point swapped, inverse byte order in comparison to that of PB spec.
Indicates the positions in the process image of OUT_x values
Raw value from EU_0
Raw value from EU_100
Scaled value to EU_0
0x80
–
Scaled value to EU_100
Profibus Status Detail
Status Substitution Value: status set by user for devices offering no status themselves, defaultvalue 0x80
Indicates the positions in the process image of OUT_x status; should these be provided by the Remote I/O
Tag of process value mapped to OUT_x parameters
254 Endress+Hauser
ControlCare Application Designer: Function Blocks
STATUS_DETAILS
9 PROFIBUS Blocks
80
81
...
87
A0
No.
1
2
3
4
5
6
7
8
9
Type
STANDARD_PA
MSB_BYTE_STATUS_0_GOOD
MSB_BYTE_STATUS_1_GOOD
Function
Status is coded in one byte according to PA/FF
• Value for the status read from the process image input data at
PI_INP_STATUS_OFFSET
MSB of the byte with the value shows the status
• MSB = 0: OK => will result in 0x80 at status of OUTx
• MSB = 1: NOT OK => will result in 0x0 at status of OUTx
MSB of the byte with the value shows the status
• MSB = 0: NOT OK => will result in 0x0 at status of OUTx
• MSB = 1: OK => will result in 0x80 at status of OUTx
MSB_WORD_STATUS_0_GOOD
MSB_WORD_STATUS_1_GOOD
MSB_DOUBLEWORD_STATUS_0_GOOD MSB of the double word with the value shows the status
• MSB = 0: OK => will result in 0x80 at status of OUTx
• MSB = 1: NOT OK => will result in 0x0 at status of OUTx
MSB_DOUBLEWORD_STATUS_1_GOOD MSB of the word with the value shows the status
• MSB = 0: NOT OK => will result in 0x0 at status of OUTx
• MSB = 1: OK => will result in 0x80 at status of OUTx
STATUS_NA_SUBST_VAL PB slave does not offer a status
• Value entered in STATUS_SUBSTITUTION_VAL will assigned to the status of OUTx
STATUS_NA_ALWAYS_OK
MSB of the word with the value shows the status
• MSB = 0: OK => will result in 0x80 at status of OUTx
• MSB = 1: NOT OK => will result in 0x0 at status of OUTx
MSB of the word with the value is shows the status
• MSB = 0: NOT OK => will result in 0x0 at status of OUTx
• MSB = 1: OK => will result in 0x80 at status of OUTx
BYTE_PACKED_STATI_0_GOOD_BIT=
BYTE_PACKED_STATI_0_GOOD_BITx
PB slave does not offer a status,
• 0x80 (GoodNonCascade, Notlimited, Nonspecific, will be assigned to the status of OUTx as long as no failure of the communication is signaled
• 0x18 (Bad, No Communication) will be assigned if these is a communication failure
Bit0 of value at PI_INP_STATUS_OFFSET shows the status
Bitx of value at PI_INP_STATUS_OFFSET shows the status
BYTE_PACKED_STATI_1_GOOD_BIT0
A1
...
A7
BYTE_PACKED_STATI_1_GOOD_BITx
Bit0 of value at PI_INP_STATUS_OFFSET shows the status
• BITx = 0: NOT OK => will result in 0x0 at status of OUTx
• BITx = 1: OK => will result in 0x80 at status of OUTx
Bitx of value at PI_INP_STATUS_OFFSET shows the status
• BITx = 0: NOT OK => will result in 0x0 at status of OUTx
• BITx = 1: OK => will result in 0x80 at status of OUTx
Endress+Hauser 255
9 PROFIBUS Blocks
Mode
Status
Block errors
256
ControlCare Application Designer: Function Blocks
9.5
PROFIBUS Digital Input
The PROFIBUS Discrete Input block provides a single discrete output and is created in PROFIBUS
Configurator when a PROFIBUS switch, e.g. Liquiphant M, is selected. Normally a switch has only one process variable for which a single PROFIBUS Discrete Input block will be created. The block is assigned the generic name Device Tag PA-DI-1 .
If the device offers more than one discrete output, then the configuration in PROFIBUS Configurator is analogous to that described in Chapter 9.2 and a block will be created for each process variable.
OUT_D
PROFIBUS
Process Image Input Data
PROFIBUS Slave
MODE
Fig. 9-6: Schematic diagram of the PROFIBUS Digital Input block
9.5.1
Functional description
The PROFIBUS Digital Input Block provides an output OUT_D to a downstream block.
9.5.2
Block operation
The PROFIBUS Analog Input block normally operates in Auto mode.
If MODE_BLK.Target
is set to Man, the OUT_D value and status can be overwritten.
The block can also be put out of service (OOS).
Status
GoodNC: NonSpecific
Bad:NoCommunication, Last Usable Value
Bad:NoCommunication, No Usable Value
Bad:Out of Service
Meaning
• Block operating correctly, OUT value valid
• No PROFIBUS communication, last valid OUT_D value used
• No PROFIBUS communication, no valid value (OUT = 0)
• Block currently out of service
Block errors are indicated in the BLOCK_ERR parameter
Condition
Output Failure
Out-of-Service
Reason
• No PROFIBUS communication or device failure
• MODE_BLK.Target currently set to OOS
9.5.3
Block parameters
Parameter Label
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
OUT_D
PI_INP_VAL_OFFSET
PI_INP_STATUS_OFFSET
Valid
Range
Default
Value
0 ... 65535 0
Spaces
0 ... 65535 0
0 to 255 0
Description
See Chapter 2.3.4.
RO
RO
–
–
Block mode, set to Auto
Block errors, see Chapter 5.2.3
Value and status of the block output OUT_D
Indicates the position in the process image of OUT_D value
Indicates the position in the process image of OUT_D status
Endress+Hauser
ControlCare Application Designer: Function Blocks 9 PROFIBUS Blocks
9.6
PROFIBUS Multiple Discrete Input
The PROFIBUS Multiple Discrete Input block provides up to eight discrete outputs and is created in PROFIBUS Configurator when a discrete input module of a PROFIBUS Remote I/O is selected.
Application Designer maps the device and creates the block Device Tag DP-MDI-1 . The number of blocks created depends on the hardware mapped in PROFIBUS Configurator.
Mode
Status
Block errors
PROFIBUS
Process
Image
Input Data
PROFIBUS
Slave(s)
OUT_D1
OUT_D2
OUT_D3
OUT_D4
OUT_D5
OUT_D6
OUT_D7
OUT_D8
MODE
Fig. 9-7: Schematic diagram of the PROFIBUS Multiple Discrete Inpute
9.6.1
Functional description
The PROFIBUS Multiple Discrete Input block provides up to eight discrete outputs. Parameters are available at the OUT_Dx outputs as one byte value plus one byte status. In order to support the several datatypes provided by remote I/O systems, each process variable is converted before being placed in the output.
The LOC_OUT_x parameter expands to show information about the OUT_Dx value.
The OUT_D signal must always have a valid status. In the case of remote I/Os that do not provide values with status, a status must be entered at STATUS_SUBSTITUTION _VAL . The default value 0x80 is "Good:NonCascade, NonLimited". Remote I/Os requiring this procedure are indicated in STATUS_DETAILS by the text "STATUS_NA_SUBST_VAL", see Chapter 9.4.2.
9.6.2
Block operation
The PROFIBUS Analog Input block normally operates in Auto mode.
If MODE_BLK.Target
is set to Man, the OUT_Dx value and status can be overwritten.
The block can also be put out of service (OOS).
Status
GoodNC:xxx
Bad:NoCommunication, Last Usable Value
Bad:NoCommunication, No Usable Value
Bad:Out of Service
Meaning
• Block operating correctly, OUT value valid
• No PROFIBUS communication, last valid OUT value used
• No PROFIBUS communication, no valid value (OUT = 0)
• Block currently out of service
Block errors are indicated in the BLOCK_ERR parameter
Condition
Output Failure
Out-of-Service
Reason
• No PROFIBUS communication or device failure
• MODE_BLK.Target currently set to OOS
Endress+Hauser 257
9 PROFIBUS Blocks
Block parameters
LOC_OUT_Dx
ControlCare Application Designer: Function Blocks
Parameter Label
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
OUT_D1
LOC_OUT_D1
OUT_D2
LOC_OUT_D2
OUT_D3
LOC_OUT_D3
OUT_D4
LOC_OUT_D4
OUT_D5
LOC_OUT_D5
OUT_D6
LOC_OUT_D6
OUT_D7
LOC_OUT_D7
OUT_D8
LOC_OUT_D8
9.6.3
Block parameters
Valid
Range
Default
Value
0 ... 65535 0
Spaces
0 ... 65535 0
0 to 255 0
Description
See Chapter 2.3.4.
Block mode, set to Auto
Block errors, see Chapter 5.2.3
Value and status of the block output OUT_D1
Conversion of OUT_D1
Value and status of the block output OUT_D2
Conversion of OUT_D2
Value and status of the block output OUT_D3
Conversion of OUT_D3
Value and status of the block output OUT_D4
Conversion of OUT_D4
Value and status of the block output OUT_D15
Conversion of OUT_D5
Value and status of the block output OUT_D6
Conversion of OUT_D6
Value and status of the block output OUT_D7
Conversion of OUT_D7
Value and status of the block output OUT_D8
Conversion of OUT_D8
Component Label
ACTIVE_FLAG
PI_INP_VAL_OFFSET
VAL_BIT_OFFSET
STATUS_DETAILS
STATUS_SUBSTITUTION_VAL
PI_INP_STATUS_OFFSET RO
PV_TAG
Valid
Range
Default
Value
Description
Disabled Flags whether OUT_x value has been refreshed
• Disable: OUT_x value not refreshed
• Enabled: OUT_x value refreshed
Indicates the positions in the process image of OUT_Dx values
Default: 0, 2, 4, 6, 8, 10, 12, 14
0
0x80
Indicates the position of the bit in the byte referenced by
PI_INP_VAL_OFFSET in which the binary value is to be found
– A value other than zero will be indicates if the PROFIBUS device packs several binary values into one word/byte
See Chapter 9.4.4
Status Substitution Value: status set by user for devices offering no status themselves, defaultvalue 0x80
– Indicates the positions in the process image of OUT_Dx status; should these be provided by the Remote I/O
Default: 1, 3, 5, 7, 9, 11, 13, 15
Tag of process value mapped to OUT_Dx parameters
258 Endress+Hauser
ControlCare Application Designer: Function Blocks 9 PROFIBUS Blocks
9.7
PROFIBUS Totalizer
The PROFIBUS Totalizer block provides one analog totalizer output and is created in PROFIBUS
Configurator when a device, e.g. a flowmeter, offers this process variable and it is selected.
Application Designer maps the configuration and creates the blocks Device Tag PA-TO-1 , Device
Tag PA-TO-2 , etc., depending upon the slave configuration.
SET_TOT
MODE_TOT
PROFIBUS
Process
Image
Output Data
PROFIBUS
Slave(s)
PROFIBUS
Process
Image
Input Data
PROFIBUS
Slave(s)
TOTAL
Fig. 9-8: Schematic diagram of the PROFIBUS Totalizer block
9.7.1
Functional description
The Profibus Totalizer block provides a totalized value at its output parameter TOTAL as four bytes value and one byte status.
The input SET_TOT allows the totalizer to be set by cyclically communicated data, i.e. by the control system. Three values are valid:
• 0: TOTALIZE – starts the totalizer
• 1: RESET – resets the totalizer to zero
• 2: PRESET – resets the totalizer to a preset value
If the option "PRESET" is selected in SET_TOT , a preset value must have been set in the flowmeter by either by using the display or a Class II master, e.g. FieldCare.
The input MODE_TOT allows the operating mode of the totalizer to be set by cyclically communicated data. Four values are valid:
• 0: BALANCED – the totalizer uses both negative and positive flows
• 1: POS_ONLY – the totalizer uses positive flows only
• 2: NEG_ONLY – the totalizer uses negative flows only
• 3: HOLD – the totalizer is stopped
The available totalizer options are dependent upon the device and are contained within its GSD.
The inputs must be configured in PROFIBUS configurator by selecting an option and placing it in the appropriate slot.
Totalizer option
TOTAL
Action
The totalizer block supports totalizing by cyclic data exchange only
– Reset are made by acyclic data exchange, e.g. by FieldCare
SETTOT_TOTAL
(SET_TOTAL*)
SETTOT_MODETOT_TOTAL
(SET_MODE_TOTAL*)
(SET_UNIT_PRESET_TOTAL*)
The totalizer supports totalizing and setting by cyclic data exchange
– Any PRESET value must be set by acyclic data exchange, e.g. by FieldCare
The totalizer supports totalizing, setting and mode selection by cyclic data exchange
(SET_MODE_ UNIT_PRESET_TOTAL*) The totalizer supports totalizing, setting, mode selection, specifcation of totalizer unit and specification of a preset value by cyclic data exchange
* Prowirl 73 PA only
The totalizer supports totalizing, setting, speicifcation of totalizer unit and specification of a preset value by cyclic data exchange
The totalizer must be placed at the appropriate slot number. The table below summarizes the current possibilities for Endress+Hauser Profile 3.0 flowmeters:
Endress+Hauser 259
9 PROFIBUS Blocks
Totalizer slots
Status
Block errors
Device
Promass 83 PA
Prosonic Flow 90 PA
Prowirl 72 PA*
Prowirl 73 PA
Prosonic Flow 92 PA
Promag 50 PA/DP
4
3
Slots
7, 8, 9
5, 6
5, 6
2
ControlCare Application Designer: Function Blocks
2
2
1
1
1
No.
3
Device
Prosonic DP*
Promag 53 DP/PA
Promass 80 PA
Promass 83 DP
Prosonic Flow 93 DP/PA
T-mass 65
Slots
3
2, 3, 4
5
7, 8, 9
9, 10, 11
4, 5
3
3
2
3
1
No.
1
9.7.2
Block operation
The PROFIBUS Totalizer block normally operates in Auto mode.
If MODE_BLK.Target
is set to Man, the TOTAL value and status can be overwritten.
The block can also be put out of service (OOS).
Status
GoodNC:xxx
Bad:NoCommunication, Last Usable Value
Bad:Out of Service
Meaning
• Block operating correctly, TOTAL value valid
• No PROFIBUS communication, last valid TOTAL value used
• Block currently out of service
Block errors are indicated in the BLOCK_ERR parameter
Condition
Output Failure
Out-of-Service
Reason
• No PROFIBUS communication or device failure
• MODE_BLK.Target currently set to OOS
9.7.3
Block parameters
Parameter Label
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
TOTAL
SET_TOT
Valid
Range
Default
Value
0 ... 65535 0
Spaces
0 ... 65535 0
0 to 255 0
OOS
0, 0
0: 0
Description
See Chapter 2.3.4.
Block mode, set to Auto
Block errors, see Chapter 5.2.3
Value and status of totalizer after execution of block
MODE_TOT 0
0: TOTALIZE
1: RESET
2: PRESET
Totalizer mode
0: BALANCED
1: POS_ONLY
2: NEG_ONLY
3: HOLD
PI_INP_TOTAL_OFFSET RO
PI_INP_TOT_STAT_OFFSET RO
PI_OUT_SET_TOT_OFFSET RO
PI_OUT_MODE_TOT_OFFSET RO
–
–
–
–
Position in the input process image of the TOTAL value
Position in the input process image of the TOTAL status
Position in the outout process image of the SET_TOT value
Position in the output process image of the MODE_TOT value
TOT_MODE_SELECT 0 Configuration of the totalizer block
• 0: TOTAL only
• 1: TOTAL plus SET_TOT
• 2: TOTAL plus SET_TOT plus MODE_TOT
*A value 0xFFFF of an offset parameter means that there is no assignment of a PB input/output data to the corresponding
TOTAL/SET_TOT/MODE_TOT parameter. In this case TOTAL/SET_TOT/MODE_TOT will not be cyclically refreshed
260 Endress+Hauser
ControlCare Application Designer: Function Blocks 9 PROFIBUS Blocks
9.8
PROFIBUS Analog Output
The PROFIBUS Analog Output block provides one analog input to a transducer block and is created in PROFIBUS Configurator when an actuator is selected. Application Designer maps the slave configuration and creates the block Device Tag PA-AO-1 .
SP
RCAS_IN
(CAS_IN)
(RCAS_IN)
SELECTOR
FSAFE_VAL
FAILSAFE
ACTIVE
PROFIBUS
Process
Image
Output Data
PROFIBUS
Slave
PROFIBUS
Process
Image
Input Data
(BKCAL_OUT)
READBACK
POS_D
PROFIBUS
Slave
(RCAS_OUT)
CHECK_BACK
RCAS_OUT
Fig. 9-9: Schematic diagram of the PROFIBUS Analog Output block
9.8.1
Functional Description
Depending on the configuration selected and control strategy, the Profibus Analog Output block receives its setpoint from:
• an upstream block, SP (=CAS_IN) or
• an external system, RCAS_IN
The setpoint is passed on to the device transducer block, which drives the actuator to the required position.
Depending on configuration, the block outputs the following transducer information:
• READBACK: current position and status of the actuator in units of PV_SCALE, whereby
PV_SCALE is set in the transducer block and is usually 0% to 100% by default
• POS_D : Current position of actuator as a discrete value with status, indicating whether the valve is closed, open or in an intermediate position
• CHECK_BACK : Detailed information on the valve status in the form of a 3 byte bit map capable of carrying several messages at once
• RCAS_OUT: current position and status of the actuator in units of PV_SCALE for an external system, whereby PV_SCALE is set in the transducer block and is usually 0% to 100% by default
The available analog output options are dependent upon the device and are contained within its
GSD. The inputs and outputs are activated by configuring the appropriate mode in the Slave
Configuration dialogue of PROFIBUS Configurator:
Analog Output option
SP
SP/READBACK/POS_D
SP/CHECK_BACK
Action
The output block uses the input SP from an upstream block only
The output block uses the input SP from an upstream block and provides the outputs READBACK and POS_D
The output block uses the input SP from an upstream block and provides the output CHECK_BACK
SP/READBACK/POS_D/
CHECK_BACK
RCAS_IN/ RCAS_OUT
The output block uses the input SP from an upstream block and provides the outputs READBACK, POS_D and CHECK_BACK
The output block the input RCAS_IN from an external application and provides the output RCAS_OUT
RCAS_IN/ RCAS_OUT/ CHECK_BACK The output block uses the input RCAS_IN from an external application and provides the outputs RCAS_OUT and CHECK_BACK
SP/ READBACK/ RCAS_IN/
RCAS_OUT/ POS_D/ CHECK_BACK
The output block uses the input SP from an upstream block or the input
RCAS_IN from an external application and provides the outputs READBACK,
RCAS_OUT, POS_D and CHECK_BACK
The block supports the failsafe mechanism as described in Chapter 9.1.2.
Endress+Hauser 261
9 PROFIBUS Blocks
Cascade control
ControlCare Application Designer: Function Blocks
9.8.2
Block configuration
Fig. 9-10 shows an example of cascade control using PROFIBUS devices. Chapter 6.1.4 has an identical application for FOUNDATION Fieldbus devices. The temperature of water measured upstream of a heat exchanger is used as input to a primary PID Control block which manipulates a secondary block controlling the supply of steam by opening and closing a control valve, see
Fig. 9-11. The input to the secondary block is the flowrate of the steam. The flowmeter Analog
Output block supplies the input value to the secondary loop, the temperature device Analog Input block the process value. The Analog Output block of the control valve controls the control valve actuator. secondary loop
FT
102
FCV
103 primary loop
TC
101
CV
104
TT
100
Fig. 9-10: Example of cascade control
Fig. 9-11 shows the control strategy together with links that must be made between the blocks. The
PID blocks are standard function blocks which run in the SFC173 field controller. Note that the downstream PID links to the SP input and the back calculation is provided by the READBACK output. The POS_D and CHECK_BACK outputs are available to downstream blocks or a SCADA system.
PA-AI-1
OUT IN
PID-1
BKCAL_IN
TT100 TC101 OUT
PA-AI-2
OUT
CAS_IN
IN
BKCAL_IN
PID-2 BKCAL_OUT
OUT SP
FT102 FCV103
PA-AO
CV104
POS_D
CHECK_BACK
READBACK
Fig. 9-11: Links required for cascade control
262 Endress+Hauser
ControlCare Application Designer: Function Blocks
Block configuration cascade control
9 PROFIBUS Blocks
PROFIBUS Configurator is used to create the Analog Input and Analog Output blocks. The measuring devices must be configured to supply an "AI" value. For the Analog Output the option
"SP/READBACK/POS_D/CHECK_BACK" is selected.
The transducer blocks of the measuring devices are configured to provide an output scaled to 0% -
100% by means of acyclic communication, e.g. by using FieldCare.
The table below describes the configuration of the function blocks.
Parameter
PB-AI-1
MODE_BLK.Target
PB-AI-2
MODE_BLK.Target
PID-1, primary loop
MODE_BLK.Target
SP
PV_SCALE.EU_100
PV_SCALE.EU_0
PV_SCALE.UNITS_INDEX
OUT_SCALE/EU_100
OUT_SCALE/EU_0
OUT_SCALE/UNITS_INDEX
CONTROL_OPTS
SP_RATE_DN
SP_RATE_UP
GAIN
RESET
RATE
SHED_OPT
PID-2, secondary loop
MODE_BLK.Target
PV_SCALE.EU_100
PV_SCALE.EU_0
PV_SCALE.UNITS_INDEX
OUT_SCALE/EU_100
OUT_SCALE/EU_0
OUT_SCALE/UNITS_INDEX
CONTROL_OPTS
SP_RATE_DN
SP_RATE_UP
GAIN
RESET
RATE
SHED_OPT
PB-AO
MODE_BLK.Target
FAILSAFE_MODE
FAILSAFE_AVALUE
FAILSAFE_STATUS
FAILSAFE_TIME
Function
Normal operating mode of block
Normal operating mode of block
Normal operating mode of block
Setpoint for ideal process control
Upper range limit for process variable
Lower range limit for process variable
Unit of process variable
Upper range limit for output variable
Lower range limit for output variable
Unit of output variable
Sets control options for bad input
Rate of change from old to new, higher SP
Rate of change from old to new, lower SP
Tuning constants for the P, I and D terms of the PID block respectively.
Behaviour when shedding from remote mode
Normal operating mode of block
Upper range limit for process variable
Lower range limit for process variable
Unit of process variable
Upper range limit for output variable
Lower range limit for output variable
Unit of output variable
Sets control options for bad input
Rate of change from old to new, higher SP
Rate of change from old to new, lower SP
Tuning constants for the P, I and D terms of the PID block respectively.
Behaviour when shedding from remote mode
Example value
AUTO
AUTO
AUTO
60%
100
0
%
100
0
%
Bypass Enable
0
0
1.5
0.1 s
0.5 s
Normal shed, normal return
CAS
100
0
%
100
0
%
Bypass Enable
0
0
1.5
0.1 s
0.5 s
Normal shed, normal return
Normal operating mode of block AUTO
Operating mode of failsafe function, see Chapter 9.1.2
Get FS Data
Value to be used on failsafe case, e.g. closed = 0%
Status to be output on failsafe case
• Bad NoUsableValue (00x14 = 20)
Time delay (s) between loss of input and failsafe case
0
20
3
Endress+Hauser 263
9 PROFIBUS Blocks
Remote cascade
ControlCare Application Designer: Function Blocks
Fig. 9-12 shows an example of remote cascade control using a PROFIBUS actuator. Chapter 6.1.6 has an identical application for FOUNDATION Fieldbus devices. The temperature of water measured upstream of a heat exchanger and the flow rate measured downstream are acquired by an external Modbus controller and used as inputs to a the cascade loop. The Modbus Control Slave block provides the setpoint to the Analog Output block, see Chapter 10.3, which drives the control valve actuator.
setpoint secondary loop
FT
102
PROFIBUS actuator
FCV
103
CV
104
CC
101
Primary and secondary loop running in external controller
TT
100
Fig. 9-12: Example of remote cascade
Fig. 9-13 shows the control strategy together with links that must be made between the blocks.
Note that the Modbus Controller Slave block links to the to the RCAS_IN input and the back calculation is provided by the RCAS_OUT output. The CHECK_BACK output is available to a downstream block or a SCADA system.
Note
• The connection to the external application may also be made via OPC server, in which case the parameter Device Tag-PB-AO-n.RCAS_IN
carries the setpoint, the parameter Device Tag-PB-AO-n.RCAS_OUT
the feedback and the parameter Device Tag-PB-AO-n.CHECK_BACK
the checkback data.
IN1
MBCS
FCV103
CHECK_BACK
OUT1
RCAS_IN
PA-AO
CV104
RCAS_OUT
Fig. 9-13: Links required for remote cascade (through MBCS block)
264 Endress+Hauser
ControlCare Application Designer: Function Blocks
Block configuration remote cascade
9 PROFIBUS Blocks
PROFIBUS Configurator is used to create the Analog Output block. The option RCAS_IN/
RCAS_OUT/ CHECK_BACK is selected in the Slave Configuration dialogue.
The configuration of the Modbus blocks is described in the Modbus Tutorial, BA037S/04/en.
A timeout must be set in the MBCF block to ensure that the status of the OUT1 signal goes bad, should the controller fail. The MBCS block must be configured to provide an output scaled to 0% -
100%. For the strategy we require the IN_1, and OUT_1 channels. When LOCAL_MOD_MAP is set to zero the data will be read and written as follows:
,
Parameter Channel Register Data type Access
OUT1 Float Read Positioner value
Status
Back calculation
Status
IN1
40009
40021
40001
40017
Float Write
The table below describes the configuration of the function blocks.
Function Parameter
MBCF
MODE_BLK.Target
MEDIA
MASTER_SLAVE
DEVICE_ADDRESS
TIMEOUT
MBCS
MODE_BLK.Target
LOCAL_MOD_MAP
SCALE_LOC_CONV_IN1
.FROM_EU_0
.FROM_EU_100
.TO_EU_0
.TO_EU_100
.DATA_TYPE
SCALE_LOC_CONV_OUT1
.FROM_EU_0
.FROM_EU_100
.TO_EU_0
.TO_EU_100
.DATA_TYPE
.STATUS_OUTPUT
PB-AO
MODE_BLK.Target
FAILSAFE_MODE
FAILSAFE_AVALUE
FAILSAFE_STATUS
FAILSAFE_TIME
Normal operating mode of block
Media used to connect with controller
Operating mode of SFC173 controller
Modbus device address
Time (ms) before reaction to a loss in communication
AUTO
TCP/IP
Slave e.g. 1
1000
Normal operating mode of block
Register location for input and output data
Scaling from RCAS_OUT parameter
Scaling from RCAS_OUT parameter
Scaling to controller
Scaling to controller
Data type
Scaling from controller
Scaling from controller
Scaling to RCAS_IN parameter
Scaling to RCAS_IN parameter
Data type
Status to be transmitted to output when "Good"
Example value
AUTO
0
0
100 e.g. 0 e.g. 100
Float e.g. 0 e.g. 1
0
100
Float
"Good_Cascade::Non
Specific:NotLimited"
Normal operating mode of block AUTO
Operating mode of failsafe function, see Chapter 9.1.2
Get FS Data
Value to be used on failsafe case, e.g. closed = 0%
Status to be output on failsafe case
• Bad NoUsableValue (00x14 = 20)
Time delay (s) between loss of input and failsafe case
0
20
3
Endress+Hauser 265
9 PROFIBUS Blocks
Status
Block errors
266
ControlCare Application Designer: Function Blocks
9.8.3
Block operation
The PROFIBUS Analog Output block normally operates:
• in Auto mode when the setpoint is provided by the SP input
• in RCas mode when the setpoint is provided by the RCAS_IN input
The block supports the failsafe mechanism as described in Chapter 9.1.2.
If MODE_BLK.Target
is set to Man, the SP or RCAS_IN value and status can be overwritten.
The block can also be put out of service (OOS).
Status
GoodNC:xxx
Bad:NoCommunication, Last Usable Value
Bad:NoCommunication, No Usable Value
Bad:Out of Service
Meaning
• Block operating correctly, TOTAL value valid
• No PROFIBUS communication, last valid output value used
• No PROFIBUS communication, output value = 0
• Block currently out of service
Block errors are indicated in the BLOCK_ERR parameter
Condition
Output Failure
Out-of-Service
Reason
• No PROFIBUS communication or device failure
• MODE_BLK.Target currently set to OOS
9.8.4
Block parameters
Parameterl
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
SP
RCAS_IN
READBACK
POS_D
CHECK_BACK
RCAS_OUT
PI_OUT_SP_OFFSET
PI_OUT_SP_STAT_OFFSET
RO
RO
PI_OUT_RCAS_IN_OFFSET RO
PI_OUT_RCAS_STAT_OFFSET RO
PI_INP_RD_BACK_OFFSET
PI_INP_RD_BACK_STAT_
OFFSET
PI_INP_POS_D_OFFSET
RO
RO
RO
PI_INP_POS_D_STAT_OFFSET RO
PI_INP_CHK_BACK_OFFSET RO
PI_INP_RCAS_OUT_OFFSET RO
PI_INP_RCAS_OUT_STAT_
OFFSET
RO
Valid
Range
Default
Value
0 ... 65535 0
Spaces
0 ... 65535 0
0 to 255 0
OOS
0, 0
0, 0
–
–
–
–
–
–
Description
See Chapter 2.3.4.
Block mode, set to Auto for SP, RCas for RCAS_IN
Block errors, see Chapter 5.2.3
Setpoint value and status in units of PV_SCALE
Remote setpoint value and status in units of PV scale provided by an external system
Current position and status of the actuator in units of
PV_SCALE
Current position of actuator (discrete) with status
• 0: Not initialized
• 1: C+losed
• 2: Open
• 3: Intermediate position
Detailed device information (3 bytes) as bit coded octet string
Current position and status of the actuator in units of
PV_SCALE for an external system
Position in the input process image of the SP value
Position in the input process image of the SP status
Position in the input process image of the RCAS_IN value
Position in the input process image of the RCAS_IN status
Position in the input process image of the READBACK value
Position in the input process image of the READBACK status
–
–
–
–
–
Position in the input process image of the POS_D value
Position in the input process image of the POS_D status
Position in the input process image of the CHECKBACK value
Position in the input process image of the RCAS_OUT value
Position in the input process image of the RCAS_OUT status
Endress+Hauser
ControlCare Application Designer: Function Blocks
AO_MODE_SEL 0 - 6
FAILSAFE_MODE
FAILSAFE_STATUS
FAILSAFE_AVALUE
FAILSAFE_TIME
1 - 3
0 .. 0xFF
)
9 PROFIBUS Blocks
Configuration of analog output block
• 0: only SP
• 1: SP, READBACK, POS_D;
• 2: SP, CHECK_BACK;
• 3: SP, READBACK, POS_D, CHECK_BACK;
• 4: RCAS_IN, RCAS_OUT;
• 5: RCAS_IN, RCAS_OUT, CHECK_BACK;
• 6: SP, READBACK, RCAS_IN, RCAS_OUT, POS_D,
CHECK_BACK
Selection of fault state mode
• 1: Disable
• 2: Get Last Data
• 3: Get FS Data
Status to be output when fault state active
FaultState Value
FaultState Time
Endress+Hauser 267
9 PROFIBUS Blocks
Scaling
ControlCare Application Designer: Function Blocks
9.9
PROFIBUS Multiple Analog Output
The PROFIBUS Multiple Analog Output block provides four analog inputs to a transducer block and is created in PROFIBUS Configurator when an analog output module of a remote I/O is selected.
Application Designer maps the slave configuration and creates the block Device Tag DP-MAO-1 .
IN_1
IN_2
IN_3
IN_4
SELECTOR
(4x)
FSAFE_VAL
FAILSAFE
ACTIVE
Range and
Data
Type
Conversion
PROFIBUS
Process
Image
Output Data
PROFIBUS
Slave(s)
Fig. 9-14: Schematic diagram of the PROFIBUS Multiple Analog Output
9.9.1
Functional description
The PROFIBUS Multiple Analog Output block has four analog inputs IN_1 to IN_4 which drive the four outputs of the Remote I/O analog output module selected in PROFIBUS Configurator. In order to support the several datatypes provided by remote I/O systems, each process variable is converted before being placed in the output data image.
The SCALE_LOC_IN_x parameter expands to show information about the conversion and allow the scaling of the IN_x value.
PB_DATATYPE indicates the way in which the value and status are transmitted over PROFIBUS.
The scaling parameters FROM_EU_0% , FROM_EU_100% , TO_EU_0% , TO_EU_100% must be set by the user to scale the IN_x value to the engineering units required by the remote I/O, see
Fig. 9-15.
Scaled value
(block output) to_EU_100% to_EU_0% from_EU_0% from_EU_100% IN_x (block input)
Fig. 9-15: Scaling of IN_x value to engineering units required by the remote I/O
SCALE_LOC_IN_x also allows a fault state behaviour can be set for each individual input by means of the parameters FS_MODE , FS_STATUS , FS_AVALUE and FS_TIME .
The parameter STATUS_DETAILS in SCALE_LOC_IN_x specifies whether and how the slave expects the status of IN_x . This parameter must be set by the user, e.g. with the help of the mapping tool.
268 Endress+Hauser
ControlCare Application Designer: Function Blocks
Status
Block errors
9 PROFIBUS Blocks
9.9.2
Block operation
The PROFIBUS Multiple Analog Output block normally operates in Auto mode.
If MODE_BLK.Target
is set to Man, the IN_x value and status can be overwritten.
The block can also be put out of service (OOS).
Status
GoodNC:xxx
Bad:NoCommunication, Last Usable Value
Bad:NoCommunication, No Usable Value
Bad:Out of Service
Meaning
• Block operating correctly, OUT value valid
• No PROFIBUS communication, last valid OUT value used
• No PROFIBUS communication, no valid value (OUT = 0)
• Block currently out of service
Block errors are indicated in the BLOCK_ERR parameter
Condition
Output Failure
Out-of-Service
Reason
• No PROFIBUS communication or device failure
• MODE_BLK.Target currently set to OOS
9.9.3
Block Configuration
It is assumed that IN_1 is scaled to 0% to 100% and the actuator connected to the first point of the
Remote I/O expects a signal of 4 mA to 20 mA. IN_2 is scaled to 0% to 100% and the actuator connected to the second point of the Remote I/O expects a signal of 4 mA to 20 mA. IN_2 is scaled to 0% to 100% and the actuator connected to the third point of the Remote I/O expects a signal of
0 V to 10 V. IN_4 is not used. The DP_MOI block must be configured as follows: f
Parameter
MODE_BLK.Target
SCALE_LOC_IN_1
FROM_EU_0
FROM_EU_100
TO_EU_0
TO_EU_100
FS_MODE
FS_STATUS
FS_AVALUE
FS_TIME
SCALE_LOC_IN_2
FROM_EU_0
FROM_EU_100
TO_EU_0
TO_EU_100
FS_MODE
FS_STATUS
FS_AVALUE
FS_TIME
SCALE_LOC_IN_3
FROM_EU_0
FROM_EU_100
TO_EU_0
TO_EU_100
FS_MODE
FS_STATUS
FS_AVALUE
FS_TIME
Function
Normal operating mode of block
Example value
Auto
IN_1 lower range limit
IN_1 upper range limit
Actuator output lower range limit
Actuator output upper range limit
Operating mode of failsafe function, see Chapter 9.1.2
Status to be output on failsafe case
Bad NoUsableValue (00x14 = 20)
Value to be used on failsafe case, e.g. closed = 4 mA
Time delay (s) between loss of input and failsafe case
4
3
0
100
4
20
Get FS Data
20
IN_2 lower range limit
IN_2 upper range limit
Actuator output lower range limit
Actuator output upper range limit
Operating mode of failsafe function, see Chapter 9.1.2
Status to be output on failsafe case
Bad NoUsableValue (00x14 = 20)
Value to be used on failsafe case, e.g. closed = 4 mA
Time delay (s) between loss of input and failsafe case
4
3
0
100
4
20
Get FS Data
20
IN_3 lower range limit
IN_3 upper range limit
Actuator output lower range limit
Actuator output upper range limit
Operating mode of failsafe function, see Chapter 9.1.2
Status to be output on failsafe case
Bad NoUsableValue (00x14 = 20)
Value to be used on failsafe case, e.g. closed = 0 V
Time delay (s) between loss of input and failsafe case
0
3
0
100
0
10
Get FS Data
20
Endress+Hauser 269
9 PROFIBUS Blocks
SCALE_LOC_IN_x
ControlCare Application Designer: Function Blocks
9.9.4
Block parameters
Parameterl
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
IN_1
SCALE_LOC_IN_1
IN_2
SCALE_LOC_IN_2
IN_3
SCALE_LOC_IN_3
IN_4
SCALE_LOC_IN_4
Valid
Range
Default
Value
0 ... 65535 0
Spaces
0 ... 65535 0
0 to 255 0
Description
See Chapter 2.3.4.
Block mode, set to Auto
Block errors, see Chapter 5.2.3
Value and status of the block input IN_1
Conversion of IN_1
Value and status of the block input IN_2
Conversion of IN_2
Value and status of the block input IN_3
Conversion of IN_3
Value and status of the block input IN_4
Conversion of IN_4
Parameterl
ACTIVE_FLAG
PB_DATATYPE
PI_OUT_VAL_OFFSET
FROM_EU_0
FROM_EU_100
TO_EU_0
TO_EU_100
STATUS_DETAILS
PI_OUT_STATUS_OFFSET
PV_TAG
FS_MODE
FS_STATUS
FS_AVALUE
FS_TIME
Valid
Range
2 ... 14
0 .. 0xFF
Default
Value
Description
Disabled Flags whether IN_x value has been refreshed
• Disable: IN_x value not refreshed
• Enabled: IN_x value refreshed
8 Profibus data type as communicated over PROFIBUS
• 2: Integer8
• 3: Integer16
• 4: Integer32
• 5: Unsigned8
• 6: Unsigned16
• 7: Unsigned32
• 8: Floating Point
• 9: Reserved:
• 10: Integer16 in Little Endian format
• 11: Integer32 in Little Endian format
• 12: Unsigned16 in Little Endian format
• 13:> Unsigned32 in Little Endian format
• 14: Floating Point swapped, inverse byte order in comparison to that of PB spec.
Indicates the positions in the process image of IN_x values 0, 5, 10,
15
0.0
1.0
0.0
1.0
Raw value from EU_0
Raw value from EU_100
Scaled value to EU_0
Scaled value to EU_100
4, 8, 12,
16
Profibus Status Detail, see next table
Indicates the positions in the process image of IN_x status; should these be provided by the Remote I/O
Tag of process value mapped to OUT_x parameters
Selection of fault state mode
• 1: Disable
• 2: Get Last Data
• 3: Get FS Data
Status to be output when fault state active
FaultState Value
FaultState Time
270 Endress+Hauser
ControlCare Application Designer: Function Blocks
STATUS_DETAILS
9 PROFIBUS Blocks
81
...
87
A0
8
9
80
No.
1
2
3
4
5
6
7
A1
...
A7
Type
STANDARD_PA
MSB_BYTE_STATUS_0_GOOD
MSB_BYTE_STATUS_1_GOOD
BYTE_PACKED_STATI_1_GOOD_BITx
Function
Status is coded in one byte according to PA/FF
• Value for the status written to the process image output data at
PI_OUT_STATUS_OFFSET
MSB of the byte with the value sends the status:
• If bit 7 of status of IN_x is set to '1' then MSB = 0: OK, else MSB = 1: NOT OK
MSB of the byte with the value sends the status:
• If bit 7 of status of IN_x is set to '1' then MSB = 1: OK, else MSB = 0: NOT OK
MSB_WORD_STATUS_0_GOOD
MSB_WORD_STATUS_1_GOOD
MSB_DOUBLEWORD_STATUS_0_GOOD MSB of the double word with the value sends the status:
• If bit 7 of status of IN_x is set to '1' then MSB = 0: OK, else MSB = 1: NOT OK
MSB_DOUBLEWORD_STATUS_1_GOOD MSB of the double word with the value sends the status:
• If bit 7 of status of IN_x is set to '1' then MSB = 1: OK, else MSB = 0: NOT OK
STATUS_NA_SUBST_VAL
Reserved
PB slave does not require a status; status of IN_x not used
BYTE_PACKED_STATI_0_GOOD_BIT=
MSB of the word with the value sends the status:
• If bit 7 of status of IN_x is set to '1' then MSB = 0: OK, else MSB = 1: NOT OK
MSB of the word with the value sends the status:
• If bit 7 of status of IN_x is set to '1' then MSB = 1: OK, else MSB = 0: NOT OK
BYTE_PACKED_STATI_0_GOOD_BITx
Bit0 of value at PI_OUT_STATUS_OFFSET sends the status
• If bit7 of status of IN_x is set to '1' then Bit0 = 0 (OK), else Bit0 = 1 (NOT OK)
BitX of value at PI_OUT_STATUS_OFFSET sends the status
• If bit7 of status of IN_x is set to '1' then BitxX = 0 (OK), else BitX = 1 (NOT OK)
BYTE_PACKED_STATI_1_GOOD_BIT0 Bit0 of value at PI_OUT_STATUS_OFFSET sends the status
• If bit7 of status of IN_x is set to '1' then Bit0 = 1 (OK), else Bit0 = 0 (NOT OK)
BitX of value at PI_OUT_STATUS_OFFSET sends the status
• If bit7 of status of IN_x is set to '1' then BitxX = 1 (OK), else BitX = 0 (NOT OK)
Endress+Hauser 271
9 PROFIBUS Blocks ControlCare Application Designer: Function Blocks
9.10 PROFIBUS Discrete Output
The PROFIBUS Discrete Output block provides one discrete input to a transducer block and is created in PROFIBUS Configurator when e.g. an on/off actuator is selected. Application Designer maps the slave configuration and creates the block Device Tag PA-DO-1 .
SP_D
RCAS_IN_D
(CAS_IN_D)
SELECTOR
(RCAS_IN_D)
PROFIBUS
Process
Image
Output Data
PROFIBUS
Process
Image
Input Data
(BKCAL_OUT_D)
READBACK_D
CHECK_BACK
(RCAS_OUT_D)
RCAS_OUT_D
PROFIBUS
Slave
FSAFE_VAL
FAILSAFE
ACTIVE
PROFIBUS
Slave
Fig. 9-16: Schematic diagram of the PROFIBUS Discrete Output
9.10.1 Functional description
Depending on the configuration selected and control strategy, the Profibus Discrete Output block receives its setpoint from:
• an upstream block, SP_D (=CAS_IN_D) or
• an external system, RCAS_IN_D
The setpoint is passed on to the device transducer block, which drives the actuator to the required position.
Depending on configuration, the block outputs the following transducer information:
• READBACK_D: current position and status of the actuator
• CHECK_BACK : Detailed information on the valve status in the form of a 3 byte bit map capable of carrying several messages at once
• RCAS_OUT_D: current position and status of the actuator for an external system
The available discrete outputoptions are dependent upon the device and are contained within its
GSD. The inputs and outputs are activated by configuring the appropriate mode in the Slave
Configuration dialogue of PROFIBUS Configurator:
Discrete Output option
SP_D
SP_D/READBACK_D
SP_D/CHECK_BACK
Action
The output block uses the input SP_D from an upstream block only
The output block uses the input SP_D from an upstream block and provides the output READBACK_D
The output block uses the input SP_D from an upstream block and provides the output CHECK_BACK
SP_D/READBACK_D/CHECK_BACK The output block uses the input SP_D from an upstream block and provides the outputs READBACK_D and CHECK_BACK
RCAS_IN_D/ RCAS_OUT_D The output block the input RCAS_IN_D from an external application and provides the output RCAS_OUT_D
RCAS_IN_D/ RCAS_OUT_D/
CHECK_BACK
SP_D/ READBACK_D/ RCAS_IN_D/
RCAS_OUT_D/ CHECK_BACK
The output block uses the input RCAS_IN_D from an external application and provides the outputs RCAS_OUT_D and CHECK_BACK
The output block uses the input SP_D from an upstream block or the input
RCAS_IN_D from an external application and provides the outputs
READBACK_D, RCAS_OUT_D and CHECK_BACK
The block supports the failsafe mechanism as described in Chapter 9.1.2.
272 Endress+Hauser
ControlCare Application Designer: Function Blocks 9 PROFIBUS Blocks
9.10.2 Block configuration
Fig. 9-17 shows an example of on-off control of process tank level that uses the PROFIBUS Discrete
Output block. The level in a process tank with random inflow is controlled by opening and closing the outlet valve (LV100) based on the level sensed in the tank by the Liquiphant level switch
(LSH100). The Liquiphant outputs a true signal when it is covered with liquid; the valve is operated by a solenoid and is open when the corresponding point of the Remote I/O this is activated. The checkback information is assessed by the SCADA system.
Block configuration
Feed In
Process
Tank
Liquiphant
LSH
100
S e.g. via PROFIBUS/HART remote I/O
LV
100
Feed Out
Fig. 9-17: Example of on-off control of process tank level
Fig. 8-3 shows the control strategy together with links that must be made between the blocks.
LSH100
Liquiphant
PA_DI
OUT_D
SP_D
PA_DO
CHECK_BACK
LSH100 LV100
Solenoid
SCADA system
Fig. 9-18: Links required for basic closed-loop control
PROFIBUS Configurator is used to create the Digital Input Block of the Liquiphant and Digital
Output block for the PROFIBUS on-off valve. For the Liquiphant the module "Discrete In" is selected in the Slave Configuration dialog, for the valve the module "SP_D/ CHECK_BACK"..
Function Example value Parameter
PA_DI block
MODE_BLK.Target
PA_DO block
MODE_BLK.Target
FS_MODE
FS_STATUS
FS_DVALUE
FS_TIME
Normal operating mode of block Auto
Normal operating mode of block Cas
Operating mode of failsafe function, see Chapter 9.1.2
Get FS value
Status to be output on failsafe case
Bad NoUsableValue (00x14 = 20)
20
Fail-to-safe value for valve (= open, prevents overspill) 1
Time delay (s) between loss of input and failsafe case 3
Endress+Hauser 273
9 PROFIBUS Blocks
Mode
Status
274
ControlCare Application Designer: Function Blocks
9.10.3 Block operation
The PROFIBUS Analog Output block normally operates:
• in Auto mode when the setpoint is provided by the SP_D input
• in RCas mode when the setpoint is provided by the RCAS_IN_D input
The block supports the failsafe mechanism as described in Chapter 9.1.2.
If MODE_BLK.Target
is set to Man, the SP or RCAS_IN value and status can be overwritten.
The block can also be put out of service (OOS).
Status
GoodNC:xxx
Bad:NoCommunication, Last Usable Value
Bad:NoCommunication, No Usable Value
Bad:Out of Service
Meaning
• Block operating correctly, TOTAL value valid
• No PROFIBUS communication, last valid output value used
• No PROFIBUS communication, output value = 0
• Block currently out of service
9.10.4 Block parameters
Parameterl
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
SP_D
RCAS_IN_D
READBACK_D
CHECK_BACK
RCAS_OUT_D
PI_OUT_SP_D_OFFSET
PI_OUT_SP_STAT_D_OFFSET
PI_OUT_RCAS_IN_D_OFFSET
PI_OUT_RCAS_STAT_OFFSET
PI_INP_RD_BACK_D_OFFSET
PI_INP_RD_BACK_STAT_
OFFSET
PI_INP_CHK_BACK_OFFSET
PI_INP_RCAS_OUT_D_
OFFSET
PI_INP_RCAS_OUT_STAT_
OFFSET
DO_MODE_SEL
Valid
Range
Default
Value
0 ... 65535 0
Spaces
0 ... 65535 0
0 to 255 0
0, 0
0, 0
0xFFFF
0xFFFF
0xFFFF
0xFFFF
0xFFFF
0xFFFF
0xFFFF
0xFFFF
0xFFFF
Description
See Chapter 2.3.4.
Block mode, set to Auto for SP_D, RCas for RCAS_IN_D
Block errors, see Chapter 5.2.3
Discrete setpoint value and status
Remote discrete setpoint value and status
Current position and status of the actuator
Detailed device information (3 bytes) as bit coded octet string
Current position and status of the actuator for external system
Position in the input process image of the SP_D value
Position in the input process image of the SP_D status
Position in the input process image of the RCAS_IN_D value
Position in the input process image of the RCAS_IN_D status
Position in the input process image of the READBACK_D value
Position in the input process image of the READBACK_D status
Position in the input process image of the CHECKBACK value
Position in the input process image of the RCAS_OUT_D value
Position in the input process image of the RCAS_OUT_D status
FS_MODE
FS_STATUS
FS_DVALUE
FS_TIME
Configuration of discrete output block
0: only SP_D
1: SP_D, READBACK_D;
2: SP_D, CHECK_BACK;
3: SP_D, READBACK_D, CHECK_BACK;
4: RCAS_IN_D, RCAS_OUT_D;
5: RCAS_IN_D, RCAS_OUT_D, CHECK_BACK;
6: SP_D, READBACK_D, RCAS_IN_D, RCAS_OUT_D,
CHECK_BACK
Selection of fault state mode
1: Disable
2: Get Last Data
3: Get FS Data
Status to be output when fault state active
FaultState Value
FaultState Time
Endress+Hauser
ControlCare Application Designer: Function Blocks 9 PROFIBUS Blocks
9.11 PROFIBUS Multiple Discrete Output
The PROFIBUS Multiple Discrete Output block provides eight discrete inputs to a transducer block and is created in PROFIBUS Configurator when a discrete output module of a PROFIBUS Remote
I/O is selected. Application Designer maps the slave configuration and creates the block Device
Tag DP-MDO-1 .
Description
Endress+Hauser
IN_D1
IN_D2
IN_D3
IN_D4
IN_D5
IN_D6
IN_D7
IN_D8
FSAFE_DVALUE
SELECTOR
(8x)
FAILSAFE
ACTIVE
PROFIBUS
Process
Image
Output Data
PROFIBUS
Slave(s)
Fig. 9-19: Schematic diagram of the PROFIBUS Multiple Discrete Output block
9.11.1 Functional description
The PROFIBUS Multiple Discrete Output block has eight discrete inputs IN_D1 to IN_D8 which drive the eight outputs of the Remote I/O discrete output module selected in PROFIBUS
Configurator.
The LOC_IN_x parameter expands to show information about the IN_Dx value. A fault state behaviour can be set within this parameter by means of the parameters FS_MODE , FS_STATUS ,
FS_DVALUE and FS_TIME .
9.11.2 Block configuration
Fig. 9-20 shows an example of a control strategy using the PROFIBUS Multiple Discrete Output block and four channels of the 8-channel NO relay module of a PROFIBUS Remote I/O.
OUT_D
False “0” or
True “1”
OUT_D
OUT_D
IN_D1
IN_D2
OUT_D
IN_D3
OUT_D
IN_D4
DP_MDO output
Fig. 9-20: Example of links required for Multiple Discrete Output block used with Remote I/O
In the example, only the first four inputs are used:
• IN_D1 drives the DO-1 output
• IN_D2 drives the DO-2 output
• IN_D3 drives the DO-3 output
• IN_D4 drives the DO-4 output
The block configuration comprises setting the block mode and fault state values.
DO-1 (NO)
DO-2 (NO)
DO-3 (NO)
DO-4 (NO)
275
9 PROFIBUS Blocks
Block configuration
Status
Block errors
ControlCare Application Designer: Function Blocks
The Multiple Discrete Output block is created according to the module selected for the Remote I/O in PROFIBUS Configurator. The way in which the value and status are transferred is configured in the PROFIBUS mapping tool.
Function Example value Parameter
DP_MDO block
MODE_BLK.Target
LOC_IN_D1
FS_MODE
FS_STATUS
FS_AVALUE
FS_TIME
LOC_IN_D2
FS_MODE
FS_STATUS
FS_AVALUE
FS_TIME
LOC_IN_D3
FS_MODE
FS_STATUS
FS_AVALUE
FS_TIME
LOC_IN_D4
FS_MODE
FS_STATUS
FS_AVALUE
FS_TIME
Normal operating mode of block
Operating mode of failsafe function, see Chapter 9.1.2
IN_D1 status to be output on failsafe case
Bad NoUsableValue (00x14 = 20)
IN_D1 value to be used on failsafe case, e.g. open = 0
Time delay (s) between loss of input and failsafe case
Operating mode of failsafe function, see Chapter 9.1.2
IN_D2 status to be output on failsafe case
Bad NoUsableValue (00x14 = 20)
IN_D2 value to be used on failsafe case, e.g. open = 0
Time delay (s) between loss of input and failsafe case
Operating mode of failsafe function, see Chapter 9.1.2
IN_D3 status to be output on failsafe case
Bad NoUsableValue (00x14 = 20)
IN_D3 value to be used on failsafe case, e.g. open = 0
Time delay (s) between loss of input and failsafe case
Operating mode of failsafe function, see Chapter 9.1.2
IN_D4 status to be output on failsafe case
Bad NoUsableValue (00x14 = 20)
IN_D4 value to be used on failsafe case, e.g. open = 0
Time delay (s) between loss of input and failsafe case
Auto
0
3
0
3
0
3
0
3
Get FS Data
20
Get FS Data
20
Get FS Data
20
Get FS Data
20
9.11.3 Block operation
The PROFIBUS Multiple Discrete Output block normally operates in Auto mode.
If MODE_BLK.Target
is set to Man, the IN_Dx value and status can be overwritten.
The block can also be put out of service (OOS).
Status
GoodNC:xxx
Bad:NoCommunication, Last Usable Value
Bad:NoCommunication, No Usable Value
Bad:Out of Service
Meaning
• Block operating correctly, OUT value valid
• No PROFIBUS communication, last valid OUT value used
• No PROFIBUS communication, no valid value (OUT = 0)
• Block currently out of service
Block errors are indicated in the BLOCK_ERR parameter
Condition
Output Failure
Out-of-Service
Reason
• No PROFIBUS communication or device failure
• MODE_BLK.Target currently set to OOS
276 Endress+Hauser
ControlCare Application Designer: Function Blocks
LOC_IN_Dx
9 PROFIBUS Blocks
Parameterl
ST_REV
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
IN_D1
LOC_IN_D1
IN_D2
LOC_IN_D2
IN_D3
LOC_IN_D3
IN_D4
LOC_IN_D4
IN_D5
LOC_IN_D5
IN_D6
LOC_IN_D6
IN_D7
LOC_IN_D7
IN_D8
LOC_IN_D8
9.11.4 Block parameters
Valid
Range
Default
Value
0 ... 65535 0
Spaces
0 ... 65535 0
0 to 255 0
Description
See Chapter 2.3.4.
Block mode, set to Auto
Block errors, see Chapter 5.2.3
Value and status of the block input IN_D1
Conversion of IN_D1
Value and status of the block input IN_D2
Conversion of IN_D2
Value and status of the block input IN_D3
Conversion of IN_D3
Value and status of the block input IN_D4
Conversion of IN_D4
Value and status of the block input IN_D5
Conversion of IN_D5
Value and status of the block input IN_D6
Conversion of IN_D6
Value and status of the block input IN_D7
Conversion of IN_D7
Value and status of the block input IN_D8
Conversion of IN_D8
.
Parameterl
ACTIVE_FLAG
PI_OUT_VAL_OFFSET
VAL_BIT_OFFSET
STATUS_DETAILS
PI_OUT_STATUS_OFFSET
PV_TAG
FS_MODE
FS_STATUS
FS_DVALUE
FS_TIME
Valid
Range
0 .. 0xFF
Default
Value
Description
Disabled Flags whether IN_Dx value has been refreshed
• Disable: IN_Dx value not refreshed
• Enabled: IN_Dx value refreshed
Indicates the positions in the process image of IN_Dx values 0, 5, 10,
15
0.0
Indicates at which bit of the byte referenced by
PI_OUT_VAL_OFFSET the binary value is to be written,
• Default value bit0;
• Another location is normal when several binary values are packed into one byte/word
4, 8, 12,
16
See Chapter 9.9.2
Indicates the positions in the process image of IN_x status; should these be provided by the Remote I/O
Tag of process value mapped to OUT_x parameters
Selection of fault state mode
• 1: Disable
• 2: Get Last Data
• 3: Get FS Data
Status to be output when fault state active
FaultState Value
FaultState Time
Status details can be taken from the table in Chapter 9.9.2
Endress+Hauser 277
10 Modbus Blocks
Establishing communication
Modbus commands
Registers
278
ControlCare Application Designer: Function Blocks
10 Modbus Blocks
10.1 ControlCare Implementation
ControlCare Field Controllers SFC162 and SFC173 are equipped with both a Modbus serial and
Ethernet interface. As a result, they can be operated in one of the following roles:
• Modbus Serial or TCP Master
• Modbus Serial or TCP Slave
• Modbus TCP Master and Serial Slave, Modbus TCP Slave and Serial Master ot
Modbus TCP Master and TCP Slave
The Modbus role and corresponding parameters are configured in the Modbus Configuration Block,
MBCF. As serial master, a Field Controller supports up to 128 Modbus slaves; as TCP master eight
Modbus slaves only. In serial (RTU) operation baudrates from 9600 to 115200 are possible. If configured as a serial or TCP slave, a field controller can be accessed by one Modbus master only.
Modbus communication is initially established by pressing the ON_APPLY button in the MBCF block. If changes are made to the Modbus configuration, the button must always be pressed to reestablish communication with the new parameters.
On recovery after a power failure, the Field Controller resumes communication automatically within 30 seconds. If a Modbus slave device loses power or is disconnected, the Field Controller will continue to poll it until it recovers, is re-connected or is removed from the strategy.
When the Field Controller is configured as a TCP slave, access to the Modbus registers is controlled by entering the IP address of the Modbus master. The Field Controller will normally communicate with the master via Port 502. If this port is unavailable, it is possible to specify a secondary TCP/IP port number.
Field Controller supports the following Modbus functions
Function
Read discrete inputs
Read coils
Write single coil
Write multiple coils
Read input register
Read holding register
Write single register
Write multiple registers
Read/Write multiple register
3
6
15
4
1
5
Function Code Hex
2 0x02
Applies To
Master, Slave
0x01
0x05
Master, Slave
Master, Slave
16
23
0x0F
0x04
0x03
0x06
0x10
0x17
Master, Slave
Master, Slave
Master, Slave
Master, Slave
Master, Slave
Slave only
Modbus specifies four different types of register:
• Discrete input registers contain the discrete input values and possibly status
• Input registers contain analog input values and status
• Coil registers contain discrete output values and possibly status
• Holding registers contain analog output values and status
.
In addition, it is possible to "pack" discrete inputs and outputs into words, which are then stored as appropriate in the input or holding registers. Fig. 2-1 gives an overview of the register and reference address ranges used for each register type in Field Controller. The table shows the relationship between the function block input and output parameters and the registers for master and slave roles.
FB Parameter
IN_D1 to IN_D4
OUT_D1 to OUT_D4
IN_1 to IN_4
OUT_1 to OUT_4
Field Controller as Modbus Master
Value written to slave coil
Value read from slave discrete input/coil
Value written to slave holding register
Field Controller as Modbus Slave
Value read by master from discrete input
Value written by master to coil
Value read from master from input register
Value read from slave input/holding register Value written by master to holding register
Endress+Hauser
ControlCare Application Designer: Function Blocks 10 Modbus Blocks
10.1.1 Register access
Depending upon the Modbus implementation, the registers are accessed by specifying:
• the function code and the register address or
• the reference address
When Field Controller is used as a master, the addresses are entered in the LOCATOR and
SCALE_LOC parameters. When it is acting as a slave, it offers the values by means of an address table which is dependent upon the unique MBCS block identifier LOCAL_MOD_MAP .
1 0
RW
Coils
10000
10001
9999
0
RO
Discrete Inputs
20000 9999
30001 0
RO
Input registers
40000
40001
9999
0
9000
Packed coils
RW
Holding registers
Slave only
50000 9999
9000
Packed discrete inputs Slave only
Fig. 10-1: Mapping of Modbus registers in ControlCare Field Controller
Endress+Hauser 279
10 Modbus Blocks
Floating point
ControlCare Application Designer: Function Blocks
10.1.2 Data types
ControlCare Field Controllers support seven different data types, which are interpreted and stored as described below:
• Floating point
• Integer32, Unsigned Integer32, Integer 16, Unsigned Integer16, Integer8, Unsigned Integer8
Value range
Byte Structure
(± ) 1.175 * 10
-38
to 3.403 * 10
38
31 23 0
Sign
Storage
Modbus Register 1
Float
15
Exponent (8 bit)
Modbus Register 2 31
0
Fraction (23 bit)
Swapped Float
31
16 15
16
0
Integer32
Unsigned32
280
Value range
Byte Structure
-2147483648 to +2147483647
31 30
Sign
Storage
Modbus Register 1
Integer32
31
Modbus Register 2 15
16
Value (31 bit)
Swapped Integer32
15
0 31
Value range
Byte Structure
0 to 4.294.967.295
31
Storage
Modbus Register 1
Modbus Register 2
Unsigned Integer32
31
15
0
0
Value (32 bit)
16
Swapped Unsigned Integer32
15
0 31
0
16
0
16
Endress+Hauser
ControlCare Application Designer: Function Blocks
Integer16
Value range
Byte Structure
-32.768 to 32.767
15 14
Sign
Storage
Modbus Register 1
Integer16
15 0
Value (15 bit)
Swapped Integer16
15
0
10 Modbus Blocks
0
Unsigned16
Value range
Byte Structure
0 to 65.535
15
Storage
Modbus Register 1
Unsigned Integer16
15
0
0
Value (16 bit)
Swapped Unsigned Integer16
15 0
Integer8
Unsigned 8
Value range
Byte Structure
-128 to +127
Storage
Modbus Register 1
Integer8
15
0 0 0 0 0 0 0 0
7
15
0 0 0 0 0 0 0 0
7 0
0
Sign Value (7 bit)
Swapped Integer8
15 14 7 0
0 0 0 0 0 0 0
Value range
Byte Structure
0 to 255
Storage
Modbus Register 1
Unsigned Integer8
15
0 0 0 0 0 0 0 0
7
15
0 0 0 0 0 0 0 0
7 0
0
Value (8 bit)
Swapped Unsigned Integer8
15 7 0
0 0 0 0 0 0 0 0
Endress+Hauser 281
10 Modbus Blocks
Block parameters
282
ControlCare Application Designer: Function Blocks
10.2 MBCF Modbus Configuration Block
The Modbus Configuration Block MBCF is used to configure the Field Controller for a role as master or slave. The table below lists the parameters and gives a short explanation of their function.
Parameter
ST_VER
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
MEDIA
MASTER_SLAVE
TIMEOUT
SERIAL_CONFIG
.BAUD_RATE
.STOP_BITS
.PARITY
TCP_IP_CONFIG
.SECOND_MOD_PORT
MASTER_CONFIG
.NUMBER_RETRIES
.MOD_SCAN_TIME
.MAX_DATA_LENGTH
SLAVE_CONFIG
.DEVICE_ADDRESS
.MAX_MOD_REACTION_TIME
TCP_SLAVE_ADDRESSES
1 - 247
.IP_SLAVE_X
.DEVICE_ID_X
.COMM_STATUS_X
TCP_ACCESS_LIST
.IP_x
ON_APPLY 0, 1
UPDATE_EVT
MB_COMM_STATUS
USED_MOD_REGISTERS
FREE_MOD_REGISTERS
Valid range
0 to 255
1 to 255
TARGET
0 to 15
0 to2
0 to2
RO
RO
Default value
0
Description/Action blanks
0
1
O/S
Serial
Slave
0 - 65535 1000
-
6 - 10
0, 1
1 - 3
-
0 - 255
-
19200
1
Even
-
1
1
None
Indicates the revision level of the block’s static parameters and may be used in configuration management
Allows the entry of a block description (up to 32 characters) which may be used in a human interface or in block documentation to clarify the block application
Allows the entry of a user assigned value that may be used in configuration or diagnostics as a key in sorting block information
Allows the entry of a user assigned value that may be used in sorting alarms or events generated by a block
Block mode, set to Auto
Block errors, see Chapter 5.2.3
Defines Modbus medium, "( )" slave in "master + slave" below
0: Serial (+TCP/IP), 1: TCP/IP (+Serial),
2: TCP/IP (+TCP/IP)
Defines if Field Controller is master or slave
• 0: Master, 1: Master + Slave, 2: Slave
Time allowed for a response from a slave (for Field Controller master) or for the OUTs be updated (for Field Controller slave).
Value 0 is used to disable.
– In the case of a slave, the TIMEOUT must be set to a value greater than the write cycle of the Modbus master, otherwise the status of the mapped values is BAD.
Configures serial interface
Defines the baud rate
• 6: 9600, 7: 19200, 8: 38400, 9: 57600, 10: 115200
Defines the number of stop bits (only for media serial).
• 0: 1, 1: 2
Defines the parity (only for media serial)
• 0 :None, 1: Even, 2: Odd
Configures TCP/IP interface
Second communication port (Port 502 is always open)
To be configured when Field Controller is Modbus master
Number of times Field Controller tries to retransmit the data if it does not receive a response from a slave
When online, displays Modbus scan time in ms when Field
Controller is Modbus master (average of the last 10 cycles)
Max. number of registers that can be read from a slave with a single telegram
– Use only if slave does not support the standard length of 125 registers (250 byte)
To be configured when Field Controller is Modbus slave
Modbus slave address of Field Controller
When online, displays max. time to respond to a master
To be configured when Field Controller is Modbus TCP master
IP address of Modbus TCP slave
Unit address of Modbus TCP slave
When online, displays status of output data
To be configured when Field Controller is Modbus TCP slave
IP address of TCP master allowed to access to registers
Applies the changes made in the Modbus blocks
• 0: None, 1: Apply
This alert is generated by any change to the static data
Displays status of Modbus communication (OK when working)
When online, displays number of Modbus points in use
When online, displays available Modbus points in percentage
Endress+Hauser
ControlCare Application Designer: Function Blocks 10 Modbus Blocks
10.2.1 Configuration as TCP/IP master
To configure the Field Controller as a Modbus TCP/IP master, set the following parameters in the
Off Line Characterization dialog of the MBCF block:
Parameter
MODE BLOCK.TARGET
MEDIA
MASTER_SLAVE
TIMEOUT
TCP/IP_CONFIG
SECOND_MOD_PORT
MASTER_CONFIG
NUMBER_OF_RETRIES
MAX_DATA_LENGTH
TCP_SLAVE_ADDRESSES
IP_SLAVE_x
DEVICE_ID_x
Function
Normal operating mode of block
Channel for Modbus communication
Role of Field Controller in Modbus network
Time allowed for slave response
If there is no response, the slave status is set to BAD
Configures TCP/IP interface
Second communication port (Port 502 is always open)
Configures Controller when acting as master
Number of retransmits if no response from a slave
Max. number of registers that can be read from a slave with a single telegram (default = 250)
Configures up to eight Modbus TCP slaves
IP address of Modbus TCP slave x
Unit address of Modbus TCP slave x
MBCF
Auto
TCP/IP (+ TCP/IP)
Master e.g. 1000 (ms) e.g. 1024 default 250 e.g. 10.125.35.50
e.g. 12
When the block is on-line, selecting the "Apply" option in the ON_APPLY parameter starts Modbus communication. This is necessary after a download or a change in the Modbus configuration.
10.2.2 Configuration as TCP/IP slave
To configure the Field Controller as a Modbus TCP/IP slave, set the following parameters in the
Off Line Characterization dialog of the MBCF block:
Parameter
MODE BLOCK.TARGET
MEDIA
MASTER_SLAVE
TIMEOUT
TCP/IP_CONFIG
SECOND_MOD_PORT
SLAVE_CONFIG
DEVICE_ADDRESS
TCP_ACCESS_LIST
IP_x
Function
Normal operating mode of block
Channel for Modbus communication
Role of Field Controller in Modbus network
Time allowed for OUT value update
If there is no update, the output status is set to BAD
Configures TCP/IP interface
Second communication port (Port 502 is always open)
Configures Controller when acting as slave
Modbus address of Field Controller
List of up to eight masters that are allowed to access field controller registers
IP address of TCP master x
MBCF
Auto
TCP/IP (+ TCP/IP)
Slave e.g. 1000 (ms) e.g. 1024 e.g. 1 e.g. 10.125.35.90
When the block is on-line, selecting the "Apply" option in the ON_APPLY parameter starts Modbus communication. This is necessary after a download or a change in the Modbus configuration.
Endress+Hauser 283
10 Modbus Blocks ControlCare Application Designer: Function Blocks
10.2.3 Configuration as serial master
To configure the Field Controller as a Modbus serial master, set the following parameters in the
Off Line Characterization dialog of the MBCF block:
Parameter
MODE BLOCK.TARGET
MEDIA
MASTER_SLAVE
TIMEOUT
SERIAL_CONFIG
BAUDRATE
STOP_BITS
PARITY
MASTER_CONFIG
NUMBER_OF_RETRIES
MAX_DATA_LENGTH
Function
Normal operating mode of block
Channel for Modbus communication
Role of Field Controller in Modbus network
Time allowed for slave response
If there is no response, the slave status is set to BAD
Configures serial interface (default for Promass 83)
Baudrate used for communcation
Number of stop bits used in telegram
Parity used in telegram
Configures Controller when acting as master
Number of retransmits if no response from a slave
Max. number of registers that can be read from a slave with a single telegram (default = 250)
MBCF
Auto
Serial (+TCP/IP)
Master e.g. 1000 (ms) e.g. 38400 e.g. 1 e.g. Even default 250
When the block is on-line, selecting the "Apply" option in the ON_APPLY parameter starts Modbus communication. This is necessary after a download or a change in the Modbus configuration.
10.2.4 Configuration as serial slave
To configure the Field Controller as a Modbus serial master, set the following parameters in the
Off Line Characterization dialog of the MBCF block:
Parameter
MODE BLOCK.TARGET
MEDIA
MASTER_SLAVE
TIMEOUT
SERIAL_CONFIG
BAUDRATE
STOP_BITS
PARITY
SLAVE_CONFIG
DEVICE_ADDRESS
Function
Normal operating mode of block
Channel for Modbus communication
Role of Field Controller in Modbus network
Time allowed for OUT value update
If there is no update, the output status is set to BAD
Configures serial interface (default for Promass 83)
Baudrate used for communcation
Number of stop bits used in telegram
Parity used in telegram
Configures Controller when acting as slave
Modbus address of Field Controller
MBCF
Auto
TCP/IP (+Serial)
Slave e.g. 1000 (ms) e.g. 38400 e.g. 1 e.g. Even e.g. 1
When the block is on-line, selecting the "Apply" option in the ON_APPLY parameter starts Modbus communication. This is necessary after a download or a change in the Modbus configuration.
10.2.5 Configuration as master and slave
The Field Controller can also be configured to act simultaneously as both master and slave. The configuration of the media depends on the selection and is as described in the Chapter 10.2.1to
Chapter 10.2.4.
Parameter
MEDIA
MASTER_SLAVE
Function
Channel for Modbus communication
• Serial (+TCP/IP): Serial master, TCP/IP slave
• TCP/IP (+Serial): TCP/IP master, serial slave
• TCP/IP (+ TCP/IP): TCP/IP master, TCP/IP slave
Role of Field Controller in Modbus network
MBCF e.g.
TCP/IP (+Serial)
Master + slave
284 Endress+Hauser
ControlCare Application Designer: Function Blocks 10 Modbus Blocks
10.3 Modbus Control Master
The Modbus Control Master block is required when the Field Controller is to act as a Modbus master. In this role Field Controller reads from or writes to registers in a Modbus slave. The Modbus values are mapped through a FOUNDATION Fieldbus function block that has four sets of channels
(AI, DI, AO, DO), allowing connection to other function blocks in a control strategy, see Fig. 10-2.
Register addresses
IN_1
IN_2
IN_3
IN_4
IN_D1
IN_D2
IN_D3
IN_D4
FB
RANGE AND
DATA TYPE
CONVERSION
SLAVE 1
SLAVE 2
.
.
.
SLAVE N
RANGE AND
DATA TYPE
CONVERSION
FB
OUT_1
OUT_2
OUT_3
OUT_4
OUT_D1
OUT_D2
OUT_D3
OUT_D4
Fig. 10-2: Schematic diagram of the Modbus Control Master block
10.3.1
Block description
Up to 16 MBCM blocks can be created in a project. The blocks are managed via the parameter
LOCAL_MOD_MAP which must have a unique value (0 to 15) for each block.
.
The mapping of the Modbus values is controlled by SCALE_LOC_XXX parameters for analog values and LOCATOR_XXX parameters for discrete values. These point the Field Controller to the register addresses to which data are to be written or from which data are to be read. The table gives an overview of the relationships of the input and output parameters to the mapping parameters:
Parameter
IN_1 to IN_4
IN_D1 to IN_D4
OUT_1 to OUT_4
Type
Analog input
Function in slave Mapping parameter Reference address
Write to holding register SCALE_LOC_INx 40001 + register address
Discrete input Write to coil LOCATOR_IN_Dx 1 + coil address
Analog output Read from input register SCALE_LOC_OUTx 30001 + register address
Read from holding register 40001 + register address
OUT_D1 to OUT_D4 Discrete output Read from discrete input LOCATOR_OUT_Dx 10001 + register address
Read from coil 1 + coil address
Both SCALE_LOC_XXX and LOCATOR_XXX use three parameters to locate the register containing the Modbus value:
• SLAVE_ADDRESS points to the Modbus address of the connected slave
• MODBUS_ADDRESS_OF_VALUE points to the register address of the required value
• MODBUS_ADDRESS_OF_STATUS points to the register address of the associated status
In the case of analog data types that require two registers, only the first one is entered in
MODBUS_ADDRESS_OF_VALUE . The second, adjacent address is automatically reserved according to the data type.
If the slave variable does not support a status or the status does not conform to the FF format, then zero must be entered in MODBUS_ADDRESS_OF_STATUS , see also Status handling. If required, an additional characterization can be made in the output status parameter OUT_x.STATUS
or
OUT_Dx.STATUS
, e.g. "GoodCascade".
Endress+Hauser 285
10 Modbus Blocks
Scaling
Status propagation
286
ControlCare Application Designer: Function Blocks
SCALE_LOC_XXX contains additional parameters concerning data type and scaling of analog values:
• DATA_TYPE determines the data format of the value, see Chapter 10.1.2
• FROM_EU_XX determines the scaling of the "input" parameter
• TO_EU_XX determines the scaling of the "output" parameter
The scaling is performed as shown in Fig. 10-3, whereby the value to be scaled may lie outside the given limits.
“Output” to_EU_100% to_EU_0% from_EU_0% from_EU_100% “Input”
Fig. 10-3: Scaling of "input" to "output" units
The meaning of the scaling parameters in SCALE_LOC_INx and SCALE_LOC_OUTx is as follows:
Parameter
.FROM_EU_0
.FROM_EU_100
.TO_EU_0
.TO_EU_100
SCALE_LOC_INx
Lower range limit IN_x value
Upper range limit IN_x value
Lower range limit Modbus slave value
Upper range limit Modbus slave value
SCALE_LOC_OUTx
Lower range limit Modbus slave value
Upper range limit Modbus slave value
Lower range limit OUT_x value
Upper range limit OUT_x value
The status of a slave output value is mapped in the corresponding OUT_XX.STATUS
parameter.
The information it carries is dependent on the entry in MODBUS_ADDRESS_OF_STATUS and whether the period entered in the TIMEOUT parameter in the MBCF block has elapsed without a response being received from the slave.
MODBUS_ADDRESS_OF_STATUS TIMEOUT
Slave address register
Status
Slave responding (communicated within timeout period) As Slave
Slave not responding (timeout elapsed) Bad
0 (no status or status not FF conform) Slave responding (communicated within timeout period) Good
Slave not responding (timeout elapsed) Bad
The communication status of each Modbus variable can be read from the COMM_STATUS parameter. Each bit corresponds to one variable and corresponds to a logical OR between its status and value, whereby:
• If only the value is used, the status is considered zero
• If only the status is used, the value is considered zero.
If the bit is set (=1), there was an error during writing/reading of the respective parameter. The table shows the relationship between bit number and parameter.
1
2
BIT
0
3
PARAMETER
IN_1
IN_2
IN_3
IN_4
5
6
BIT
4
7
PARAMETER
IN_D1
IN_D2
IN_D3
BIT
8
9
10
IN_D4 11
PARAMETER
OUT_1
OUT_2
OUT_3
OUT_4
BIT
12
13
14
15
PARAMETER
OUT_D1
OUT_D2
OUT_D3
OUT_D4
Endress+Hauser
ControlCare Application Designer: Function Blocks 10 Modbus Blocks
10.3.2 Block configuration
The Modbus Control Master block is often used when measured values are to be acquired from and/or actuators are to be controlled in an existing Modbus network. In this example it is assumed that a serial Modbus Remote I/O is to be connected to the Field Controller:
• Slave address "5"
• Baud rate 19.2 kbit/s, Parity odd, Stopbits one
• Watchdog 2000 ms.
Fig. 10-4 shows the signals to be used by the application:
MBCM block
I/O signals
Discrete inputs
(10497 - 10502)
Coils
(497 - 502)
Input registers
(30034, 30035)
Holding registers
(40033, 40034)
Field Controller access through
MBCM block
Discrete inputs
(497 - 502)
Coils
(497 - 502)
Input registers
(34, 35)
Holding registers
(33, 34)
Remote I/O registers
Endress+Hauser
Digital Input Digital Output Analog Input Analog Output
Remote I/O modules
Signals to/from field
Fig. 10-4: Signal flow through MBCM blpock and Remote I/O
Six digital inputs and eight digital outputs are to be used together with two analog inputs (level and flow) and two analog outputs (valve positioners). The discrete inputs DI4 and DI5 are used directly to drive the outputs DO6 and DO7. The RIO registers start at one. The table shows the reference address range and location of the MODBUS_ADDRESS_OF_VALUE parameter. The status of the digital input will not be used by the Field Controller, so the MODBUS_ADDRESS_OF_STATUS must be set to "0" for all OUT parameters.
Input signals
RIO Module
Discrete Input
Analog Input
Output signals
Module
Discrete Output
Analog Output
Signals used
DI 0 ... DI 5
Status DI 0 ... DI5
AI0, AI1
Signals
DO0 ... DO7
AO0, AO1
Register
32
33
34, 35
Coil Action
497 – 502
513 – 518
–
Read
–
Read
Register
32
33, 34
Coil Action
497 – 504 Write
Write
LOCATOR_OUT_Dx/
SCALE_LOC_OUTx
10497 – 10502
_
30034, 30035
LOCATOR_IN_Dx/
SCALE_LOC_INx
497 – 502
40033, 40034
287
10 Modbus Blocks ControlCare Application Designer: Function Blocks
The Analog Input has a level and flow meter connected to it, the Analog Output drives two valve actuators. The values offered by the RIO in the range 0...27648 must be scaled to or from the values used in the control strategy:
Input signal
4 mA
20 mA
Output signal
4 mA
20 mA
ROI scale/FROM_EU
0
27648
ROI scale/TO_EU
0
27648
AI 0 scale/TO_EU
0%
100%
AO 0 scale/FROM_EU
0%
100%
AI 1 scale/TO_EU
0
2000 l/h
AO 1 scale/FROM_EU
0%
100%
To accommodate the six discrete inputs and eight discrete outputs, two MBCM blocks are required.
Fig. 10-5 shows a control strategy for the above application, whereby the upstream and downstream blocks, have been left out for clarity. The MBCM block can be connected to any function block that is available in the network, e.g. a PID block, and vice versa. to valve 1 to valve 2
IN_1
IN_2
IN_D1
IN_D2
IN_D3
IN_D4
IN_D1
IN_D2
IN_D3
IN_D4
AO 0
AO 1
AI 0
AI 1
DO 0
DO 1
MBCM-1
DI 0
DI 1
DO 2
DO 3
DI 2
DI 3
OUT_1
OUT_2
OUT_D1
OUT_D2
OUT_D3
OUT_D4
DO 4
DO 5
DO 6
MBCM-2
DI 5
DO 7
DI 4
OUT_D1
OUT_D2 level flow
Fig. 10-5: Control Strategy for integration of Modbus variables
MBCF block configuration The MBCF and MBCM blocks must be configured as follows:
Parameter
MODE BLOCK.TARGET
MEDIA
MASTER_SLAVE
TIMEOUT
SERIAL_CONFIG
BAUDRATE
STOP_BITS
PARITY
MASTER_CONFIG
NUMBER_OF_RETRIES
MAX_DATA_LENGTH
Function
Normal operating mode of block
Channel for Modbus communication
Role of Field Controller in Modbus network
Time allowed for slave response (= Watchdog)
If there is no response, the slave status is set to BAD
Configures serial interface (default for Promass 83)
Baudrate used for communcation
Number of stop bits used in telegram
Parity used in telegram
Configures Controller when acting as master
Number of retransmits if no response from a slave
Max. number of registers that can be read from a slave with a single telegram
Example value
Auto
Serial (+TCP/IP)
Master
2000 (ms)
19200
1
Odd
3
250 (default)
288 Endress+Hauser
ControlCare Application Designer: Function Blocks
MBCS block configuration The MBCM blocks must be configured as follows:
Parameter
MBCM-1 block
MODE_BLK.Target
LOCAL_MOD_MAP
SCALE_LOC_IN1
FROM_EU_0
FROM_EU_100
TO_EU_0
TO_EU_100
DATA_TYPE
SLAVE_ADDRESS
MODBUS_ADDRESS_OF_VALUE
MODBUS_ADDRESS_OF_STATUS
SCALE_LOC_IN2
FROM_EU_0
FROM_EU_100
TO_EU_0
TO_EU_100
DATA_TYPE
SLAVE_ADDRESS
MODBUS_ADDRESS_OF_VALUE
MODBUS_ADDRESS_OF_STATUS
LOCATOR_IN_D1
SLAVE_ADDRESS
MODBUS_ADDRESS_OF_VALUE
MODBUS_ADDRESS_OF_STATUS
LOCATOR_IN_D2
SLAVE_ADDRESS
MODBUS_ADDRESS_OF_VALUE
MODBUS_ADDRESS_OF_STATUS
LOCATOR_IN_D3
SLAVE_ADDRESS
MODBUS_ADDRESS_OF_VALUE
MODBUS_ADDRESS_OF_STATUS
LOCATOR_IN_D4
SLAVE_ADDRESS
MODBUS_ADDRESS_OF_VALUE
MODBUS_ADDRESS_OF_STATUS
SCALE_LOC_OUT1
FROM_EU_0
FROM_EU_100
TO_EU_0
TO_EU_100
DATA_TYPE
SLAVE_ADDRESS
MODBUS_ADDRESS_OF_VALUE
MODBUS_ADDRESS_OF_STATUS
SCALE_LOC_OUT2
FROM_EU_0
FROM_EU_100
TO_EU_0
TO_EU_100
DATA_TYPE
SLAVE_ADDRESS
MODBUS_ADDRESS_OF_VALUE
MODBUS_ADDRESS_OF_STATUS
LOCATOR_OUT_D1
SLAVE_ADDRESS
MODBUS_ADDRESS_OF_VALUE
MODBUS_ADDRESS_OF_STATUS
LOCATOR_OUT_D2
SLAVE_ADDRESS
MODBUS_ADDRESS_OF_VALUE
MODBUS_ADDRESS_OF_STATUS
Function
Normal operating mode of block
Identifier of Modbus block (0 - 15)
Scaling and conversion of IN_1 (valve 1)
Lower range limit of IN_1
Upper range limit of IN_1
Lower range limit of ROI signal
Upper range limit of ROI signal
Type of data transmitted
Modbus address of variable source
Holding register to which value is to be written
Register to which status is to be written
Scaling and conversion of IN_2 (valve 2)
Lower range limit of IN_2
Upper range limit of IN_2
Lower range limit of ROI signal
Upper range limit of ROI signal
Type of data transmitted
Modbus address of variable source
Holding register to which value is to be written
Register to which status is to be written
Location of IN_D1
Modbus address of variable source
Coil to which value is to be written
Register/coil to which status is to be written
Location of IN_D2
Modbus address of variable source
Coil to which value is to be written
Register/coil to which status is to be written
Location of IN_D3
Modbus address of variable source
Coil to which value is to be written
Register/coil to which status is to be written
Location of IN_D4
Modbus address of variable source
Coil to which value is to be written
Register/coil to which status is to be written
Scaling and conversion of OUT_1 (level)
Lower range limit of ROI signal
Upper range limit of ROI signal
Lower range limit of OUT_1
Upper range limit of OUT_1
Type of data transmitted
Modbus address of variable source
Input register containing value
Register containing status
Scaling and conversion of OUT_2 (flow)
Lower range limit of ROI signal
Upper range limit of ROI signal
Lower range limit of OUT_2
Upper range limit of OUT_2
Type of data transmitted
Modbus address of variable source
Input register containing value
Register containing status
Location of OUT_D1
Modbus address of variable source
Discrete input containing value
Register containing status
Location of OUT_D2
Modbus address of variable source
Discrete input containing value
Register containing status
10 Modbus Blocks
Example value
Auto
0
0
100
0
27468 float
5
40035
0
0
100
0
27468 float
5
40034
0
5
499
0
5
500
0
5
497
0
5
498
0
0
27468
0
2000 float
5
30035
0
0
27468
0
100 float
5
30034
0
5
10497
0
5
10498
0
Endress+Hauser 289
10 Modbus Blocks
Status
Block errors
ControlCare Application Designer: Function Blocks
Parameter
LOCATOR_OUT_D3
SLAVE_ADDRESS
MODBUS_ADDRESS_OF_VALUE
MODBUS_ADDRESS_OF_STATUS
LOCATOR_OUT_D4
SLAVE_ADDRESS
MODBUS_ADDRESS_OF_VALUE
MODBUS_ADDRESS_OF_STATUS
MBCM-2 block
MODE_BLK.Target
LOCAL_MOD_MAP
LOCATOR_IN_D1
SLAVE_ADDRESS
MODBUS_ADDRESS_OF_VALUE
MODBUS_ADDRESS_OF_STATUS
LOCATOR_IN_D2
SLAVE_ADDRESS
MODBUS_ADDRESS_OF_VALUE
MODBUS_ADDRESS_OF_STATUS
LOCATOR_IN_D3
SLAVE_ADDRESS
MODBUS_ADDRESS_OF_VALUE
MODBUS_ADDRESS_OF_STATUS
LOCATOR_IN_D4
SLAVE_ADDRESS
MODBUS_ADDRESS_OF_VALUE
MODBUS_ADDRESS_OF_STATUS
LOCATOR_OUT_D1
SLAVE_ADDRESS
MODBUS_ADDRESS_OF_VALUE
MODBUS_ADDRESS_OF_STATUS
LOCATOR_OUT_D2
SLAVE_ADDRESS
MODBUS_ADDRESS_OF_VALUE
MODBUS_ADDRESS_OF_STATUS
Function
Location of OUT_D3
Modbus address of variable source
Discrete input containing value
Register containing status
Location of OUT_D4
Modbus address of variable source
Discrete input containing value
Register containing status
Normal operating mode of block
Identifier of modbus block (0 - 15)
Location of IN_D1
Modbus address of variable source
Coil to which value is to be written
Holding register/coil to which status is to be written
Location of IN_D2
Modbus address of variable source
Coil to which value is to be written
Holding register/coil to which status is to be written
Location of IN_D3
Modbus address of variable source
Coil to which value is to be written
Holding register/coil to which status is to be written
Location of IN_D4
Modbus address of variable source
Coil to which value is to be written
Holding register/coil to which status is to be written
Location of OUT_D1
Modbus address of variable source
Discrete input containing value
Register containing status
Location of OUT_D2
Modbus address of variable source
Discrete input containing value
Register containing status
5
10501
0
5
10502
0
5
503
0
5
504
0
Auto
1
5
501
0
5
502
0
Example value
5
10499
0
5
10500
0
10.3.3 Block operation
The Modbus Control Master block normally operates in Auto mode. It can also be put out of service
(OOS) to change parameters.
After download of the strategy and after the change of any parameter, Modbus communication must be configured and initialized by toggling the APPLY_ON parameter in the MBCF block, i.e set to
"Apply".
Status
GoodNC:xxx
Bad:NoCommunication
Bad:Out of Service
Meaning
• Block operating correctly, OUT value valid
• No Modbus communication
• Block currently out of service
Block errors are indicated in the BLOCK_ERR parameter
Condition
Other
Out-of-Service
Reason
• Value out of range for data type selected
– Check correct data type
– Check correct engineering units scaling
• MODE_BLK.Target currently set to OOS
290 Endress+Hauser
ControlCare Application Designer: Function Blocks 10 Modbus Blocks
Parameter
ST_VER
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
LOCAL_MOD_MAP
COMM_STATUS
IN_1
SCALE_LOC_IN1
IN_2
SCALE_LOC_IN2
IN_3
SCALE_LOC_IN3
IN_4
SCALE_LOC_IN4
IN_D1
LOCATOR_IN_D1
IN_D2
LOCATOR_IN_D2
IN_D3
LOCATOR_IN_D3
IN_D4
LOCATOR_IN_D4
OUT_1
SCALE_ LOC_OUT1
OUT_2
SCALE_ LOC_OUT2
OUT_3
SCALE_ LOC_OUT3
OUT_4
SCALE_ LOC_OUT4
OUT_D1
LOCATOR_OUT_D1
OUT_D2
LOCATOR_OUT_D2
OUT_D3
LOCATOR_OUT_D3
OUT_D4
LOCATOR_OUT_D4
UPDATE_EVT
BLOCK_ALM
10.3.4 Block parameters
Valid range/
Options
0 to 255
1 to 255
TARGET
0 to 15
0 to 15 0
0
Default value
0 blanks
0
1
O/S
Description/Action
See Chapter 2.3.3
Block mode, set to Auto
Block errors, see Chapter 2.9.4
Unique identifier for MBCM block
Indicates if communication from slave is good or not (each bit corresponds to a Modbus variable
Value and status of analog input 1
Scaling, data format and register addresses for input signal 1
Value and status of analog input 2
Scaling, data format and register addresses for input signal 2
Value and status of analog input 3
Scaling, data format and register addresses for input signal 3
Value and status of analog input 4
Scaling, data format and register addresses for input signal 4
Value and status of discrete input 1
Register addresses for discrete input signal 1
Value and status of discrete input 2
Register addresses for discrete input signal 2
Value and status of discrete input 3
Register addresses for discrete input signal 3
Value and status of discrete input 4
Register addresses for discrete input signal 4
Value and status of analog output 1
Scaling, data format and register addresses for output signal 1
Value and status of analog output 2
Scaling, data format and register addresses for output signal 2
Value and status of analog output 3
Scaling, data format and register addresses for output signal 3
Value and status of analog output 4
Scaling, data format and register addresses for output signal 4
Value and status of discrete output 1
Register addresses for discrete output signal 1
Value and status of discrete output 2
Register addresses for discrete output signal 2
Value and status of discrete output 3
Register addresses for discrete output signal 3
Value and status of discrete output 4
Register addresses for discrete output signal 4
This alert is generated by any change to the static data
Block alarms
Endress+Hauser 291
10 Modbus Blocks
Register addresses
IN_x
IN_Dx
292
ControlCare Application Designer: Function Blocks
10.4 Modbus Control Slave
The Modbus Control Slave block is required when the Field Controller is to act as a Modbus slave.
In this role the Modbus Master reads from or writes to registers in the Field Controller. The Modbus values are mapped through a FOUNDATION Fieldbus function block that has four sets of channels
(AI, DI, AO, DO), allowing connection to other function blocks in a control strategy, see Fig. 10-6.
IN_D1
IN_D2
IN_D3
IN_D4
IN_1
IN_2
IN_3
IN_4
FF
RANGE AND
DATA TYPE
CONVERSION FC
SLAVE
RANGE AND
DATA TYPE
CONVERSION
FF
OUT_1
OUT_2
OUT_3
OUT_4
OUT_D1
OUT_D2
OUT_D3
OUT_D4
Fig. 10-6 Schematic diagram of the Modbus Control Slave block
10.4.1
Block description
Up to 16 MBCS blocks can be created in a project. The blocks are managed via the parameter
LOCAL_MOD_MAP which must have a unique value (0 to 15) for each block.
The value of LOCAL_MOD_MAP is used to define a unique set of Modbus register address ranges for the particular MBCS block, whereby:
• Register address = Constant + 8 x Value of LOCAL_MOD_MAP for analog values
• Register address = Constant + 4 x Value of LOCAL_MOD_MAP for discrete values/status.
The Modbus master accesses the Field Controller slave registers by specifying the function code and the register address. The registers are assigned to the analog/discrete input/outputs as follows:
Parameter
IN_1.Value
IN_2.Value
IN_3.Value
IN_4.Value
IN_1.Status
IN_2.Status
IN_3.Status
IN_4.Status
Type
Input register
Register Address
0 + (8 x LOCAL_MOD_MAP)
2 + (8 x LOCAL_MOD_MAP)
4 + (8 x LOCAL_MOD_MAP)
6 + (8 x LOCAL_MOD_MAP)
128 + (4 x LOCAL_MOD_MAP)
129 + (4 x LOCAL_MOD_MAP)
130 + (4 x LOCAL_MOD_MAP)
131 + (4 x LOCAL_MOD_MAP)
Access by Function Code
0x04 (Read input register)
Parameter
IN_D1.Value
IN_D2.Value
IN_D3.Value
IN_D4.Value
IN_D1.Status
IN_D2.Status
IN_D3.Status
IN_D4.Status
Type
Discrete Input
Input Register
Register Address
0 + (4 x LOCAL_MOD_MAP)
1 + (4 x LOCAL_MOD_MAP)
2 + (4 x LOCAL_MOD_MAP)
3 + (4 x LOCAL_MOD_MAP)
192 + (4 x LOCAL_MOD_MAP)
193 + (4 x LOCAL_MOD_MAP)
194 + (4 x LOCAL_MOD_MAP)
195 + (4 x LOCAL_MOD_MAP)
Access by Function Code
0x02 (Read discrete input)
0x04 (Read input register)
Endress+Hauser
ControlCare Application Designer: Function Blocks
OUT_x
OUT_Dx
Packed words
Configuration
10 Modbus Blocks
Parameter
OUT_1.Value
OUT_2.Value
OUT_3.Value
OUT_4.Value
OUT_1.Status
OUT_2.Status
OUT_3.Status
OUT_4.Status
Type
Holding register
Register Address
0 + (8 x LOCAL_MOD_MAP)
2 + (8 x LOCAL_MOD_MAP)
4 + (8 x LOCAL_MOD_MAP)
6 + (8 x LOCAL_MOD_MAP)
128 + (4 x LOCAL_MOD_MAP)
129 + (4 x LOCAL_MOD_MAP)
130 + (4 x LOCAL_MOD_MAP)
131 + (4 x LOCAL_MOD_MAP)
Access by Function Code
0x03 (Read holding registers)
0x06 (Write single register)
0x10 (Write multiple registers)
0x17 (Read/Write multiple registers)
Parameter
OUT_D1.Value
OUT_D2.Value
OUT_D3.Value
Type
Coil
OUT_D4.Value
OUT_D1.Status
Holding register
OUT_D2.Status
OUT_D3.Status
OUT_D4.Status
Register Address
0 + (4 x LOCAL_MOD_MAP)
1 + (4 x LOCAL_MOD_MAP)
2 + (4 x LOCAL_MOD_MAP)
3 + (4 x LOCAL_MOD_MAP)
192 + (4 x LOCAL_MOD_MAP)
193 + (4 x LOCAL_MOD_MAP)
194 + (4 x LOCAL_MOD_MAP)
195 + (4 x LOCAL_MOD_MAP)
Access by Function Code
0x01 (Read coils)
0x05 (Write single coil)
0x0F (Write multiple coils)
0x03 (Read holding registers)
0x06 (Write single register)
0x10 (Write multiple registers)
0x17 (Read/Write multiple registers)
The Field Controller also offers Discrete Inputs and Coils as packed words. The associated status is not available as packed words and must be acquired individually from the input or holding register.
Type
Input register
(Discrete inputs)
Holding register
(Coils)
Parameters
DI0 (Bit0) - DI15 (Bit15)
DI16 - DI31
...
Register Address
9000
9001
9002 - 9624
DI9984 - DI9999 9625
DO0 (Bit0) - DO15 (Bit15) 9000
DO16 - DO31
...
DO9984 - DO9999
9001
9002 - 9624
9625
Access by Function Code
0x04 (Read input register)
0x03 (Read holding registers)
0x06 (Write single register)
0x10 (Write multiple registers)
0x17 (Read/Write multiple registers)
The SCALE_CONV_XXX and STATUS_OUT_D parameters allow the configuration of the analog I/O and discrete output channels respectively.
• The Modbus register is assigned automatically according to the tables above.
• STATUS_OUT_Dx and STATUS_OUTPUT determine how the status of the OUT_Dx and
OUT_x parameters is generated
The status can be generated in one of two ways:
• If the option "Set by master" in the picklist is used, the output status written by the Modbus master in the associated input (IN_Dx, IN_x) or holding register (OUT_Dx, OUT_x) is used.
• If any other option is set, the output status will be set automatically to the status selected, e.g Good_NonCascade: NonSpecific: NotLimited.
In both cases, a communication failure will force the status to Bad: NoCommunication, see Status handling
Endress+Hauser 293
10 Modbus Blocks
Scaling
Status propagation
ControlCare Application Designer: Function Blocks
SCALE_CONV_XXX contains additional parameters concerning data type and scaling of analog values:
• DATA_TYPE determines the data format of the value, see Chapter 10.1.2
• FROM_EU_XX determines the scaling of the "input" parameter
• TO_EU_XX determines the scaling of the "output" parameter
The scaling is performed as shown in Fig. 10-7, whereby the value to be scaled may lie outside the given limits.
“Output” to_EU_100% to_EU_0% from_EU_0% from_EU_100% “Input”
Fig. 10-7: Scaling of raw value to OUT_x value engineering units
The meaning of the scaling parameters in SCALE_CONV_INx and SCALE_CONV_OUTx is as follows:
Parameter
.FROM_EU_0
.FROM_EU_100
.TO_EU_0
.TO_EU_100
SCALE_CONV_INx
Lower range limit IN_x value
Upper range limit IN_x value
Lower range limit Modbus master value
Upper range limit Modbus master value
SCALE_CONV_OUTx
Lower range limit Modbus master value
Upper range limit Modbus master value
Lower range limit OUT_x value
Upper range limit OUT_x value
The status of a slave output value is mapped in the corresponding OUT_XX.STATUS
parameter.
The information it carries is dependent on the entry in STATUS_OUT_Dx or STATUS_OUTPUT and whether the period entered in the TIMEOUT parameter in the MBCF block has elapsed.
STATUS_OUT_Dx or
STATUS_OUTPUT
Set by master
Status from pick list
TIMEOUT Status
Slave responding (communicated within timeout period) As master
Slave not responding (timeout elapsed) Bad
Slave responding (communicated within timeout period) As set
Slave not responding (timeout elapsed) Bad
294 Endress+Hauser
ControlCare Application Designer: Function Blocks 10 Modbus Blocks
10.4.2 Block configuration
The Modbus Control Slave block is often used when measured values are to be acquired from and/ or actuators are to be controlled in an FOUNDATION Fieldbus or PROFIBUS network by an existing
Modbus controller. In this case, the FieldController acts as a Remote I/O, presenting and receiving the measured and manipulated variables.
As an example it is assumed a new section of plant has built comprising two tanks, each fitted with two level limit switches, a level meter, a flow meter, a temperature meter, an on/off valve and a control valve, see Fig. 10-8.
LIC
101
S
Feed In
LV
100
TT
104
Process
Tank
LSH
102
CV
106
LSL
103
FT
105
Feed Out
Fig. 10-8: Example for use of Modbus Control Slave (no control-loops shown)
Communication between the Field Controller and Modbus Controller is via Ethernet and the designated Modbus slave address 16. A timeout of 2000 ms is to be used.
An example for the strategy is shown in Fig. 10-9. As two blocks have to be created to accommodate the six analog inputs, all I/O relating to Tank 1 are in block MBCS-1 and all relating to Tank 2 in
MBCS-2.
level temperature flow level high level low level temperature flow level high level low
IN_1
IN_2
IN_3
IN_D1
IN_D2
IN_1
IN_2
IN_3
IN_D1
IN_D2
LIC101
LSL103
LIC201
LSL203
CV106
TT104
FT105
LSH102
LV100
MBCS-1
Tank 1
CV206
TT204
FT205
LSH202
LV200
MBCS-2
Tank 2
OUT_1
OUT_D1
OUT_1
OUT_D1
Fig. 10-9: Control strategy for the Modbus Control Slave (no control-loops shown)
The required scaling is as follows: control valve solenoid valve control valve solenoid valve
Input signal FROM_EU_0 (IN)
Level 0%
Temperature
Flow
-150°C
0 l/h
FROM_EU_100 (IN) TO_EU_0 (ROI)
100%
+600°C
2000 l/h
0
0
0
Output signal FROM_EU_0 (ROI) FROM_EU_100 (ROI) TO_EU_0 (OUT)
Actuator 0 27648 0%
TO_EU_100 (ROI)
27648
27648
27648
TO_EU_100 (OUT)
100%
Endress+Hauser 295
10 Modbus Blocks
Fig. 10-10 shows the associated signal flow:
ControlCare Application Designer: Function Blocks
Discrete inputs
(10001,10002)
Coils
(1)
MBCS_1 block
I/O signals
LOCAL_MOD_MAP = 0
Input registers
(30001, 30003,
30005)
Holding registers
(40001)
Reference address for Modbus master
MBCS_2 block
I/O signals
LOCAL_MOD_MAP = 1
Discrete inputs
(10005, 10006)
Coils
(5)
Input registers
(30009, 300011,
300013)
Holding registers
(40009)
Reference address for Modbus master
MBCF block configuration
Parameter
MODE BLOCK.TARGET
MEDIA
MASTER_SLAVE
TIMEOUT
TCP/IP_CONFIG
SECOND_MOD_PORT
SLAVE_CONFIG
DEVICE_ADDRESS
TCP_ACCESS_LIST
IP_x
Fig. 10-10: Signal fllow (values) through MBCS block to Modbus master
Function
Normal operating mode of block
Channel for Modbus communication
Role of Field Controller in Modbus network
Time allowed for OUT value update
If there is no update, the output status is set to BAD
Configures TCP/IP interface
Second communication port (Port 502 is always open)
Configures Controller when acting as slave
Modbus address of Field Controller
List of up to eight masters that are allowed to access field controller registers
IP address of TCP master x
MBCF
Auto
TCP/IP (+TCP/IP)
Slave e.g. 1000 (ms) e.g. 1024 e.g. 1 e.g. 10.125.35.90
MBCS block configuration
296
Parameter
MBCS-1 block
MODE_BLK.Target
LOCAL_MOD_MAP
SCALE_CONV_IN1
FROM_EU_0
FROM_EU_100
TO_EU_0
TO_EU_100
DATA_TYPE
SCALE_CONV_IN2
FROM_EU_0
FROM_EU_100
TO_EU_0
TO_EU_100
DATA_TYPE
SCALE_CONV_IN3
FROM_EU_0
FROM_EU_100
TO_EU_0
TO_EU_100
DATA_TYPE
Function
Normal operating mode of block
Identifier of modbus block (0 - 15)
Scaling and conversion of IN_1 (level)
Lower range limit of IN_1
Upper range limit of IN_1
Lower range limit of ROI signal
Upper range limit of ROI signal
Type of data transmitted
Scaling and conversion of IN_2 (temperature)
Lower range limit of IN_2
Upper range limit of IN_2
Lower range limit of ROI signal
Upper range limit of ROI signal
Type of data transmitted
Scaling and conversion of IN_3 (flow)
Lower range limit of IN_3
Upper range limit of IN_3
Lower range limit of ROI signal
Upper range limit of ROI signal
Type of data transmitted
Example value
Auto
0
0
100
0
27468 float
-150
600
0
27468 float
0
2000
0
27468 float
Endress+Hauser
ControlCare Application Designer: Function Blocks
Status
Endress+Hauser
10 Modbus Blocks
Parameter
SCALE_CONV_OUT1
FROM_EU_0
FROM_EU_100
TO_EU_0
TO_EU_100
DATA_TYPE
STATUS_OUTPUT
STATUS_OUT_D1
MBCS-2 block
MODE_BLK.Target
LOCAL_MOD_MAP
SCALE_CONV_IN1
FROM_EU_0
FROM_EU_100
TO_EU_0
TO_EU_100
DATA_TYPE
SCALE_CONV_IN2
FROM_EU_0
FROM_EU_100
TO_EU_0
TO_EU_100
DATA_TYPE
SCALE_CONV_IN3
FROM_EU_0
FROM_EU_100
TO_EU_0
TO_EU_100
DATA_TYPE
SCALE_CONV_OUT1
FROM_EU_0
FROM_EU_100
TO_EU_0
TO_EU_100
DATA_TYPE
STATUS_OUTPUT
STATUS_OUT_D1
Function
Scaling and conversion of OUT_1 (valve)
Lower range limit of ROI signal
Upper range limit of ROI signal
Lower range limit of OUT_1
Upper range limit of OUT_1
Type of data transmitted
Status to be used by good output
Status to be used by good output
Example value
0
27468
0
100 float
GoodNC:NSpecNLim
GoodNC:NSpecNLim
Normal operating mode of block
Identifier of modbus block (0 - 15)
Scaling and conversion of IN_1 (level)
Lower range limit of IN_1
Upper range limit of IN_1
Lower range limit of ROI signal
Upper range limit of ROI signal
Type of data transmitted
Scaling and conversion of IN_2 (temperature)
Lower range limit of IN_2
Upper range limit of IN_2
Lower range limit of ROI signal
Upper range limit of ROI signal
Type of data transmitted
Scaling and conversion of IN_3 (flow)
Lower range limit of IN_3
Upper range limit of IN_3
Lower range limit of ROI signal
Upper range limit of ROI signal
Type of data transmitted
Scaling and conversion of OUT_1 (valve)
Lower range limit of ROI signal
Upper range limit of ROI signal
Lower range limit of OUT_1
Upper range limit of OUT_1
Type of data transmitted
Status to be used by good output
Status to be used by good output
After configuration the data are made available by or to the Modbus master at the following reference addresses:
Auto
1
0
100
0
27468 float
-150
600
0
27468 float
0
2000
0
27468 float
0
27468
0
100 float
GoodNC:NSpecNLim
GoodNC:NSpecNLim
Tag
LV100
LIC101
LSH102
LSL103
TT104
FT105
CV106
Master Action Value
Write 1
Read
Read
30001, 30002
10001
Status
40192
30128
30192
Tag
LV200
LIC201
LSH202
Read
Read
Read
Write
10002
30003, 30004
30005, 30006
40001
30193
30129
30130
40128
LSL203
TT204
FT205
CV206
Master Action Value
Write 5
Read
Read
30009, 30010
10005
Status
40196
30132
30196
Read
Read
Read
Write
10006
30011, 30012
30013, 30014
40009
30197
30133
30134
40132
10.4.3 Block operation
The Modbus Control Slave block normally operates in Auto mode. It can also be put out of service
(OOS) to change parameters.
After download of the strategy and after the change of any parameter, Modbus communication must be initialized by toggling the APPLY_ON parameter in the MBCF block, i.e set to "1".
Status
GoodNC:xxx
Bad:NoCommunication
Bad:Out of Service
Meaning
• Block operating correctly, OUT value valid
• No Modbus communication
• Block currently out of service
297
10 Modbus Blocks
Block errors
ControlCare Application Designer: Function Blocks
Block errors are indicated in the BLOCK_ERR parameter
Condition
Other
Out-of-Service
Reason
• Value out of range for data type selected
– Check correct data type
– Check correct engineering units scaling
• MODE_BLK.Target currently set to OOS
Parameter
ST_VER
TAG_DESC
STRATEGY
ALERT_KEY
MODE_BLK
BLOCK_ERR
LOCAL_MOD_MAP
IN_1
SCALE_CONV_IN1
IN_2
SCALE_CONV_IN2
IN_3
SCALE_CONV_IN3
IN_4
SCALE_CONV_IN4
IN_D1
IN_D2
IN_D3
IN_D4
OUT_1
SCALE_CONV_OUT1
OUT_2
SCALE_CONV_OUT2
OUT_3
SCALE_CONV_OUT3
OUT_4
SCALE_CONV_OUT4
OUT_D1
STATUS_OUT_D1
OUT_D2
STATUS_OUT_D2
OUT_D3
STATUS_OUT_D3
OUT_D4
STATUS_OUT_D4
UPDATE_EVT
BLOCK_ALM
10.4.4 Block parameters
Valid range/
Options
0 to 255
1 to 255
TARGET
0 to 15
0 to 15
Default value
0 blanks
0
1
O/S
Description/Action
See Chapter 2.3.3.
0
Block mode, set to Auto
Block errors, see Chapter 2.9.4
Unique identifier for MBCS block
Value and status of analog input 1
Scaling and data format for analog input signal 1
Value and status of analog input 2
Scaling and data format for analog input signal 2
Value and status of analog input 3
Scaling and data format for analog input signal 3
Value and status of analog input 4
Scaling and data format for analog input signal 4
Value and status of discrete input 1
Value and status of discrete input 2
Value and status of discrete input 3
Value and status of discrete input 4
Value and status of analog output 1
Scaling, data format and status for analog output signal 1
Value and status of analog output 2
Scaling, data format and status for analog output signal 2
Value and status of analog output 3
Scaling, data format and status for analog output signal 3
Value and status of analog output 4
Scaling, data format and status for analog output signal 4
Value and status of discrete output 1
Status for discrete output signal 1
Value and status of discrete output 2
Status for discrete output signal 2
Value and status of discrete output 3
Status for discrete output signal 3
Value and status of discrete output 4
Status for discrete output signal 4
This alert is generated by any change to the static data
Block alarms
298 Endress+Hauser
ControlCare Application Designer: Function Blocks
Appendix A: Interpreting parameter status
The Status has the following composition:
MSB LSB
10 Modbus Blocks
Substatus values
Quality Substatus Limits
Bad
Bad
Bad
Bad
Bad
Bad
Bad
Bad
Fig. 10-11: Composition of status byte
The quality, sub-status, and limit components of status are defined as follows:
Quality - The quality used is determined by the highest priority condition:
• 0 = Bad
• 1 = Uncertain
• 2 = Good (Non-cascade)
• 3 = Good (Cascade)
Substatus - Sub-status values in the status attribute are defined as shown in the table below.
Limit - The following limit conditions will be always available in the status attribute.
• 0 = Not limited
• 1 = Low limited
• 2 = High limited
• 3 = Constant
Examples:
• 0xC1 (in hexadecimal) is "Good-Cascade Non Specific and Low Limited " status
• 0xCF(in hexadecimal) is "Good-Cascade Not invited and Constant " status
• 0x4E(in hexadecimal) is "Uncertain Initial Value and High Limited" status
Substatus values as a function of quality
Quality Substatus
0 = Non-specific
1 = Configuration Error
2 = Not Connected
3 = Device Failure
4 = Sensor Failure
5 = No Communication
6 = No Communication
7 = Out of Service (highest priority)
Hex value
0x00
0x04
0x08
0x0c
0x10 last usable value no usable value
0x1c
Not in
X
X
Cascade path
Forward Backward
X
X
X
X
X
X
0x14
0x18
X
X
X
X
Quality Substatus
Uncertain 0 = Non-specific
Uncertain 1 = Last Usable Value
Uncertain 2 = Substitute
Uncertain 3 = Initial Value
Uncertain 4 = Sensor Conversion not Accurate
Uncertain 5 = Engineering Unit Range Violation
Uncertain 6 = Sub-normal
Hex value
0x40
0x44
0x48
0x4c
0x50
0x54
0x58
Not in
X
X
X
X
X
X
X
Cascade path
Forward Backward
Endress+Hauser 299
10 Modbus Blocks ControlCare Application Designer: Function Blocks
Quality Substatus
Uncertain 0 = Non-specific
Uncertain 1 = Last Usable Value
Uncertain 2 = Substitute
Uncertain 3 = Initial Value
Uncertain 4 = Sensor Conversion not Accurate
Uncertain 5 = Engineering Unit Range Violation
Uncertain 6 = Sub-normal
Quality Sub-status
Quality
GoodC
GoodC
GoodC
GoodC
GoodC
GoodC
GoodC
GoodC
GoodNC
GoodNC
GoodNC
GoodNC
GoodNC
GoodNC
GoodNC
0 = Non-specific (lowest priority)
1 = Active Block Alarm
2 = Active Advisory Alarm
3 = Active Critical Alarm
4 = Unacknowledged Block Alarm
5 = Unacknowledged Advisory Alarm
6 = Unacknowledged Critical Alarm
Sub-status
0 = Non-specific 0xc0
1 = Initialization Acknowledge(IA) 0xc4
2 = Initialization Request(IR)
3 = Not Invited (NI)
0xc8
0xcc
4 = Not Selected(NS)
6 = Local Override(LO)
7 = Fault State Active(FSA)
8 = Initiate Fault State (IFS)
0xd0
0xd8
0xdc
0xe0
0x80
0x84
0x88
0x8c
0x90
0x94
0x98
Hex value
Hex value
0x40
0x44
0x48
0x4c
0x50
0x54
0x58
Hex value
Not in
X
X
X
X
X
X
X
Cascade path
Forward Backward
Not in
X
X
X
X
X
X
X
Cascade path
Forward Backward
Not in
Cascade path
Forward Backward
X
X
X
X
X
X
X
X
X
Conversion from index to number
Conversion from number to index
The following formula is used to obtain the enumeration number of a determinate status attribute:
• Decimal Value Status = 64*Quality + 4* Sub-Status + Limit
For example, considering the following status:
• "Uncertain - Initial Value - High Limited"
Quality = "uncertain" = 1, Sub-Status = "Initial Value" = 3, Limit = "High Limited " = 2.
Applying the formula:
• Decimal Value Status = 64 * 1 + 4 * 3 + 2 = 78 (in decimal) or 0x4E (in Hexadecimal) a) Expressing the number in binary.
• Hex Value Status = 78 = 0x4E = 01001110 (in binary)
Dividing this binary number in quality, sub-status and limit fields:
• Quality = 01 = 1 = "Uncertain", Sub-Status = 0011 = 3 = "Initial Value",
Limit = 10 = 2 = "High Limited"
The corresponding status is "Uncertain - Initial Value - High Limited".
b) Expressing the value of status in decimal format.
• Decimal Value Status = 78
Divide the number by 64. The quotient will be the duality and save the remainder:
Quality = 78 / 64 = 1
• Remainder = 14. Divide the remainder by 4. The quotient will be the substatus and the remainder will be the limit:
SubStatus = 14 / 4 = 3
Limit = 2
300 Endress+Hauser
ControlCare Application Designer: Function Blocks 10 Modbus Blocks
Appendix B: Standard data types and structures
This chapter contains definitions of every standard data type and structure used in the system.
Data Type
Boolean
Integer8
Integer16
Integer32
Unsigned8
Unsigned16
Unsigned32
FloatingPoint
VisibleString
OctetString
Date
TimeofDay
TimeDifference
BitString
DataTimeValue
Description
True or false they are one byte per character, and include the 7 bit ASCII character set.
Octet strings are binary.
Block
DS-64
Analog Value & Status
DS-65
Discrete Value & Status
DS-66
This data structure comprises the attributes of a block.
6
7
4
5
2
3
E
1
Element Name
Block Tag
DD MemberId
DD ItemId
DD Revision
Profile
Profile Revision
Execution Time
8
9
Period of Execution
Number of Parameters
10 Next FB to Execute
11 Starting Index of Views
12 NumberofVIEW_3
13 NumberofVIEW_4
Data Type Size
VisibleString 32
Unsigned32 4
Unsigned32 4
Unsigned16 2
Unsigned16 2
Unsigned16 2
Unsigned32 4
Unsigned32 4
Unsigned16 2
Unsigned16 2
Unsigned16 2
Unsigned8
Unsigned8
1
1
This data structure comprises the value and status of inputs and outputs that are floating point parameters.
E
1
2
Element Name
Status
Value
Data Type
Unsigned8
Float
Size
1
4
This data structure consists of the value and status of discrete value parameters.
E
1
2
Element Name
Status
Value
Data Type
Unsigned8
Unsigned8
Size
1
1
Endress+Hauser 301
ControlCare Application Designer: Function Blocks
Scaling
DS-68
10 Modbus Blocks
This data structure consists of the static data used to scale floating point values for display purposes.
Mode
DS-69
Access Permissions
DS-70
Alarm Float
DS-71
Alarm Discrete
DS-72
Event Update
DS-73
Alarm Summary
DS-74
2
3
E
1
4
Element Name
EU at 100%
EU at 100%
Units Index
Decimal Point
Data Type
Float
Float 4
Unsigned16 2
Integer8
Size
4
1
This data structure consists of bit strings for target, actual, permitted, and normal modes.
2
3
E
1
4
Element Name
Target
Actual
Permitted
Normal
Data Type
Bitstring
Bitstring
Bitstring
Bitstring
1
1
Size
1
1
This data structure consists of access control flags for access to block parameters.
E
1
2
Element Name
Grant
Deny
Data Type
Bitstring
Bitstring
Size
1
1
This data structure consists of data that describes floating point alarms.
2
3
E
1
4
5
Element Name
Unacknowledged
Alarm State
Time Stamp
Subcode
Value
Data Type
Unsigned8
Unsigned8
Time Value
Unsigned16 2
Float 4
1
8
Size
1
This data structure consists of data that describes discrete alarms.
2
3
E
1
4
5
Element Name
Unacknowledged
Alarm State
Time Stamp
Subcode
Value
Data Type
Unsigned8
Unsigned8
Time Value
Unsigned16 2
Unsigned8 1
1
8
Size
1
This data structure consists of data that describes a static revision alarm.
2
3
E
1
4
5
Element Name
Unacknowledged
Update State
Time Stamp
Static Revision
Relative Index
Data Type
Unsigned8
Unsigned8
Time Value
Unsigned16 2
Unsigned16 2
1
8
Size
1
This data structure consists of data that summarize 16 alerts.
2
3
E
1
4
Element Name
Current
Unacknowledged
Unreported
Disabled
Data Type
Bit String
Bit String
Bit String
Bit String
2
2
Size
2
2
Endress+Hauser 302
10 Modbus Blocks ControlCare Application Designer: Function Blocks
Simulate Floating Point
DS-82
Simulate Discrete
DS-83
Test Read/Write
DS-85
Value And Status
Unsigned16
DS-145
Discrete Structure
DS-159
This data structure consists of a simulate and transducer floating point value and status and a simulate enable/disable discrete.
2
3
E
1
4
5
Element Name
Simulate Status
Simulate Value
Transducer Status
Transducer Value
Simulate En/Disable
Data Type
Unsigned8
Float
Unsigned8
Float
Unsigned8
4
1
4
1
Size
1
This data structure consists of a simulate and transducer discrete value and status and a simulate enable/disable discrete.
2
3
E
1
4
5
Element Name
Simulate Status
Simulate Value
Transducer Status
Transducer Value
Simulate En/Disable
Data Type
Unsigned8
Unsigned8
Unsigned8
Unsigned8
Unsigned8
4
1
4
1
Size
1
This data structure consists of function block test read/write data.
6
7
4
5
2
3
E
1
ElementName
Value1
Value2
Value3
Value4
Value5
Value6
Value7
8
9
Value8
Value9
10 Value10
11 Value11
12 Value12
13 Value13
14 Value14
15 Value15
DataType
Boolean
Integer8
Integer16
Integer32
Unsigned8
Unsigned16 2
Unsigned32 4
4
1
1
2
Size
1
FloatingPoint 4
VisibleString 32
OctetString
Date
32
7
Time of Day 6
Time
Difference
6
Bitstring
Time Value
2
8
This data structure is used to transmit value and status of PROFIBUS device values.
E
1
2
Element Name
Status
Value
Data Type Size
Unsigned16 1
Unsigned16 2
This data structure consists of one status and eight discrete value parameters.
6
7
4
5
8
9
2
3
E
1
Element Name
Status
Value1
Value2
Value3
Value4
Value5
Value6
Value7
Value8
Data Type
Unsigned8
Unsigned8
Unsigned8
Unsigned8
Unsigned8
Unsigned8
Unsigned8
Unsigned8
Unsigned8
1
1
1
1
1
1
1
1
Size
1
303 Endress+Hauser
ControlCare Application Designer: Function Blocks
Discrete Structure
DS-160
This data structure consists of one status and sixteen discrete value parameters.
6
7
4
5
2
3
E
1
8
9
Value7
Value8
10 Value9
11 Value10
12 Value11
13 Value12
14 Value13
15 Value14
16 Value15
17 Value16
Element Name
Status
Value1
Value2
Value3
Value4
Value5
Value6
Data Type
Unsigned8
Unsigned8
Unsigned8
Unsigned8
Unsigned8
Unsigned8
Unsigned8
Unsigned8
Unsigned8
Unsigned8
Unsigned8
Unsigned8
Unsigned8
Unsigned8
Unsigned8
Unsigned8
Unsigned8
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
Size
1
10 Modbus Blocks
Endress+Hauser 304
10 Modbus Blocks ControlCare Application Designer: Function Blocks
Appendix C: Manufacturer-specific data structures
Scaling Conversion
DS-256
Scaling Conversion with
Status
DS-257
This appendix contains the manufacturer-specific data structures used in the system.
This data structure consists of data used to generate constants A and B in equation Y= A*X + B.
2
3
E
1
4
5
Element Name
From EU 100%
From EU 0%
To EU 100%
To EU 0%
Data Type
Data Type
Float
Float
Float
Float
Unsigned8
4
1
4
4
Size
4
This data structure consists of data used to generate constants A and B in equation Y= A*X + B plus the output status.
4
5
6
2
3
E
1
Element Name
From EU 100%
From EU 0%
To EU 100%
To EU 0%
Data Type
Output Status
Data Type
Float
Float
Float
Float
Unsigned8
Unsigned8
4
1
1
4
4
Size
4
Scaling Locator
DS-258
This data structure consists of data used to generate constants A and B in equation Y= A*X + B plus the addresses in a slave device.
6
7
4
5
2
3
E
1
Element Name
From EU 100%
From EU 0%
To EU 100%
To EU 0%
Data Type
Slave Address
Modbus Address of Value
Data Type
Float
Float
Float
Float
Unsigned8
Unsigned8 1
Unsigned16 2
4
1
4
4
Size
4
Scaling Locator with Status
DS-259
This data structure consists of data used to generate constants A and B in equation
Y= A*X + B plus the addresses in a slave device.
6
7
4
5
8
2
3
E
1
Element Name
From EU 100%
From EU 0%
To EU 100%
To EU 0%
Data Type
Slave Address
Modbus Address of Value
Modbus Address of Status
Data Type
Float
Float
Float
Float
Unsigned8
Unsigned8 1
Unsigned16 2
4
1
Unsigned16 2
4
4
Size
4
Modbus Variable Locator
DS-260
This data structure consists of data indicating the addresses in a slave device.
E
1
2
Element Name
Slave Address
Modbus Address of Value
Data Type
Unsigned8
Unsigned16 2
Size
1
305 Endress+Hauser
ControlCare Application Designer: Function Blocks 10 Modbus Blocks
Modbus Variable Locator with Status
DS-261
This data structure consists of data indicating the addresses in a slave device.
FF Parameter ID
DS-262
Slave Address
DS-263
2
3
E
1
Element Name
Slave Address
Modbus Address of Value
Modbus Address of Status
Data Type
Unsigned8
Unsigned16 2
Unsigned16 2
Size
1
This data structure consists of data informing the position of the FF parameter requested.
2
3
E
1
Element Name
Block Tag
Relative Index
Sub Index
Data Type Size
VisibleString(32) 32
Unsigned16
Unsigned8
2
1
This data structure consists of data informing the IP address and the Modbus address of the slaves.
6
7
4
5
2
3
E
1
Element Name
IP Slave1
IP Slave2
IP Slave3
IP Slave4
IP Slave5
IP Slave6
IP Slave7
8
9
IP Slave8
Slave Address1
10 Slave Address2
11 Slave Address3
12 Slave Address4
13 Slave Address5
14 Slave Address6
15 Slave Address7
16 Slave Address8
Data Type Size
VisibleString(16) 16
VisibleString(16) 16
VisibleString(16) 16
VisibleString(16) 16
VisibleString(16) 16
VisibleString(16) 16
VisibleString(16) 16
VisibleString(16) 16
Unsigned8 1
Unsigned8
Unsigned8
1
1
Unsigned8
Unsigned8
Unsigned8
Unsigned8
Unsigned8
1
1
1
1
1
Endress+Hauser 306
10 Modbus Blocks ControlCare Application Designer: Function Blocks
307 Endress+Hauser
ControlCare Application Designer: Function Blocks 10 Modbus Blocks
Endress+Hauser 308
Table of Contents ControlCare Application Designer: Function Blocks
Index
A
ACK_OPTION . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52
Adaptive gain . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 105
Advanced Equations block . . . . . . . . . . . . . . . . . . . . . . . 209
Advanced PID Control . . . . . . . . . . . . . . . . . . . . . . . . . . 103
Alarm . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
Alarm display . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43
Alert handling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39
Alert objects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
Analog Alarm block . . . . . . . . . . . . . . . . . . . . . . . . . . . . 148
Analog Input block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66
Analog output block . . . . . . . . . . . . . . . . . . . . . . . . . . . 226
Anti-reset wind-up . . . . . . . . . . . . . . . . . . . . . . . . . . . . 105
Application Designer . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
Arithmetic block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 116
Automatic (Auto) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
B
Back calculation . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 , 86
Backward path . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32
Block modes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
Block objects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
Block parameters
AALM block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 154
Advanced PID block . . . . . . . . . . . . . . . . . . . . . . . . . 107
AEQU block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 210
AI block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 71
AO block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 231
ARTH block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 123
CCHAR block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 139
CHAR block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 133
CT block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 193
CTRW block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 199
DENS block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 215
Device transducer block . . . . . . . . . . . . . . . . . . . . . . . 62
DI block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 74
DO block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 236
DP_MAO . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 271
DP_MAO block . . . . . . . . . . . . . . . . . . . . . . . . . . . . 255
DP_MDI block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 259
DP_MDO block . . . . . . . . . . . . . . . . . . . . . . . . . . . . 278
Enhanced PID control . . . . . . . . . . . . . . . . . . . . . . . 102
ESPG block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 168
FFET block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 208
HC block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58
HY_EMB_IO block . . . . . . . . . . . . . . . . . . . . . . . . . 225
HY_MA_IO block . . . . . . . . . . . . . . . . . . . . . . . . . . 218
HY_MD_IO block . . . . . . . . . . . . . . . . . . . . . . . . . . 221
INTG block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 146
ISEL block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 160
LL block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 183
MAI block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 80
MAO block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 240
MBCM block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 292
MBCS block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 299
MDI block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 82
309
MDO block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 243
OS block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 129
OSDL block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 191
PA_AI block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 252
PA_AO block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 267
PA_DI block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 257
PA_DO block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 275
PA_TO block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 261
PI block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 78
PID block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 98
PROFIBUS Transducer block . . . . . . . . . . . . . . . . . . 248
Resource block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54
SPG block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 166
STEP block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 114
TEMP block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60
TMR block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 177
BLOCK_ERR . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42
Bock parameters
EAAL block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 155
C
Calculated variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . 119
CAS_IN . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
Cascade (Cas) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
Cascade control . . . . . . . . . . . . . . . . . . . . 32 , 90 , 112 , 264
Cascade initialization . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33
Cascade Signal Characterizer block . . . . . . . . . . . . . . . . 134
Characterization dialog . . . . . . . . . . . . . . . . . . . . . . . . . . 17
Closed-loop control . . . . . . . . . . . . . . . . . . . . . . . . . 87 , 111
Commissioning . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
Constant and Contained RW block . . . . . . . . . . . . . . . . . 194
Constant block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 192
Contained parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
Control Blocks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 83
Control loop integrit . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
Control strategy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
CONTROL_OPTS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
ControlCare documents . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
D
Density block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 211
Discrete Input block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 72
Discrete output block . . . . . . . . . . . . . . . . . . . . . . . . . . . 232
Dynamic parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
E
EMV . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
Enhanced PID Control . . . . . . . . . . . . . . . . . . . . . . . . . . 100
Enhanced Setpoint Ramp Generator block . . . . . . . . . . . 168
Error . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 106
Event . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
Events and alarms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39
F
Fault state handling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34
Fault state mechanism, PROFIBUS . . . . . . . . . . . . . . . . . 246
Feedforward control . . . . . . . . . . . . . . . . . . . . . . . . . . . . 88
Endress+Hauser
ControlCare Application Designer: Function Blocks Table of Contents
Field Controller . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
Flip-flop and Edge Trigger block . . . . . . . . . . . . . . . . . . . 201
Forward path . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
Function block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
Function block application process . . . . . . . . . . . . . . . . . . 11
Function block options . . . . . . . . . . . . . . . . . . . . . . . . . . . 36
G
Gain . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 85 , 106
H
Hardware Configuration . . . . . . . . . . . . . . . . . . . . . . . . . . 57
Hybrid block with Analog I/O . . . . . . . . . . . . . . . . . . . . 216
Hybrid block with Discrete I/O . . . . . . . . . . . . . . . . . . . 219
Hybrid block with Mixed I/O . . . . . . . . . . . . . . . . . . . . . 222
I
Initialization manual (Iman) . . . . . . . . . . . . . . . . . . . . . . . 18
Input parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
Input Selector block . . . . . . . . . . . . . . . . . . . . . . . . . . . . 156
Installation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
Integrator block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 140
L
Lead-Lag block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 179
Limit alarms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41
Linearization . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
Link objects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
Local override (LO) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
M
Manual (Man) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
MBCF Modbus Configuration Block . . . . . . . . . . . . . . . . 283
MBCM Modbus Control Master Block . . . . . . . . . . . . . . 286
MBCS Modbus Control Slave block . . . . . . . . . . . . . . . . 293
Modbus Blocks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 279
Mode priority . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
Mode shedding . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
Multiple Analog Input block . . . . . . . . . . . . . . . . . . . . . . . 79
Multiple Analog Output block . . . . . . . . . . . . . . . . . . . . 237
Multiple Discrete Input block . . . . . . . . . . . . . . . . . . . . . . 81
Multiple Discrete Output block . . . . . . . . . . . . . . . . . . . . 241
N
Non-volatile parameters . . . . . . . . . . . . . . . . . . . . . . . . . . 13
O
Off Line Characterization . . . . . . . . . . . . . . . . . . . . . 17 , 46
On Line Characterization . . . . . . . . . . . . . . . . . . . . . 17 , 47
Operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
Ouput limits . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
Out of service (OOS) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
Output parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
Output Signal Selector and Dynamic Limiter block . . . . . 184
Output Splitter block . . . . . . . . . . . . . . . . . . . . . . . . . . . 124
Output tracking . . . . . . . . . . . . . . . . . . . . . . . . . . . . 86 , 92
P
Parameter
ACK_OPTION . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40
ALARM_HYS . . . . . . . . . . . . . . . . . . . . . . . . . . . 67 , 75
ALARM_SUM . . . . . . . . . . . . . . . . . . . . 42 , 69 , 73 , 76
ALERT_ KEY . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
ARITH_TYPE . . . . . . . . . . . . . . . . . . . . . . . . . 117 , 119
BIAS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 117
BKCAL_IN, BKCAL_OUT . . . . . . . . . . . . . . . . . . 27 , 86
BLOCK_ERR, BLOCK_ALM . . . . . . . . . . . . . . . . . . . . 42
CHANNEL . . . . . . . . 59 , 61 , 65 , 66 , 72 , 75 , 79 , 81
CONTROL_OPTS . . . . . . . . . . . . . . . . . . . . . . . . 27 , 38
DISC_ALM . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 72
DISC_PRI . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 72
FEATURES . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40
FEATURES, FEATURE_SEL . . . . . . . . . . . . . . . . . 51 , 53
FF_VAL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 84
FIELD_VAL . . . . . . . . . . . . . . . . . . . . . . . . . . 67 , 69 , 76
FSAFE_TYPE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67
FSAFE_VAL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67
FSTATE_TIME, FSTATE_VAL, FSTATE_VAL_D . . . . . 34
GAIN . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 117 , 119
GRANT_DENY . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36
INPUT_OPTS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 117
IO_OPTS . . . . . . . . . . . . . . . . . . . . . . . 27 , 34 , 37 , 67
IO_TYPE_Rxx . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57
L_TYPE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 , 66
MODE_BLK . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
OSDL_OPTS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34
OUT . . . . . . . . . . . . . . . . . . . . 27 , 45 , 69 , 76 , 80 , 82
OUT_D . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 73
OUT_RANGE . . . . . . . . . . . . . . . . . . . . . . . . . . 24 , 117
OUT_SCALE . . . . . . . . . . . . . . . . . . . . . . . . . 24 , 67 , 75
PRE_OUT . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 119
PV . . . . . . . . . . . . . . . . . . . . . . . . . 23 , 69 , 76 , 84 , 97
PV_D . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 73
PV_FTIME . . . . . . . . . . . . . . . . . . . . . . 23 , 67 , 72 , 75
RCAS_IN, RCAS_OUT . . . . . . . . . . . . . . . . . . . . . . . . 93
READBACK . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45
RESTART . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51
ROUT_IN, ROUT_OUT . . . . . . . . . . . . . . . . . . . . . . . 95
RS_STATE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50
SHED_OPT . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
SIMULATE . . . . . . . . . . . . . . . . . . . . . . . . . . 45 , 69 , 76
SIMULATE_D . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 73
SLOT_x . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57
SP . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 , 85
ST_REV . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
STATUS_OPTS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34
STRATEGY . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
TAG_DESC . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
TRK_VAL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 92
UPDATE_EVT . . . . . . . . . . . . . . . . . . . . . . . . . . 15 , 42
WRITE_LOCK . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53
XD_ERROR . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42
XD_SCALE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24 , 67
XD_STATE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 73
XXX_ALM . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67 , 75
XXX_PRI . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67 , 75 xxx_PRI . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52
Parameter identifiers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
Parameter status
Endress+Hauser 310
Table of Contents ControlCare Application Designer: Function Blocks
Substatus values . . . . . . . . . . . . . . . . . . . . . . . . . . . . 300
Parameter types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
PID algorithm . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 85 , 104
PID Control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 83
PID control algorithm . . . . . . . . . . . . . . . . . . . . . . . . . . . 85
Process value . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 84
PROFIBUS
Analog Input block . . . . . . . . . . . . . . . . . . . . . . . . 66 , 72
PROFIBUS Analog Input block . . . . . . . . . . . . . . . . . . . . 252
PROFIBUS Analog Output block . . . . . . . . . . . . . . . . . . 262
PROFIBUS Blocks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 244
PROFIBUS Digital Input block . . . . . . . . . . . . . . . . . . . . 257
PROFIBUS Discrete Output block . . . . . . . . . . . . . . . . . 273
PROFIBUS Multiple Analog Input block . . . . . . . . . . . . . 253
PROFIBUS Multiple Analog Output block . . . . . . . . . . . 269
PROFIBUS Multiple Discrete Input block . . . . . . . . . . . . 258
PROFIBUS Multiple Discrete Output block . . . . . . . . . . 276
PROFIBUS output block . . . . . . . . . . . . . . . . . . . . . . . . . 19
PROFIBUS process image . . . . . . . . . . . . . . . . . . . . . . . 245
PROFIBUS slave configuration . . . . . . . . . . . . . . . . . . . . 247
PROFIBUS Totalizer block . . . . . . . . . . . . . . . . . . . . . . . 260
PROFIBUS Transducer block . . . . . . . . . . . . . . . . . . . . . 248
Project File . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 46 , 47
Pulse Input block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75
PV_SCALE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24
R
Ramp generator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 161
Range extension . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 117
Rate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 85
Remote cascade . . . . . . . . . . . . . . . . . . . . . . . . . . . . 93 , 265
Remote cascade (RCas) . . . . . . . . . . . . . . . . . . . . . . . . . . 19
Remote output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 95
Remote output (ROut) . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
Reporting, priority and acknowledgement . . . . . . . . . . . . 40
Reset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 85
Resource block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
S
Safety conventions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
Scaling parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24
Setpoint limits . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
Setpoint Ramp Generator block . . . . . . . . . . . . . . . . . . . 161
Setpoint rate limits . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
Setpoint tracking . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
Setpoint value . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 85
SFC445 temperature ranges . . . . . . . . . . . . . . . . . . . . . . . 70
Signal Characterizer block . . . . . . . . . . . . . . . . . . . . . . . 130
Simulation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45
ST_REV . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39
Static parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
Status propagation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28
Step Output PID . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 108
Substatus and limit propagation . . . . . . . . . . . . . . . . . . . . 30
Substatus values . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29
T
Temperature block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 59
Time constant . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
Timer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 162 , 170
Timer and Logic block . . . . . . . . . . . . . . . . . . . . . . . . . . 169
Transducer block . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 , 56
Trouble-shooting . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
U
Universal parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
UPDATE_EVT . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39
V
View and trend objects . . . . . . . . . . . . . . . . . . . . . . . . . . 12
W
Write lock . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53
WRITE_LOCK . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
39
311 Endress+Hauser
ControlCare Application Designer: Function Blocks Table of Contents
Endress+Hauser 312
www.endress.com/worldwide
Scarica
Pubblicità