Anda di halaman 1dari 30

Control Engineering

Lab Report

By:

Gohar Zaman
2009-ME-372
Instructor:

Mr. Moeen Sultan


Lecturer,
Department of Mechanical Engg.

Department of Mechanical Engineering,


University of engineering and Technology, Lahore (KSK Campus)

This Lab Report contains the following:


Experiment No.1.3
To carry out an open loop control for flow using an AVS-I solenoid Valves

Experiment No.2 6
To carry out a closed loop control for flow by an on/off controller using AVS-1
Solenoid valve

Experiment No.3 .. 9
To carry out a closed loop control for flow by a PROPORTIONAL (P)
CONTROLLER

Experiment No.4 .. 13
To carry out a closed loop control for flow by a PROPORTIONAL INTEGRAL
(PI)CONTROLLER

Experiment No.5 . 17
To carry out a closed loop control for flow by a PROPORTIONAL
DIFFERENTIAL(PD)CONTROLLER

Experiment No.6 .. 21
To carry out a closed loop control for flow by a PROPORTIONAL INTEGRAL
DIFFERENTIAL (PID)CONTROLLER

Experiment No.7 .. 24

2 | Page

Use several inputs to implement logic OR, AND , NOT , NAND, NOR, XOR
Gates Using PLC.

3 | Page

Experiment No. 1
To carry out an open loop control for flow using an AVS-I solenoid Valves

Apparatus:

UCP-F
Control and Acquisition Software
Water
Pipes

Theoretical Background

Control System:

A control system is a device, or set of devices to manage, command,


direct or regulate the behavior of other devices or systems. Industrial
control systems are used in industrial production. All our tools and
machines need appropriate control to work, otherwise it will be
difficult to finish their designated tasks accurately. Therefore, we
need control systems to guide, instruct and regulate our tools and
machines. Common control systems include mechanical, electronic,
pneumatic and computer aided. A system usually contains three main parts: input, process and
output. A schematic diagram of control system is shown below

INPUT

PROCE
SS

OUTPU
T

There are basically two types of control system: the open loop system and the closed loop system

4 | Page

Open Loop Control System:


In an Open loop system, an input is converted to an output by a control unit, this is independent
of any effect of output. The diagram shows general open loop system:

Its operation is very simple, when an input signal directs the control element to respond, an
output will be produced. Examples of the open loop control systems include washing machines,
light switches, gas ovens, etc.

Solenoid valve
A solenoid valve is an electromechanically operated valve. The valve is controlled by an electric
current through a solenoid: in the case of a two-port valve the flow is switched on or off; in the
case of a three-port valve, the outflow is switched between the two outlet ports. Multiple
solenoid valves can be placed together on a manifold.
Solenoid valves are the most frequently used control elements in fluidics. Their tasks are to shut
off, release, dose, distribute or mix fluids. They are found in many application areas. Solenoids
offer fast and safe switching, high reliability, long service life, good medium compatibility of the
materials used, low control power and compact design. The parts of solenoid valve are as below:

if the valve is closed, then the two ports are connected and fluid may flow between the ports; if
the valve is open, then ports are isolated. If the valve is open when the solenoid is not energized,

5 | Page

then the valve is termed normally open (N.O.). Similarly, if the valve is closed when the solenoid
is not energized, then the valve is termed normally closed.

Procedure:
I.
II.
III.
IV.

Connect the interface of the equipment and the control software.


Select the open loop control 1 option.
Click the start button, and start the pump.
Now manually move the AVS-1 bar to control the flow through the valve in to the
container.

Comments and Conclusions:

This is basic implementation of the control unit to control the output from input according to a
given controller gain since the open loop controllers have no influence of output on the input.
The experiment demonstrated that how for a given value of flow the valve operated with the
control, the valve opened and allowed the flow until the desired flow rate was achieved. Also this
could be used on the very same apparatus to control the depth of water in the tank.
The software usage is friendly and makes control easier for the unit since every
parameter is just one click away and can be controlled from the computer. Such control systems
are widely used in industries but more sophistication has been achieved such as closed system.

6 | Page

Experiment No. 2
To carry out a closed loop control for flow by an on/off controller
using AVS-1 Solenoid valve

Apparatus:

UCP-F
Control and Acquisition Software
Water
Pipes

Theoretical Background
Control System:

