You are on page 1of 88

1 - 88

Table of Contents
Introduction ...........................................................3
PLCs ...................................................................5
Number Systems ............................................9
Terminology ......................................................... 15
Basic e!uirements .........................................."#
S$%"&& 'icro PLCs ........................................."9
Connecting ()ternal *e+ices ................................#&
Programming a PLC ..........................................#"
*iscrete In,uts-.ut,uts ....................................5&
/nalog In,uts and .ut,uts .............................01
Timers ..................................................................0#
Counters .......................................................$1
1ig2%S,eed Instructions .................................$5
S,eciali3ed (),ansion 'odules .......................$4
e+ie5 /ns5ers ..................................................4#
6inal ()am ..........................................................45
2 - 88

Introduction
This course covers Basics of PLCs and related products.
7,on com,letion o8 Basics o8 PLCs you s2ould be able to9
Identi8y t2e ma:or com,onents o8 a PLC and describe t2eir 8unctions
Con+ert numbers 8rom decimal to binary; BC*; and 2e)adecimal
Identi8y ty,ical discrete and analog in,uts and out,uts
ead a basic ladder logic diagram and statement list
Identi8y o,erational di88erences bet5een di88erent S$%"&& models
Identi8y t2e ,ro,er manual to re8er to 8or ,rogramming or
Installation o8 an S$%"&& PLC
Connect a sim,le discrete in,ut and out,ut to an S$%"&&
Select t2e ,ro,er e),ansion module 8or analog in,uts and out,uts
*escribe t2e o,eration o8 timers and counters
3 - 88

This knowledge will help you better understand customer
applications. In addition, you will be better able to
describe products to customers and determine
important differences between products. You should
complete Basics of Electricity before attempting
Basics of PLs. !n understanding of many of the
concepts co"ered in Basics of Electricity is re#uired
for Basics of PLs. In addition you may wish to
complete Basics of ontrol omponents. $e"ices
co"ered in Basics of ontrol omponents are used
with programmable logic controllers.
%I&!TI, %TEP ', %TEP '(&icro, %TEP '(&icro)*I+,
P, '-., and P, '/- are registered trademarks of
%iemens Energy 0 !utomation, Inc.
1ther trademarks are the property of their respecti"e
owners.
4 - 88


PLCs
Programmable Logic ontrollers 2PLs3, also referred to as
programmable controllers, are in the computer family. They
are used in commercial and industrial applications. ! PL
monitors inputs, makes decisions based on its program, and
controls outputs to automate a process or machine. This
course is meant to supply you with basic information on the
functions and configurations of PLs.

5 - 88

Basic PLC Operation:
PLCs consist of input modules or points, a Central Processing Unit (CPU), and output
modules or points. An input accepts a variety of digital or analog signals from various
field devices(Sensors) and converts them into a logic signal that can be used by the CPU.
he CPU ma!es decisions and e"ecutes control instructions based on program
instructions in memory. #utput modules convert control instructions from the CPU into a
digital or analog signal that can be used to control various field devices (Actuators). A
programming device is used to input the desired instructions. hese instructions
determine $hat the PLC $ill do for a specific input. An operator interface device allo$s
process information to be displayed and ne$ control parameters to be entered.
Pushbuttons (sensors), in this simple e"ample, connected to PLC inputs, can be used to
start and stop a motor connected to a PLC through a motor starter (actuator).
6 - 88
Input
Module
CPU
Central processing
Unit

Output
Module
Programming
Deice
Operator
Inter!ace

Hard-Wired Control:
Prior to PLCs, many of these control tas!s $ere solved $ith contactor or relay controls.
his is often referred to as hard$ired control. Circuit diagrams had to be designed,
electrical components specified and installed, and $iring lists created. %lectricians $ould
then $ire the components necessary to perform a specific tas!. &f an error $as made, the
$ires had to be reconnected correctly. A change in function or system
e"pansion re'uired e"tensive component changes and re$iring.
Advantages of PLCs:
he same, as $ell as more comple" tas!s, can be done $ith a PLC. (iring bet$een
devices and relay contacts is done in the PLC program. )ard*$iring, though still re'uired
to connect field devices, is less intensive. +odifying the application and correcting errors
are easier to handle. &t is easier to create and change a program in a PLC than it is to $ire
and re*$ire a circuit.
"ollo#ing are $ust a !e# o! t%e adantages o! P&Cs'
Smaller physical si,e than hard*$ire solutions.
%asier and faster to ma!e changes.
PLCs have integrated diagnostics and override functions.
-iagnostics are centrally available.
Applications can be immediately documented.
Applications can be duplicated faster and less e"pensively.
( - 88

Siemens PLCs:
Siemens makes several PLC product lines in the SIMATIC S7
Family. They are: S7!""# S7$""# and S7%"".
%'(.--
he S.*/00 is referred to as a micro PLC because of its small si,e. he S.*/00 has a
bric! design, $hich means that the po$er supply and &1# are on*board. he S.*/00 can
be used on smaller, stand*alone applications such as elevators, car $ashes, or mi"ing
machines. &t can also be used on more comple" industrial applications such as bottling
and pac!aging machines.

%'(4-- and %'(/--
he S.*200 and S.*300 PLCs are used in more comple" applications that support a
greater number of &1# points. 4oth PLCs are modular and e"pandable. he po$er supply
and &1# consist of separate modules connected to the CPU. Choosing either the S.*200 or
S.*300 depends on the comple"ity of the tas! and possible future e"pansion. 5our
Siemens sales representative can provide you $ith additional information on
any of the Siemens PLCs.


+umber %ystems5
8 - 88

Since a PLC is a computer, it stores information in the form of #n or #ff conditions (6 or
0), referred to as binary digits (bits). Sometimes binary digits are used individually and
sometimes they are used to represent numerical values.
Decimal System:
7arious number systems are used by PLCs. All number systems have the same three
characteristics8 digits, base, $eight. he -ecimal system, $hich is commonly used in
everyday life, has the follo$ing characteristics8
Ten digits 0, 1, 2, 3, 4, 5, , !, ", #
$ase 10
%eig&ts 1, 10, 100, 1000, '''
$ina(y System:
he binary system is used by programmable controllers. he binary system has the
follo$ing characteristics8
T)o digits 0, 1
$ase 2
%eig&ts Po)e(s of *ase 2 +1, 2, 4, ", 1, ''',
&n the binary system 6s and 0s are arranged into columns. %ach Column is $eighted. he
first column has a binary $eight of /
0
. this is e'uivalent to a decimal.
1. his is referred to as the least significant bit. he binary $eight is doubled $ith each
succeeding column. he ne"t column, for e"ample, has a $eight of /
6
, $hich is
e'uivalent to a decimal.
2. he decimal value is doubled in each successive column. he number in the far left
hand column is referred to as the most significant bit. &n this e"ample, the most
significant bit has a binary $eight of /
.
. his is e'uivalent to a decimal 6/9.
Conve(ting $ina(y to Decimal:
he follo$ing steps can be used to interpret a decimal number from a binary value.
6) Search from least to most significant bit for 6s.
/) (rite do$n the decimal representation of each column containing a 6.
) - 88

2) Add the column values.
&n the follo$ing e"ample, the fourth and fifth columns from the right contain a 6. he
decimal value of the fourth column from the right is 9, and the decimal value of the fifth
column from the right is 6:. he decimal e'uivalent of this binary number is /3. he sum
of all the $eighted columns that contain a 6 is the decimal number that the PLC has
stored.

&n the follo$ing e"ample the fourth and si"th columns from the right contain a 6. he
decimal value of the fourth column from the right is 9, and the decimal value of the si"th
column from the right is 2/. he decimal e'uivalent of this binary number is 30.

