Chapter 6 PLC Programming 135
Example 6-3
Latch and unlatch are functions that use two inputs to control
the state of a bit that affects a single output. Refer to the diagram in
Figure 6-40. Pressing the pushbutton PB-1 at address I:1/0 latches
the B3:0/0 bit and turns on the green pilot light at address O:2/0. To
turn off the pilot light, the B3:0/0 bit must be unlatched. Pressing the
pushbutton PB-2 at address I:1/1 unlatches the B3:0/0 bit and turns
off the green pilot light.
Illustrating the concept of output sealing or locking itself in position.
000
001
O:2/0
Pilot Light
End
I:1/1
PB-2
I:1/0
PB-1
O:2/0
Pilot Light
Figure 6-39. PLC ladder logic diagram for Example 6-2. How an output can lock itself in position.
Lach/Unlatch Functions
000
001
002
003
B3:0/0
L
B3:0/0
U
O:2/0
G-PLT
End
I:1/0
PB-1
I:1/1
PB-2
B3:0/0
Figure 6-40. PLC ladder logic diagram for Example 6-3. How to use the latch/unlatch functions.