A control system is a device, or set of devices to manage, command, direct or regulate the
behavior of other devices or systems. Industrial control systems are used in industrial production.
All our tools and machines need appropriate control to work, otherwise it will be difficult to
finish their designated tasks accurately. Therefore, we need control systems to guide, instruct and
regulate our tools and machines. Common control systems include mechanical, electronic,
pneumatic and computer aided. A system usually contains three main parts: input, process and
output. A schematic diagram of control system is shown below

INPUT

PROCE
SS

OUTPU
T

There are basically two types of control system: the open loop system and the closed loop system

Close Loop Control System:


7 | Page

Sometimes, we may use the output of the control system to adjust the input signal. This is
called feedback. Feedback is a special feature of a closed loop control system. A closed loop
control system compares the output with the expected result or command status, then it takes
appropriate control actions to adjust the input signal. Therefore, a closed loop system is always
equipped with a sensor, which is used to monitor the output and compare it with the expected
result.
Diagram below shows a simple closed loop system. The output signal is fed back to the input to
produce a new output. A well-designed feedback system can often increase the accuracy of the
output.

Feedback can be divided into positive feedback and negative feedback. Positive feedback
causes the new output to deviate from the present command status. For example, an amplifier is
put next to a microphone, so the input volume will keep increasing, resulting in a very high
output volume. Negative feedback directs the new output towards the present command status,
so as to allow more sophisticated control.
Most modern appliances and machinery are equipped with closed loop control
systems. Examples include air conditioners, refrigerators, automatic rice cookers, automatic
ticketing machines, etc. An air conditioner, for example, uses a thermostat to detect the
temperature and control the operation of its electrical parts to keep the room temperature at a
preset constant. Diagram shows the block diagram of the control system of an air conditioner.

One advantage of using the closed loop control system is that it is able to adjust its output
automatically by feeding the output signal back to the input. When the load changes, the error
signals generated by the system will adjust the output. However, closed loop control systems are
generally more complicated and thus more expensive to make.

8 | Page

Procedure:
I.
II.
III.
IV.

Connect the interface of the equipment and the control software.


Select the on/off control option.
By double clicking on the on/off control, select the flow wanted. There is certain flow, a
tolerance and a performance time set by default.
It calculates the inertia of the system considering an on/off response and determines the
time limit for an exact control.

Comments and Conclusions:


Te purpose of feedback in the closed loop is to provide control a measure of how well the
output has been controlled. The feedback is observed by the controller and the input is varied in
such a way to achieve the output quickly and accurately. Therefore the closed loop control is
much more intelligent and sophisticated than the open loop control which does not consider the
output in controlling the input.
Since closed loop systems are composed of a feedback mechanism, so they clear out
the errors between input and output signals, and hence remain unaffected to the external noise
sources.

9 | Page

Experiment No. 3
To carry out a closed loop control for flow by a Proportional Controller

Apparatus:
I.
II.
III.
IV.

Data Acquisition Interface


Control and Acquisition Software
Water pump and reservoir apparatus
Pipes and other accessories

Theoretical background

PID Controller
A proportional-integral-derivative controller (PID controller) is a generic control loop feedback
mechanism (controller) widely used in industrial control systems. A PID controller calculates an
"error" value as the difference between a measured process variable and a desired set-point. The
controller attempts to minimize the error by adjusting the process control inputs.
PID controllers can be viewed as three terms a proportional term, and integral term and a
derivative term - added together. PID
controllers are also known as three-term
controllers and three-mode controllers. Here's
a block diagram representation of the PID.

The textbook version of the PID controller is

10 | P a g e

where u is the control signal and e is the control error (e = r - y). The reference value is also
called the set-point. The control signal is thus a sum of three terms: the P-term (which is
proportional to the error), the I-term (which is proportional to the integral of the error), and the
D-term (which is proportional to the derivative of the error). The controller parameters are
proportional gain k, integral gain ki and derivative gain kd.

Proportional Controller
This controller sets the manipulated variable in proportion to the difference between the set-point
and the measured variable. The greater the difference, the greater is the change in the
manipulated variable.
The equation that describes a proportional controller is

where ub is a bias or reset term which is adjusted to


give the desired steady state value.
The advantage of proportional control is that it is
relatively easy to implement. However the
disadvantage is that when implementing a
proportional only controller there will be an offset in
the output. Thus there is always a difference between
the set-point and the actual output.

Procedure:
I.
II.
III.
IV.

