49
Introduction: Programmable logic controllers (PLC) have been evolved out from Relay logic circuits (RLC). A typical RLC circuit is as shown in Fig 1.1 As seen the logic circuits are hard wired. When the process became complicated and automation level increased so did the circuits. These RLC’s had many drawbacks. Viz., 1. Circuits were bulky: a. Apart from relays, external components like counters, timers etc. were to be used. b. Relays had limited number of auxiliary contacts. Hence if the circuits demanded for more contacts, then additional relays (Aux relays) were to be used in parallel to actual relays (e.g. R12 in Fig1.1). Hence more relays were required. 2. Troubleshooting was very difficult. a. If a particular relay was not becoming ON (e.g. R1 in Fig.1.1), the entire loop had to be traced from one point to other. A rather tedious process. 3. Inflexible: a. Logics were built on hardwired circuits. Hence any changes in the logic, the wiring had to be changed. In some cases it would be impossible, as the required contacts (Normally open (NO) / Normally closed (NC) would not be available. Page 1 of 49 L1 L2 PB1 PB2 R1 R12 R12 Fig 1.1 L1-L2 Control Voltage (AC/DC) PB1 Start Pushbutton PB2 Stop Pushbutton R1 Relay R12 Auxiliary relay Circuit Functioning: When PB1 is pressed, R1 & R12 coils pickup. This makes R12 Normally open (NO) Contact to close. Once R12 contact closes even if PB1 is released, R12 will remain ON as there is an alternative path for the coil (Termed as Latching). The only way to break the latch is

Plc for Beginners

Embed Size (px)

Citation preview

Page 1: Plc for Beginners

Introduction:

Programmable logic controllers (PLC) have been evolved out from Relay logic circuits (RLC). A typical RLC circuit is as shown in Fig 1.1

As seen the logic circuits are hard wired. When the process became complicated and automation level increased so did the circuits. These RLC’s had many drawbacks. Viz.,

1. Circuits were bulky:a. Apart from relays, external components like counters, timers etc.

were to be used.b. Relays had limited number of auxiliary contacts. Hence if the circuits

demanded for more contacts, then additional relays (Aux relays) were to be used in parallel to actual relays (e.g. R12 in Fig1.1). Hence more relays were required.

2. Troubleshooting was very difficult.a. If a particular relay was not becoming ON (e.g. R1 in Fig.1.1), the

entire loop had to be traced from one point to other. A rather tedious process.

3. Inflexible:a. Logics were built on hardwired circuits. Hence any changes in the

logic, the wiring had to be changed. In some cases it would be impossible, as the required contacts (Normally open (NO) / Normally closed (NC) would not be available.

4. If the logic were complicated, sometimes it would not be feasible to build a RLC.

To overcome the above drawbacks, a new product called the PROGRAMMABLE LOGIC CONTROLLERS (PLC) Emerged.

Page 1 of 40

L1

L2

PB1

PB2

R1 R12

R12

Fig 1.1

L1-L2 Control Voltage (AC/DC)PB1 Start PushbuttonPB2 Stop PushbuttonR1 RelayR12 Auxiliary relay

Circuit Functioning:When PB1 is pressed, R1 & R12 coils pickup. This makes R12 Normally open (NO) Contact to close. Once R12 contact closes even if PB1 is released, R12 will remain ON as there is an alternative path for the coil (Termed as Latching). The only way to break the latch is to press PB2.

Page 2: Plc for Beginners

Programmable logic controller (PLC) is a solid-state device, basically designed to perform logical decision making for industrial control application. Since their development in early 1970’s, PLC’s have evolved to challenge not only relays but also other discrete control devices such as stepping switches, drum sequencers etc.

The PLC’s is composed of electronic circuit with a microcomputer centered. However, it can be equivalently regarded as an integrated body of ordinary relay, timer, counter etc.

The block diagram of a PLC is as shown in Fig 1.2:

Power Supply: It is basically required for the circuits of the PLC to function. These power supplies are designed and rated only to operate the internal structure and not the field elements. The external supply to the PLC can be AC/DC and can be of different ranges, but the PLC power supply converts these to the appropriate voltages required for internal functioning of the PLC circuits.

The common voltages are:AC: 110v, 220vDC: +24v, 110v

Processor: This is the heart of the PLC. It interfaces the input and output subsystems through software written to it. The input and output subsystems are explained in the preceding discussions.

INPUT SUB SYSTEM:

Page 2 of 40

POWER SUPPLY

PROCESSOR

INPUTS

OUTPUTS

P L CRELAY COIL

LAMP

SOLENOID COIL

NO CONTACT

PUSHBUTTONNC CONTACT

PUSHBUTTON

NC CONTACT SWITCH

Fig 1.2

Page 3: Plc for Beginners

The sensing elements (input elements) are wired to the input section of the PLC. These elements sense the dynamic status of the machine operation or process.Inputs are classified into two:

1. Digital2. Analog

1. Digital inputs: These inputs have only two states, viz., ON or OFF (digitally 1 or 0). Therefore

these are also called as discrete inputs. Elements used to give the various commands for e.g. Push buttons, Limit switches, Selector switches, Proximity switches, Level switches and Pressure switches etc. are directly connected to the input of the PLC.

2 . Analog inputs: These inputs have multiple states and rather continuously changing one and are having a range of values. Electrically these are categorized into two:

i) Voltage : The commonly used ranges are 1. 0 to 10 Vdc -unipolar 2. –10 to +10 Vdc -bipolar 3. 0 to 5Vdcii) Current : The commonly used ranges are 1. 0 to 20mA

2. 4 to 20mA

The field parameters like pressure, flow, temperature etc are converted to electrical parameters through transducers and are converted further to the above voltage / current signals through transmitters. The output of transmitters is then connected to analog inputs of the PLC. The PLC in turn converts these voltage / current signals to their equivalent digital values through the analog to digital convertors. Typical example is shown below

The most commonly used range is 4-20mA, as it has no voltage drop for longer distances and wire cut can be detected as the minimum signal voltage is 4mA.

OUTPUT SUB SYSTEMS:

Page 3 of 40

Process TransmitterAnalog Input of

PLCRange: 0 to 10 kg/cm2

Pressure to resistance Transducer

Resistance to 4-20 mA

4-20 mA to 4000-20000 counts

Page 4: Plc for Beginners

The actuating elements (output elements) are wired to the output section.Output are classified into two:1.Digital2.Analog

1.Digital Output: These have only two states, viz., ON or OFF (digitally 1 or 0). Therefore these are also called as discrete outputs. These elements are mainly actuators like contactors. Relays, solenoid coils, indicating lamps, annunciation lamps etc., and are directly connected to outputs of the PLC.

