Posted in

By

8 of 12Updated 2026-11-1723 min read中文版

Structured programming design is a major trend in software design. The benefits are high readability, easy maintenance, convenient updating and high quality and reliability. For the control applications, consisted of many sequential tasks, designed by conventional ladder program design methodology usually makes others hard to maintain. Therefore, it is necessary to combine the current widely used ladder diagrams with the sequential controls made especially for machine working flow. With help from step instructions, the design work will become more efficient, time saving and controlled. This kind of design method that combines process control and ladder diagram together is called the step ladder language.

The basic unit of step ladder diagram is a step. A step is equivalent to a movement (step) in the machine operation where each movement has an output. The complete machine or the overall sequential control process is the combination of steps in serial or parallel. Its step-by-step sequential execution procedure allows others to be able to understand the machine operations thoroughly, so that design, operation, and maintenance will become more effective and simpler.

8.1The Operation Principle of Step Ladder Diagram

【Example】

Y0

【Description】

M1924

1. STP Sxxx is the symbol representing a step

Sxxx that can be one of S0 ~S999. When

STP S0

executing the step (status ON), the ladder diagram

on the right will be executed and the previous step

and output will become OFF.

X1

Y1

Y4

X2

Y2

2. M1924 is on for a scan time after program start.

STP S20

Y3

STP S21

Hence, as soon as ON, the stop of the initial step

X3

S0 is entered (S0 ON) while the other steps are

kept inactive, i.e. Y1~Y5 are all OFF. This means

STP S22

X5

M1924 ONÆS0 ONÆY0 ON and Y0 will remain

X4

ON until one of the contacts X1 or X2 is ON.

X10

3. Assume that X2 is ON first; the path to S21 will

STP S23

then be executed.

Y5

X6

S21 ON
X2 ON⇒⇒

S0 OFF

Y2 ON

Y0 OFF

Y2 will remain ON until X5 is ON.

4. Assume that X5 is ON, the process will move
forward to step S23.

i.e. X5 ON⇒

S23 ON

⇒

Y4 ON

S21 OFF

Y2 OFF

Y4 and Y5 will remain ON until X6 is ON.
※If X10 is ON, then Y5 will be ON.

5. Assume that X6 is ON, the process will move
forward to S0.

S0 ON
i.e. X6 ON⇒⇒
S23 OFF

Y0 ON

Y4、Y5 OFF

Then, a control process cycle is completed and the
next control process cycle is entered.

8.2Basic Formation of Step Ladder Diagram

cSingle path

STP S20

X0

STP S21

dSelective divergence/convergence

z Step S20 alone moves to step S21 through X0. z X0 can be changed to other serial or parallel combination of contacts.

STP S20

Selective divergence

z Step S20 selects an only one path which divergent

condition first met. E.g. X2 is ON first, then only the path

X0

X1

X2

of step S23 will be executed.

z A divergence may have up to 8 paths maximum.

STP S21

STP S22

STP S23

z X1, X2, ….., X22 can all be replaced by the serial or

parallel combination of other contacts.

STP S30

STP S31

STP S32

X20

X21

X22

Selective convergence

STP S40

eSimultaneous divergence/convergence

STP S20

Simultaneous divergence

z After X0 is ON, step S20 will simultaneously execute all

X0

paths below it, i.e. all S21, S22, S23, and so on, are in

action.

z All divergent paths at a convergent point will be executed

STP S21

STP S22

STP S23

to the last step (e.g. S30, S31 and S32). When X1 is ON,

they can then transfer to S40 for execution.

z The number of divergent paths must be the same as the

STP S30

STP S31

STP S32

number of convergent paths. The maximum number of

divergence/convergence path is 8.

X1

Simultaneous convergence

STP S40

fJump
a. The same step loop
z There are 3 paths below step S20 as shown on the left.

STP S20

3-divergence

Assume that X2 is ON, then the process can jump directly

to step S23 to execute without going through the process

X0

X1

X2

of selective convergence.

z The execution of simultaneous divergent paths can not be

