Professional Documents
Culture Documents
Høgskolen I Telemark: Bachelor I Ingeniørfag
Høgskolen I Telemark: Bachelor I Ingeniørfag
Two-Tank Control
2-tank Process
DeltaV Workstation
-PID Controller
-Alarm System
-User Control
Ethernet
DeltaV
Controller with
I/O Moduls
24VDC Power
Supply
AO
Control Signal
4-20mA
(PUMP)
|
DO
Valve Signal
0/24VDC
Out
420mA
Out
0/
24VDC
DI Level Indicators
0/24VDC
AI Level Measurement
(Level)
4-20mA
Hgskolen i Telemark
Table of contenst
TABLE OF CONTENST
Table of contenst .................................................................................................................. 3
1 Introduction ..................................................................................................................... 4
2 Program ........................................................................................................................... 7
2.1
2.2
2.3
2.4
2.5
2.6
3 HMI ................................................................................................................................ 19
3.1
3.2
3.3
3.4
3.5
3.6
3.7
4 Operate ........................................................................................................................... 29
Hgskolen i Telemark
1 Introduction
1 INTRODUCTION
In this task you will learn how to create a program and a HMI to control the two-tank system
with DeltaV. Figure 1-1 shows the two-tank system you will be controlling.
While Figure 1-2 shows a P&ID drawing of the two-tank system.
Hgskolen i Telemark
1 Introduction
Qp [cm^3/s]
LT1
Overlp
Overlp
HA1
Tank1
y1
LA1
FT
Q2
Q1
LV1
LT2
Overlp
HA2
y2
Tank2
LA2
Q4
Q3
LV2
u[V]
Reservoar
Hgskolen i Telemark
1 Introduction
Tank1
(1-1)
Tank2
(1-2)
Where:
Hgskolen i Telemark
2 Program
2 PROGRAM
In this chapter we will learn how to create the program used to control the Two-tank system.
Now set the database you just made active, with the Set Active Database button. Select the
database you just made and press ok.
Your database is now created and active.
Hgskolen i Telemark
2 Program
We also need a new Area where we can configure all the other I/O. Right click on Control
Strategies and choose New Area. This new area we can name 2-TANK2.
Figure 2-3 is a picture of how it should look.
Hgskolen i Telemark
2 Program
CARD/CHANEL
DESCRIPTION
LT1
C01CH03
LEVEL TANK1
LT2
C01CH04
LEVEL TANK2
FT1
C01CH05
FLOW
HA1
C03CH01
LA1
C03CH02
HA2
C03CH03
LA2
C03CH04
P1
C02CH03
PUMP
LV1
C04CH01
SOLONOID VALVE
TANK1
LV2
C04CH02
SOLONOID VALVE
TANK2
OUT
Table 2-1 is an overview over cards with channels connected to the controller. Right click on the
channels, as shown in Figure 2-5, and enable all the channels presented in the table above. When
the channels are active they should change color from grey to yellow.
Hgskolen i Telemark
2 Program
All I/O that we need to control the 2-TANK should now be active.
10
Hgskolen i Telemark
2 Program
Figure 2-7 is showing the PID block. Right click the block and choose Assign I/O to Signal Tag.
.
Figure 2-7 Assign I/O to Signal Tag
Mark IO_OUT and press Modify, now choose Browse and double click on CTLR-1_HIT, mark
TLR-1-HITC02CH03 and press OK. It is the gain signal to the pump that is connected to this
card. This procedure is shown in Figure 2-8.
11
Hgskolen i Telemark
2 Program
The level transmitter on the tank has a 4mA output signal when the level is at 100%. Because of
this we need to reverse the signal to the regulator, this is done by getting an Analog Input block
from the I/O tab, and a Scaler block from the Analog Control tab.
Your picture should now look similar to Figure 2-9.
Now we need to connect the OUT on the Analog In block to the IN on the SCLR block. We also
need to connect the OUT on SCLR to the IN on the PID block.
12
Hgskolen i Telemark
2 Program
Right click on the Analog In block and choose Assign I/O to Signal Tag, press browse, double
click on CTLR-1-HIT, mark TLR-1-HITC01CH03 and press OK. This is the level transmitter
that is connected to this channel.
Now mark the SCLR block. A property window will appear in the lower left corner, as shown in
Figure 2-10. Double click on OUT SCALE and enter 0 on 100% scale, and 100 on 0% scale.
Press OK.
button.
Press yes, and choose CTLR-1-HIT and click OK. Press yes, and OK until the download is
completed.
Close Control Studio. Press yes if you get question about saving.
13
Hgskolen i Telemark
2 Program
Lets call this module IO. The module is located in the area 2-TANK2. Figure 2-12 shows you
what happens when you right click the IO area. Do this and Open with Control Studio.
Now we need to connect the remaining I/O to the physical model. All the blocks we need are
found under the I/O tab. Grab four Discrete Input blocks, two Discrete Output blocks and two
Analog Input blocks.
By right clicking on the blocks you can change the name on each of the blocks to the correct tag
they are supposed to have. Name each of the blocks as seen in Figure 2-13, this will make the
program easier to read.
14
Hgskolen i Telemark
2 Program
15
Hgskolen i Telemark
2 Program
To be able to operate the valves LV1 and LV2 you need to change their mode from Cascade to
Manual. This is done by marking LV1, a property box will appear in lower left corner as shown
in Figure 2-15. Double click on mode that is located in the Operating sub-menu. Set Normal
Mode and Target to Manual. Do exactly the same for LV2.
16
Hgskolen i Telemark
2 Program
button.
Press yes, and choose CTLR-1-HIT and click OK. Press yes, and OK until the download is
completed.
Close Control Studio. Press yes if you get question about saving.
17
Hgskolen i Telemark
2 Program
Now we need to download the program to the controller. This is done by right clicking on
Physical Network and choose download Physical Network as seen in Figure 2-17.
Our program is now done and the next thing we need to do is create a HMI, so we can control
our model with the program.
18
Hgskolen i Telemark
3 HMI
3 HMI
To be able to read and write values and simulate a process we need to create an HMI.
Press + on the Pictures folder, then templates and double-click on main. See Figure 3-2. Then
you will get the default picture.
Mark everything on the picture and delete it. Figure 3-3 is showing you how your picture should
look when everything is deleted.
19
Hgskolen i Telemark
3 HMI
Figure 3-4 shows you that there are lots of pre drawn tanks with animations.
Find a suitable tank you would like to use. A Dynamo box will appear after you have placed
your tank, as shown in Figure 3-5.
20
Hgskolen i Telemark
3 HMI
Now we need to connect this to the value of the level to tank1. Press the
button and press
Browse DeltaV Control Parameters, choose PID_LOOP_1, PID1, choose PV, then choose CV.
Press OK until you are back to your picture.
We are now done with one tank. Now grab another tank, similar to the first one. This one we
need to reverse the visual display, because it is not scaled in the program. This is done by setting
Lowest Input Value to 100 and Highest Input Value to 0.
Press the
button.
button and press Browse DeltaV Control Parameters, then press the folder up
21
Hgskolen i Telemark
3 HMI
Choose 2-TANK2, then IO, LT2, PV then CV and press OK until you are back to your picture.
By pressing A in the toolbox you can write on your picture. Write Tank1,Tank2 and
Open Faceplate and make your picture similar to Figure 3-8.
22
Hgskolen i Telemark
3 HMI
We now made it possible to open the faceplate to our regulator when the program is running.
23
Hgskolen i Telemark
3 HMI
Figure 3-10 How to make your pump change color when its running
Press the
button, choose Browse DeltaV Control Parameters. Then we need to choose 2TANK,PID_LOOP_1, double click on PID1,OUT, choose CV and press OK until you are back
at your picture.
The Flow Transmitter can be found under Dynamo Sets and FlowMeters see Figure 3-11. Find a
suitable flow transmitter to use on your picture.
24
Hgskolen i Telemark
3 HMI
Double click on the valve you placed next to tank1. Figure 3-13 will appear, make sure
Foreground Color is activated and press the button next to it.
Make sure Exact Match is activated, delete all the rows and add two new rows. The color of the
valve, at value 0 should be gray. At value 1, the valve should be green, as seen in Figure 3-14.
25
Hgskolen i Telemark
3 HMI
Figure 3-14 Changing the color of the valve when its open
26
Hgskolen i Telemark
3 HMI
The valve will now change color from gray to green when its open. Now do the same thing with
the valve you placed close to tank2. The only difference is that you need to choose LV2 instead
of LV1 when we configured the other valve.
in
27
Hgskolen i Telemark
3 HMI
Save your picture in the Templates folder, and name it your name.
28
Hgskolen i Telemark
4 Operate
4 OPERATE
In this chapter we will learn how to run the program used to control the Two-tank system.
To be able to control the two-tank you need to physically connect the model to DeltaV. This is
done by connecting the connection pins together. They are marked, and the wire with nr 1 from
the model is connected to the wire with nr 1 on DeltaV. Figure 4-1 is how the connection is
done.
The model also needs to be connected to 230V and be turned on. When turning the power on,
make sure the components inside the model are powered.
To run the model you need to open DeltaV Operate config. Open the HMI you created, that you
named with your name. This HMI is found under templates. Press Ctrl+w to witch to run mode
in DeltaV. The process can now be operated. As you can see in Figure 4-2 the process is running.
29
Hgskolen i Telemark
4 Operate
Now press the faceplate button you made. The faceplate window should appear, Figure 4-3.
On the faceplate you have options to control the process manually or set it to auto. You can trend
the regulator by pressing the button that looks like a graph. You will then see SP, OP and PV.
If you would like to change the regulator parameters you press the magnify glass button in the
faceplate window. The detail picture in Figure 4-4 will appear.
This is where you change the PID parameters. Under tuning, Gain is the P-value, Reset is the
I-value and Rate is the D-value. We choose P=2 and I=10 as start values. But feel free to
experiment and find better values.
30
Hgskolen i Telemark
4 Operate
31