2.Analog output: These output have multiple states and rather continuously changing one and are having a range of values. Electrically these are categorized into two.1. Voltage: The commonly used ranges are

1.0 to 10VDC -unipolar2.–10 to +10VDC bipolar3.0 to 5VDC

2. Current: The commonly used ranges are 1. 0 to 20ma 2. 4 to 20ma

In case of analog outputs, the digital value is converted to analog signals and these signals are fed to actuators such as control valves. These control valves in turn open / close from 0 to 100% depending on digital values fed.

A typical example for analog output is as shown below:

FLAGS: Flags are just like auxiliary relays used in conventional RLC systems (ref. R12 in fig 1.1). These are similar to digital outputs as far as internal execution is considered. These are internal to the system to store temporary digital data (bit 1/0) and will not have any physical output. These will be accessed as bits.

Page 4 of 40

Analog

output of PLC

4000-20000 counts to

4 to 20 mAUncontrolled

FlowControlled

Flow

0-100%

Page 5: Plc for Beginners

1

2

3

COM

L1 L2

Fig 1.3

REGISTERS:

Just as flags are used to store temporary digital data, registers are used to store temporary analog data. These will be used in mathematical calculations, Timers, counters etc. These will be accessed as word, and length of word depends on processor used (for e.g. 16bit, 32 bit etc)

Wiring of Digital Inputs

The field sensing elements such as pushbuttons, Switches etc., are wired as shown in the fig 1.3

Page 5 of 40

Page 6: Plc for Beginners

1

2

3

COM

L1 L2

Fig 1.3

In case of AC voltage type Digital input cards, L1and L2 can be fed with line and Neutral.

(To remind AC voltage has alternating polarity, hence L1 can either be connected to Line or Neutral with L2 connected the other.)

In case of DC voltage type digital input cards, if L1 is connected to 0Vdc and L2 is connected to +Vdc then inputs are called “Sink type inputs”. When the input circuit is completed, +ve signal is available at the channel. The input card converts it to “1” if +ve signal is available and “0” if no signal is available. Hence these are also called “Positive inputs”.

If L1 is connected to +ve Vdc and L2 is connected to 0Vdc, then inputs are called “Source type inputs”. When the input circuit is completed, 0Vdc signal is available at the channel. The input card converts it to “0” if 0Vdc signal is available and “1” if no signal is available. Hence these are also called “Negative inputs”.

We are positive thinkers and hence the most commonly used input wiring for DC voltage is the sink type. Source type of cards is used when interfacing devices like PNP Proximity sensors.

One major advantage of PLC is that, the inputs connected can either be normally open or normally closed. Internally PLC can generate unlimited number of normally open and normally closed contacts from it. If normally open (NO) contacts are wired, then normally the PLC input will be “0”. And when the contact is actuated then the input will be “1”. If normally closed contacts are wired, then normally the PLC input will be “1” and when the contact is actuated then the input will be “0”. Normally NO contacts are used to start applications and NC contacts for stopping. If equipment couldn’t be started then there much less problem, compared to if the equipment could not be stopped. Hence the stop signal should be wired as NC signals as far as possible which then can be termed as “fail safe”.

(Note: The most commonly used DC voltage for I/O interrogation is 24v dc)

Wiring of digital outputs

The two most common types of digital outputs are1.DC type2.Relay type

In case of DC type the field actuators will be connected to the Digital output card as shown in fig1.4. Here, if L1 is connected to +ve Vdc and L2 is connected to 0Vdc then

Page 6 of 40

Page 7: Plc for Beginners

the outputs are called “Source type outputs”. When the output circuit is completed, +ve signal is available at the channel if the PLC writes “1” to the channel and no signal if PLC writes “0” to it. Hence these are also called “Positive Outputs”.

On the other hand, if L1 is connected to 0Vdc and L2 to +Vdc, then the outputs are called “ sink type outputs “. When the output circuit is completed, 0 Vdc is available at the channel if plc writes 1 to the channel and no signal if plc writes 0 to it. Hence these are also called negative outputs. As in the case of inputs most commonly used output wiring for dc voltage is the source type. Sink type outputs are used in specific cases.

In case of relay type outputs, there are two types.

1.Isolated type :Here each output is isolated from the other. Hence different voltages can be fed to different channels. These outputs are potential free contacts. Fig 1.4 shows the wiring details of isolated relay type outputs.

2.Non-isolated type:Here all the outputs are grouped into one. Hence only one type of voltage can be fed to the group. Fig 1.5 shows the wiring details of non-isolated or Partially Isolated relay type outputs.

Wiring of analog input:

For 4wire and 2 wire current transducers, the wiring diagram is as shown in Fig1.6 and fig 1.7 respectively. Fig1.8 shows the wiring diagram of voltage transducers to the analog input card.

Page 7 of 40

Fig 1.4

1L2

L1

2L4

L3

3L6

L5

L2

Fig 1.5

1

COM

2

L1

3

4WT

+

-

I ref

Ret

AC/DC

Signal Earth

Fig 1.6

Analog Input

(Current)

Cable Shield

+

-

VoltageTransducer

Signal Earth

Fig 1.8

Analog Input

(Voltage)

+

-

Cable Shield

Page 8: Plc for Beginners

Tip: In case of analog inputs, wiring should be done in such way considering analog input cards as the measuring meter. On the other hand, in case of analog outputs, wiring should be done in such a way considering the “load” as measuring meter.

PSU

CPU

COMM

Fig. 1.14

IU 1

I/O

I/O

I/O

IU 2

I/O

I/O

I/O

IU 3

I/O

I/O

I/O

Wiring of Analog Output:

The wiring for analog output for current and voltage is as shown in fig 1.9 and Fig 1.10 respectively. In case of current analog outputs, the required voltages are generated with the analog signal itself.

There is another classification of PLC input / outputs (I/O).1.Local I/Os.2.Remote I/Os.

1.Local I/Os: If the PLC I/Os are connected directly to the PLC CPU system, then the I/Os are termed as Local I/Os. Fig 1.13 shows the scheme of local I/Os. Here all the input and output wiring will be done directly to CPU system.

2.Remote I/Os:If the PLC I/Os are connected through Remote communication card (COMM) to the PLC system, then the I/Os are termed as of Remote I/Os. Fig1.14 shows the scheme of remote I/Os. Here the I/Os are wired and

Page 8 of 40

+ 2WT - I ref

Ret

POWERSUPPLY

Signal Earth

Fig 1.7

Analog Input

(Current)

+

-

Cable Shield

Note:

Analog inputs are like meters, just as voltmeters are connected in parallel and ammeters are connected in series, the wiring to the analog input cards should be done similarly

I ref

Ret

Load

Signal Earth

Fig 1.9

Analog Output

(Current)

+

-

Cable Shield

+