STP S21

STP S22

S23

skipped.

X3

X4

STP S23

2-convergence

b. Different step loop

M1924

X4

X10

X12

STP S0

STP S7

X0

X11

STP S20

S30

STP S30

S21

X2

X1

STP S21

STP S31

X3

X3

gClosed Loop and Single Cycle

a. Closed Loop

M1924
STP S1

z The initial step S1 is ON, endless cycle will be continued afterwards.

S20
S1ÆÆS22
S21

X0

STP S20 STP S21

X1
STP S22
X2

b. Single Cycle

M1924

X0

z When step S20 is ON, if X2 is also ON, then “RST S21”

instruction will let S21 OFF which will stop the whole step

process.

STP S0

X1

STP S20
X2
STP S21 RST S21

c. Mixed Process

M1924

STP S0

X0

X1

X2

RST S25

STP S20

STP S21

STP S24

X3

X4

X7

X5

STP S23

STP S25

STP S22

X6

hCombined Application

A branch can have up to 8 branch loops

1

2

3

4

5

6

7

8

16

The maximum number of downward horizontal branch loops of an initial step is 16

8.3 Introduction of Step Instructions: STP, FROM, TO and STPEND

●

STP Sx : S0≦Sx≦S7 (Displayed in WinProladder)

or
STP Sx:S0≦Sx≦S7 (Displayed in FP-08)

This instruction is the initial step instruction from where the step control of each machine process can be derived. Up to 8 initial steps can be used in the FBs series, i.e. a PLC can make up to 8 process controls simultaneously. Each step process can operate independently or generate results for the reference of other processes.

【Example 1】 Go to the initial step S0 after each start (ON)

1

924

STP S0

WinProladder

FP-08

M1924

M1924

TO S0

ORG

STP S0

TO

S0

STP

S0

【Example 2】 Each time the device is start to run or the manual button is pressed or the device is malfunction, then the device automatically enters the initial step S0 to standby.

M1924

X0

M0

STP S0

WinProladder

TO S0

FP-08

M1924

ORG

M1924

OR

X0

X0

OR

M0

TO

S0

M0

STP

S0

Standby process program

Standby

STP S0

Process
Program

【Description】X0: Manual Button, M0: Abnormal Contact.

●

STPSxxx : S20≦Sxxx≦S999(Displayed in WinProladder)

or
STPSxxx : S20≦Sxxx≦S999(Displayed in FP-08)

This instruction is a step instruction, each step in a process represents a step of sequence. If the status of step is ON then the step is active and will execute the ladder program associate to the step.

【Example】

M1924

X1

Y0

WinProladder

X10

TO S0

Y0

FP-08

M1924

M1924

ORG

TO

S0

STP S0

STP S0

TO S20

STP

S0

OUT

Y0

X10

Y1

FROM

S0

AND

X10

STP S20

TO

S20

X11

X2

Y2

STP S20

X1

TO S0

Y1

STP

S20

OUT

TR0

X2

Y2

AND

X1

OUT

Y1

X11

LD

TR0

AND

X2

STPEND

OUT

Y2

FROM

S20

AND

X11

TO

S0

STPEND

【Description】1. When ON, the initial step S0 is ON and Y0 is ON.

2. When transfer condition X10 is ON (in actual application, the transferring condition may be formed by the serial or parallel combination of the contacts X, Y, M, T and C), the step S20 is activated. The system will automatically turn S0 OFF in the current scan cycle and Y0 will be reset automatically to OFF.

i.e. X10 ON⇒

S20 ON

⇒

X1 ON

ÆY1 ON

X2 ON

ÆY2 ON

S0OFF

Y0 OFF

3. When the transfer condition X11 is ON, the step S0 is ON, Y0 is ON and S20, Y1 and Y2 will turn OFF at the same time.

i.e. X11 ON⇒

S0ON

⇒

Y0 ON

Y1 OFF

S20OFF

Y2 OFF

●

FROM Sxxx : S0≦Sxxx≦S999(Displayed in WinProladder)

or

