RLL
P
LUS
Stage
Programming
7--21
RLL
PLUS
Stage Programming
DL105 PLC User Manual, 3rd Edition
Questions and Answers about Stage Programming
We include the following commonly-asked questions about Stage Programming as
an aid to new students. All question topics are covered in more detail in this chapter.
Q. What does stage programming do that I can’t do with regular RLL programs?
A.
Stages allow you to identify all the states of your process before you begin
programming. This approach is more organized, because you divide up a ladder
program into sections. As stages, these program sections are active only when they
are actually needed by the process. Most processes can be organized into a
sequence of stages, connected by event-based transitions.
Q. Isn’t a stage really just like a software subroutine?
A.
No, it is very different. A subroutine is called by a main program when needed, and
executes just once before returning to the point from which it was called. A stage,
however, is part of the main program. It represents a state of the process, so an
active stage executes on every scan of the CPU until it becomes inactive.
Q. What are Stage Bits?
A.
A stage bit is just a single bit in the CPU’s image register, representing the
active/inactive status of the stage in real time. For example, the bit for Stage 0 is
referenced as “S0”. If S0 = 0, then the ladder rungs in Stage 0 are bypassed (not
executed) on each CPU scan. If S0 = 1, then the ladder rungs in Stage 0 are
executed on each CPU scan. Stage bits, when used as contacts, allow one part of
your program to monitor another part by detecting stage active/inactive status.
Q. How does a stage become active?
A.
There are three ways:
S
If the Stage is an initial stage (ISG), it is automatically active at powerup.
S
Another stage can execute a stage JMP instruction naming this stage,
which makes it active upon its next occurrence in the program.
S
A program rung can execute a Set Stage Bit instruction (such as Set
S0).
Q. How does a stage become inactive?
A.
There are three ways:
S
Standard Stages (SG) are automatically inactive at powerup.
S
A stage can execute a stage JMP instruction, resetting its Stage Bit to 0.
S
Any rung in the program can execute a Reset Stage Bit instruction (such
as Reset S0).
Q. What about the power flow technique of stage transitions?
A.
The power flow method of connecting adjacent stages (directly above or below in
the program) actually is the same as the stage Jump instruction executed in the
stage above, naming the stage below. Power flow transitions are more difficult to edit
in
Direct
SOFT, we list them separately from two preceding questions.
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...