-

Load

Signal Earth

Fig 1.10

Analog Output

(Voltage)

+

-

Cable Shield

PSU

CPU

I/O

I/O

Fig. 1.13

Page 9: Plc for Beginners

communicate to the interface unit (IU). These units in turn communicate to the communication card on the PLC system. These I/O’s are interconnected in a daisy chain fashion.

Remote I/Os have following advantages over the local I/Os. Wiring is minimum, as the I/O wiring is done locally to the equipment. Only one

communication cable is used to interface the communication card on the CPU rack and interface unit on the I/O rack remotely placed. Hence cable cost is considerably brought down.

Diagnosis becomes simpler, as the I/O related to the remotely located equipment can be checked near the equipment itself.

Various communication protocols (pattern) are used to communicate between the communication cards and interface units.Some of them are Device-net, Profibus etc. Also, there are quite a few proprietary protocols from various manufacturer of the PLC. Efforts are being made to standardize these protocols.

Addressing of Inputs and Outputs in PLC:

PLC considers each input, output be it analog or digital or be it flags or registers as different memory location. Various addressing methods are used and depend on vendor how they decide to differentiate the different memory locations viz., Digital input, analog input, Digital output, analog output, flags, registers.Also the individual channels can be addressed in different formats viz.,1.Decimal: 1,2,3….9, 10, 11 etc.2.octal:0, 1, 2,..7,10,11 etc.3.Hexadecimal: 1,2…9,A, B, C, D, E, F, 10, 11 etc These are prefixed with some characters to differentiate the different I/Os.

For e.g.:Digital inputs : X1,X2…Digital outputs: Y1,Y2…Analog Inputs: XX1, XX2….Analog outputs: YY1, YY2….Flags: F1, F2….Registers: R1, R2….

Sample ladder program:

Page 9 of 40

Page 10: Plc for Beginners

Consider the electrical network shown in Fig 1.1. If the same has to be replaced by the plc, then the pushbutton PB1, PB2 would be the inputs and relay coil R1 as output. The auxiliary contactor R12 can be omitted. Suppose PB1, PB2 are connected to 1st and 2nd channel of the digital input card of the PLC and R1 is connected to 1st channel of the digital output card of PLC then the PLC program will be as shown in the above example.

The auxiliary relay R12 in Fig 1.1 is omitted and is replaced by a contact of output itself. This is permitted in PLC. Outputs are memory addresses, which can be read as well as written. Hence if it read, a contact is placed and when it is written a coil is placed in the logic. As seen Fig.1.11 looks like a ladder, that is why this is termed as ladder program.

HOW DOES A PLC WORK?

Most PLC systems execute a scan sequence. Fig 1.12 displays the various blocks in this sequence.

Page 10 of 40

X1

Y1

X2 Y1

Fig 1.11

SERVICECOMMUNICATIONS HOUSE KEEPING

OUTPUT SCANINPUT SCAN

LOGIC SCAN

PLC SCAN

Fig 1.12

Page 11: Plc for Beginners

House keeping consists of internal checksums and diagnostics that the processor executes every scan cycle. These can be done at the beginning or the end of the scan cycle or both depending upon the PLC. Input scan consists of reading the current state for each input connected to the PLC system and updating the input memory tables (buffer memory).

Logic scan consists of reading the use program that has been stored in the PLC memory. These programs can be written in ladder logic, instruction list, sequential Flow charts, function block, structure text, c code or state logic depending upon their manufacturer of the system. Some system supports programming using combination of languages within the same program.

Output scan consists of adjusting the values of the outputs connected to the system based upon the status of inputs and execution of the logic.

Service communications consists of opening the window of time for the processor to communicate to other devices. These can be programming devices, operator interface devices, remote IO controllers, other PLC’s or any other devices having communication capability that is compatible with the PLC system.

INTRODUCTION TO

GE FANUC has a wide range of PLC’s catering various sectors of industrial requirements.

90-70 PLC’s for I/Os ranging from 4096 to unlimited.

90-30 PLC’s for I/Os ranging from 16 to 4096

Page 11 of 40

Page 12: Plc for Beginners

Versamax PLC’s for small & medium applications.

Apart from these, a range of I/O modules from the simple I/O’s to power monitoring systems are available.

Built on Microsoft windows platform is the programming software for all these range of PLC’s.

GE FANUC has also developed a high powerful S upervisory C ontrol A nd D ata A cquisition ( SCADA ) Software called the

PLC addressing in GEFanuc PLC’s:

All addressing in GEFanuc series of PLC’s is in the decimal format. The different memory locations are prefixed with characters as follows

1 Digital input: %IXXXX2 Digital output: %QXXXX3 Analog input: %AIXXX4.Analog output: %AQXXXX5.Registers: %RXXXX6.Flags: %MXXXX7.Temporary bits: %TXXXX8.System bits: %SXXXX9.Global bits: %GXXX

Page 12 of 40

Page 13: Plc for Beginners

90-30 PLC’s:

The different parts of a 90-30 PLC are as shown in Fig 2.1. The base plates are of two types1 CPU base plates

a. IC693CHS397 five slot modular CPU base plate b. IC693CHS391 ten slot modular CPU base plate

2 Expansion base plate a. IC693CHS398 five slot expansion base plate b. IC693CHS3392 ten slot expansion base plate

The ranges of power supply modules for 90-30 PLC are as follows:

Page 13 of 40

10 Slot Base

Rack Expansion

Power Supply

CPU I/Os

Fig 2.1

Page 14: Plc for Beginners

Catalog number Nominal input voltage Output voltage

IC693PWR321 100 TO 240 VAC OR 125 VDC +5VDC,15WATTSIC693PWR330 100 TO 240 VAC OR 125 VDC +5VDC,30 WATTSIC693PWR322 24 OR 48 VDC +5VDC,15 WATTSIC693PWR328 48 VDC +5VDC,15 WATTSIC693PWR331 24 VDC +5VDC,30 WATTSIC693PWR332 12 VDC +5VDC,30 WATTS

The range of CPUs along specification is given as follows

CPU type(IC693CPUxxx) 331 340 341 350 351 352No. Of expansion base plates 4 4 4 7 7 7Load required from +5v dc supply 350ma 490ma 490ma 670ma 890ma 890maProcessor Speed (mega hertz) 10 20 20 25 25 25Processor type

80188 80c188xl80c188xl80386e

x80386e

x80386e