FROM Sxxx : S0≦Sxxx≦S999(Displayed in FP-08)

The instruction describes the source step of the transfer, i.e. moving from step Sxxx to the next step in coordination

with transfer condition.

【Example】

M1924

Y1

X0

Y0

Y2

X3

Y3

WinProladder

X0

X7

TO S0

Y0

FP-08

M1924

M1924

ORG

TO

S0

STP S0

STP S0

TO S20

STP

S0

AND

X0

X1

X2

OUT

Y0

X1

FROM

S0

STP S20

X2

TO S21

Y1

OUT TR

0

STP S20

STP S21

STP S22

AND

X1

X5

X4

X6

X3

TO

S20

TO S22

LDTR

0

S0

X7

AND

X2

TO

S21

STP S23

Y4

STP S21

X4

TO S0

Y2

LDTR

0

AND

X3

TO

S22

X8

STP

S20

STP S22

X5

TO S23

Y3

OUT

Y1

STP

S21

OUT

Y2

FROM S20

FROM

S21

FROM S22

X6

Y4

AND

X4

TO

S0

STP

S22

STP S23

TO S0

X8

OUT

Y3

FROM

S20

STPEND

AND

X5

FROM

S22

AND

X6

ORLD
AND X7
TO S23
STP S23
OUT
Y4 FROM S23
AND X8
TO S0
STPEND

【Description】: 1. When ON, the initial step S0 is ON. If X0 is ON, then Y0 will be ON.

2. When S0 is ON: a. if X1 is ON, then step S20 will be ON and Y1 will be ON.

b. if X2 is ON, then step S21 will be ON and Y2 will be ON.

c. if X3 is ON, then step S22 will be ON and Y3 will be ON.

d. if X1, X2 and X3 are all ON simultaneous, then step S20 will have the priority to be ON first and either S21 or S22 will not be ON.

e. if X2 and X3 are ON at the same time, then step S21 will have the priority to be ON first and S22 will not be ON.

3. When S20 isON, if X5 and X7 are ON at the same time, then step S23 will be ON, Y4 will be ON and S20 and Y1 will be OFF.

4. When S21 is ON, if X4 is ON, then step S0 will be ON and S21 and Y2 will be OFF.

5. When S22 is ON, if X6 and X7 are ON at the same time, then step S23 will be ON, Y4 will be ON and S22 and Y3 will be OFF.

6. When S23 is ON, if X8 is ON, then step S0 will be ON and S23 and Y4 will be OFF.

●

TO Sxxx : S0≦Sxxx≦S999(Displayed in WinProladder)

or
TO Sxxx : S0≦Sxxx≦S999(Displayed in FP-08)

This instruction describes the step to be transferred to.

【Example】

M1924

Y1

X0

Y0

Y2

WinProladder

X0

TO S0

Y0

FP-08

M1924

M1924

ORG

TO

S0

STP S0

STP

S0

STP S0

AND

X0

STP S21

STP S20

X1

TO S20

Y1

OUT

Y0

X1

FROM

S0

AND

X1

STP S20

TO S21

TO

S20

TO

S21

Y3

X2

STP

S20

OUT

Y1

Y2

STP S22

STP

S21

STP S21

OUT

Y2

X3

X4

Y4

STP S22

X2

TO S22

Y3

FROM

S21

AND

X2

TO

S22

STP

S22

STP S23

X3

TO S23

Y4

OUT

Y3

FROM S20

FROM

S20

X5

FROM

S22

FROM S22

X4

AND

X3

TO

S23

STP S23

STP

S23

STPEND

X5

TO S0

AND

X4

OUT

Y4

FROM

S23

AND

X5

TO

S0

STPEND

【Description】: 1. When ON, the initial step S0 is ON. If X0 is ON, then Y0 will be ON.

2. When S0 is ON: if X1 is ON, then steps S20 and S21 will be ON simultaneously and Y1 and Y2 will also be ON.

3. When S21 is ON: if X2 is ON, then step S22 will be ON, Y3 will be ON and S21 and Y2 will be OFF.

