ueeneed026b design a computer based control system · reference list ... relay control systems that...
TRANSCRIPT
UEE07 Electrotechnology Training Package
Learner Workbook
Version 1
TRAINING AND EDUCATION SUPPORT
INDUSTRY SKILLS UNIT, MEADOWBANK
Product 5495
UEENEED026B
Design a computer based control system
SAMPLE
UEENEED026B Design a computer based control system
Developed by Training & Education Support Industry Skills Unit, Meadowbank
@ TAFE NSW 2011
Acknowledgments
The TAFE NSW Training and Education Support Industry Skills Unit, Meadowbank
would like to acknowledge the support and assistance of the following people in
the production of this learner workbook:
Writers:
Jeffrey Stokes
TAFE NSW
Reviewers:
TAFE NSW
Project Manager:
Steve Parkinson
TAFE NSW
Enquiries
Enquiries about this and other publications can be made to:
Training and Education Support Industry Skills Unit, Meadowbank
Meadowbank TAFE
Level 3, Building J,
See Street,
MEADOWBANK NSW 2114
Tel: 02-9942 3200 Fax: 02-9942 3257
ISBN 978-1-74236-256-4
© The State of New South Wales, Department of Education and
Training, TAFE NSW, Training and Education Support Industry Skills
Unit, Meadowbank, 2011.
Copyright of this material is reserved to TAFE NSW Training and Education
Support Industry Skills Unit, Meadowbank. Reproduction or transmittal in
whole or in part, other than for the purposes of private study or research, and
subject to the provisions of the Copyright Act, is prohibited without the written
authority of, TAFE NSW. Training and Education Support Industry Skills Unit,
Meadowbank.
SAMPLE
UEENEED026B Design a computer based control system
Developed by Training & Education Support Industry Skills Unit, Meadowbank
@ TAFE NSW 2011
Table of contents
Introduction .................................................................................. 9
1. General introduction ........................................................................... 9
2. Using this learner workbook ................................................................ 9
3. Prior knowledge and experience ......................................................... 11
4. Unit of competency overview ............................................................. 11
5. Assessment ..................................................................................... 16
Section 1: .................................................................................... 17
Control System Architecture ........................................................ 17
1.1 Microprocessor Based Controllers ........................................................ 17
1.2 PC Based Control Systems ................................................................. 21
1.3 Distributive and Hybrid Systems ......................................................... 30
1.4 Safety Considerations in Control System Design ................................... 34
Section 2: .................................................................................... 39
Measurement, Signals and Connections ....................................... 39
2.1 Industrial Sensors ............................................................................. 39
2.2 Controller I/O Electrical Specifications ................................................. 42
2.3 Signal Conditioning and Calibration ..................................................... 46
2.4 Input Protection Methods ................................................................... 48
2.5 Data Signals and Connections ............................................................. 51
Section 3: .................................................................................... 53
Control Programming .................................................................. 53
3.1 PLC Programming ............................................................................. 53
3.2 SCADA Programming ......................................................................... 55
3.2 Data Acquisition Systems ................................................................... 57
Section 4: .................................................................................... 61
SAMPLE
UEENEED026B Design a computer based control system
Developed by Training & Education Support Industry Skills Unit, Meadowbank
@ TAFE NSW 2011
Introduction to Labview .............................................................. 61
4.1 Labview Installation and Setup ........................................................... 61
4.2 Creating a Virtual Instrument (VI) ....................................................... 66
4.4 Introduction to HMI Design ................................................................ 72
Section 5: .................................................................................... 75
Analogue to Digital Conversion .................................................... 75
5.1 ADC Methods ................................................................................ 75
5.2 Resolution and Sample Rate ............................................................... 77
5.3 Noise Reduction ................................................................................ 78
5.4 Data Logging .................................................................................... 82
Section 6: .................................................................................... 83
Introduction to Visual Basic.net .................................................. 83
6.1 VB.net Installation and Setup ............................................................. 83
6.2 Navigating the IDE ............................................................................ 84
The Default Form ......................................................................... 86
6.3 Components and Properties ................................................................ 87
6.4 Events, Methods and Functions ........................................................... 97
6.5 Data Types and Variable Declarations .................................................. 98
6.6 Testing and Debugging a Program ..................................................... 111
Section 7: .................................................................................. 115
Programming Structures ........................................................... 115
7.1 If... Then... Else .............................................................................. 115
7.2 Select... Case ................................................................................. 117
7.3 For... Next ..................................................................................... 118
7.4 Do... While and Do... Until ............................................................... 119
7.5 Writing Function, Moving Objects ...................................................... 120
SAMPLE
UEENEED026B Design a computer based control system
Developed by Training & Education Support Industry Skills Unit, Meadowbank
@ TAFE NSW 2011
Section 8: .................................................................................. 131
Advanced Maths Techniques ...................................................... 131
8.1 Order of Operations......................................................................... 131
8.2 Trigonometric Functions ................................................................... 132
Section 9: .................................................................................. 133
Graphical Methods and Techniques ........................................... 133
9.1 Drawing in a Picture Box .................................................................. 133
9.4 Form and Component Opacity .......................................................... 136
Section 10: ................................................................................ 139
Control Programming Techniques .............................................. 139
10.1 Accessing I/O Devices .................................................................... 139
10.2 The Basic Control Loop .................................................................. 139
10.3 Timing Functions ........................................................................... 140
10.4 Counting External Events ............................................................... 141
Reading and Scaling Analogue Values ..................................................... 144
Section 11: ................................................................................ 147
Software Design Planning ......................................................... 147
11.1 Top-Down Methodology.................................................................. 147
11.2 Project Planning ............................................................................ 148
11.3 Modular Programming .................................................................... 150
11.4 Documenting Software Design Projects ............................................ 151
Section 12: ................................................................................ 153
Software Design Implementation – Project ............................... 153
12.1 Control Algorithms ........................................................................ 153
12.2 Data Logging Features ................................................................... 155
12.3 Programming Alarms ..................................................................... 156
SAMPLE
UEENEED026B Design a computer based control system
Developed by Training & Education Support Industry Skills Unit, Meadowbank
@ TAFE NSW 2011
12.4 Programming Access Control .......................................................... 158
12.5 Managing Project Changes ............................................................. 159
Section 13: ................................................................................ 161
Beta Testing and System Commissioning .................................. 161
13.1 Testing Modules of Code ................................................................ 161
13.2 Safety Testing and System Commissioning ....................................... 161
13.3 Commissioning Documentation ....................................................... 161
13.4 Operating Manuals and Training ...................................................... 161
Section 14: ................................................................................ 163
Data Communications Features ................................................. 163
14.1 Networks ..................................................................................... 163
14.2 Network Topologies ....................................................................... 173
14.3 Network Standards and Protocols .................................................... 174
Section 15: ................................................................................ 177
Computer Based Control System Project ................................... 177
15.1 System Planning ........................................................................... 177
15.2 System Implementation ................................................................. 178
15.3 System Problem Solving ................................................................ 179
15.4 System Completion ....................................................................... 180
Reference list ............................................................................ 183
Resource Evaluation Form ......................................................... 185
SAMPLE
UEENEED026B Design a computer based control system
Page 17 of 188
Section 1:
Control System Architecture
1.1 Microprocessor Based Controllers
Control System History
Early in the history of what we would call modern industrial
development, control systems were manually operated. They
relied on human measurement and decision making. This
means that they were flawed.
Over a period of time many
manual systems, especially
simple ON/OFF control
systems, were replaced with
relay control systems that
were capable of a level of
automation.
These were more reliable and saved money
because of the lower labour cost. Relay
operation is still relatively slow to respond to
process changes when compared with
electronics and systems still broke down often,
due to the electromechanical nature of the
devices used. We still use relays today but only
to isolate and control loads. They are not as
part of the control. If a relay operation takes 15
milliseconds and there are 10 stages in the
control circuit where one relay drives another,
the propagation of the signal might be greater
than 150 milliseconds. This is inadequate for
many applications today.
With the invention and introduction of
electronic devices, some relay control systems
were replaced by dedicated digital systems.
These systems were able to respond more
quickly and required less maintenance as the
devices were “solid state”, an old fashioned
term meaning that they had no moving parts.
They were essentially still hard-wired though,
and process modifications and fixes meant that
part of the system had to be re-designed and
re-wired. It was not until the arrival of the
microprocessor, that programmable control
was made possible.
Figure 1 Manual Valve
Figure 2 3000 Type relays used for control
Figure 3 Early transistor circuits in computers
SAMPLE
UEENEED026B Design a computer based control system
Page 18 of 188
Eventually the PLC was invented. It came about because of the needs of the
automotive manufacturers who needed to make changes to designs and build
new models.
PLCs became popular for control and are
still currently the most common solution
used by control engineers and electricians.
They grew in size and power until their
complexity made them too slow for some
applications. It is now more common to use
several small PLCs that communicate with
each other than one very large PLC with a
lot of processing power.
Activity box – A1.1
Using the Internet links below, complete the following
activities and respond in the space provided.
http://en.wikipedia.org/wiki/Programmable_logic_controller
http://www.machine-information-systems.com/PLC_History.html
http://www.plcs.net/chapters/links.htm
1.
In what year was the
very first PLC
designed?
2.
Why is it that PLC
programs have a
“ladder” like layout
rather than being
written in a normal
programming
language?
3.
List four well known
PLC manufacturers.
Figure 4
A shoebox PLC
SAMPLE
UEENEED026B Design a computer based control system
Page 19 of 188
Microprocessor Control
There are a number of choices in regard to a control system
solution. The decision to utilise a specific type of controller
and control system architecture is often based on the
number of inputs and outputs required and the complexity of
the control algorithms and therefore the processing power
required to do the calculations. Other considerations might
be the development time available, the lifecycle of the
project, the likelihood of process changes and limits on the
cost of system implementation.
Some of the choices are;
An embedded system (a dedicated system) such as is used for TV remote
controls, simple alarm systems and pool chlorination systems. In such
systems, a microprocessor or microcontroller executes a program that is
stored as “firmware” in EPROM memory. Costs for these systems are very
low because of mass production. If large production numbers are not
required, this sort of system is often not viable.
A single PLC, or a number of PLCs,
(a programmable system) where
changes are easily made and the
costs of both equipment and
development time are relatively
low. These systems are capable of
some analogue measurement but
only in a limited way. If a large
number of analogue channels are
required or very high sample rates,
then other solutions might be more
effective.
A third option is to use what is popularly called a single board computer.
This is something that has a PC operating system but is a limited
configuration in terms of computing power, memory and communications
capabilities. The benefits of a single board computer are that its power
consumption is low and
physically, it can be incorporated
in pieces of equipment. Flash
memory is used instead of a
hard drive. Graphics processors
are limited compared with a
normal PC and the processor is a
low power (slower) version of
standard CPU. Even today, it is
often a Pentium 4, not dual core
PC architecture. Software can be
developed easily as it is still
essentially a PC platform.
Figure 5 Embedded System
Figure 6 PLCs with SCADA control
Figure 7 Single Board Computer with onboard graphics,
Ethernet, expansion bus and USB ports
SAMPLE
UEENEED026B Design a computer based control system
Page 20 of 188
Ever since the advent of the personal computer, a PC based control
system has been an option. The processing power available in such a
system makes it perfect for complex measurement, analysis and advanced
control systems. The use of a PC along with data acquisition hardware, is
common in scientific circles. It is less commonly used in industry because
of the relatively high cost. As industrial process control becomes more
sophisticated and the price of PC technology continues to fall, this is
becoming less of a constraint. This type of control is the focus of this unit
of competency.
Technology Change
1. Why answer questions about historically irrelevant technology? Simply to
bring into focus the fact that technology will not stop changing. The
control solutions that are common today may not meet the needs of
tomorrow‟s industry.
Activity box – A1.2
Try to guess what year each of the two computers above
is from. The first is a relatively early PC. You will notice
the two floppy drives. There was no hard drive. Each time
you booted the PC you had to load the operating system
from a floppy disk.
The second PC is fairly recent. The flat LCD monitor
places it within the last five years.
Write your responses
to the right.
PC 1 PC 2
Figure 8 Two computers from different generations
SAMPLE