xOperating temperature (in dg .c) 0- 60 0-60 0-60 0-60 0-60 0-60Typical scan rate (ms/1k of logic) 0.4 0.3 0.3 0.22 0.22 0.22User program memory (max) 16kb 32kb 80kb 32kb 240kb 240kbDiscrete input points-%I 512 512 512 2048 2048 2048Discrete output points-%Q 512 512 512 2048 2048 2048Discrete global memory-%G 1280 1280 1280 1280 1280 1280Internal coils-%M 1024 1024 1024 4096 4096 4096Output temporary coils-%T 256 256 256 256 256 256System status reference-%S 128 128 128 128 128 128Register memory-%R 2048 9999 9999 9999 16384 16384Analog Inputs-%AI 128 1024 1024 2048 16384 16384Analog Outputs-%AQ 64 256 256 512 16384 16384System registers-%SR 16 16 16 28 28 28Timers/Counters 680 >2000 >2000 >2000 >2000 >2000

Page 14 of 40

Page 15: Plc for Beginners

Interrupts No Yes YES Yes Yes YesTypes of memory storage RAM RAM RAM RAM RAM RAMOptional memory EEPROM FLASH FLASH FLASH FLASH FLASHNo. Of programming ports 1 1 1 1 3 3Built in Ethernet ports No No No No No No

CPU Type (IC693CPUXXX) 360 363 364

No of expansion base plates 7 7 7

Load required from +5v dc supply 670 mA 890mA 1.51A

Processor speed (MHz) 25 25 25

Processor type 80386EX 80386EX 80386EX

Operating temperature in *c 0 to 60 0 to 60 0 to 60

Typical san rate (ms/1k of logic) 0.22 0.22 0.22

User program memory (max) 240 kb 240 kb 240 kb

Discrete input points %I 2048 2048 2048

Discrete output points %q 2048 2048 2048

Discrete global memory %G 1280 1280 1280

Internal coils %M 4096 4096 4096

Output (temporary) coils %T 256 256 256

System status reference %S 128 128 128

Register memory %R 16384 16384 16384

Analog inputs %AI 16384 16384 16384

Analog outputs %AQ 16384 16384 16384

System registers %R 28 28 28

Timers / counters >2000 >2000 >2000

Interrupts Yes Yes Yes

Type of memory storage RAM RAM RAM

Optional memory Flash Flash Flash

Floating point math support Yes Yes Yes

No. Of programming ports 1 3 1

Built in Ethernet port No No Yes

Page 15 of 40

Page 16: Plc for Beginners

Features of the latest CPU in the market is IC693CPU374

CPU type : Single slot CPU with embedded Ethernet interfaceProcessor speed : 133 MHz Processor type : embedded 586 Typical scan rate : 0.15 ms/1k of logic (Boolean contacts)Type of memory storage : RAM and flashUser memory (total) : 240kbDiscrete input points %I : 2048 (fixed)Discrete output points % Q : 2048 (fixed)Discrete global memory %G : 1280 bits fixed Internal coils %M : 4096 bits fixedOutput (temporary)coils %T : 256 bits fixedSystem status references % S : 128 bits (%S,%SA,%SB,%SC 32 bits each) (fixed)Register memory %R configurable : 128 to 32640 wordsAnalog inputs %AI configurable : 128 to 32640 wordsAnalog outputs %AQ configurable : 128 to 32640 wordsSystem registers % SR : 28 words (fixed)Timers/counters : > 2000 (depends on available user memory)Battery backed clock) : yes Load required from power supply : 7,4 watts of 5v dcEz program storage device : yes Total base plate per system : 8 ( CPU base plate + 7 expansion and /or remote)Interrupt support : supports the periodic subroutine feature Floating point math : yes, hardware floating point mathBuilt in serial ports :supports RS485 port on the power supplyBuilt in Ethernet : communications Ethernet (built in) 10/100base T/TX

Ethernet switchNo. of Ethernet ports : 2,both are 10/100 base T/TX ports with auto sensing RJ 45 connection No. of IP addresses :1 Operating Temperature :0 to 60 °C (32 to 140 °F) ambientStorage Temperature :-40 °C to +85 °C

Page 16 of 40

Page 17: Plc for Beginners

Types of Discrete/Digital Input Modules:

Page 17 of 40

Page 18: Plc for Beginners

Types of Discrete/Digital Output Modules:

Types of Discrete Mixed Modules

Types of Analog Input Modules:

Types of Analog Output Modules:

Types of Analog Mixed Modules:

Page 18 of 40

Page 19: Plc for Beginners

LADDER PROGRAMMING:

As earlier discussed, ladder program is one of the methods of programming the PLC’s. The flow of the program is “Left to right top to bottom”

GE Fanuc PLC’s has a powerful set of functions and categorically divided as under1.Relay functions 2.Timers and counters 3.Math functions 4.Relational functions 5.Bit operation functions 6.Data move functions 7.Table functions 8.Conversion functions 9.Control functions

1.RELAY FUNCTIONS:

Relay function is composed of contacts and coils as is so in a relay.

Contacts:1.Logical “Normally Open” contact (NO)

A NO contact acts as a switch that passes power flow if associated reference is ON

2.Logical “Normally Closed” contact (NC) A NC contact acts as a switch that passes power flow if associated reference is OFF

(Note: XXX means the reference address which can be %I ,%Q,%M,%S, %G or %T)

Example:

In the above example %Q001 will be ON if %I001, %Q010, %S007 and %G002 is ON (1) and %I003, %M0100 and %T001 is OFF (0)

Page 19 of 40

XXX

XXX

%I001 %I003 %M0100 %Q010 %S007 %T01 %G02 %Q01

Page 20: Plc for Beginners

%I001 %Q001

%I001 %Q001

Ladder logic permits only 9 contacts and a coil in series. If the number of contact is more than 9 then, continuation contact Can be used in combination with continuation coil

For e.g.:

<+>

<+>

Coils: Types of coils:

Normally open coil

Negated coil. The referenced coil will be ON when the conditions previous to it i.e., the contacts does not satisfy the power flow

Set coil. The referenced coil will be ON when the conditions previous to it i.e., the contact satisfies. Once the coil is ON, it will remain ON even when the condition previous to it does not satisfy the power flow anymore. The only way to reset the coil is by a reset coil to the same referenced address.

Reset coil. The referenced coil, which has been made ON through a set Coil, is made OFF through reset coil. The set and reset coil together form a latch.

Positive transition coil. The referenced coil will be ON once the condition (contacts) previous to it satisfy and give a power-flow to the coil. The coil will be ON only for one PLC scan time.For e.g.:

Here %M001 will be ON the moment

%I001 is ON only for 1 PLC scan. If %M001 has to become

ON again, then %I001 has to go OFF and become ON again.

Negative transition coil. The referenced coil will be ON once the condition (contacts) previous does not satisfy and there is power-flow. The coil will be ON only for one PLC scan time.

Page 20 of 40

%I001 %I003 %M0100 %Q010 %S007 %T01 %G02 %I05 %I06

%Q01%I007

S

R