4. When S20 and S22 are ON at the same time and the transferring condition X3 is ON, then step S23 will be ON (if X4 is ON, then Y4 will be ON) and S20 and S22 will automatically turn OFF and Y1 and Y3 will also turn OFF.

5. When S23 is ON: if X5 is ON, then the process will transfer back to the initial step, i.e. So will be ON and S23 and Y4 will be OFF.

●

STPEND :(Displayed in WinProladder)

or
STPEND:(Displayed in FP-08)

This instruction represents the end of a process. It is necessary to include this instruction so all processes can be operated correctly.

A PLC can have up to 8 step processes (S0~S7) and is able to control them simultaneously. Therefore, up to 8 STPEND instructions can be obtained.

【Example】

M1924

WinProladder

TO S0

FP-08

M1924

M1924

ORG

TO

S0

STP S0

STP S0

TO S1

STP

S0

․

․

STPEND

․

M1924

STPEND

STPEND

ORG

M1924

TO

S1

M1924

STP S1

TO S7

STP

S1

․

STP S1

․

․

STPEND

M1924

STPEND

STPEND

ORG

M1924

TO

S7

M1924

STP S7

STP

S7

․

STP S7

․

STPEND

․

STPEND

STPEND

【Description】 When ON, the 8 step processes will be active simultaneously.

8.4Notes for Writing a Step Ladder Diagram

【Notes】

● In actual applications, the ladder diagram can be used together with the step ladder.

● There are 8 steps, S0~S7, that can be used as the starting point and are called the “initial steps”.

● When PLC starts operating, it is necessary to activate the initial step. The M1924 (the first scan ON signal) provided

by the system may be used to activate the initial step.

● Except the initial step, the start of any other steps must be driven by other step.

● It is necessary to have an initial step and the final STPEND instruction in a step ladder diagram to complete a step

process program.

● There are 980 steps, S20~S999, available that can be used freely. However, used numbers cannot be repeated.

S500~S999 are retentive(The range can be modified by users), can be used if it is required to continue the machine

process after power is off.

● Basically a step must consists of three parts which are control output, transition conditions and transition targets.

● MC and SKP instructions cannot be used in a step program and the sub-programs. It’s recommended that JMP

instruction should be avoided as much as possible.

● If the output point is required to stay ON after the step is divergent to other step, it is necessary to use the SET

instruction to control the output point and use RST instruction to clear the output point to OFF.

● Looking down from an initial step, the maximum number of horizontal paths is 16. However, a step is only allowed to

have up to 8 branch paths.

● When M1918=0(default), if a PULSE type function instruction is used in master control loop (FUN 0) or a step

program, it is necessary to connect a TU instruction before the function instruction. For example,

S20

STP S20

C0

5

PV :

When M1918=1, the TU instruction is not required, e.g.:

STP S20

C0

5

PV :

Example 1

M1924

X0

Y0

X4

Y2

WinProladder

X0

X2

TO S0

Y0

FP-08

ORG

M1924

M1924

Net0

TO

S0

STP S0

STP S0

STP

S0

TO S20

AND

X0

X1

X1

Y1

X3

OUT

Y0

S0

X2

FROM

S0

X3

AND

X1

TO S0

STP S20

STP S21

OUT TR

0

X5

X11

X6

STP S20

X5

X4

TO S21

Y1

Net1

AND

X2

TO

S20

X7

Y3

LD TR

0

AND

X3

STP S22

TO

S0

X7

Y2

LD TR

0

STP S21

X8

AND

X4

TO

S21

FROM S20

X6

TO S22

Y3

Net2

STP

S20

OUT

Y1

FROM S21

Net3

STP

S21

X11

STP S22

OUT

Y2

STPEND

X8

TO S0

Net4

FROM

S20

AND

X5

FROM

S21

AND

X6

ORLD

AND

X7

TO

S22

Net5

STP

S22

AND

X11

OUT

Y3

FROM

S22

AND

X8

TO

S0

Description 1. Input the condition to initial step S0

Net6

