EasyManua.ls Logo

Mitsubishi Electric MELSEC iQ-F FX5 - Program Block

Mitsubishi Electric MELSEC iQ-F FX5
64 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
Loading...
10
2 PROGRAM CONFIGURATION
2.1 Program Block
2.1 Program Block
A program block is a unit of a program.
Multiple program blocks can be created in one program file, and are executed in the registered order.
By dividing program blocks by functions or processing, changing the program order or replacing the program becomes easy.
Program blocks are stored in program files of each program in the registration destination.
Creating main routine programs, subroutine programs, and interrupt programs for each program block makes the program
easy to read.
For details on the main routine program, subroutine program, and interrupt program, refer to the following.
User's manual (Application)
Create subroutine programs and interrupt programs after the FEND instruction. The program area after the FEND
instruction is not executed as the main routine program. For example, when the FEND instruction is used at the end of the
second program block, the third program block and later are handled as subroutine programs or interrupt programs.
To make the program easy to read, use twin instructions, such as FOR and NEXT instructions and MC and MCR
instructions, in the same program block.
A simple program can be executed by the CPU module with just a main routine program in one program block.
Type Description
Main routine program Program segment from the step 0 to the FEND instruction
Subroutine program Program segment from a pointer (P) to the RET instruction
Executed only when a subroutine call instruction (CALL instruction etc.) is executed.
Interrupt program Program segment from an interrupt pointer (I) to the IRET instruction
When an interrupt is triggered, the interrupt program corresponding to the interrupt pointer number is executed.
Program file
Program block 1
Program block 2

Other manuals for Mitsubishi Electric MELSEC iQ-F FX5

Related product manuals