Page 21: Plc for Beginners

Here %M001 will be ON the moment %I001 is OFF from ON. %M001 will be ON only for 1 PLC scan. If %M001 has to become ON again, then %I001 has to go ON and become OFF again.

Important things to remember when using coils:

Tip1: Avoid multiple coils of the same referenced address i.e.,

PLC considers the bottom most coil in such case, and the first rung never gets satisfied. If two or more conditions can, make a coil ON, then the logic should be as under:

Tip2: Coils can be used only for %M, %Q, %T & %G bits.

Tip3: Use the %Q bits at the end of the program preferably. It’s a good programming practice.

Page 21 of 40

%I001 %I002 %Q001

%M001 %I004 %Q001

%M001 %I004 %M1002

%I001 %I002 %M1001

%M1001

%M1002

%Q001

Page 22: Plc for Beginners

2.Timers and counters: Timers:

There are three types of timer functions:

Normal timer On-delay timer Off- delay timer

Normal timer

Enable Necessarily has to be contacts and can be a single or series of contacts.Done Necessarily has to be a coilPV Can be a constant or %R reference???? Must be necessarily %R reference. Once a register is specified,

automatically the other 2 consecutive registers are taken. These 3 %R reference should not be used anywhere else in the logic.

Actual time = PV * time base

Function:

When the timer enable is ON, the “TMR” block starts counting the specified time (PV*Tb). Once the actual time has elapsed, the timer done bit is made ON till the timer enable is ON. If the timer enable is OFF the timer resets to zero.

Page 22 of 40

TMR Tb

????

PV

???? - %R reference (3 consecutive)Tb -Time Base

1 tenth, 1 hundredth, 1 thousandth of a second

PV -Preset Value

Enable Done

Page 23: Plc for Beginners

2. On-delay timer:

Enable & Reset Necessarily has to be contacts and can be a single or series of contacts.

Done Necessarily has to be a coilPV Can be a constant or %R reference???? Must be necessarily %R reference. Once a register is

specified, automatically the other 2 consecutive registers are taken. There 3 %R reference should not be used anywhere else in the logic.

Actual time = PV * time base

Function:

When the timer enable is ON & timer reset is OFF, the “TMR” block starts counting the specified time (PV*Tb). Once the actual time has elapsed, the timer bit is made ON and will remain ON till the timer enable is ON. Incase, If the timer enable is OFF, the timer is counting the on-delay timer retains the elapsed time and will resume counting timer when the enable input becomes ON again. The only way to reset the On-delay timer is by making the timer reset ON. This timer can be used as RETENTIVE TIMER.

Page 23 of 40

TMR Tb

????

PV

???? - %R reference (3 consecutive)Tb -Time Base

1 tenth, 1 hundredth, 1 thousandth of a second

PV -Preset Value

Enable

DoneReset

Page 24: Plc for Beginners

3. Off- delay timer

Enable Necessarily has to be contacts and can be a single or series of Contacts

Done Necessarily has to be a coilPV can be a constant or %R reference???? Must be necessarily %R reference. Once a register is specified, automatically the other 2 consecutive registers are taken. There

3 %R reference should not be used anywhere else in the logic.

Actual time = PV * time base

Function: When the timer enable is ON, timer done is also ON. Once the timer enable is OFF, the “TMR” block starts counting the specified time (PV*Tb). Once the actual time has elapsed, the timer done bit is made OFF and will remain OFF till the timer enable is ON.

E.g.: A typical; application is with turbine and its associated lubrication oil pump. The requirement is as long as turbine is running; lubrication oil pump also must be ON. When the turbine stops electrically, lubrication pump should continue to be ON for some time (because turbine is till running mechanically due to moment of inertia). Here OFF delay timer can be used by giving the turbine running contact to timer enable, and lubrication pump output to timer done.

Page 24 of 40

OFDT Tb

???? PV

???? - %R reference (3 consecutive)Tb -Time Base

1 tenth, 1 hundredth, 1 thousandth of a second

PV -Preset Value

Enable Done

Page 25: Plc for Beginners

Counters:

There are two types of counters1. Up counter 2. Down counter

Up-counter:

Counting pulse Necessarily has to be a contact& ResetDone Necessarily has to be a coilPV Can be a constant or %R reference ???? Must be necessarily %R reference. Once register is specified, Automatically the other 2 consecutive registers are taken.

These 3 %R reference should not be used anywhere else in the logic

Function:

The counter increments by one when, there is a transition high at Counting Pulse input. The initial value of the counter will be zero. Once the counter reaches the PV, the counter dome bit becomes ON.

Down-counter:

Page 25 of 40

UPCTR

????

PV

???? - %R reference (3 consecutive)PV -Preset Value

Counting Pulse

DoneReset

DNCTR

????

PV

???? - %R reference (3 consecutive)PV -Preset Value

Counting Pulse

DoneReset

Page 26: Plc for Beginners

Function: Every time the down counter receives a high transition input at the counting pulse, the counter decrements by one. The initial value of the counter will be PV. Once the counter reaches the zero, the counter dome bit becomes ON.

3.Math Functions:

Before the discussion about Math function, Data types needs to be explained.Data is the operand on which the operation or function is performed. There are various data types. Viz.,

Int- Signed Integer-Signed integers use 16 bit memory data locations, and are represented in 2’s complement notation. The valid range of an INT data type is – 32,768 to 32,767.

Dint- Double Precision Signed IntegerDouble precision-signed integer is stored in 32 bit data memory locations (actually two consecutive 16 bit memory locations) and represented in 2’s complement notation (Bit 32 is the sign bit) The valid range of a DINT data type is 2,147,483,648 to +2,147,483,647.

Bit- bitA bit data type is the smallest unit of memory. It has two states, 1 or 0.A BIT string may have length N

Byte- byteA byte data type has an 8-bit value. The valid ranges is 0 to 255 (0 to FF in Hexadecimal)

Word- wordA word data type uses 16 consecutive bits of data memory; but, instead of the bits in the data location representing a number, the bits are independent of each other. Each bit represents its own binary state (1 or 0) and the bits are not looked at together to represent an integer number. The valid ranges of word values is 0 to FFFF

Dword- Double wordA double word data type has the same characteristics as a single word data type, except that it uses 32 consecutive bits in data memory instead of 16 bits.

BCD-4-Four-Digit Binary Coded DecimalFour-digit BCD numbers use 16-bit data memory locations. Each BCD digit uses four bits and can represent numbers between 0 and 9. This BCD coding of the 16 bits has a legal value range of 0 to 9999.

Real-Floating point.Real numbers use 32 consecutive bits (actually two consecutive 16-bit memory locations). The range of numbers that can be stored in this format

Page 26 of 40

Page 27: Plc for Beginners

+/- 1.401298 E-45 to +/- 3.402823 E+38

The various Math functions available in 90-30 PLCs are:

Standard Math Functions:

ADD (Addition)SUB (Subtraction)MUL (Multiplication)DIV (Division)MOD (Modular Division) – division to obtain the reminder

E- Enable PF- Power flow XXX- Function name (Add, Sub, etc)YYY- Data typeI1- Operand1I2- Operand2Q- Result of (I1 function I2)

ADD, SUB, MUL & DIV operate on INT, DINT & REAL data types.MOD operates only on INT & DINT data types.

Note: PF can be used as enabling conditions for a cascaded function.

Special Math functions:

1. SQRT- Square root2. SIN, COS, TAN, ASIN, ACOS, ATAN- Trignometric functions3. LOG, LN, EXP, EXPT- Logarithmic/exponential Functions.4. RAD, DEG- Radian conversion Functions

4.Relational Functions:

Page 27 of 40

XXX YYYI1 Q

I2

XXX YYY

IN Q

E PF????

????????

E PF

???? ????

E- Enable PF- Power flow XXX- Function name (LOG, SQRT, etc)YYY- Data typeIN- OperandQ- Result of (Function (IN))

SQRT operate on INT, DINT & REAL data types. Other functions operate only on REAL data types.

Page 28: Plc for Beginners

Relational Functions are used to determine the relationship of two values.

Standard Relational Functions:EQ (Equals to)NE (Not Equal to)GT (Greater than)GE (Greater than or equal to)LT (Less than)LE (less than or equal to)

Range Relational Function:

1. Range (Greater than low limit and less than high limit)

Range function operates on INT, DINT & WORD data types.

Note: “ Q “ can be given to a coil or can be used as an enable input to the next cascaded function.

5.BIT Operations

Logical:

AND, OR, XOR

Page 28 of 40

XXX YYY QI1 I2

RANGE YYYL1

L2 Q

IN

????

????

E

E- Enable XXX- Function name (EQ, GE, etc)YYY- Data typeI1- Operand1I2- Operand2Q- ON if (I1 function I2) is true EQ, NE, GT, GE, LT, & LE operate on INT, DINT & REAL data types.

????????????

E- Enable YYY- Data typeL1- Lower limitL2- Upper limitIN- Data InputQ- ON if (IN is > L1 and < L2)

XXX YYYI1 Q

I2

E PF????????

Page 29: Plc for Beginners

E- Enable PF- Power flow XXX- Function name (AND, OR etc)YYY- Data type is always WORDI1- Operand1I2- Operand2Q- Result of (I1 function I2)

NOT

E- Enable PF- Power flow I1- Operand1Q- Result of (I1 NOT)

Note: PF can be used as enabling conditions for a cascaded function.

SHIFT:

When enabled, the group of bits at “IN” are shifted “N” times in the direction specified. When shifted, the result is placed in “Q”. “B2” provides power-flow based on last bit shifted out.

Page 29 of 40

????

NOT WORD

I1 Q

E PF

???? ????

XXX YYYIN B2

N

QB1

EPF????

????

????????

LEN????

Page 30: Plc for Beginners

E- Enable PF- Power flow XXX- Function name (SHL / SHR)YYY- Data type is always WORDIN- OperandN- Number of times to be shiftedQ- Result after shiftLEN-1 to 256

ROTATE:

When enabled, the group of bits at “IN” are rotated within the group “N” times in the direction of the rotate. The bits shifted out goes to “Q” and to the other end of the group. Power-flow occurs after the instruction when enabled.

E- Enable PF- Power flow XXX- Function name (SHL / SHR)YYY- Data type is always WORDIN- OperandN- Number of times to be shiftedQ- Result after shiftLEN-1 to 256

BIT TEST:

When enabled, the bit specified at “BIT” within the group at “IN” will be tested. The results will be indicated with power-flow at “Q”.

BIT MANUPULATION:

BITSET, BIT RESET

When enabled, the bit specified at “BIT” will be set or cleared. If enabled and the “BIT” is within the group of bits, power-flow will occur after the instruction.

Page 30 of 40

XXX YYY

IN

N Q

EPF????

???? ????

LEN????

BIT TEST WORDIN Q

BIT

E????

????

LEN????

E- Enable IN- OperandBIT- Bit to be testedQ- Result (1 if Tested bit is ON, 0 if Tested bit is OFF)LEN- 1 to 256

Page 31: Plc for Beginners

BIT POSITION:

When enabled, the group of bits specified at “BIN” will be searched for an “ON” condition. When found, the bit number will be placed in “POS”. Power-flow after the instruction will occur when enabled.

BIT SEQUENCER: The Bit Sequencer (BITSEQ) function performs a bit sequence shift through an array of bits.

6.DATA MOVE:

MOVE: Source to Destination

Page 31 of 40

XXX WORDIN Q

BIT

E????

????

LEN????

E- Enable XXX- BIT_SET, BIT_CLRIN- OperandBIT- Bit to be manipulatedLEN- 1 to 256

XXX WORD

IN POS

E

????

LEN????

E- Enable XXX- BIT_POSIN- OperandPOS- Bit positionLEN- 1 to 256????

MOVE XXX

IN Q

E

????

LEN????

E- Enable XXX- INT, BIT, WORD,REALIN- SourceLEN- 1 to 256Q- Destination

????

BITSEQ R

DIR

STEP

ST

E

????

LEN????

LEN Length specifies the number of bits (starting at ST) that this instruction will step through. Acceptable values range from 1-256.

Add The control word for the BIT_SEQ function. The default data type is BIT_SEQ. This data type is 3-words long.

Current step number = word 1. Length of sequence in bits = word 2. Control word = word 3.R When R is energized, the bit sequencer's step number

is set to the value in STEP (default = 1), and the bit sequencer is filled with zeros, except for the current step number bit.

DIR When DIR is energized, the bit sequencer's step number is incremented prior to the shift. Otherwise, it is decremented.

N When R is energized, the step number is set to this value.

ST ST contains the first word of the bit sequencer.

R

????

????

????

Add

Page 32: Plc for Beginners

BLOCK MOVE: Source to Destination

BLOCK CLEAR: Source to Zero

SHIFT REGISTER: Shift data words or bits to a new memory location or in the same memory location.

COMMREQ: Use the COMMREQ function to send a command request to specialty modules like the Genius Bus Controller, Ethernet Interface, CMM or PCM modules. When the COMMREQ receives power flow, the command block defined by IN is sent to the specialty module located at the rack/slot location specified by the SYSID parameter.

Page 32 of 40

BLKMV XXX IN1 IN2IN3IN4 QIN5IN6IN7

E

????

E- Enable XXX- INT, WORD, REALIN1 to 7- Source & ConstantQ- Destination????