STPEND

2. Input the S0 and the divergent conditions of S20, S0 and S21 3. Input the S20
4. Input the S21
5. Input the convergence of S20 and S21
6. Input the S22

Example 2

M1924

WinProladder

TO S0

FP-08

ORG

M1924

M1924

Net0

TO

S0

STP S0

X0

Y0

Y3

STP S0

X0

X2

TO S20

Y0

Net1

STP

S0

AND

X0

X1

X1

OUT

Y0

FROM

S0

X2

Y1

X3

STP S20

X4

X3

TO S22

Y1

AND

X1

STP S20

STP S22

OUT TR

0

AND

X2

Y2

X4

X6

TO

S20

LD TR

0

STP S21

TO S21

Y2

AND

X3

X5

TO

S22

X11

Y4

STP S21

X5

X7

Net2

STP

S20

X7

STP S22

Y3

OUT

Y1

FROM

S20

STP S23

AND

X4

TO

S21

X8

FROM S21

X6

TO S23

Net3

STP

S21

FROM S22

OUT

Y2

STP S23

X11

Y4

Net4

STP

S22

OUT

Y3

STPEND

X8

TO S0

Net5

FROM

S21

AND

X5

FROM

S22

AND

X6

ORLD

AND

X7

TO

S23

Net6

STP

S23

AND

X11

OUT

Y4

FROM

S23

AND

X8

TO

S0

Description 1. Input the condition to initial step S0

Net7

STPEND

2. Input the S0 and the divergent condition of S20 and S22
3. Input the S20
4. Input the S21
5. Input the S22
6. Input the convergence of S21 and S22
7. Input the S23

Example 3

M1924

Y0

STP S22

X4

Y5

WinProladder

X1

X7

TO S0

Y0

FP-08

ORG

M1924

M1924

Net0

TO

S0

STP S0

Y1

STP S0

TO S20

Net1

STP

S0

OUT

Y0

X1

FROM

S0

X4

Y1

OUT TR

0

TO S24

AND

X1

STP S20

STP S24

TO

S20

X2

Y2

X6

STP S20

X2

TO S21

Net2

LD TR

0

AND

X4

Y3

STP S21

TO

S24

Y2

STP

S20

TO S22

X3

OUT

Y1

FROM

S20

STP S23

Y4

STP S21

X3

TO S23

Y3

AND

X2

TO

S21

STP S22

X5

TO

S22

Net3

STP

S21

FROM S21

X7

OUT

Y2

FROM S22

X5

TO S0

Y4

Net4

STP

S22

OUT

Y3

STP S23

Y5

FROM

S21

Net5

STP S24

FROM

S22

AND

X3

FROM S23

X6

Net6

TO

S23

FROM S24

STP

S23

OUT

Y4

STPEND

Net7

STP

S24

OUT

Y5

Net8

FROM

S23

AND

X5

FROM

S24

AND

X6

ORLD

AND

X7

TO

S0

Description 1. Input the condition to initial step S0

Net9

STPEND

2. Input the S0 and the divergences of S20 and S24
3. Input the S20
4. Input the S20 and the divergences of S21 and S22
5. Input the S21
6. Input the S22
7. Input the convergences of S21 and S22
8. Input the S23
9. Input the S24
10. Input the convergences of S23 and S24

8.5 Application Examples

Example 1 Grasp an object from tank A and put it in Tank B

X4 : Right Limit
LS

X0 : Start

X1 : Left Limit

LS

Y0 : Move Left
Motor Leadscrew Y1 : Move Right

Y2 : Lift Up X2 : Upper Limit
Y3 : Stretch Down X3 : Lower Limit

Arm

Claw (Y4)

Tank A Tank B

M1924

STP S0

Start

Return to the origin (claw released

1S delay to ensure the object is firmly grasped

at the left limit and the upper limit)

X0

Lower Limit

Arm stretches downward

STP S20

X3

Stop stretching downward

STP S21

Claw grasps (after 1S)

before being lifted up

T0

1S Delaly

Arm lifts up

