Program Execution Control; Timer Execution - Mitsubishi Electric MELSEC iQ-R Series Programming Manual

Process control function blocks
Hide thumbs Also See for MELSEC iQ-R Series:
Table of Contents

Advertisement

1.5

Program Execution Control

An FBD/LD program for process control can be set a program execution cycle.
There are two methods for executing a program: timer execution and interrupt execution (fixed scan). Select either of the
methods in accordance with the intended use of the program.

Timer execution

An FBD/LD program for process control is executed in the execution cycle (T) which is set to each program.
Among tag access FBs that structure of a loop tag FB, M+P_IN, M+P_PHPL, and M+P_OUT1 used in I/O control are
executed every execution cycle. Additionally, M+P_PID and M+P_2PID used in loop control operation are executed in the
control cycle (CT) which is set to each tag. ( Page 28 Control cycle (CT))
Setting the execution cycle (T)
Select "High-Speed", "Normal-Speed", or "Low-Speed" for an execution cycle of each program block.
Set the execution cycle on the "Properties" window of the program block.
Changing the execution cycle (T)
The following table lists the setting values and details of the execution cycle.
Execution cycle
Description
High-Speed
"50ms", "100ms", or "200ms" can be selected for the high-speed execution cycle.
The normal-speed execution cycle is "High-speed execution cycle  Setting value".
Normal-Speed
"2", "3", "4", or "5" can be selected for the normal-speed execution cycle.
The normal-speed execution cycle is "High-speed execution cycle  Setting value".
Low-Speed
"5", "10", "20", "25", or "50" can be selected for the low-speed execution cycle.
The high-speed execution cycle and the setting values for normal/low-speed execution cycle can be set on the "Options"
window of the engineering tool.
■Precautions
Set the scan time so that it is equal to or shorter than the high-speed execution cycle.
If the scan time exceeds the high-speed execution cycle, the fixed scan cycle cannot be maintained and an error of one scan
time will occur at maximum in the timer execution program cycle. ( Page 25 Phase and execution order)
Ex.
When the high-speed execution cycle is 200ms
0ms
(1)
Scan program
High speed
(1) When the timer exceeds the specific cycle, the program block for process control is executed.
(2) When the scan program is executed for the specific cycle or longer, the program block for process control is executed after the execution of the scan
program ends.
(3) The time to the end of the last scan program is an error. An error of one scan time can be occur at maximum.
1 PROCESS CONTROL FUNCTION BLOCK
24
1.5 Program Execution Control
200ms
(2)
Scan program
High speed
(3)
400ms
Scan program
Default
200ms
1000ms
(Setting value = 5)
4000ms
(Setting value = 20)

Advertisement

Table of Contents
loading

Table of Contents