????????????????????????

BLKCLR XXX

IN

E

????

LEN????

E- Enable XXX- WORDIN- SourceLEN- 1 to 256

SHFR XXX

IN Q

ST

E

????

LEN????

E- EnableR- ResetXXX- BIT, WORDIN- SourceLEN- 1 to 256ST- First bit or word of the shift registerQ- Contains the bit or word shifted out of the shift register. For variables of type BIT, any discrete reference may be used.

R

????

????

COMM REQ IN

SYS

TASK

E

????

IN Contains the location of the command block. Refer to the documentation for your specialty module to

define the command block. Data Type: WORDSYSID Contains the rack/slot location of the intelligent

module. Data Type: WORD TASK Contains information specific to your specialty

module. Refer to the documentation for your specialty module to define this field. Data Type: WORD FT FT is energized if the COMMREQ fails.????

????

Page 33: Plc for Beginners

7.TABLE FUNCTIONS:

ARRAY MOVE(BOOL,BYTE,INT,DINT & WORD): The Array Move (Array Move) function to copy a specified number of data elements from a source array to a destination array. The Array Move function has five input parameters and two output parameters. When the function receives power flow, the number of data elements in the count indicator (N) is extracted from the input array starting with the indexed location (SR + SNX – 1). The data elements are written to the output array starting with the indexed location (DS + DNX – 1). The variable length specifies the number of elements that make up each array.

SEARCH (BOOL,BYTE,INT,DINT & WORD):

The Search function to search a value in a array of values. This search function has four input parameters and two output parameters. When the function receives power, the array is searched starting at (AR + INX). This is the starting address of the array (AR) plus the index into this array (INX). The search continues until condition of the search object (IN) is found or until the end of the array is reached. If an array element is found, output parameter (FD) is set ON and output parameter (ONX) is set to the relative position of this element within the array. If no array element is found before the end of the array is reached, then output parameter (FD) is set OFF and output parameter (ONX) is set to zero.

Page 33 of 40

ARRAY MOVE XXX SR

SNX

DNX

N

E

????

LEN????

XXX The length specifies the number of elements (starting at SR and DS) that make up each array.

SR SR contains the starting address of the source array. For an Array Move with the data type BIT, any reference may be used; it does not need to be byte aligned.

Data Types: WORD, WORD Length 2, BIT, and BYTESNX SNX contains the index of the source array. Data Type: WORDDNX DNX contains the index of the destination array.Data Type: WORDN N provides a count indicator.Data Type: WORDDS DS contains the starting address of the destination

array. For an Array Move with the data type BIT, any reference may be used; it does not need to be byte aligned.

R

????

????

SEARCH YY XX

AR

INX

IN

E

????

XX Length. The length specifies the number of elements (starting at AR) that make up the array to be searched. Acceptable values range from 1-32767.

AR AR contains the starting address of the array to be searched.

Data Types: WORD, WORD Length 2, and BYTEINX Input NX (INX) contains the index into the array at

which to begin the search.Data Type: UINTIN IN contains the object of the search. Data Types: WORD, WORD Length 2, and BYTEONX Output NX (ONX) holds the position within the array

of the search target. Data Type: UINTFD FD indicates that an array element has been found

and the function was successful.YY EQ, NE, GT, GE, LT & LE.

????

????

Page 34: Plc for Beginners

8. CONVERSION

BCD4 to INT, BCD4 to REAL, DINT to REAL, INT to BCD4, INT to REAL, REAL to DINT, REAL to INT, REAL to WORD, WORD to REAL CONVERSIONS.

9. CONTROL

CALL: To call Ladder blocks.

. Blocks should exist in the folder prior to making the Call.·The PLC will only allow a maximum of 8 nested calls before an "Application Stack Overflow" fault is logged and the PLC transitions to STOP/FAULT mode. ·You can use up to 64 blocks in a folder (subject to available memory). The maximum number of block calls within a given block is 64. The maximum number of calls to a particular block is 255. (A block can be executed any number of times, but there can be no more than 255 explicit calls to any given block.)

PID (ISA,IND):

Page 34 of 40

XXX

IN Q

E XXX CONVERSIONBCD4 to INT, BCD4 to REAL, DINT to REAL, INT to BCD4, INT to REAL, REAL to DINT, REAL to INT, REAL to WORD, WORD to REAL.

IN INPUT DATAQ OUTPUT DATA AFTER CONVERSION

Data Types: WORD, WORD Length 2, BIT, and BYTE

????

CALL E

Page 35: Plc for Beginners

For Proportional Integral & Derivative closedloop control algorithms.

The PID function is designed to solve one loop equation in one execution. The function block data uses 40 registers in a loop data table. The first 35 registers are reserved for the function and should not be used by any application. The last 5 registers are reserved for external use.

Registers cannot be shared. If there are multiple occurrences of the same PID function controlling multiple loops, each occurrence requires a separate block of 40 registers.

The PID function has six input parameters: a process set point (SP), a process variable (PV), a manual/auto Boolean switch (MAN), a manual mode up adjustment input (UP), and a manual mode down adjustment (DN). It also has an address, which specifies the location of a block of parameters associated with the function. It has two output parameters, a successful Boolean output and the control variable result (CV).

If power flow is provided to the Manual input contact, the PID block is placed in Manual mode and the output Control Variable is set from the Manual Command parameter %Ref+13. If either the UP or DN inputs have power flow, the Manual Command word is incremented or decremented by one CV count every PID solution. For faster manual changes of the output Control Variable, it is also possible to add or subtract any CV count value directly to/from the Manual Command word.

VersaPro allows you to tune PID instructions in real-time. Series 90 PLCs use the Proportional plus Integral plus Derivative (PID_ISA and PID_IND) function for control of real time processes. To access the Tuning Parameters dialog box, choose Tuning Parameters from the PLC menu. Use the Tuning Parameters dialog box to customize operation of the PID loop in your application. the following describes each field that appears on this dialog box.

Loop No.(Loop number) Uniquely identifies the PID block for reference by external devices, operator interfaces.

Manual CommandIf the PID block is in Automatic mode, this value is set to the current CV output. If the PID block is switched to Manual mode, this value is used to set the CV output and the internal value of the integrator, within the Upper and Lower Clamp and Slew Time limits.

ControlThis internal parameter is normally set to 0. If Override is ON, these bits and internal SP, PV and CV words will be used for remote operation of this PID block. This allows operator interface devices, such as a computer, to control the PID loop remotely. CAUTION: If you do not want to enable remote control, set Override to OFF.

Enable: Tracks the enable input into the function block and is used to determine whether or not the function block is active.