1S delay to ensure the object has been

STP S22

Upper Limit

X2

Stop lifting up

STP S23

Right Limit

Move arm to the right

X4

Stop moving to the right

STP S24

Lower Limit

Arm stretches downwards

X3

Stop stretching downwards

STP S25

1S Delay

Release claw (after 1S)

completely released before lifting the arm up

T1

Upper Limit

Arm lifts up

STP S26

X2

Left Limit

Stop lift up

STP S27

Move arm to the left

X1

WinProladder

X1

TO S0

Release claw

FP-08

M1924

M1924

ORG

TO

S0

STP S0

STP

S0

Y4

OUT TR

0

Y0

OUT NOT

Y4

AND NOT

X1

Return to the left limit

OUT

Y0

STP S20

X2

Y2

Return to the upper limit

LD TR

0

AND NOT

X2

X0

OUT

Y2

TO S20

Turn the switch ON before moving to S20

FROM

S0

AND

X0

Y3

Stretch arm downward

TO

S20

STP

S20

STP S21

X3

TO S21

Move to S21 after stretching to the lower

OUT

Y3

limit

FROM

S20

Claw grasps (since the SET instruction is

AND

X3

EN

SET Y4

TO

S21

used, Y4 should remain ON after departing

STP

S21

from STP S21)

SET

Y4

STP S22

EN

T0 100

Divergent into S22 after 1S

T0 PV:

100

T0

FROM

S21

TO S22

AND

T0

Lift the arm up

TO

S22

Y2

STP

S22

Divergent into S23 after reaching the upper

OUT

Y2

STP S23

X2

TO S23

limit

FROM

S22

AND

X2

Move arm to the right

TO

S23

Y1

Divergent into S24 after moving to the right

STP

S23

X4

TO S24

OUT

Y1

limit

FROM

S23

Stretch the arm downward

AND

X4

TO

S24

STP S24

X3

Y3

Divergent into S25 after stretching to the

STP

S24

lower limit

OUT

Y3

TO S25

FROM

S24

Release claw

AND

X3

STP S25

EN

Delay for 1S

TO

S25

RST Y4

STP

S25

RST

Y4

STP S26

EN

T1 100

Transfer into S26 after 1S

T1 PV:

100

FROM

S25

T1

Lift the arm up

TO S26

AND

T1

TO

S26

Y2

Divergent into S27 after reaching the upper

STP

S26

limit

OUT

Y2

STP S27

X2

TO S27

FROM

S26

Move the arm to the left

AND

X2

Divergent into S0 after moving to the left

TO

S27

Y0

STP

S27

limit (a complete cycle)

OUT

Y0

STPEND

X1

TO S0

FROM

S27

AND

X1

TO

S0

STPEND

Example 2 Liquid Stirring Process

Liquid

No Liquid Limit

Dried
material

Empty Limit
Switch
X1

Switch

X2

Value Y7

Value 1 Y5

CH0 : R3840

Weighing

Value 1 Y6

Clear Water Clean Water

Value Y9

Stirring Unit

Value 4 Y10

Finished Product
Outlet

Œ

Y8

Stirring

X4

Electromagnetic Switch

Motor

Overload Switch

Input Points: Empty limit switch X1

No liquid limit switch X2
Empty limit switch X3
Over-load switch X4
Warning clear button X5
Start button X6
Water washing button X7

Œ Warning Indicators: Empty dried material Y1
Insufficient liquid Y2
Empty stirring unit Y3
Motor over-load Y4

Œ Output Points: Dried material inlet valve Y5
Dried material inlet valve Y6
Liquid inlet valve Y7
Motor start electromagnetic valve Y8
Clean water inlet valve Y9
Finished product outlet valve Y10

Œ Weighing Output: CH0(R3840)

Œ M1918=0

WinProladder

Warning indicators

FP-08

M1924

STP

S22

M1924

TO S0

ORG

TO

S0

OUT

Y7

STP S0

X1

SET Y1

STP

S0

T1 PV: 800

X2

SET Y2

OUT TR

