RLL
P
LUS
Stage
Programming
7--4
RLL
PLUS
Stage Programming
DL105 PLC User Manual, 3rd Edition
The state transition diagram to the right is
a picture of the solution we need to create.
The beauty of it is this: it expresses the
problem
independently
of
the
programming language we may use to
realize it. In other words,
by drawing the
diagram we have already solved the
control problem!
OFF
ON
X0
X1
Output equation: Y0 = ON
First, we’ll translate the state diagram to traditional RLL. Then we’ll show how easy it
is to translate the diagram into a stage programming solution.
The RLL solution is shown to the right. It
consists of a self-latching control relay,
C0. When the On pushbutton (X0) is
pressed, output coil C0 turns on and the
C0 contact on the second row latches
itself on. So, X0
sets the latch
C0 on, and
it remains on after the X0 contact opens.
The motor output Y0 also has power flow,
so the motor is now on.
When the Off pushbutton (X1) is pressed,
it opens the normally-closed X1 contact,
which
resets the latch
. Motor output Y0
turns off when the latch coil C0 goes off.
X1
X0
OUT
C0
OUT
Y0
C0
Set
Reset
Latch
Output
Latch
The stage program solution is shown to
the right. The two inline stage boxes S0
and S1 correspond to the two states OFF
and ON. The ladder rung(s) below each
stage box belong to each respective
stage. This means that the PLC only has
to
scan
those
rungs
when
the
corresponding stage is active!
For now, let’s assume we begin in the OFF
State, so stage S0 is active. When the On
pushbutton (X0) is pressed, a stage
transition occurs. The JMP S1 instruction
executes, which simply turns off the stage
bit S0 and turns on stage bit S1. So on the
next PLC scan, the CPU will not execute
stage S0, but will execute stage S1!
In the On State (stage S1), we want the
motor to always be on. The special relay
contact SP1 is defined as always on, so Y0
turns the motor on.
S1
X0
JMP
SG
S0
S0
X1
JMP
SG
S1
OUT
Y0
OFF State
ON State
Output
Transition
Transition
SP1
Always on
When the Off pushbutton (X1) is pressed, a transition back to the Off State occurs.
The JMP S0 instruction executes, which simply turns off the stage bit S1 and turns on
stage bit S0. On the next PLC scan, the CPU will not execute stage S1, so the motor
output Y0 will turn off. The Off state (stage 0) will be ready for the next cycle.
RLL Equivalent
Stage Equivalent
Summary of Contents for DL105
Page 2: ...DL105 PLC User Manual Manual Number D1 USER M...
Page 308: ...1B DL105 Error Codes In This Appendix Error Code Table...
Page 314: ...1C Instruction Execution Times In This Appendix Introduction Instruction Execution Times...
Page 324: ...1D Special Relays In This Appendix DL105 PLC Special Relays...
Page 327: ...1E PLC Memory In This Appendix DL105 PLC Memory...