$its, $ytes, and %o(ds:
%ach binary piece of data is a bit. %ight bits ma!e up one byte. $o bytes, or 6: bits,
ma!e up one $ord.
Logic 0, Logic 1:
1* - 88

Programmable controllers can only understand a signal that is #n or #ff (present or not
present). he binary system is a system in $hich there are only t$o numbers, 6 and 0.
4inary 6 indicates that a signal is present, or the s$itch is #n. 4inary 0 indicates that the
signal is not present, or the s$itch is #ff.
BCD:
4inary*Coded -ecimal (4C-) are decimal numbers $here each digit is represented by a
four*bit binary number. 4C- is commonly used $ith input and output devices. A
thumb$heel s$itch is one e"ample of an input device that uses 4C-. he binary numbers
are bro!en into groups of four bits, each group representing a decimal e'uivalent. A four*
digit thumb$heel s$itch, li!e the one sho$n here, $ould control 6: (3 " 3) PLC inputs.
-e.adecimal:
)e"adecimal is another system used in PLCs. he he"adecimal system has the follo$ing
characteristics8
11 - 88

1 digits 0, 1, 2, 3, 4, 5, , !, ", #, A, $, C, D, /, 0
$ase 1
%eig&ts Po)e(s of *ase 1 +1, 1, 25, 40#''',
he ten digits of the decimal system are used for the first ten digits of the he"adecimal
system. he first si" letters of the alphabet are used for the remaining si" digits.
A 1 10 D 1 13
$ 1 11 / 1 14
C 1 12 0 1 15
he he"adecimal system is used in PLCs because it allo$s the status of a large number of
binary bits to be represented in a small space such as on a computer screen or
programming device display. %ach he"adecimal digit represents the e"act status of four
binary bits. o convert a decimal number to a he"adecimal number the decimal number is
divided by the base of 6:. o convert decimal /9, for e"ample, to he"adecimal8
-ecimal /9 divided by 6: is 6 $ith a remainder of 6/. $elve is e'uivalent to C in
he"adecimal. he he"adecimal e'uivalent of decimal /9 is 6C. he decimal value of a
he"adecimal number is obtained by multiplying the individual he"adecimal digits by the
base 6: $eight and then adding the results. &n the follo$ing e"ample the he"adecimal
number /4 is converted to its decimal e'uivalent of 32.
Conve(sion of 23m*e(s:
12 - 88

+%e !ollo#ing c%art s%o#s a !e# numeric alues in decimal, -inar., /CD, and
%e0adecimal representation1
4evie) 1
13 - 88

Terminology:
14 - 88

he language of PLCs consists of a commonly used set of terms; many of $hich are
uni'ue to PLCs. &n order to understand the ideas and concepts of PLCs, an understanding
of these terms is necessary.
Senso(:
A sensor is a device that converts a physical condition into an electrical signal for use by
the PLC. Sensors are connected to the input of a PLC. A pushbutton is one e"ample of a
sensor that is connected to the PLC input. An electrical signal is sent from the pushbutton
to the PLC indicating the condition (open1closed) of the pushbutton contacts.
Act3ato(s:

Actuators convert an electrical signal from the PLC into a physical condition. Actuators
are connected to the PLC output. A motor starter is one e"ample of an actuator that is
connected to the PLC output. -epending on the output PLC signal the motor starter $ill
either start or stop the motor.
Disc(ete 5n63t:
A discrete input, also referred to as a digital input, is an input that is either in an O2 or
O"" condition. Pushbuttons, toggle s$itches, limit s$itches, pro"imity s$itches, and
contact closures are e"amples of discrete sensors $hich are connected to the PLCs
discrete or digital inputs. &n the O2 condition a discrete input may be referred to as a
15 - 88

logic 6 or a logic high. &n the O"" condition a discrete input may be referred to as a logic
0 or a logic lo$.
A <ormally #pen (<#) pushbutton is used in the follo$ing e"ample. #ne side of the
pushbutton is connected to the first PLC input. he other side of the pushbutton is
connected to an internal /3 7-C po$er supply. +any PLCs re'uire a separate po$er
supply to po$er the inputs. &n the open state, no voltage is present at the PLC input. his
is the #== condition. (hen the pushbutton is depressed, /3 7-C is applied to the PLC
input. his is the #< condition.
Analog 5n63ts:
An analog input is a continuous, variable signal. ypical analog inputs may vary from 0
to /0 milliamps, 3 to /0 milliamps, or 0 to 60 volts. &n the follo$ing e"ample, a level
transmitter monitors the level of li'uid in a tan!. -epending on the level transmitter, the
signal to the PLC can either increase or decrease as the level increases or decreases.
16 - 88

Disc(ete 73t63ts:
A discrete output is an output that is either in an #< or #== condition. Solenoids,
contactor coils, and lamps are e"amples of actuator devices connected to discrete outputs.
-iscrete outputs may also be referred to as digital outputs. &n the follo$ing e"ample, a
lamp can be turned on or off by the PLC output it is connected to.
Analog 73t63ts:

An analo& output is a continuous# varia'le si&nal. The output may 'e as
simple as a "(" )*C level that drives an analo& meter. +,amples o- analo&
meter outputs are speed# .ei&ht# and temperature. The output si&nal may
also 'e used on more comple, applications such as a currenttopneumatic
transducer that controls an airoperated -lo.control valve.
1( - 88

CP8:

The central processor unit /CP01 is a microprocessor system that contains the
system memory and is the PLC decisionmakin& unit. The CP0 monitors the
inputs and makes decisions 'ased on instructions held in the pro&ram
memory. The CP0 per-orms relay# countin&# timin&# data comparison# and
se2uential operations.
P(og(amming:

A program consists of one or more instructions that accomplish a tas!. Programming a
PLC is simply constructing a set of instructions. here are several $ays to loo! at a
program such as ladder logic, statement lists, or function bloc! diagrams.
18 - 88

Ladde( Logic:
Ladder logic (LA-) is one programming language used $ith PLCs. Ladder logic uses
components that resemble elements used in a line diagram format to describe hard*$ired
control.
Ladde( Logic Diag(am:
he left vertical line of a ladder logic diagram represents the po$er or energi,ed
conductor. he output element or instruction represents the neutral or return path of the
circuit. he right vertical line, $hich represents the return path on a hard*$ired control
line diagram, is omitted. Ladder logic diagrams are read from left*to*right, top*to*bottom.
>ungs are sometimes referred to as net$or!s. A net$or! may have several control
elements, but only one output coil.
&n the above e"ample program sho$n e"ample &0.0, &0.6 and ?0.0 represent the first
instruction combination. &f inputs &0.0 and &0.6 are energi,ed, output relay ?0.0
energi,es. he inputs could be s$itches, pushbuttons, or contact closures. &0.3, &0.@, and
?6.6 represent the second instruction combination. &f either &nput &0.3 or &0.@ are
energi,ed, output relay ?0.6 energi,es.
Statement list :
1) - 88

A statement list (SL) provides another vie$ of a set of instructions. he operation, $hat
is to be done, is sho$n on the left. he operand, the item to be operated on by the
operation, is sho$n on the right. A comparison bet$een the statement list sho$n belo$,
and the ladder logic sho$n on the previous page, reveals a similar structure. he set of
instructions in this statement list perform the same tas! as the ladder diagram.
03nction $loc9 Diag(ams:
=unction 4loc! -iagrams (=4-) provide another vie$ of a set of instructions. %ach
function has a name to designate its specific tas!. =unctions are indicated by a rectangle.
&nputs are sho$n on the left*hand side of the rectangle and outputs are sho$n on the
right*hand side. he function bloc! diagram sho$n belo$ performs the same function as
sho$n by the ladder diagram and statement list.
PLC Scan:
he PLC program is e"ecuted as part of a repetitive process referred to as
a scan. A PLC scan starts $ith the CPU reading the status of inputs. he
application program is e"ecuted using the status of the inputs.
#nce the program is completed, the CPU performs internal
diagnostics and communication tas!s. he scan cycle ends by
updating the outputs, then starts over. he cycle time depends on
the si,e of the program, the number of &1#s, and the amount of
communication re'uired.

2* - 88

Soft)a(e:

So-t.are is any in-ormation in a -orm that a computer or PLC can use.
So-t.are includes the instructions or pro&rams that direct hard.are.
-a(d)a(e:
)ard$are is the actual e'uipment. he PLC, the programming device, and the connecting
cable are e"amples of hard$are.
:emo(y Si;e:
Ailo, abbreviated A, normally refers to 6000 units. (hen tal!ing about computer or PLC
memory, ho$ever, 6A means 60/3. his is because of the binary number system
(/60B60/3). his can be 60/3 bits, 60/3 bytes, or 60/3 $ords, depending on memory
type.
21 - 88

4A::
>andom Access +emory (>A+) is memory $here data can be directly accessed at any
address. -ata can be $ritten to and read from >A+.>A+ is used as a temporary storage
area. >A+ is volatile, meaning that the data stored in >A+ $ill be lost if po$er is lost. A
battery bac!up is re'uired to avoid losing data in the event of a po$er loss.
47::
>ead #nly +emory (>#+) is a type of memory that data can be read from but not
$ritten to. his type of memory is used to protect data or programs from accidental erasure.
>#+ memory is nonvolatile. his means a user program $ill not lose data during a loss
of electrical po$er. >#+ is normally used to store the programs that define the
capabilities of the PLC.
/P47::

%rasable Programmable >ead #nly +emory (%P>#+) provides some level of security
against unauthori,ed or un$anted changes in a program. %P>#+Cs are designed so that
data stored in them can be read, but not easily altered. Changing %P>#+ data re'uires a
special effort. U7%P>#+s (ultraviolet erasable programmable read only memory) can
only be erased $ith an ultraviolet light. %%P>#+ (electronically erasable programmable
read only memory), can only be erased electronically.
0i(m)a(e:

=irm$are is user or application specific soft$are burned into %P>#+ and delivered as
part of the hard$are. =irm$are gives the PLC its basic functionality.
P3tting it Toget&e(:
he memory of the S.*/00 is divided into three areas8 program space, data space,
and configurable parameter space.
Program space stores the ladder logic (LA-) or statement list (SL) program
instructions. his area of memory controls the $ay data space and &1# points are
used. LA- or SL instructions are $ritten using a programming device such as a
PC, then loaded into program memory of the PLC.
22 - 88

-ata space is used as a $or!ing area, and includes memory locations for
calculations, temporary storage of intermediate results and constants. -ata space
includes memory locations for devices such as timers, counters, high*speed
counters, and analog inputs and outputs. -ata space can be accessed under
program control.
Configurable parameter space, or memory, stores either the default or modified
configuration parameters.
Basic Requirements
5n o(de( to c(eate o( c&ange a 6(og(am, t&e follo)ing items a(e needed:
PLC
Pro&rammin& *evice
Pro&rammin& So-t.are
Connector Ca'le
23 - 88

PLC:
hroughout this course $e $ill be using the S.*/00 because of its ease of use.
P(og(amming Devices:
he program is created in a programming device (PD) and then transferred to the PLC.
he program for the S.*/00 can be created using a dedicated Siemens S&+A&C S.
programming device, such as a PD ./0 (not sho$n) or PD .30, if S%P . +icro1(&<
soft$are is installed.
A personal computer (PC), $ith S%P . +icro1(&< installed, can also be used as a
programming device $ith the S.*/00.
24 - 88

Soft)a(e:
A soft$are program is re'uired in order to tell the PLC $hat instructions it must follo$.
Programming soft$are is typically PLC specific. A soft$are pac!age for one PLC, or one
family of PLCs, such as the S. family, $ould not be useful on other PLCs. he S.*/00
uses a (indo$s based soft$are program called S%P .*+icro1(&<2/. he PD ./0 and
PD .30 have S%P . soft$are pre*installed. +icro1(&<2/ is installed on a personal
computer in a similar manner to any other computer soft$are.
Connecto( Ca*les PP5 +Point<to<Point 5nte(face,:
Connector cables are re'uired to transfer data from the programming device to the PLC.
Communication can only ta!e place $hen the t$o devices spea! the same language or
25 - 88

protocol. Communication bet$een a Siemens programming device and the S.*/00 is
referred to as PP& protocol (point *to * point interface). An appropriate cable is re'uired
for a programming device such as a PD ./0 or PD .30. he S.*/00 uses a E*pin, -*
connector. his is a straight*through serial device that is compatible $ith Siemens
programming devices (+P& port) and is a standard connector for other serial interfaces.
A special cable is needed $hen a personal computer is used as a
programming device. $o versions of this cable are available. #ne version,
called an >S*/2/1PP& +ulti*+aster Cable, connects a personal computerCs
>S*/2/ interface to the PLCs >S*39@ connector. he other version, called a
US41PP& +ulti*+aster Cable connects a personal computerCs US4 interface
to the PLCs >S*39@ connector.
26 - 88

4evie) 2:
2( - 88


S7-200 Micro PLCs:
28 - 88

he S.*/00 +icro PLC is the smallest member of the S&+A&C S. family of
programmable controllers. he central processing unit (CPU) is internal to the PLC.
&nputs and outputs (&1#) are the system control points. &nputs monitor field devices, such
as s$itches and sensors. #utputs control other devices, such as motors and pumps. he
programming port is the connection to the programming device.
S!<200 :odels
here are five S.*/00 CPU types8 CPU //6, CPU ///, CPU //3,CPU //3FP, and CPU
//: and t$o po$er supply configurations for each type.
he model description indicates the type of CPU, the po$er supply, the type of input, and
the type of output.
S!<200 0eat3(es:

he S.*/00 family includes a $ide variety of CPUs and features. his variety provides a
range of features to aid in designing a cost*effective automation solution. he follo$ing
table provides a summary of the maGor features, many of $hich $ill be covered in this
course.
2) - 88

:ode S)itc& and Analog Ad=3stment:

(hen the mode s$itch is in the >U< position the CPU is in the run mode and e"ecuting
the program. (hen the mode s$itch is in the S#P position the CPU is stopped. (hen
the mode s$itch is in the %>+ position the programming device can select the
operating mode.
3* - 88

he analog adGustment is used to increase or decrease values stored in special memory.
hese values can be used to update the value of a timer or counter, or can be used to set
limits.
76tional Ca(t(idge
he S.*/00 supports an optional memory
cartridge that provides a portable %%P>#+ storage for your program. he cartridge can
be used to copy a program from one S.*/00 PLC to a li!e S.*/00 PLC. &n addition, t$o
other cartridges are available. A real*time cloc! $ith battery is available for use on the
CPU //6 and CPU ///. he battery provides up to /00 days of data retention time in the
event of a po$er loss. he CPU //3, CPU //3FP and CPU //: have a real*time cloc!
built in. Another cartridge is available $ith a battery only.
/.6ansion :od3les:
he S.*/00 PLCs are e"pandable. %"pansion modules contain additional inputs and
outputs. hese are connected to the base unit using a ribbon connector.
31 - 88

A cover on the base unit protects the ribbon connector. Side*by*side mounting completely
encloses and protects the ribbon connector.
Availa*le /.6ansion:
he CPU //6 comes $ith : digital inputs and 3 digital outputs. hese are not e"pandable.
he CPU /// comes $ith 9 digital inputs and : digital outputs and $ill accept up to /
e"pansion modules. he CPU //3 and CPU //3FP come $ith 63 digital inputs and 60
32 - 88

digital outputs and $ill accept up to . e"pansion modules. he S.*//: comes $ith /3
digital inputs and 6: digital outputs and $ill accept up to . e"pansion modules.
Stat3s 5ndicato(s:
he CPU status indicators reflect the current mode of CPU operation. (hen the CPU is in
the >U< mode, the green >U< indicator is lit. (hen the CPU is in the S#P mode, the
yello$ S#P indicator is lit. he System =ault1-iagnostic (S=1-&AD) indicator turns red
for a system fault and yello$ to indicate certain diagnostic conditions.
he &1# status indicators represent the #n or #ff status of corresponding inputs and
outputs. =or e"ample, $hen the CPU senses an input is on, the corresponding green
indicator is lit.
5nstalling:
he S.*/00 can be installed in one of t$o $ays. A -&< clip allo$s installation on a
standard -&< rail. he -&< clip snaps
open to allo$ installation and snaps
closed to secure the unit on the rail.
33 - 88

he S.*/00 can also be panel mounted using installation holes located behind the access
covers.
/.te(nal Po)e( S366ly So3(ces:
An S.*/00 can be connected to either a /3 7-C or a 6/01/20 7AC po$er supply
depending on the CPU. An S.*/00 -C1-C1 -C $ould be connected to a /3 7-C po$er
supply.
An S.*/00 AC1-C1>elay $ould be connected to a 6/0 or /20 7AC po$er supply.
5>7 23m*e(ing:

S.*/00 inputs and outputs are labeled at the $iring terminations and ne"t to the status
indicators. hese alphanumeric symbols identify the &1# address to $hich a device is
connected. his address is used by the CPU to determine $hich input is present and
$hich output needs to be turned on or off. I designate a discrete input and 3 designates a
discrete output. he first number identifies the byte, the second number identifies the bit.
&nput &0.0, for e"ample, is byte 0, bit 0.
I"." 3 4yte "# 4it "
I".( 3 4yte "# 4it (
34 - 88

I(." 3 4yte (# 4it "
I(.( 3 4yte (# 4it (
+%e !ollo#ing ta-le identi!ies t%e input and output designations.
5n63ts:
&nput devices, such as s$itches, pushbuttons, and other sensor devices are connected to
the terminal strip under the bottom cover of the PLC.
5n63t Sim3lato(:

A convenient method of testing a program is to $ire toggle s$itches to the inputs. &nput
simulators $ith pre$ired toggle s$itches are available for the S.*/00s. S$itches are
$ired bet$een the /3 7-C po$er supply (LH) and the inputs. =or e"ample, the s$itch on
the far left is $ired bet$een the first input (0.0) and LH. (hen the s$itch is closed, /3
7-C is applied to the input. his is referred to as a logic 6. (hen the s$itch is open, 0
7-C is applied to the input. his is referred to as a logic 0.
35 - 88

73t63ts:
#utput devices, such as relays, are connected to the terminal strip under the top cover of
the PLC. (hen testing a program, it is not necessary to connect output devices. he L%-
status indicators signal if an output is active.
76tional Connecto(:

An optional fan*out connector allo$s for field $iring connections to remain fi"ed $hen
removing or replacing a CPU //6 or CPU ///. he appropriate connector slides into
either the input, output, or e"pansion module terminals.
36 - 88

4emova*le Te(minal St(i6:
he CPU //3, CPU //3FP, and CPU //: do not have an optional fan*out connector.
&nstead, the terminal strips are removable. his allo$s the field $iring connections to
remain fi"ed $hen removing or replacing the PLC.
S36e(
Ca6acito(:
A super capacitor, so named because of its ability to maintain a charge for a long period
of time, protects data stored in >A+ in the event of a po$er loss. he >A+ memory is
typically bac!ed up on the CPU //6 and CPU /// for @0 hours, and on the CPU //3,
CPU //3 FP, and CPU //: for 600 hours.

3( - 88

4evie) 3:
38 - 88

Connectin !"ternal #e$ices:
3) - 88

TD200:+ -:5,

he S.*/00 programming port can be used to communicate $ith a variety of e"ternal
devices. #ne such device is the -/00 te"t display unit. he -/00 displays messages
read from the S.*/00, allo$s adGustment of designated program variables, provides the
ability to force, and permits setting of the time and date. he -/00 can be connected to
an e"ternal po$er supply or receive its po$er from the S.*/00.
0(ee6o(t :ode:
he programming port has a mode called freeport mode. =reeport mode allo$s
connectivity to various intelligent sensing devices such as a bar code reader.
P(inte(:
=reeport mode can also be used to connect to a non*S&+A&C Printer.
4* - 88

5nte(connection:
&t is possible to use one programming device to address multiple S.*/00 devices on the
same communication cable. A total of 26 units can be interconnected $ithout a repeater.
Prorammin a PLC:
S%P .*+icro1(&<2/ is the program soft$are used $ith the S.*/00 PLC to create the
PLC operating program. S%P . consists of a number of instructions that must be
arranged in a logical order to obtain the desired PLC operation. hese instructions are
41 - 88

divided into three groups8 standard instructions, special instructions, and high*speed
instructions.
Standa(d 5nst(3ctions:
A standard instruction consists of instructions that are found in most programs. Standard
instructions include8 timer, counter, math, logical, increment1decrement1invert, move, and
bloc! instructions.
S6ecial 5nst(3ctions:
Special instructions are used to manipulate data. Special instructions include8 shift, table,
find, conversion, for1ne"t, andreal*time instructions.
-ig&<S6eed 5nst(3ctions:
)igh*speed instructions allo$ for events and interrupts to occur independent of the PLC
scan time. hese include high*speed counters, interrupts, output, and transmit
instructions. &t is not the purpose of this te"t to e"plain all of the instructions and
capabilities. A fe$ of the more common instructions necessary for a basic understanding
of PLC operation $ill be discussed. PLC operation is limited only by the hard$are
capabilities and the ingenuity of the person programming it.
>efer to the 4IM5+IC 4(-2** Programma-le Controller 4.stem Manual for detailed
information concerning these instructions.
:ic(o>%5232:

he programming soft$are can be run #ff*line or #n*line. #ffline programming allo$s
the user to edit the ladder diagram and perform a number of maintenance tas!s. he PLC
does not need to be connected to the programming device in this mode. #n*line
programming re'uires the PLC to be connected to the programming device. &n this mode
program changes are do$nloaded to the PLC. &n addition, status of the input1output
elements can be monitored. he CPU can be started, stopped, or reset.
42 - 88

Sym*ols:
&n order to understand the instructions a PLC is to carry out, an understanding of the
language is necessary. he language of PLC ladder logic consists of a commonly used set
of symbols that represent control components and instructions.
Contacts:
#ne of the most confusing aspects of PLC programming for first*time users is the
relationship bet$een the device that controls a status bit and the programming function
that uses a status bit. $o of the most common programming functions are the normally
open (<#) contact and the normally closed (<C) contact. Symbolically, po$er flo$s
through these contacts $hen they are closed. he normally open contact (<#) is closed
$hen the input or output status bit controlling the contact is 6. he normally closed
contact (<C) is closed $hen the input or output status bit controlling the contact is 0.
Coils:
Coils represent relays that are energi,ed $hen po$er flo$s to them. (hen a coil is
energi,ed, it causes a corresponding output to turn on by changing the state of the status
bit controlling that output to 6. hat same output status bit may be used to control
normally open and normally closed contacts else$here in the program.

$o.es:
43 - 88

4o"es represent various instructions or functions that are e"ecuted $hen po$er flo$s to
the bo". ypical bo" functions are timers, counters, and math operations.

/nte(ing /lements:
Control elements are entered in the ladder
diagram by positioning the cursor and selecting the element from a lists. &n the follo$ing
e"ample the cursor has been placed in the position to the right of &0./. A coil $as selected
from a pull do$n list and inserted in this position.
An A2D 76e(ation:
%ach rung or net$or! on a ladder represents a logic operation. he follo$ing
programming e"ample demonstrates an A<- operation. $o contact closures and one
output coil are placed on net$or! 6. hey $ere assigned addresses &0.0, &0.6, and ?0.0.
<ote that in the statement list a ne$ logic operation al$ays begins $ith a load instruction
(L-). &n this e"ample &0.0 (input 6) and (A in the statement list) &0.6 (input /) must be
true in order for output ?0.0 (output 6) to be true. &t can also be seen that &0.0 and &0.6
must be true for ?0.0 to be true by loo!ing at the function bloc! diagram representation.
44 - 88
4tatement &ist 6epresentatie
2et#or7' 1
&D IO12
O IO13
8 3O11

Another $ay to see ho$ an A<- function $or!s is $ith a 4oolean logic diagram. &n
4oolean logic an A<- gate is represented by a number of inputs on the left side. &n this
case there are t$o inputs. he output is represented on the right side. &t can be seen from
the table that both inputs must be a logic 6 in order for the output to be a logic 6.
An 74 76e(ation:
&n this e"ample an #> operation is used in net$or! 6. &t can be seen that if either input
&0./ (input 2) or (# in the statement list) input &0.2 (input 3), or both are true, then output
?0.6 (output /) $ill be true.
45 - 88
"unction /loc7 Diagram 6epresentatie1
2et#or7' 1
IO13
IO12
3O11

Another $ay to see ho$ an #> function $or!s is $ith a 4oolean logic diagram. he
symbol differs slightly from an A<- function. he #> function is represented by a
number of inputs on the left side. &n this case there are t$o inputs. he output is
represented on the right side. &t can be seen from the table that any input can be a logic 6
in order for the output to be a logic 6.
Testing a P(og(am:

#nce a program has been $ritten it needs to be tested and debugged. #ne $ay this can be
done is to simulate the field inputs $ith an input simulator, such as the one made for the
S.*/00. he program is first do$nloaded from the programming device to the CPU. he
selector s$itch is placed in the >U< position. he simulator s$itches are operated and
the resulting indication is observed on the output status indicator lamps.
46 - 88
IO12

O6
IO13
3O11
"unction /loc7 Diagram 6epresentatie1
2et#or7' 1


Stat3s 03nctions:
After a program has been loaded and is running in the PLC, the actual status of ladder
elements can be monitored using S%P . +icro1(&<2/ soft$are. he standard method
of sho$ing a ladder element is by indicating the circuit condition it produces $hen the
device is in the deenergi,ed or non*operated state. &n the follo$ing illustration input 6
(&0.0) is programmed as a normally open (<#) contact. &n this condition, po$er $ill not
flo$ through the contacts to the output (?0.0).
(hen vie$ing the ladder diagram in the status mode, control elements that are active, or
true (logic 6), are highlighted. &n the e"ample sho$n the toggle s$itch connected to input
6 has been closed. Po$er can no$ flo$ through the control element associated $ith input
6 (&0.0) and activate the output (?0.0). he lamp $ill illuminate.
4( - 88

0o(cing:
=orcing is another useful tool in the commissioning of an application. &t can be used to
temporarily override the input or output status of the application in order to test and
debug the program. he force function can also be used to override discrete output points.
he force function can be used to s!ip portions of a program by enabling a Gump
instruction $ith a forced memory bit. Under normal circumstances the toggle s$itch,
sho$n in the illustration belo$, $ould have to be closed to enable input 6 (&0.0) and turn
on the output light. =orcing enables input 6 even though the input toggle s$itch is open.
(ith input 6 forced high the output light $ill illuminate. (hen a function is forced the
control bit identifier is highlighted. he element is also highlighted because it is on.
he follo$ing table sho$s the appearance of ladder elements in the #ff, forced, and #n
condition.
48 - 88

#iscrete %np&ts'O&tp&ts
o understand discrete control of a programmable controller the same simple lamp circuit
illustrated $ith forcing $ill be used. his is only for instructional purposes as a circuit
4) - 88

this simple $ould not re'uire a programmable controller. &n this e"ample the lamp is off
$hen the s$itch is open and on $hen the s$itch is closed.
%i(ing:
o accomplish this tas!, a s$itch is $ired to the input of the PLC and an indicator light is
$ired to output terminal.
5* - 88

he follo$ing dra$ing illustrates the se'uence of events. A s$itch is $ired to the input
module of the PLC. A lamp is $ired to the output module. he program is in the CPU.
he CPU scans the inputs. (hen it finds the s$itch open &0.0 receives a binary 0. his
instructs ?0.0 to send a binary 0 to the output module. he lamp is off. (hen it finds the
s$itch closed &0.0 receives a binary 6. his instructs ?0.0 to send a binary 6 to the output
module, turning on the lamp.
P(og(am 5nst(3ction:
(hen the s$itch is open the CPU receives a logic 0 from input &0.0. he CPU sends a
logic 0 to output ?0.0 and the light is off.
(hen the s$itch is closed the CPU receives a logic 6 from input &0.0.he CPUsends a
logic 6 to output?0.0, thus activating ?0.0.he light turns on.
:oto( Sta(te( /.am6le:
51 - 88

he follo$ing e"ample involves a motor start and stop circuit. he line diagram
illustrates ho$ a normally open and a normally closed pushbutton might be used in a
control circuit. &n this e"ample a motor started (+) is $ired in series $ith a normally
open momentary pushbutton (Start), a normally closed momentary pushbutton (Stop), and
the normally closed contacts of an overload relay (#L).
+omentarily depressing the Start pushbutton completes the path of current flo$ and
energi,es the motor starter (+).
his closes the associated + and +a (au"iliary contact located in the motor starter)
contacts. (hen the Start button is released a holding circuit e"ists to the + contactor
through the au"iliary contacts +a. he motor $ill run until the normally closed Stop
52 - 88

button is depressed, or the overload relay opens the #L contacts, brea!ing the path of
current flo$ to the motor starter and opening the associated + and +a contacts.
+%is control tas7 can also -e accomplis%ed #it% a P&C1
P(og(am 5nst(3ction:
A normally open Start pushbutton is $ired to the first input (&0.0), a normally closed Stop
pushbutton is $ired to the second input (&0.6), and normally closed overload relay
53 - 88

contacts (part of the motor starter) are connected to the third input (&0./). he first input
(&0.0), second input (&0.6), and third input (&0./) form an A<- circuit and are used to
control normally open programming function contacts on <et$or! 6. &0.6 status bit is a
logic 6 because the normally closed (<C) Stop Pushbutton is closed. &0./ status bit is a
logic 6 because the normally closed (<C) overload relay (#L) contacts are closed. #utput
?0.0 is also programmed on <et$or! 6. &n addition, a normally open se of contacts
associated $ith ?0.0 is programmed on <et$or! 6 to form an #> circuit. A motor starter
is connected to output ?0.
(hen the Start pushbutton is depressed the CPU receives a logic 6 from input &0.0. his
causes the &0.0 contact to close. All three inputs are no$ a logic 6.he CPUsends a logic6
to output ?0.0.he motor starter is energi,ed and the motor starts.

(hen the Start pushbutton is pressed, output ?0.0 is no$ true and on the ne"t scan, $hen
normally open contact ?0.0 is solved, the contact $ill close and output ?0.0 $ill stay on
even if the Start pushbutton has been released.
54 - 88

he motor $ill continue to run until the Stop pushbutton is depressed. &nput &0.6 $ill no$
be a logic 0 (false). he CPU $ill send a binary 0 to output ?0.0. he motor $ill turn off.
(hen the Stop pushbutton is released &0.6 logic function $ill again be true and the
program ready for the ne"t time the Start pushbutton is pressed.
55 - 88

/.6anding t&e A66lication
he application can be easily e"panded to include indicator lights for >U< and S#P
conditions. &n this e"ample a >U< indicator light is connected to output ?0.6 and a
S#P indicator light is connected to output ?0./.
&t can be seen from the ladder logic that a normally open output ?0.0 is connected on
<et$or! / to output ?0.6 and a normally closed ?0.0 contact is connected to output ?0./
on net$or! 2. &n a stopped condition output ?0.0 is off. he normally open ?0.0 contacts
on <et$or! / are open and the >U< indicator, connected to output ?0.6 light is off. he
56 - 88

normally closed ?0.6 on <et$or! 2 lights are closed and the S#P indicator light,
connected to output ?0./ is on.
Adding a Limit S)itc&:

Adding a limit s$itch $ith normally open contacts to input &0.2 can further e"pand the
application.
A limit s$itch could be used to stop the motor or prevent the motor from being started.
An access door to the motor, or its associated e'uipment, is one e"ample of a limit
s$itchCs use. &f the access door is open, the normally open contacts of LS6connected to
input &0.2 are open and the motor $ill not start.
5( - 88

(hen the access door is closed, the normally open contacts on the limit s$itch (LS6) are
closed. &nput &0.2 is no$ on (logic 6), and the motor $ill start $hen the Start pushbutton
is pressed.
/.6ansion:
he PLC program can be e"panded to accommodate many commercial and industrial
applications. Additional Start1Stop pushbuttons and indicator lights can be added for
remote operation, or control of a second motor starter and motor. #ver travel limit
s$itches can be added along $ith pro"imity s$itches for sensing obGect position. &n
58 - 88

addition, e"pansion modules can be added to further increase the &1# capability. he
applications are only limited by the number of &1#s and amount of memory available on
the PLC.
4evie) 4:
5) - 88


6* - 88

(nalo %np&ts and O&tp&ts:
PLs must also work with continuous or analog signals. Typical
analog signals are - ( 6- 7$ or / ( .- m!. !nalog signals
are used to represent changing "alues such as speed,
temperature, weight, and le"el. ! PL cannot process these
signals in an analog form. The PL must con"ert the analog
signal into a digital representation. !n e8pansion module,
capable of con"erting the analog signal, must be used. The
%'(.-- analog modules con"ert standard "oltage and
current analog "alues into a 6.(bit digital representation.
The digital "alues are transferred to the PL for use in
register or word locations.
%n addition) analo mod&les are a$ailable for &se *it+ t+ermoco&ple and
,T# t-pe sensors &sed in to ac+ie$e a +i+ le$el of acc&rac- in
temperat&re meas&rement.
61 - 88

A66lication /.am6le:
A field device that measures a varying value is typically connected to a transducer. &n the
follo$ing e"ample a scale is connected to a load cell. A load cell is a device that ta!es a
varying value and converts it to a variable voltage or current output. &n this e"ample the
load cell is converting a value of $eight into a 0 * 60 7-C output. he output value
depends entirely on the manufactured specifications for the device. his load cell outputs
0 * 60 7-C for a 0 * @00 Lbs input. he 0 I 60 7-C load cell output is connected to the
input of an analog e"pansion module.
he e"ample application can be e"panded to include a conveyor system $ith a gate to
direct pac!ages of varying $eight. As pac!ages move along the conveyor they are
$eighed. A pac!age that $eighs at or greater than a specified value is routed along one
conveyor path. A pac!age that $eighs less than a specified value is routed along another
conveyor path, $here it $ill later be inspected for missing contents.
Analog 73t63ts:
62 - 88

Analog outputs are used in applications re'uiring control capability of field
devices $hich respond to continuous voltage or current levels. Analog
outputs may be used as a variable reference for control valves, chart
recorders, electric motor drives, analog meters, and pressure transducers.
Li!e analog inputs, analog outputs are generally connected to a controlling
device through a transducer. he transducer ta!es the voltage signal and,
depending on the re'uirement, amplifies, reduces, or changes it into another
signal $hich controls the device. &n the follo$ing e"ample a 0 * 60 7-C
signal controls a 0 * @00 Lbs. scale analog meter.
Timers:
63 - 88

imers are devices that count increments of time. raffic lights are one e"ample $here
timers are used. &n this e"ample timers are used to control the length of time bet$een
signal changes.
imers are represented by bo"es in ladder logic. (hen a timer receives an enable, the
timer starts to time. he timer compares its current time $ith the preset time. he output
of the timer is a logic 0 as long as the current time is less than the preset time. (hen the
current time is greater than the preset time the timer output is a logic 6. S.*/00 uses three
types of timers8 #n* -elay (#<), >etentive #n*-elay (#<>), and #ff*-elay (#=).
S!<200 Time(s:
S.*/00 timers are provided $ith resolutions of 6 millisecond, 60 milliseconds, and 600
milliseconds. he ma"imum value of these timers is 2/..:. seconds, 2/..:. seconds, and
64 - 88

2/.:.. seconds, respectively. 4y adding program elements, logic can be programmed for
much greater time intervals.
-a(d<%i(ed Timing Ci(c3it:
imers used $ith PLCs can be compared to timing circuits used in hard*$ired control line
diagrams. &n the follo$ing e"ample, a normally open (<#) s$itch (S6) is used $ith a
timer (>6). =or this e"ample the timer has been set for @ seconds. (hen S6 is closed,
>6 begins timing. (hen @ seconds have elapsed, >6 $ill close its associated normally
open >6 contacts, illuminating pilot light PL6. (hen S6 is open, deenergi,ing >6, the
>6 contacts open, immediately e"tinguishing PL6. his type of timer is referred to as
#< delay. #< delay indicates that once a timer receives an enable signal, a
predetermined amount of time (set by the timer) must pass before the timerCs contacts
change state.
7n<Delay +T72,:
(hen the #n*-elay timer (#<) receives an enable (logic 6) at its input (&<), a
predetermined amount of time (preset time * P) passes before the timer bit (*bit) turns
on. he *bit is a logic function internal to the timer and is not sho$n on the symbol. he
timer resets to the starting time $hen the enabling input goes to a logic 0.
&n the follo$ing simple timer e"ample, a s$itch is connected to input &0.2, and a light is
connected to output ?0.6.
65 - 88

(hen the s$itch is closed input 3 becomes a logic 6, $hich is loaded into timer 2.. 2.
has a time base of 600 ms (.600 seconds). he preset time (P) value has been set to 6@0.
his is e'uivalent to 6@ seconds (.600 " 6@0 ). he light $ill turn on 6@ seconds after the
input s$itch is closed. &f the s$itch $ere opened before 6@ seconds had passed, then
reclosed, the timer $ould again begin timing at 0.
A small sample of the fle"ibility of PLCs is sho$n in the follo$ing program logic. 4y
reprogramming the 2. contact as a normally closed contact, the function of the circuit is
66 - 88

changed to cause the indicator light to turn off only $hen the timer times out. his
function change $as accomplished $ithout changing or re$iring &1# devices.
4etentive 7n<Delay +T724,:

he >etentive #n*-elay timer (#<>) functions in a similar manner to the #n*-elay
timer (#<). here is one difference. he >etentive #n*-elay timer times as long as the
enabling input is on, but does not reset $hen the input goes off. he timer must be reset
$ith a >%S% (>) instruction.

he same e"ample used $ith the #n*-elay timer $ill be used $ith the >etentive #n*
-elay timer. (hen the s$itch is closed at input &0.2, timer @ (>etentive timer) begins
timing. &f, for e"ample, after 60 seconds input &0.2 is opened the timer stops. (hen input
&0.2 is closed the timer $ill begin timing at 60 seconds. he light $ill turn on @ seconds
6( - 88

after input &0.2 has been closed the second time. A >%S% (>) instruction can be added.
)ere a pushbutton is connected to input &0./. &f after 60 seconds input &0.2 $ere opened,
@ can be reset by momentarily closing input &0./. @ $ill be reset to 0 and begin timing
from 0 $hen input &0.2 is closed again.
7ff<Delay +T70,:
he #ff*-elay timer is used to delay an output off for a fi"ed period of time after the
input turns off. (hen the enabling bit turns on the timer bit turns on immediately and the
value is set to 0. (hen the input turns off, the timer counts until the preset time has
elapsed before the timer bit turns off.


S!<200 Time(s:
he S.*/00s have /@: timers. he specific number chosen for the timer determines its
time base and $hether it is #<, #<>, or #=.
68 - 88

Time( /.am6le:
&n the follo$ing e"ample a tan! $ill be filled $ith t$o chemicals, mi"ed, and then
drained. (hen the Start 4utton is pressed at input &0.0, the program starts pump 6
controlled by output ?0.0. Pump 6 runs for @ seconds, filling the tan! $ith the first
chemical, then shuts off. he program then starts pump /, controlled by output ?0.6.
Pump / runs for 2 seconds filling the tan! $ith the second chemical. After 2 seconds
pump / shuts off. he program starts the mi"er motor, connected to output ?0./ and
mi"es the t$o chemicals for :0 seconds. he program then opens the drain valve
controlled by output ?0.2, and starts pump 2 controlled by output ?0.3. Pump 2 shuts off
after 9 seconds and the process stops. A manual Stop s$itch also provided at input &0.6.
6) - 88

4evie) 5:
(* - 88

Co&nters:
Counters used in PLCs serve the same function as mechanical
counters. Counters compare an accumulated value to a
preset value to control circuit functions. Control
applications that commonly use counters include the
following:
ount to a preset "alue and cause an e"ent to occur
ause an e"ent to occur until the count reaches a preset "alue
! bottling machine, for e8ample, may use a counter to count bottles into
groups of si8 for packaging.
(1 - 88

Counters are represented by bo"es in ladder logic. Counters increment1decrement one
count each time the input transitions from off (logic 0) to on (logic 6). he counters are
reset $hen a >%S% instruction is e"ecuted. S.*/00 uses three types of counters8 up
counter (CU), do$n counter (C-), and up1do$n counter (CU-).
S!<200 Co3nte(s:
here are /@: counters in the S.*/00, numbered C0 through C/@@. he same number
cannot be assigned to more than one counter. =or e"ample, if an up counter is assigned
number 3@, a do$n counter cannot also be assigned number 3@. he ma"imum count
value of a counter is J2/,.:..
86 Co3nte(:
he up counter counts up from a current value to a preset value (P7). &nput CU is the
count input. %ach time CU transitions from a logic 0 to a logic 6 the counter increments
by a count of 6. &nput > is the reset. A preset count value is stored in P7 input. &f the
current count is e'ual to or greater than the preset value stored in P7, the output bit (?)
turns on (not sho$n).

Do)n Co3nte(:
(2 - 88

he do$n counter counts do$n from the preset value (P7) each time C- transitions from
a logic 0 to a logic 6. (hen the current value is e'ual to ,ero the counter output bit (?)
turns on (not sho$n). he counter resets and loads the current value $ith the preset value
(P7) $hen the load input (L-) is enabled.
86>Do)n Co3nte(:
he up1do$n counter counts up or do$n from the preset value each time either C- or CU
transitions from a logic 0 to a logic 6. (hen the current value is e'ual to the preset value,
the output ?U turns on. (hen the current value (C7) is e'ual to ,ero, the output ?-
turns on. he counter loads the current value (C7) $ith the preset value (P7) $hen the
load input (L-) is enabled. Similarly, the counter resets and loads the current value (C7)
$ith ,ero $hen the reset (>) is enabled. he counter stops counting $hen it reaches preset
or ,ero.
Co3nte( /.am6le:
(3 - 88

A counter might be used to !eep trac! of the number of vehicles in a par!ing lot. As
vehicles enter the lot through an entrance gate, the counter counts up. As vehicles e"it the
lot through an e"it gate, the counter counts do$n. (hen the lot is full a sign at the
entrance gate turns on indicating the lot is full.
Up1do$n counter C39 is used in this e"ample. A s$itch, connected to the entrance gate,
has been $ired to input &0.0. A s$itch, connected to the e"it gate, has been $ired to input
&0.6. A reset s$itch, located at the collection booth, has been $ired to input &0./. he
par!ing lot has 6@0 par!ing spaces. his value has been stored in the preset value (P7).
he counter output has been directed to output ?0.6. #utput / is connected to a KPar!ing
Lot =ullL sign. As cars enter the lot the entrance gate opens. &nput &0.0 transitions from a
logic 0 to a logic 6, incrementing the count by one. As cars leave the lot the e"it gate
opens. &nput &0.6 transitions from a logic 0 to a logic 6, decrementing the count by 6.
(hen the count has reached 6@0 output ?0.6 transitions from a logic 0 to a logic 6. he
KPar!ing Lot =ullL sign illuminates. (hen a car e"its, decrementing the count to 63E, the
sign turns off.

Hi+-Speed %nstr&ctions:
(4 - 88

!s discussed earlier, PLs ha"e a scan time. The scan time
depends on the si9e of the program, the number of I)1s,
and the amount of communication re#uired. E"ents may
occur in an application that re#uire a response from the PL
before the scan cycle is complete. :or these applications
high(speed instructions can be used.
-ig&<S6eed Co3nte(s:
)igh*speed counters are represented by bo"es in ladder logic. CPU 221 and CPU 222
support four high*speed counters 9:4C*, :4C3, :4C4, :4C5;1 CPU 224, CPU 224<P,
and CPU 226 support si" high*speed counters 9:4C*, :4C1, :4C2, :4C3, :4C4,
:4C5;1
Definition $o.es and -ig&<S6eed Co3nte(s:
he high*speed counter definition bo"es are used to assign a mode to the counter. )igh*
speed counters can be defined by the definition bo" to operate in any of the t$elve
(5 - 88

available modes. &t should be noted that not all counters can operate in all of the available
modes. %ach counter has dedicated inputs for cloc!s, direction control, reset, and start
$here these functions are supported.
Positioning:
Positioning is one e"ample of an application that can use high*speed counters. &n the
follo$ing illustration a motor is connected through a starter to a PLC output. he motor
shaft is connected to an encoder and a positioning actuator. he encoder emits a series of
pulses as the motor turns. &n this e"ample the program $ill move an obGect from position
6 to position :. Assume the encoder generates :00 pulses per revolution, and it ta!es 6000
motor revolutions to move the obGect from one position to another. o move the obGect
from position 6 to position : (@ positions) $ould ta!e @000 motor revolutions. he
counter $ould count up 20,000 counts (@000 revolutions " :00 pulses per revolution) and
stop the motor.

5nte((36ts:
&nterrupts are another e"ample of an instruction that must be e"ecuted before the PLC has
completed the scan cycle. &nterrupts in the S.*/00 are prioriti,ed in the follo$ing order8
(. Communications
!. I56 Interrupts
$. Time4ased Interrupts
PT7:
Pulse rain #utput (P#) is used to provide a series of pulses to an output device, such as
a stepper motor driver. he P# provides a s'uare $ave output for a specified number of
pulses and a specified cycle time. he number of pulses can be from 6 to 3,/E3,E:.,/E@
pulses. P#s have a @0M duty cycle. his means the pulse is off for the same amount of
time it is on. he number of pulses and the cycle time can be changed $ith an interrupt.
(6 - 88

&n the follo$ing e"ample each pulse is on for @00 ms, and off for @00 ms. After four
pulses an interrupt occurs $hich changes the cycle time to 6000 ms.
P%::
he Pulse (idth +odulation (P(+) function provides a fi"ed cycle time $ith a variable
duty cycle time. (hen the pulse $idth is e'ual to the cycle time, the duty cycle is 600M
and the output is turned on continuously. &n the follo$ing e"ample the output has a 60M
duty cycle (on 60M off E0M). After an interrupt the cycle s$itches to a @0M duty cycle
(on @0M, off @0M).
he P(+ function can be used to provide a programmable or adGustable control of
machine timing. his allo$s machine operation to be varied to compensate for product
variations or mechanical $ear.
T(ansmit:

ransmit allo$s communication $ith e"ternal devices, such as modems, printers,
computers, via the serial interface. See the section titled KConnecting %"ternal -evicesL
for e"amples.
Speciali/ed !"pansion Mod&les:
In addition to I56 modules# e,pansion modules are availa'le -or
the S7!"" that measure temperature# controlpositionin&
applications# and provide various communication -unctions.
/: 241:
(( - 88

&n any comple" system communication is essential. +odems are electronic devices used
for sending and receiving data over long distances. he %+ /36 is an e"pansion module
that supports communication bet$een an S.*/00 PLC and S%P . +icro1(&< via a
modem.
he %+ /36 provides an international telephone line interface, supports sending numeric
and te"t paging messages, as $ell as S+S (Short +essage Service) messages to cellular
phones. his is useful for remote diagnostics and maintenance, machine control, alarm
systems, and general communication functions.
&n addition to CPU*to*CPU communication via a telephone line, the %+ /36 also
supports the +od4us >U protocol. Protocols are rules that identify ho$ devices should
communicate $ith each other. +od4us >U is a protocol originally developed by
+#-&C#<, $hich is no$ part of Schneider Automation. +od4us >U has been $idely
used by other companies.
CP 243<1, CP 243<1 5T:
&ndustrial %thernet provides a proven means of net$or!ing computers and a variety of
intelligent devices. CP /32*6 and CP /32*6 & are communication processors used to
connect the 4(-2** system to &ndustrial %thernet.

he S.*/00 can be remotely configured, programmed, and diagnosed via &ndustrial
%thernet using S%P . +icro1(&<. he S.*/00 can also communicate $ith other S.*
/00, S.*200, and S.*300 PLCs and a variety of other devices using &ndustrial %thernet.
(8 - 88

he & functions of the CP /32*6 & &nternet module simplify the process of setting up a
control system that can email diagnostic information or transfer files using &nternet
protocols.
/: 2!!:
&nformation flo$ bet$een intelligent devices such as PLCs, computers, variable speed
drives, actuators, and sensors is often accomplished through a local area net$or! (LA<).
LA<s are used in office, manufacturing, and industrial areas.
&n the past, these net$or!s $ere often proprietary systems designed to a specific vendorCs
standards. Siemens has been a leader in pushing the trend to open systems based upon
international standards developed through industry associations. P>#=&4US*-P and
Actuator Sensor &nterface (ASi) are e"amples of these open net$or!s.
he P>#=&4US*-P %+ /.. module allo$s connection of the S.*/00 CPU to a
P>#=&4US*-P net$or! as a slave. he CP /32*/ Communication Processor allo$s
communication bet$een AS*i devices and an S.*/00.
P4705$8S DP:
P>#=&4US -P is an open bus standard for a $ide range of applications in various
manufacturing and automation processes. P>#=&4US -P $or!s at the field device level
such as po$er meters, motor protectors, circuit brea!ers, and lighting controls. hrough
P>#=&4US -P the features of S.*/00 PLCs can be used to their full e"tent $ithin a
distributed system. An advantage to P>#=&4US -P is the ability to communicate
bet$een P>#=&4US -P devices of different vendors. his provides uniform
communication bet$een all S&+A&C devices on the P>#=&4US -P net$or! as $ell as
devices from other manufacturers.
() - 88

AS<5:
Actuator Sensor &nterface (AS*i or AS*&nterface) is a system for net$or!ing binary
devices such as sensors. Until recently, e"tensive parallel control $iring $as needed to
connect sensors to the controlling device. AS*i replaces comple" $iring $ith a simple /*
core cable. he cable is designed so that devices can only be connected correctly. Several
devices can be connected to the cable.
PLCs, for e"ample, use &1# modules to receive inputs from binary devices such as
sensors. 4inary outputs are used to turn on or off a process as the result of an input.
8* - 88

/: 253:
Position control describes a range of applications that involve movement $ith varying
degrees of precision. >otary tables and traversing cars are e"amples $here obGects are
moved from one position during a productCs manufacturing process.
he %+ /@2 is a positioning module that enables the user to control the speed and
position for either stepper motors or servo motors. he %+ /@2 interfaces bet$een an S.*
/00 PLC and the stepper1servo motorCs po$er control module.
/: 253 0eat3(es:
he %+ /@2 provides functionality for single*a"is, open*loop position control. =eatures
of the module include8
)igh*speed control $ith a range of 6/ * /00,000 pulse per second
Ner! (S curve) or linear acceleration1deceleration
Configurable measuring system to enter data as engineering units (such as
inches or centimeters) or number of pulses
Configurable bac!lash compensation
Supports absolute, relative, and manual methods of position control
81 - 88

Continuous operation
Provides up to /@ motion profiles $ith up to 3 speed changes per profile
=our different reference*point see! modes, $ith a choice of the starting see!
direction and final approach direction for each se'uence
,e$ie* 0:
82 - 88

,e$ie* (ns*ers

83 - 88

4evie) 1:

1) a: input module, b: CPU, c: output module, d: programming device, e:
operator interface; ) ; !) 1"; #) 1$1$, $$$1 $$$$, %&
4evie) 2:
1) 'iscrete; ) discrete; !) CPU; #) Ladder logic; () program; ")
program, data, configurable parameter; )) 1$#; *) firm+are;
,) e; 1$) R-.#*(&
4evie) 3:
1) 1, , #, #/P, "; ) b; !) , ); #) *, "; () 1#, 1$; ")
0$&!; )) '12&
4evie) 4:
) a: bo3, b: contact, c: coil; ) %2' 4unction . a: $, b: $, c: $, d: 1,
1) 5r 4unction . e: $, f: 1, g: 1, 6: 1; !) 1$&$ or 0$&$, and 1$&1&
4evie) 5
1) 'igital; ) retentive, off; !) !)"&) seconds; #) ($; () ("&
4evie)
1) ("; ) C7U, C7', C7U'; !) 8!,)"); #) 6ig6.speed; () 1; ") CP
#!. Communication Processor; )) 9: (!&
1inal !"am:
76e final e3am is intended to be a learning tool& 76e boo; ma< be used
during t6e e3am& % tear.out ans+er s6eet is provided& %fter completing
t6e test, mail t6e ans+er s6eet in for grading& % grade of )$= or
84 - 88

better is passing& Upon successful completion of t6e test a certificate
+ill be issued&
1' The component o- a PLC that makes decisions and e,ecutes control
instructions 'ased on the input si&nals is the 777777777777.
a. CPU -. &nput module
c1 Programming device d. #perator interface
2' 6ne 'yte is made up o- 777777777777 .

a' ! 'its *. 8 'its
c. (9 'its d' $! 'its
3' The 'inary e2uivalent o- a decimal : is 777777777777 .
a. (( *. (""
c' ("( d' (((
4' An input that is either 6n or 6-- is a5an 777777777777 input.
a' analo& * discrete
c' hi&hspeed d. normally open
5' A pro&rammin& lan&ua&e that uses sym'ols resem'lin& elements used in
hard.ired control line dia&rams is re-erred to as a 777777777777 .
a. ladder lo&ic dia&ram *' statement list
c' net.ork d' PLC scan
. A type o- memory that can 'e read -rom 'ut not .ritten to is
777777777777 .
a. ;AM *' ;6M
c. -irm.are d. < memory
85 - 88

!. A 0S45PPI MultiMaster ca'le connects a personal computer=s 0S4
inter-ace to a5an 777777777777 connector on an S7!"" CP0.
a' ;S%8: *' ;S!$!
c. +thernet d. P;6FI40S*P
"' The CP0 !!% AC5*C5;+LA> has 777777777777 .
a' 8 *C inputs and (" relay outputs
*. 8 AC inputs and 9 relay outputs
c' (% *C inputs and (% relay outputs
$' (% *C inputs and (" relay outputs
#. CP0 !!% .ill accept up to 777777777777 e,pansion modules.
a. none *. 7
c. (" d' $"
10. The S7!!! has the a'ility to store 777777777777 <'ytes in user data.
a' % *' 8
c' ! d' :
11' ?hich o- the -ollo.in& is not part o- a PLC scan@
a. ;ead Inputs *' +,ecute Pro&ram
c' Force Interrupts d. 0pdate 6utputs
12' The address desi&nation -or output -our o- an S7!"" is 777777777777 .
a. I".% *' I".$
c' A".$ d' A".%
13' CP0 !!( and CP0 !!! provide 777777777777 hi&hspeed counters .
86 - 88

a' t.o *' three
c. -our d' -ive
14' The ma,imum value o- an S7!"" timer .ith a resolution o- ( millisecond
is 777777777777 seconds.
a. $.!797 *' $!.797
c. $!7.97 d. $!79.7
15. An S7!"" timer .ith a time 'ase o- ("" ms can count to a ma,imum
value o- 777777777777 seconds.
a' $.!797 *' $!.797
c' $!7.97 d' $!79.7
1' The time 'ase o- T6B $! o- is 777777777777 ms.
a' ( *' ("
c' ( d' (""
1!' The ma,imum count o- an S7!"" up counter is 777777777777 .
a' $!#797 *' 9:#:$%
c' C8#$"( d' (#"""#"""
1". A5An 777777777777 is used to assi&n a mode to a hi&hspeed counter.
a' to&&le s.itch *' interrupt
c' PLC scan d' de-inition 'o,
1#' 777777777777 instructions allo.s communication .ith e,ternal devices#
such as modems# printers# and computers.
a' Transmit *' Interrupt
c' Di&hspeed counters d' Di&hspeed outputs
8( - 88

20' 777777777777 is used to temporarily override the input or output status in
order to test and de'u& the pro&ram.
a' Transmit *' Forcin&
c' Interrupt d' PLC scan
88 - 88

You might also like