0

FROM

S21

X3

SET Y3

AND NOT

X1

FROM

S22

SET

Y1

AND

T0

X4

SET Y4

LD TR

0

AND

T1

X5

RST Y1

AND NOT

X2

TO

S23

RST Y2

Reset warning

SET

Y2

STP

S23

LD TR

0

OUT TR

0

RST Y3

AND

X3

OUT

Y8

RST Y4

Production start

SET

Y3

LD TR

0

X6

Y1

Y2

Y3

Y4

TO S20

LD TR

0

T2 PV:

4500

X7

Y3

Y4

TO S24

AND

X4

LD TR

0

Water washing start

SET

Y4

AND

X4

Y5

LD TR

0

OUT

Y4

STP S20

17CMP

M0

Input weighing

AND

X5

STP

S24

RST

Y1

OUT TR

0

Sa : R3840
Sb : R0

M1

RST

Y2

T3 PV:

500

Status after weighing

RST

Y3

LD TR

0

M0

TO S21

RST

Y4

AND NOT

T3

M1

TO S22

FROM

S0

OUT

Y9

Divergent into S21 and S22

Y6

OUT TR

1

LD TR

0

STP S21

Input material to stirring

AND

X6

T4 PV:

1500

ENT0 500

unit

AND NOT

Y1

LD TR

0

AND NOT

Y2

AND NOT

T4

Y7

Add liquid to stirring unit

AND NOT

Y3

OUT

Y10

STP S22

AND NOT

Y4

FROM

S23

ENT1 800

TO

S20

AND

T2

FROM S21

T0

T1

TO S23

LD TR

1

FROM

S24

Complete dried material

AND

X7

AND

T4

FROM S22

and liquid input, transfer

AND NOT

Y3

ORLD

S25

Y8

the status to S23

AND NOT

Y4

TO

STP S23

TO

S24

STP

S25

ENT2 4500

Stirring timer

STP

S20

OUT TR

0

X4

Y4

Wash stirring unit

OUT

Y5

AND

X3

FUN

17

OUT

Y10

STP S24

ENT3 500

Sa:R3840

LD TR

0

T3

Y9

Sb:R0

0

AND TU

S25

Input clean water

FO

FUN

15DP

ENT4 1500

Drain water out

OUT

M0

D:R10

S25

FO

1

FROM

T4

Y10

OUT

M1

AND NOT

X3

FROM S23

T2

TO S25

Output finished product

FROM

S20

TO

S0

LD

M0

STPEND

T4

FROM S24

OR

M1

STP S25

X3

Y10

ANDLD

and accumulate the cycle

TO

S21

S25

15DP
+1 R10

TO

S22

X3

TO S0

STP

S21

STPEND

OUT

Y6

T0 PV:

500

Example 3 Pedestrian Crossing Lights

Y0 (Red) Y0 (Red)

Y1 (Amber) Y1 (Amber)

Y2 (Green)

Y2 (Green)

Y4 Y4

(Green) (Green)

X0 X0

Y3 (Red) Y3 (Red)

Y4 (Green) Y4 (Green)

X1 X1

Œ

Input Points:

Pedestrian Push Button X0

Œ

Output Points:

Road Red Light Y0

Pedestrian Push Button X1

Œ M1918=0

● Pedestrian Crossing Lights Control Process Diagram

M1924

Y2

STP S0 Road Green Light

Y3

Pedestrian Crossing Light

X0

X1

Pedestrian Push Button

STP S30

Y3

Pedestrian Crossing

Y2

STP S20

Road Green Light

Red Light

T0

Y1

T0 3000

T2

Y4

Pedestrian Crossing

STP S21

STP S31

Road Amber Light

Green Light

T1

T3

Y4

T3 2000

Y0

T1 500

STP S22

STP S32

T4 100

Road Red Light

T4

T2 500

STP S33

Pedestrian Crossing

Green Light BLink

S33

C1

PV : 6

T5 100

C1

Y3

C1

T5

T5

STP S34

S32

Pedestrian Crossing