Override: Enables remote control of the PID block. If Override is OFF (default), use the other control bits to track the status of the PID input contacts. If Override is ON, the PID function will be controlled by remote devices by modifying internal SP, PV and CV words. When the override bit is ON, the function block executes based on the current values of manual, up, and down, that is, the next three

Page 35 of 40

Page 36: Plc for Beginners

fields. When the override is OFF, the manual, up, and down values are set to the values as defined by the function block's discrete inputs.

Manual: If ON, block is in manual mode. If OFF, block is in automatic mode.Up: If ON and Manual is ON, CV is incremented every solution.Down: If ON and Manual is ON, CV is decremented every solution.

Tuning

Proportional (Proportional Gain): Sets the proportional gain (0.01 seconds timebase). Derivation (Derivation Gain): Sets the derivation gain (0.01 seconds timebase).Integral (Integral Rate): Sets the integral rate with a timebase of .001 repeats per second.

SP, PV and CV Percentage Bar Graphs

Calculated based on the SP (Set Point Value) and PV (Preset Value) values. The maximum and minimum scale values are set by the user. CV graph is calculated based on the value of CV (Current Value) and the lower and upper clamp parameters.

SP/PV RangeOptional integer values in PV Counts that define the highest and lowest display value for the SP and PV bar graphs.

SP ValueRepresents the process Set Point input. In PID control, the loop adjusts the output CV so that PV matches SP.

Sample PeriodShortest time, in 10 millisecond increments, between solutions of the PID loop. If 0, the loop is solved every time the block is called. Note: The PID loop is solved only if the current PLC elapsed time clock is at or later than the last PID solution time plus this sample period. The PLC sweep time should be less than 10% of the sample period to ensure a regular solution time. If not, the sample period should be set to 0.00, specifying execution every sweep.

BiasA value (in CV Counts) added to the PID Output before the rate and amplitude clamps. It can be used to set non-zero CV values if using only Kp Proportional gains, or for feed forward control of this PID loop output from another control loop. The usual setting for the Bias field is +16000 to let the function regulate error around the output midpoint.

Dead Band Upper and LowerInteger values defining the upper and lower dead band limits. If no dead band is required, set these two values to 0. Read the following notes if setting dead band limits:1.If the PID Error (SP - PV) or (PV - SP) between the dead band limits, the PID calculations are solved with an Error of 0.2.If setting the dead band limits, Dead Band Upper must greater than 0 and Dead Band Lower must be less than 0 or the PID block will not function.3.You should leave the dead band limits set to 0 until the PID loop gains are setup or tuned. It may then be desirable to add Dead Band to avoid small CV output changes due to small variations in error, perhaps to reduce mechanical wear.

Upper Clamp and Lower ClampIntegers (in CV Counts) that define the high and low values for CV. The clamps are used to define limits based on physical limits for a CV output. The Upper Clamp must have a more positive value than the Lower Clamp, or the PID loop will not work. The PID block has anti-reset windup to modify the integrator value when a CV clamp is reached The upper clamp is usually set to +32,000 to allow the CV output to take on the full range of values.

Page 36 of 40

Page 37: Plc for Beginners

Error TermSelects how the error will be calculated.

Min Slew TimeDefines the minimum number of seconds for the CV output to move from 0 to full travel of 100% or 32000 CV Counts. It is an inverse rate limit on how fast the CV output can be changed. If positive, CV cannot change more than 32000 CV Counts times Delta Time (seconds) divided by Minimum Slew Time. For example, if the Sample Period was 2.5 seconds and the Minimum Slew Time is 500 seconds, CV cannot change more than 32000*2.5/500 or 160 CV Counts per PID solution. As with the CV Clamps, there is an anti-windup feature that adjusts the integrator value if the CV rate limit is exceeded. If Minimum Slew Time is 0, there is no CV rate limit.

Note: Make sure you set Minimum Slew Time to 0 while you are tuning or adjusting PID loop gains.

Derivative ActionSelects how the derivative action is applied.

Output PolaritySelects the output polarity of the CV.

Update Folder ButtonSaves values which have been edited in the dialog box to the stored value field of the PID variable. Clicking this button will cause the PLC status to become Not Saved. In order for this button to function, the variable assigned to the Address parameter must have a length of 40 words. If you are online and equal, you will have to rebuild your equipment folder, then Verify equality or Check All to regain equality with the attached PLC.

Update PLC ButtonIf you are online and equal with the PLC CPU, click this button to update edited values in the PLC.

There are two types of algorithm ( INDEPENDENT & ISA)

1.The Independent term PID (PID_IND) algorithm calculates the output as:PID Output = Kp * Error + Ki * Error * dt + Kd * Derivative + CV Bias

2.The standard ISA (PID_ISA) algorithm has a different form:PID Output = Kc * (Error + Error * dt/Ti + Td * Derivative) + CV Bias

Fault diagnosis & Troubleshooting

For PLC diagnosis & troubleshooting, The Series 90 PLCs maintain two fault tables, the I/O fault table for faults generated by I/O devices (including I/O controllers) and the PLC fault table for internal PLC faults. Both tables contain similar information. The fault data in these tables only exists in the PLC.

• The PLC fault table contains:

Page 37 of 40

Page 38: Plc for Beginners

. Fault location.

. Fault description.

. Date and time of fault.

Stores upto 16 fault entries, 8 Oldest and 8 latest. After 16 faults, the latest fault entry is over-written on to the 16th fault, with 16th shifting to 15th and downwards until the 9th fault entry. The 9th entry is over-written by the 10th, thereby deleting the 9th entry.

• The I/O fault table contains:. Fault location.. Reference address.. Fault category.. Fault type.. Date and time of fault.

Stores upto 32 fault entries, 16 Oldest and 16 latest. After 32 faults, the latest fault entry is over-written on to the 32nd fault, with 32nd shifting to 31st and downwards until the 17th

fault entry. The 17th entry is over-written by the 18th, thereby deleting the 17th entry.

The system status can also be monitored by the help of System reference bits:

System reference bits are internal bits used to indicate PLC status. The system reference bits are assigned to the %S data memory type. The %S(System status table) is divided into four groups: %S1 to %S32, %SA1 to %SA32, %SB1 to %SB32 and %SC1 to %SC32.%S1 through %S32 are set by the PLC and are defined in the table below

The references in the %SA, %SB and %SC tables are used to indicate system and I/O faults.

Faults are segregated Fatal faults: Faults that halt the system (Drop the CPU out of RUN Mode), set the Corresponding system references and are logged to the fault table.Diagnostic faults: These faults do not halt the system, but they do set the appropriate system references and are logged to the fault table.Information faults: These faults do not halt the system, but they are logged to the fault tables.

Page 38 of 40

Page 39: Plc for Beginners

Page 39 of 40

Page 40: Plc for Beginners

Page 40 of 40