Connect the sensors of the water tank apparatus to the analogue input of the Data
Acquisition interface
Adjust a desired flow rate or Depth from the software interface and set a gain value for
the control
Turn on the pump and observe the line being produced and turning on and off of pump
Collect the data produced by software, and plot the graphs.

Observations:
The obtained data was plotted and the resulting graphs were as below:

11 | P a g e

GRAPHS
Kc=1
80
60
Flow
rate
(lit/min)

40
20
0
0

10

20

30

40

50

60

70

80

90

100

Time /seconds

Kc=3.5
120
100

Flow
rate
(lit/min

80
60
40
20
0
0

10

20

30

40

50

60

70

80

Time(seconds)

Kc=5

12 | P a g e

120
100

Flow
rate
(lit/min)

80
60
40
20
0
0

10

20

30

40

50

60

Time(seconds)

Comments and Conclusions:


A proportional controller attempts to perform better than the On-off type by
applying power in proportion to the difference in flow rates between the measured and the setpoint. As the gain is increased the system responds faster to changes in set-point but becomes
progressively under-damped and eventually unstable. The final flow rate lies below the set-point
for this system because some difference is required to keep the pump supplying.
It can be noted from the graphs as well that by increasing the gain 2 things happened
1. System responded quickly
2. Fluctuations have been increased
Proportional units with lower gain will show fluctuations but they will have lesser magnitude and
a lesser frequency so that the system will appear to be stable. A proportional controller (Kp) will
have the effect of reducing the rise time and will reduce, but never eliminate, the steady-state
error.
So, to summarize following conclusion can be drawn:

13 | P a g e

Experiment No. 4
To carry out a closed loop control for flow by a Proportional Integrated
Controller

Apparatus:
V.
VI.
VII.
VIII.

Data Acquisition Interface


Control and Acquisition Software
Water pump and reservoir apparatus
Pipes and other accessories

Theoretical background
Proportional Controller
This controller sets the manipulated variable in proportion to the difference between the set-point
and the measured variable. The greater the difference, the greater is the change in the
manipulated variable.
The equation that describes a proportional controller is

where ub is a bias or reset term which is adjusted to give the desired steady state value.
The advantage of proportional control is that it is relatively easy to implement. However the
disadvantage is that when implementing a proportional only controller there will be an offset in
the output. Thus there is always a difference between the set-point and the actual output.

Integral Action:
14 | P a g e

With integral action, the controller output is proportional to the amount of time the error is
present. Integral action eliminates offset. The Integral controller is represented in equation as:

The integral controller produce an output proportional with the summarized deviation between
the set point and measured value and integrating gain or action factor.
Integral controllers tend to respond slowly at first, but over a long period of time they tend to
eliminate errors.The integral controller eliminates the steadystate error, but may make the transient response worse. The
controller may be unstable.
The integral regulator may also cause problems during
shutdowns and start up as a result of the integral saturation or
wind up effect. An integrating regulator with over time
deviation (typical during plant shut downs) will summarize
the output to +/- 100%.
The contribution from the integral term is proportional to both
the magnitude of the error and the duration of the error. The integral in a PID controller is the
sum of the instantaneous error over time and gives the accumulated offset that should have been
corrected previously. The accumulated error is then multiplied by the integral gain and added to
the controller output.

Procedure:
I.
II.
III.
IV.

Connect the sensors of the water tank apparatus to the analogue input of the Data
Acquisition interface
Adjust a desired flow rate or Depth from the software interface and set a gain value for
the control
Turn on the pump and observe the line being produced and turning on and off of pump
Collect the data produced by software, and plot the graphs.

Observations:
The data obtained was plotted and following graph was obtained
15 | P a g e

For Ki = 0.5

Flow rate

1
0

3
2

5
4

7
6

9 11 13 15 17 19 21 23 25 27 29 31 33 35 37 39 41 43
8 10 12 14 16 18 20 22 24 26 28 30 32 34 36 38 40 42
Time

For Ki = 0.2

16 | P a g e

105
95
85
75
65
Flow rate

55
45
35
25.66

25
15
5
-15 -5 5

25

45

65

85

105

125

145

165

185

205

time

Comments and Conclusions:


When the integral component comes into action the response becomes more
oscillatory and needs longer to settle, the error disappears. It can be observed clearly from the
graph that the settling time has increased also that the oscillations are continuous, It can further
be seen that when the gain is increased the settling time is further reduced but one thing that is
important about the integral controller is that it eliminates the steady state error which is a big
achievement for any system. So the following conclusions can be drawn from this,

17 | P a g e

Experiment No. 5
To carry out a closed loop control for flow by a Proportional Derivative
Controller

Apparatus:
IX.
X.
XI.
XII.

Data Acquisition Interface


Control and Acquisition Software
Water pump and reservoir apparatus
Pipes and other accessories

Theoretical background
18 | P a g e

Proportional Controller
This controller sets the manipulated variable in proportion to the difference between the set-point
and the measured variable. The greater the difference, the greater is the change in the
manipulated variable.
The equation that describes a proportional controller is

where ub is a bias or reset term which is adjusted to give the desired steady state value.
The advantage of proportional control is that it is relatively easy to implement. However the
disadvantage is that when implementing a proportional only controller there will be an offset in
the output. Thus there is always a difference between the set-point and the actual output.

Proportional Derivative Controller:


With derivative action, the controller output is proportional to the rate of change of the
measurement or error. The controller output is calculated by the rate of change of the deviation or
error with time. Derivative action can improve the stability of the closed-loop system. The inputoutput relation of a controller with proportional and derivative action is

where Td = kd/d is the derivative time.


The action of a controller with proportional and derivative
action can be interpreted as if the control is made proportional
to the predicted process output, where the prediction is made
by extrapolating the error. The system is oscillatory when not
derivative action is used and it becomes more damped as
derivative gain is increased
The derivative or differential controller is never used alone.
With sudden changes in the system the derivative controller
will compensate the output fast. The long term effects the
controller allow huge steady state errors.
19 | P a g e

A derivative controller will in general have the effect of increasing the stability of the system,
reducing the overshoot, and improving the transient response

Procedure:
V.
VI.
VII.
VIII.

Connect the sensors of the water tank apparatus to the analogue input of the Data
Acquisition interface
Adjust a desired flow rate or Depth from the software interface and set a gain value for
the control
Turn on the pump and observe the line being produced and turning on and off of pump
Collect the data produced by software, and plot the graphs.

Observations:
The data obtained was plotted and following graph was obtained

20 | P a g e

21 | P a g e

Comments and Conclusions:


The stability and overshoot problems that arise when a proportional controller is used at high
gain can be alleviated by adding a term proportional to the time-derivative of the error signal.
The value of the damping can be adjusted to achieve a critically damped response. A derivative
control shows the effect of increasing the stability of the system, reducing the overshoot, and
improving the transient response

22 | P a g e

Experiment No. 6
To carry out a closed loop control for flow by a Proportional Integral
Differential (PID) Controller

Apparatus:
I.
II.
III.
IV.

Data Acquisition Interface


Control and Acquisition Software
Water pump and reservoir apparatus
Pipes and other accessories

Theoretical background

PID Controller:
The PID control algorithm is used for the control of
almost all loops in the process industries, and is also the
basis for many advanced control algorithms and
strategies. In order for control loops to work properly,
the PID loop must be properly tuned. Standard methods
for tuning loops and criteria for judging the loop tuning
have been used for many years, but should be
reevaluated for use on modern digital control systems.

The basic function of a controller is to execute an algorithm (electronic controller) based on the
control engineer's input (tuning constants), the operators desired operating value (setpoint) and
the current plant process value. In most cases, the requirement is for the controller to act so that
the process value is as close to the setpoint as possible. In a basic process control loop, the
control engineer utilises the PID algorithms to achieve this.

23 | P a g e

What the PID controller is looking at is the difference (or "error") between the PV and the SP. It
looks at the absolute error and the rate of change of error. Absolute error means -- is there a big
difference in the PV and SP or a little difference? Rate of change of error means -- is the
difference between the PV or SP getting smaller or larger as time goes on.
Once the PID controller has the process variable equal to the set-point, a good PID controller
will not vary the output. You want the output to be very steady (not changing). If the valve
(motor, or other control element) are constantly changing, instead of maintaining a constant
value, this could cause more wear on the control element.

Procedure:
I.
II.
III.
IV.

Connect the sensors of the water tank apparatus to the analogue input of the Data
Acquisition interface
Adjust a desired flow rate or Depth from the software interface and set a gain value for
the control
Turn on the pump and observe the line being produced and turning on and off of pump
Collect the data produced by software, and plot the graphs.

Observations:
The data obtained was plotted and following graph was obtained

24 | P a g e

Flow rate vs Time


120
100
80
60
40
20
0
0

10

20

30

40

50

Comments and Conclusions:


Although PD control deals neatly with the overshoot and ringing problems associated
with proportional control it does not cure the problem with the steady-state error.
Fortunately it is possible to eliminate this while using relatively low gain by adding an
integral term to the control function which becomes more accurate. Therefor PID system
is used to enhance the performance of PD system by eliminating the steady state error
and PID system satisfies all of the requirements. PID, though complex than others, are
widely used for control in industries. The mixed effect was observed during this
experiment from the graph.

25 | P a g e

60

Experiment No. 7
To use several inputs to implement logic OR, AND , NOT , NAND, NOR, XOR
Gates Using PLC.

Apparatus:
I.
II.

Programmable Logic Controller (PLC Hardware)


PLC Programming software

Theoretical Background
Programmable Logic Controller
A Programmable Logic Controller, PLC or Programmable Controller is a digital computer used
for automation of electromechanical processes, such as control of machinery on factory assembly
lines, amusement rides, or light fixtures. The abbreviation "PLC" and the term "Programmable
Logic Controller" are registered trademarks of the Allen-Bradley Company (Rockwell
Automation).[1] PLCs are used in many industries and machines. Unlike general-purpose
computers, the PLC is designed for multiple inputs and output arrangements, extended
temperature ranges, immunity to electrical noise, and resistance to vibration and impact.
Programs to control machine operation are typically stored in battery-backed-up or non-volatile
memory. A PLC is an example of a hard real time system since output results must be produced
in response to input conditions within a limited time, otherwise unintended operation will result.

