EasyManuals Logo
Home>Mitsubishi>Controller>00JCPU

Mitsubishi 00JCPU User Manual

Mitsubishi 00JCPU
542 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 #50 background imageLoading...
Page #50 background image
2 - 5
2.2.2 Subroutine program
(1) Definition
Subroutine program is a program from a pointer (P ) to the RET instruction.
This program is executed only when it is called by a subroutine program call instruction (such as CALL(P),
FCALL(P)) from a main routine program.
(2) Application
• Programming a program which is executed two or more times in one scan as a subroutine program can
reduce the number of steps in the entire program.
• Programming a program which is executed only when a certain condition is satisfied as a subroutine
program can shorten the scan time.
(3) Programming of subroutine programs
Create subroutine programs between the FEND and END instructions in the main routine program.
*1: Since the Basic model QCPU cannot execute multiple programs, the file name is fixed to "MAIN".
*2: The pointer numbers do not need to be specified in ascending order.
Subroutine programs can be managed as one separate program (stand-by type program). ( Section 2.3.4)
Remark
Subroutine programs can be configured with the nesting. ( Section 9.8)
Figure 2.6 Programming location of subroutine programs
Program A
*1
P0
FEND
RET
RET
RET
END
Y10
Y11
Y12
P8
P1
Main routine
program
Subroutine
program
pointer
*2

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Mitsubishi 00JCPU and is the answer not in the manual?

Mitsubishi 00JCPU Specifications

General IconGeneral
BrandMitsubishi
Model00JCPU
CategoryController
LanguageEnglish

Related product manuals