Professional Documents
Culture Documents
Lecture 3
Lecture 3
Timing diagrams represents how the ladder logic program respond to the changing states of the
inputs and outputs
E.g. 1:
Simple ladder Networks(Continued)
E.g.2 :
Simple ladder Networks(Continued)
• Bit represent the memory bit and N represent the number of bit set or reset once the input is
received.
Set Reset
When setting any When setting any
0-bit, it becomes 1 1-bit, it becomes 0
0→1 and any 1-bit stays 0→0 and any 0-bit stays
1→1 the same 1→0 the same
Simple ladder Networks(Continued)
Consider following examples
• When the memory Q0.1 receives an input, the memory is set for 3 bits counting from Q0.1
(Q0.1, Q0.2 and Q0.3)
Simple ladder Networks(Continued)
• As mentioned previously, when an input from I0.0 is received, the 3 memory bits counting
from Q0.1 are set (Q 0.1, Q0.2, Q0.3)
• When an input from I0.1 is received, 2 memory bits counting from Q0.2 are reset (Q0.2 and
Q0.3 become reset)
Simple ladder Networks(Continued)
Input received
from I0.0
Input received
from I0.1
Simple ladder Networks(Continued)
Special Note :
• When there are multiple networks, the flow can be represented in the following manner
Problem 1
Two push buttons A and B are wired to I0.0 and I0.1 ports in S7-200 PLC. The indicator wired to
Q0.0 port. When the A push button is pressed once, the indicator will turn on and keep
indicating. The indicator will turn off and keep off when the B push button is pressed once. Write
the ladder program to implement the system
Simple ladder Networks(Continued)
Answer
Simple ladder Networks(Continued)
Self-latching circuit
• The previous example can be done using a special block arrangement called self-latching
circuit
• In this arrangement, the output Q0.0 has been given as input to the circuit
Simple ladder Networks(Continued)
Timers
• Timer is a instruction that can be used to delay inputs or outputs in a PLC program for a
specific time period
• There are mainly 3 different types of timers used in the ladder programs
2. Off-delay timers(TOF)**
IN :Input(Enabling output)
TON :On-delay
PT :Preset
Preset time = 10 × 100ms
= 1000ms = 1s (Preset time)
Simple ladder Networks(Continued)
On-delay timers(TON)
Simple ladder Networks(Continued)
Timer resolutions and timer numbers
• For TON timers, you may use timers within this range
Simple ladder Networks(Continued)
Counters
• PLC counter is an instruction that can be used to count input or output signals in the ladder
program
1. Up-counters (CTU)
2. Down-counters(CTD)**
CU : Count-up
R : Reset
CU- Count Up
CD – Count down
R – Reset
PV-Preset value =10