Advantages of PLC:

Less wiring.
Wiring between devices and relay contacts are done in the PLC program.
Easier and faster to make changes.
Trouble shooting aids make programming easier and reduce downtime.
Reliable components make these likely to operate for years before failure.

26 | P a g e

PLC Programming Languages


IEC 1131-3 is the international standard for programmable controller programming languages.
The following is a list of programming languages specified by this standard:

Ladder diagram (LD)

Sequential Function Charts (SFC)

Function Block Diagram (FBD)

Structured Text (ST)

Instruction List (IL)

One of the primary benefits of the standard is that it allows multiple languages to be used within
the same programmable controller. This allows the program developer to select the language best
suited to each particular task.

Ladder Logic
Ladder logic is the main programming method used for PLC's. As mentioned before, ladder logic
has been developed to mimic relay logic. The decision to use the relay logic diagrams was a
strategic one. By selecting ladder logic as the main programming method, the amount of
retraining needed for engineers and trades people was greatly reduced.
The first PLC was programmed with a technique that was based on relay logic wiring
schematics. This eliminated the need to teach the electricians, technicians and engineers how to
program - so this programming method has stuck and it is the most common technique for
programming in today's PLC.

Sequential Function Charts (SFC)


SFC have been developed to accommodate the programming of more advanced systems. These
are similar to flowcharts, but much more powerful. This method is much different from
flowcharts because it does not have to follow a single path through the flowchart.

