EasyManuals Logo

Omron SYSMAC CP Series Instruction & Reference Manual

Omron SYSMAC CP Series
467 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #333 background imageLoading...
Page #333 background image
2-297
2 Instructions
CP1E CPU Unit Instructions Reference Manual(W483)
Subroutines Instructions
2
SBN/RET
• The step instructions, STEP(008) and SNXT(009) cannot be used in subroutines.
• Place the subroutines after the main program and just before the END(001) instruction in the program
for each task. If part of the main program is placed after the subroutine region, that program section
will be ignored.
Sample program
Note The input method for the subroutine number, N, is dif-
ferent for the CX-Programmer. Input #0 to #127 on
the CX-Programmer.
When CIO 0.00 is ON in the following exam-
ple, subroutine 10 is executed and program
execution returns to the next instruction after
the SBS(091) or MCRO(099) instruction that
called the subroutine.
SBN
SNXT
STEP
RET
Not allowed
END
Subroutine region
This part of the
program won’t
be executed.
SBS
n
0.00
SBN
n
RET
SBS
#10
0.00
SBN
#10
RET
END
Subroutine 10

Table of Contents

Other manuals for Omron SYSMAC CP Series

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Omron SYSMAC CP Series and is the answer not in the manual?

Omron SYSMAC CP Series Specifications

General IconGeneral
BrandOmron
ModelSYSMAC CP Series
CategoryComputer Hardware
LanguageEnglish

Related product manuals