Transcript
Page 1: Programmable Logic Controllers - lecture-notes.tiu.edu.iq

Programmable Logic

Controllers

Mr. Ali Al-Dabbagh

Programming Counter and Timer

1

Lecture (8)

Page 2: Programmable Logic Controllers - lecture-notes.tiu.edu.iq

Lecture Objectives

After completing this lecture, you will be able to:

• Apply combinations of counters and timers to control systems.

• Know the set and reset switches.

• Understanding the condition switches.

2

Page 3: Programmable Logic Controllers - lecture-notes.tiu.edu.iq

Example

3

Page 4: Programmable Logic Controllers - lecture-notes.tiu.edu.iq

classwork Activity

4

PLC can-counting program. Design ladder program, the operation of the

program can be summarized as follows:

• Counts the total number of cans coming off an assembly line for final

packaging.

• Each package must contain 10 parts.

• When 10 cans are detected, initiate the box closing sequence.

• Counts the total number of packages filled in a day. (The maximum

number of packages per day is 300.)

• A pushbutton is used to restart the total part and package count from

zero daily.

Page 5: Programmable Logic Controllers - lecture-notes.tiu.edu.iq

Counter Up-Down (CTUD)

5

One application for an up/down-counter is to keep count of the cars that

enter and leave a parking garage. Write PLC program that could be used

to implement this. The operation of the program can be summarized as

follows:

• As a car enters, the enter switch triggers the up-counter output

instruction and increments the accumulated count by 1.

• As a car leaves, the exit switch triggers the down-counter output

instruction and decrements the accumulated count by 1.

• Whenever the accumulated value of 150 equals the preset value of

150, the counter output is energized by the light up the Full sign.

• A reset button has been provided to reset the accumulated count.

Page 6: Programmable Logic Controllers - lecture-notes.tiu.edu.iq

Applications of TON and CTU

6

Many PLC applications use both the counter function and the timerfunction. Figure bellow illustrates an automatic stacking program thatrequires both a timer and counter.

In this process, conveyor M1 is usedto stack metal plates onto conveyorM2. The photoelectric sensorprovides an input pulse to the PLCcounter each time a metal platedrops from conveyor M1 to M2.When 15 plates have been stacked,conveyor M2 is activated for 5 s bythe PLC timer. The operation of theprogram can be summarized asfollows:

Page 7: Programmable Logic Controllers - lecture-notes.tiu.edu.iq

Applications of TON and CTU

7

• When the start button is pressed, conveyor M1 begins running.• After 15 plates have been stacked, conveyor M1 stops and conveyor M2

begins running.• After conveyor M2 has been operated for 5 s, it stops and the sequence

is repeated automatically.

Page 8: Programmable Logic Controllers - lecture-notes.tiu.edu.iq

Applications of TON and CTU

8

• Design ladder program to make attention with Red lamp after 10 days tochange the spare part of the motor in the factory

Page 9: Programmable Logic Controllers - lecture-notes.tiu.edu.iq

Condition Switches

9

Page 10: Programmable Logic Controllers - lecture-notes.tiu.edu.iq

Condition Switches

10

Page 11: Programmable Logic Controllers - lecture-notes.tiu.edu.iq

Condition Switches

11

Page 12: Programmable Logic Controllers - lecture-notes.tiu.edu.iq

12

Page 13: Programmable Logic Controllers - lecture-notes.tiu.edu.iq

13

Page 14: Programmable Logic Controllers - lecture-notes.tiu.edu.iq

Questions & Answers

14

Page 15: Programmable Logic Controllers - lecture-notes.tiu.edu.iq

15


Recommended