4-35
4 Understanding Programming
CP2E CPU Unit Software User’s Manual(W614)
4-8 L
ad
d
er Pr
o
g
ram
m
in
g Precaution
s
4
4-
8
-1 Special Prog
ram Sections
4-8
Ladder Programming Precautions
For CP2E CPU Units, programs have special program sections that will control instruction conditions.
The following special program sections are available.
The following table shows which of the special instructions can be used inside other program sections.
Place all the subroutines together just after all of the main program and before the END instruction.
A subroutine cannot be placed in a step ladder, block program, or FOR-NEXT section.
If instructions other than those in a subroutine are placed after a subroutine (SBN to RET), those
instructions will not be executed.
4-8-1
Special Program Sections
Program sections
Instructions
Instruction
conditions
Status
Subroutine sections
SBS, SBN, and RET instruc-
tions
Subroutine program
is executed.
The subroutine program
section between SBN and
RET instructions is exe-
cuted.
IL-ILC sections
IL and ILC instructions
During IL
The output bits are turned
OFF and timers are reset.
Other instructions will not be
executed and previous sta-
tus will be maintained.
Step ladder sections
STEP instructions
FOR-NEXT sections
FOR and NEXT instructions
Break in progress.
Looping
Instruction Combinations
Subroutine
sections
IL-ILC
sections
MILH and
MILR-MILC
sections
Step ladder
sections
FOR-NEXT
sections
Subroutine sections
No
No
No
No
No
IL-ILC sections
Yes
No
No
No
Yes
MILH and MILR-MILC sections
Yes
No
Yes
No
Yes
Step ladder sections
No
Yes
Yes
No
No
FOR-NEXT sections
Yes
Yes
Yes
No
Yes
Subroutines
Program
S
ub
ro
u
tines
Summary of Contents for SYSMAC CP Series
Page 3: ......
Page 32: ...1 Overview 1 4 CP2E CPU Unit Software User s Manual W614 ...
Page 44: ...3 CPU Unit Operation 3 8 CP2E CPU Unit Software User s Manual W614 ...
Page 116: ...6 I O Allocation 6 8 CP2E CPU Unit Software User s Manual W614 ...
Page 144: ...7 PLC Setup 7 28 CP2E CPU Unit Software User s Manual W614 ...
Page 170: ...10 Interrupts 10 14 CP2E CPU Unit Software User s Manual W614 ...
Page 200: ...11 High speed Counters 11 30 CP2E CPU Unit Software User s Manual W614 ...
Page 272: ...12 Pulse Outputs 12 72 CP2E CPU Unit Software User s Manual W614 ...
Page 278: ...13 PWM Outputs 13 6 CP2E CPU Unit Software User s Manual W614 ...
Page 460: ...18 Programming Device Operations 18 28 CP2E CPU Unit Software User s Manual W614 ...
Page 576: ...Revision 2 CP2E CPU Unit Software User s Manual W614 ...
Page 577: ......