Red Light

RST C1

T6 100

T6

●

Pedestrian Crossing Lights Control Program

FP-08

M1924

STP

S32

WinProladder

M1924

TO S0

ORG

TO

S0

T4 PV:

100

Y2

STP S0

STP

S0

FROM

S32

Y3

OUT

Y2

AND

T4

X0

TO S20

OUT

Y3

TO

S33

X1

TO S30

FROM

S0

STP

S33

Y2

LD

X0

OUT TR

0

STP S20

OR

X1

OUT

Y4

ENT0 3000

ANDLD

S20

LD TR

0

TO

AND TU

S33

T0

TO S21

TO

S30

LD

OPEN

Y1

STP

S20

C1 PV:

6

STP S21

ENT1 500

OUT

Y2

LD TR

0

T0 PV:

3000

T5 PV:

100

T1

TO S22

FROM

S20

FROM

S33

Y0

AND

T0

OUT TR

1

STP S22

TO

S21

AND NOT

C1

ENT2 500

STP

S21

AND

T5

Y3

OUT

Y1

TO

S32

STP S30

T1 PV:

500

LD TR

1

T2

TO S31

FROM

S21

AND

C1

Y4

AND

T1

AND

T5

STP S31

TO

S22

TO

S34

ENT3 2000

STP

S22

STP

S34

T3

TO S32

OUT

Y0

OUT

Y3

T2 PV:

500

RST

C1

STP S32

ENT4 100

STP

S30

T6 PV:

100

T4

TO S33

OUT

Y3

FROM

S22

Y4

FROM

S30

FROM

S34

STP S33

AND

T2

AND

T6

S33

TO

S31

TO

S0

C1

STP

S31

STPEND

PV : 6

ENT5 100

OUT

Y4

T3 PV:

2000

C1

T5

TO S32

FROM

S31

C1

T5

TO S34

AND

T3

Y3

TO

S32

STP S34

RST C1

ENT6 100

FROM S22

T6

TO S0

FROM S34

STPEND

8.6Syntax Check Error Codes for Step Instruction

The error codes for the usage of step instruction are as follows:

E51 : TO(S0-S7) must begin with ORG instruction.

E52 : TO(S20-S999) can’t begin with ORG instruction.

E53 : TO instruction without matched FROM instruction.

E54 : To instruction must comes after TO, AND, OR, ANDLD or ORLD instruction.

E56 : The instructions before FROM must be AND, OR, ANDLD or ORLD E57 :The instruction after FROM can’t be a coil or a function
E58 :Coil or function must before FROM while in STEP network
E59 : More than 8 TO# at same network.

E60 : More than 8 FROM# at same network.

E61 : TO(S0-S19) must locate at first row of the network.

E62 : A contact occupies the location for TO instruction.

E72 : Duplicated TO Sxx instruction.

E73 : Duplicated STP sxx instruction.

E74 : Duplicated FROM sxx instruction.

E76 : STP(S0~S19) without a matched STPEND or STPEND without a matched STP(S0~S19). E78 : TO(S20~S999), STP (S20~S999) or FROM instructions comes before or without STP(S0~S19). E79 : STP Sxx or FROM Sxx instructions comes before or without TO Sxx.

E80 : FROM Sxx instruction comes before or without STP Sxx.

E81 : The max. level of branches must <=16.

E82 : The max. no. of branches with same level must <=16.

E83 : Not place the step instruction with TO->STP->FROM sequence.

E84 : The definition of STP# sequence not follow the TO# sequence.

E85 : Convergence do not match the corresponding divergence.

E86 : Illegal usage of STP or FROM before convergent with TO instruction.

E87 : STP# or FROM# comes before corresponding TO#.

E88 : During this branch, STP# or FROM# comes before the corresponding TO#.

E89 : FROM# comes before corresponding TO# or STP#.

E90 : Invalid To# usage in the simultaneous branch.

E91 : Flow control function cannot be used in the step ladder region

Was this page helpful?

Tip: press ← → to switch chapters, Ctrl+K to search