Structured Text (ST)


Programming has been developed as a more modern programming language. It is quite similar to
languages such as BASIC and Pascal.
Structured Text (ST) is a high level textual language that is a Pascal like language. It is very
flexible and intuitive for writing control algorithms.
27 | P a g e

Function Block Diagram (FBD)


FBD is another graphical programming language. The main concept is the data flow that start
from inputs and passes in block(s) and generate the output.

Implementation of Logic Gates:


1.
2.
3.
4.
5.
6.

Draw a truth table for the logic gate to be used


Find boolian equation
For two or inputs to multiply Connect them is series (AND)
For two inputs to add Connect them in parallel (OR)
In order to negate an input (invert) right click and negate it (NOT)
Use these combinations to make ladder diagram for several inputs to implement any sort
of logic.

Symbols in Ladder Diagram:

( )

Regular Output

(\)

Negated Output

[ ]

Input

[\] Negated Input

Ladder Diagram for a XOR gate :

Following are Ladder Diagrams for AND and OR gates:

28 | P a g e

29 | P a g e

Comments:
PLC programming is user friendly as well as it is very essential for implementing
control in several apparatuses and industries. The Ladder diagram is visually elaborated and does
not contain complex programming like other programming languages for example C++, Fortran
etc.
The Lab sessions have been very instrumental to develop a skill of implementing a
control as several random relations were generated, then their truth table were drawn, boolian
equation was established and these were successfully implemented on PLC and observed
physically.

30 | P a g e

Anda mungkin juga menyukai