Omron CP - PROGRAMMING MANUAL 05-2007 Programming Manual page 706

Cp1h/cp1l cpu unit
Table of Contents

Advertisement

Subroutines
Main program
Subroutines
Example 2: Sequential (Non-nested) Subroutines
When CIO 0.00 is ON in the following example, subroutine 1 is executed and
program execution returns to the next instruction after SBS(091) 1. When
CIO 0.01 is ON, subroutine 2 is executed and program execution returns to
the next instruction after SBS(091) 2.
0.00
0.01
1
CIO 0.00 ON
3
CIO 0.01 ON
5
0.00
2
4
Program end
Section 3-18
Order of execution
0.01
A
S1 B
S2 C
A
S1 B
C
A
B
S2 C
A
B
C
673

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents