Mitsubishi PLC PID Control Instructions
Mitsubishi PLC PID Control Instructions
Mitsubishi PLC PID Control Instructions
Under some circumstances, failure to observe the precautions given under " CAUTION" may lead to serious
consequences.
Observe the precautions of both levels because they are important for personal and system safety.
Make sure that the end users read this manual and then keep the manual in a safe place for future reference.
[Design Precautions]
WARNING
Configure safety circuits external to the programmable controller to ensure that the entire system
operates safely even when a fault occurs in the external power supply or the programmable controller.
Failure to do so may result in an accident due to an incorrect output or malfunction.
(1) Emergency stop circuits, protection circuits, and protective interlock circuits for conflicting
operations (such as forward/reverse rotations or upper/lower limit positioning) must be configured
external to the programmable controller.
(2) When the programmable controller detects an abnormal condition, it stops the operation and all
outputs are:
Turned off if the overcurrent or overvoltage protection of the power supply module is activated.
Held or turned off according to the parameter setting if the self-diagnostic function of the CPU
module detects an error such as a watchdog timer error.
(3) All outputs may be turned on if an error occurs in a part, such as an I/O control part, where the
CPU module cannot detect any error. To ensure safety operation in such a case, provide a safety
mechanism or a fail-safe circuit external to the programmable controller. For a fail-safe circuit
example, refer to "General Safety Requirements" in the MELSEC-L CPU Module User's Manual
(Hardware Design, Maintenance and Inspection).
Configure a circuit so that the programmable controller is turned on first and then the external power
supply. If the external power supply is turned on first, an accident may occur due to an incorrect output
or malfunction.
1
[Design Precautions]
WARNING
When connecting a peripheral with the CPU module or connecting an external device, such as a
personal computer, with an intelligent function module to modify data of a running programmable
controller, configure an interlock circuit in the program to ensure that the entire system will always
operate safely. For other forms of control (such as program modification or operating status change)
of a running programmable controller, read the relevant manuals carefully and ensure that the
operation is safe before proceeding. Especially, when a remote programmable controller is controlled
by an external device, immediate action cannot be taken if a problem occurs in the programmable
controller due to a communication failure. To prevent this, configure an interlock circuit in the program,
and determine corrective actions to be taken between the external device and CPU module in case of
a communication failure.
2
CONDITIONS OF USE FOR THE PRODUCT
(1) Mitsubishi programmable controller ("the PRODUCT") shall be used in conditions;
i) where any problem, fault or failure occurring in the PRODUCT, if any, shall not lead to any major or serious accident;
and
ii) where the backup and fail-safe function are systematically or automatically provided outside of the PRODUCT for the
case of any problem, fault or failure occurring in the PRODUCT.
(2) The PRODUCT has been designed and manufactured for the purpose of being used in general industries.
MITSUBISHI SHALL HAVE NO RESPONSIBILITY OR LIABILITY (INCLUDING, BUT NOT LIMITED TO ANY AND ALL
RESPONSIBILITY OR LIABILITY BASED ON CONTRACT, WARRANTY, TORT, PRODUCT LIABILITY) FOR ANY
INJURY OR DEATH TO PERSONS OR LOSS OR DAMAGE TO PROPERTY CAUSED BY the PRODUCT THAT ARE
OPERATED OR USED IN APPLICATION NOT INTENDED OR EXCLUDED BY INSTRUCTIONS, PRECAUTIONS, OR
WARNING CONTAINED IN MITSUBISHI'S USER, INSTRUCTION AND/OR SAFETY MANUALS, TECHNICAL
BULLETINS AND GUIDELINES FOR the PRODUCT.
("Prohibited Application")
Prohibited Applications include, but not limited to, the use of the PRODUCT in;
Nuclear Power Plants and any other power plants operated by Power companies, and/or any other cases in which the
public could be affected if any problem or fault occurs in the PRODUCT.
Railway companies or Public service purposes, and/or any other cases in which establishment of a special quality
assurance system is required by the Purchaser or End User.
Aircraft or Aerospace, Medical applications, Train equipment, transport equipment such as Elevator and Escalator,
Incineration and Fuel devices, Vehicles, Manned transportation, Equipment for Recreation and Amusement, and
Safety devices, handling of Nuclear or Hazardous Materials or Chemicals, Mining and Drilling, and/or other
applications where there is a significant risk of injury to the public or property.
Notwithstanding the above, restrictions Mitsubishi may in its sole discretion, authorize use of the PRODUCT in one or
more of the Prohibited Applications, provided that the usage of the PRODUCT is limited only for the specific
applications agreed to by Mitsubishi and provided further that no special quality assurance or fail-safe, redundant or
other safety features which exceed the general specifications of the PRODUCTs are required. For details, please
contact the Mitsubishi representative in your region.
3
CONTENTS
SAFETY PRECAUTIONS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1
CONDITIONS OF USE FOR THE PRODUCT . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3
MANUALS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .6
RELEVANT MANUALS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .6
GENERIC TERMS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .9
4
CHAPTER 8 INCOMPLETE DERIVATIVE PID CONTROL INSTRUCTIONS AND
PROGRAM EXAMPLES 60
8.1 PID Control Instructions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60
PID control data settings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60
PID operation. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61
Operation stop/start of designated loop no.. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63
Parameter change at designated loop. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64
8.2 PID Control Program Examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66
System configuration for program examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66
CONTENTS
Program example for automatic mode PID control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66
Program example for changing the PID control mode between automatic and manual . . . . . . . . . . . . . . . . . . . 69
APPENDICES 96
Appendix 1 Processing Time List. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 96
Appendix 2 Anti-Reset Windup Measure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 100
INDEX 101
REVISIONS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .105
WARRANTY . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .106
5
MANUALS
The manuals related to this product are listed below.
In necessary, order them by quoting the details in the tables below.
RELEVANT MANUALS
Manual name Manual number
(Model Code)
QnUCPU User's Manual (Function Explanation, Program Fundamentals) SH-080807ENG
Describes the functions, programming procedures, devices, etc. necessary to create programs. (Sold separately) (13JZ27)
Qn(H)/QnPH/QnPRHCPU Users Manual(Function Explanation, Program Fundamentals) SH-080808ENG
Describes the functions, programming procedures, devices, etc. necessary to create programs. (Sold separately) (13JZ28)
MELSEC-L CPU Module User's Manual (Function Explanation, Program Fundamentals) SH-080889ENG
Describes the functions, programming procedures, devices, etc. necessary to create programs. (13JZ35)
QnACPU Programming Manual (Fundamentals) IB-66614
Describes how to create programs, the names of devices, parameters, and types of program. (Sold separately) (13JF46)
MELSEC-Q/L Programming Manual (Common Instructions) SH-080809ENG
Describes how to use sequence instructions, basic instructions, and application instructions. (Sold separately) (13JW10)
QnACPU Programming Manual (Common Instructions) SH-080810ENG
Describes how to use sequence instructions, basic instructions, and application instructions. (Sold separately) (13JW11)
QnACPU Programming Manual (Special Function) SH-4013
Describes the dedicated instructions for special function modules available when using the Q2ACPU(S1), Q3ACPU, and (13JF56)
Q4ACPU. (Sold separately)
QnACPU Programming Manual (AD57 Instructions) IB-66617
Describes the dedicated instructions for controlling an AD57(S1) type CRT controller module available when using the (13JF49)
Q2ACPU(S1), Q3ACPU, or Q4ACPU. (Sold separately)
MELSEC-Q/L/QnA Programming Manual (SFC) SH-080041
Describes the system configuration, performance specifications, functions, programming, debugging, and error codes for SFC (13JF60)
(MELSAP3) programs. (Sold separately)
MELSEC-Q/L Programming Manual (MELSAP-L) SH-080076
Describes programming methods, specifications, and functions for SFC (MELSAP-L) programs. (Sold separately) (13JF61)
MELSEC-Q Programming/Structured Programming Manual (Process Control Instructions) SH-080316E
Describes the dedicated instructions for process control. (Sold separately) (13JF67)
MELSEC-Q/L Programming Manual (Structured Text) SH-080366E
Describes programming using the structured text language. (Sold separately) (13JF68)
Before reading this manual, refer to the user's manual of the used CPU module or the QnACPU Programming Manual
(Fundamentals), and confirm which programs, I/O processing, and devices can be used with the used CPU module.
6
When QCPU is used
7
When QnACPU is used
8
GENERIC TERMS
This manual uses the following generic terms unless otherwise described.
Generic term Description
CPU module A generic term for the Basic model QCPU, High Performance model QCPU, Redundant CPU, Universal model QCPU,
LCPU, and QnACPU
QCPU A generic term for the Q00CPU, Q01CPU, Q02CPU, Q02HCPU, Q06HCPU, Q12HCPU, Q25HCPU, Q12PRHCPU,
Q25PRHCPU, Q00UJCPU, Q00UCPU, Q01UCPU, Q02UCPU, Q03UDCPU, Q03UDVCPU, Q03UDECPU,
Q04UDHCPU, Q04UDVCPU, Q04UDEHCPU, Q06UDHCPU, Q06UDVCPU, Q06UDEHCPU, Q10UDHCPU,
Q10UDEHCPU, Q13UDHCPU, Q13UDVCPU, Q13UDEHCPU, Q20UDHCPU, Q20UDEHCPU, Q26UDHCPU,
Q26UDVCPU, Q26UDEHCPU, Q50UDEHCPU, Q100UDEHCPU
QnCPU A generic term for the Q02CPU
QnHCPU A generic term for the Q02HCPU, Q06HCPU, Q12HCPU, Q25HCPU
QnPHCPU A generic term for the Q02PHCPU, Q06PHCPU, Q12PHCPU, Q25PHCPU
QnPRHCPU A generic term for the Q12PRHCPU, Q25PRHCPU
LCPU A generic term for the L02SCPU, L02SCPU-P, L02CPU, L02CPU-P, L06CPU, L06CPU-P, L26CPU, L26CPU-P, L26CPU-
BT, L26CPU-PBT
QnACPU A generic term for the Q2ASCPU, Q2ASCPU-S1, Q2ASHCPU, Q2ASHCPU-S1, Q2ACPU, Q2ACPU-S1, Q3ACPU,
Q4ACPU, Q4ARCPU
QnA A generic term for the Q2ASCPU, Q2ASCPU-S1, Q2ASHCPU, Q2ASHCPU-S1, Q2ACPU, Q2ACPU-S1, Q3ACPU,
Q4ACPU
Q4AR A generic term for the Q4ARCPU
Basic model QCPU A generic term for the Q00JCPU, Q00CPU, Q01CPU
Basic
High Performance model QCPU A generic term for the Q02CPU, Q02HCPU, Q06HCPU, Q12HCPU, Q25HCPU
High Performance
Process CPU A generic term for the Q02PHCPU, Q06PHCPU, Q12PHCPU, Q25PHCPU
Redundant CPU A generic term for the Q12PRHCPU, Q25PRHCPU
Universal model QCPU A generic term for the Q00UJCPU, Q00UCPU, Q01UCPU, Q02UCPU, Q03UDCPU, Q03UDVCPU, Q03UDECPU,
Q04UDHCPU, Q04UDVCPU, Q04UDEHCPU. Q06UDHCPU, Q06UDVCPU, Q06UDEHCPU, Q10UDHCPU,
Universal
Q10UDEHCPU, Q13UDHCPU, Q13UDVCPU, Q13UDEHCPU, Q20UDHCPU, Q20UDEHCPU, Q26UDHCPU,
Q26UDVCPU, Q26UDEHCPU, Q50UDEHCPU, Q100UDEHCPU
9
1 GENERAL DESCRIPTION
This manual describes the sequence program instructions used to implement PID control with any of the following CPU
modules.
Basic model QCPU (first five digits of serial No. are 04122 or later)
High Performance model QCPU
Redundant CPU
Universal model QCPU
LCPU
QnACPU
For the Basic model QCPU, High Performance model QCPU, Redundant CPU, Universal model QCPU, and LCPU, the
instructions for PID control by using complete and incomplete derivatives are featured as standard.
The QnACPU has the instructions used to perform PID control by complete derivative (PID control instructions) as standard
features.
Since the incomplete derivative PID control instructions and complete derivative PID control instructions are independent of
each other, they can be executed at the same time.
The following table indicates the CPU modules that can use the incomplete derivative PID control instructions and complete
derivative PID control instructions.
: Usable, : Unusable
CPU Module Model Name Incomplete Derivative Complete Derivative
Basic model QCPU First five digits of serial No. are "04121" or earlier
First five digits of serial No. are "04122" or later *1
High Performance model QCPU First five digits of serial No. are "05031" or earlier
First five digits of serial No. are "05032" or later
Redundant CPU
Universal model QCPU
LCPU
QnACPU
*1 Version 7 or earlier version of GX Developer issues an "instruction code alarm" if it loads a new CPU instruction realized with GX
Developer Version 8.
There are the following PID control instructions.
Classification Incomplete Derivative Complete Derivative
PID control data setting S(P).PIDINIT PIDINIT(P)
PID operation S(P).PIDCONT PIDCONT(P)
PID control status monitor PID57(P)
Specified loop No. operation stop S(P).PIDSTOP PIDSTOP(P)
Specified loop No. operation start S(P).PIDRUN PIDRUN(P)
Specified loop No. parameter change S(P).PIDPRMW PIDPRMW(P)
PID control via PID control instructions is implemented by combining the CPU module with the A/D converter module and D/A
converter module.
In the case of the QnACPU, the PID control status can be monitored using the AD57(S1) CRT controller module.
The Process CPU is not compatible with the PID control instructions described in this manual. To implement
PID control using the Process CPU, use the process control instructions described in the MELSEC-Q
Programming/Structured Programming Manual (Process Control Instructions).
The Redundant CPU can use the PID control instructions and process control instructions.
1 GENERAL DESCRIPTION
10
1.1 PID Processing Method
This section describes the processing method for PID control using PID control instructions. ( Page 25 FUNCTIONS OF
1
PID CONTROL)
In the PID control processing method, as shown above, the PID operation is executed using the set value (SV) and the
process value (PV) read from the A/D converter module, and the manipulated value (MV) is then calculated.
The calculated MV (manipulated value) is output to the D/A converter module.
1 GENERAL DESCRIPTION
1.1 PID Processing Method 11
2 SYSTEM CONFIGURATION FOR PID CONTROL
This chapter describes the system configuration for PID control using the PID control instructions.
*1 When the resolution of the A/D converter module or D/A converter module used for I/O of PID control is other than 0 to 2000, convert the
digital values into 0 to 2000.
Operation expressions
The operation expressions for PID control using PID control instructions are indicated below.
Name Operation Expressions Meanings of Symbols
Process value Forward EVn: Deviation in the present sampling cycle
differentiation operation EVn-1: Deviation in the preceding sampling cycle
Incomplete SV: Set value
derivative PVfn: Process value of the present sampling cycle (after
filtering)
PVfn-1: Process value of the preceding sampling cycle
(after filtering)
PVfn-2: Process value of the sampling cycle two cycles
Reverse before (after filtering)
operation MV: Output change value
MVn: Present manipulation value
Dn: Present derivative term
Dn-1: Derivative term of the preceding sampling cycle
KP: Proportional constant
TS: Sampling cycle
TI: Integral constant
TD: Derivative constant
KD: Derivative gain
*1 For the Basic model QCPU, High Performance model QCPU, Redundant CPU, Universal model QCPU, and LCPU, "with or without PID
limits" can be selected.
Refer to Sections 5.1 and 5.2 for details of the setting range when "with/without PID limits" has been selected.
Page 36 PID Control Data, Page 51 I/O Data
Indicates an instruction that is executed once only at the leading edge (OFF to ON) of the condition for its execution; thereafter the
instruction will not be executed, and no processing will be carried out, even if the condition is ON.
*1 For the Basic model QCPU, High Performance model QCPU, Redundant CPU, Universal model QCPU, and LCPU, "with or without PID
limits" can be selected.
Refer to Sections 5.1 and 5.2 for details of the setting range when "with/without PID limits" has been selected.
Page 36 PID Control Data, Page 51 I/O Data
Indicates an instruction that is executed once only at the leading edge (OFF to ON) of the condition for its execution; thereafter the
instruction will not be executed, and no processing will be carried out, even if the condition is ON.
Monitoring PID57 Monitors the PID operation results for the 4 - Page 76
AD57 (S1) (designated by n ). Monitoring
n : First I/O number of the AD57(S1) PID control
S1 : Monitor screen number status
1: Loop 1 to loop 8 (QnACPU
2: Loop 9 to loop16 only)
3: Loop17 to loop24
4: Loop25 to loop32
S2 : Initial screen display request
"PID operation by incomplete derivative" and "PID operation by complete derivative" can be executed
simultaneously since they are independent.
When the PIDINIT(P) instruction was used to make initialization, use the PIDCONT(P) instruction to perform
PID operation. To stop and start the PID operation of the specified loop No. and to change the PID control
data, use the PIDSTOP(P) instruction, PIDRUN(P) instruction and PIDPRMW(P) instruction.
During PID control, the value measured by the sensor (process value) is compared with the preset value (set value). The
output value (manipulated value) is then adjusted in order to eliminate the difference between the process value and the set
value.
The MV (manipulated value) is calculated by combining the proportional operation (P), the integral operation (I), and the
derivative operation (D) so that the PV is brought to the same value as the SV quickly and precisely.
The MV is made large when the difference between the PV and the SV is large so as to bring the PV close to the SV quickly.
As the difference between the PV and the SV gets smaller, a smaller MV is used to bring the PV to the same value as the SV
gradually and accurately.
The figure below shows examples of process control with forward operation and reverse operation:
The proportional operation in step response with a constant E (deviation) is illustrated below. 4
A certain error produced relative to a set value is called an offset. An offset is produced in proportional operation.
The integral operation in step response with a constant E (deviation) is illustrated below.
Integral operation is always used in combination with proportional operation (PI operation) or with proportional and
derivative operations (PID operation). Integral operation cannot be used independently.
Derivative operation
In derivative operation, an MV (manipulated value) proportional to the deviation change rate is added to the system value to
zero deviation when it occurs. This operation prevents significant fluctuation at the control objective due to external
disturbances.
The time required for the MV in the derivative operation to reach the MV for the proportional operation after the generation
of deviation is called the derivative time. Derivative time is expressed as TD.
Condition Derivative Operation
When derivative time TD is shorter Differentiating effect decreases. 4
When derivative time TD is longer Differentiating effect increases. However, hunting of short cycle is more likely
to occur.
The derivative operation when the deviation is a constant value stepped response is shown below.
Derivative operation is always used in combination with proportional operation (PD operation) or with proportional and
integral operations (PID operation). Derivative operation cannot be used independently.
[Complete derivative]
Complete derivative is PID control that uses the input of a derivative term as it is.
The PIDCONT instruction is the complete derivative PID control instruction.
PID operation
The control method when proportional operation (P operation), integral operation (I operation), and derivative operation (D
operation) are used in combination is described below.
During PID operation, the system is controlled by the MV (manipulated value) calculated in the (P + I + D) operation.
PID operation in step response with a constant E (deviation) is illustrated below.
When the MV upper/lower limit control is used, the MV is controlled as illustrated above. A MVHL (MV upper limit) and
MVLL (MV lower limit) takes on a value between -50 and 2050 or a user-defined value (except the QnACPU). The following
are the default settings: The value set for the upper limit must not be smaller than the value set for the lower limit. An error
will occur if it is.
MV Default value
Upper limit 2000 (Or user-defined value)
Lower limit 0 (Or user-defined value)
Mode switching from manual to automatic depending on ON/OFF of SM774 and SM794
There are the following differences in control when the manual mode is switched to the automatic mode.
When SM774/SM794 is OFF, the PV is transferred to the SV storage device. Therefore, there is no difference between the
PV and SV when the manual mode is switched to the automatic mode. Hence, an abrupt change does not occur in MV at
the time of mode switching. Instead, since the SV after mode switching differs from the target value in the automatic mode,
the user should change the SV to the target value step by step in the sequence program.
When SM774/SM794 is ON, the PV is not transferred to the SV storage device. Therefore, there is a difference between
the PV and SV when the manual mode is switched to the automatic mode. If the difference is large at the time of mode
switching, an abrupt change may occur in MV. Use this method in a system where the mode is switched when the PV has
fully neared the SV. PID control in the automatic mode can be executed immediately without the SV being changed step by
step in the sequence program.
The SV and PV are stored into the devices specified in the I/O data area with the PID operation instruction.
To make the user setting valid, turn the bit corresponding to the relevant loop of the PID limit setting special register (SD774,
SD775, SD794, SD795) to "1".
PID Limit Setting Special Register Setting Range
Incomplete derivative Complete derivative
SD794 SD774
SD795 SD775
(1)
*1
(2)
(3)
(3)
(3)
(4)
(5)
(6)
5
Registering or changing the PID control data per sequence program scan will present no problem. However,
execute the the PID control data setting instructions *2 when you registered or changed the PID control
data. If you do not execute the PID control data setting instructions instruction, the data registered or the
correction made to the PID control data will not be reflected at the execution of the the PID operation
instructions.
You need not execute the PID control data setting instructions when using the parameter change instruction
*3 to change the PID control data per loop.
Store 0 into the " * " marked area of the PID control data.
If other than 0 is stored into the " * " marked area, an error occurs and processing is not performed.
(Error code: 4100)
Use the following formula to calculate the number of device points to be used when setting the PID control data:
Number of device points = 2 + 10 n (n: Number of loops to be used)
Set each data as a binary value.
If the number of device points used for the corresponding loops exceeds the last device number of the specified device, an
error occurs and processing is not performed. (Error code: 4101)
The number of loops to be executed in a single scan means the number of loops for which PID operation is executed in one
scan when there is more than one loop for which sampling cycle time reaches or exceeds the set sampling cycle when the
PID operation instruction is executed. If the number of loops to be executed in a single scan is set, PID operation is only 5
executed for the set number of loops even if there are a greater number of loops for which the sampling cycle time reaches
or exceeds the set sampling cycle when the PID operation instruction is executed. PID operation is executed for the rest of
the loops in the next scan.
If the number of loops for which sampling cycle time reaches or exceeds the set sampling cycle is greater than
the number of loops to be executed in a single scan, the PID operation execution priority is as follows:
The lowest numbered loop is given the highest priority.
If there are loops in the preceding scan for which PID operation has not been executed, they are given the
highest priority.
The sampling cycle is measured when the PID operation instruction is executed.
Therefore, a value smaller than the sequence program scan time cannot be set for the sampling cycle.
If a value smaller than the scan time is set, PID operation will be executed in accordance with the scan time.
QnACPU
Data Name Description Setting Range Processing when Set Data is Outside
the Specified Range
Set value SV PID control target value 0 to 2000 For the QCPU or LCPU with "With PID limits"
setting or QnACPU, convert it to the following
value for PID operation.
When SV is less than 0, SV must be 0.
When SV is greater than 2000, SV must be
2000.
Process value PV Feedback data from controlled system -50 to 2050 For the QCPU or LCPU with "With PID limits"
objective to A/D converter module setting or QnACPU, convert it to the following
value for PID operation.
When PV is less than -50, PV must be -50.
When PV is greater than 2050, PV must be
2050.
Automatic MV The manipulated value calculated by PID -50 to 2050
manipulated operation.
value Output from the D/A converter module to the
controlled system.
Process value PVf Process value calculated using the operation -50 to 2050
after filtering formula in POINT(1) in Section 3.1.2/
POINT(1) in Section 3.2.2. ( Page 15
Operation expressions, Page 21
Operation expressions)
Manual MVMAN In the manual control mode, the data output -50 to 2050 For the QCPU or LCPU with "With PID limits"
manipulated from the D/A converter module is stored. setting or QnACPU, convert it to the following
value value for PID operation.
When MVMAN is less than -50, MVMAN must
be -50.
When MVMAN is greater than 2050, MVMAN
must be 2050.
Manual/ MAN/ Selects whether the output data to the D/A 0: Manual manipulated value An error occurs if the setting is neither 0 nor 1,
automatic AUTO converter module is shown as a manual 1: Automatic manipulated and PID operation of the corresponding loop
selection manipulated value or an automatic value will not be executed.
manipulated value.
In manual control mode, the automatic
manipulated value remains unchanged.
Alarm ALARM Used to determine if the change rate of the
MV (manipulated value) and the PV (process
value) is within or outside the allowable range.
Once set, the alarm data is retained until the
user resets it.
If the MV is outside the limit range, "1" is set
for bit 1 (b1).
If the PV is outside the limit range, "1" is set
for bit 0 (b0).
Use the following formula to calculate the number of device points to be used when setting the input/output data:
Number of device points = 10 + 23 n (n: Number of loops to be used)
Where "write" is designated for a data area, it indicates that the data should be written with a user sequence program.
Where "read" is designated for a data area, it indicates that the data should be read with a user sequence program. Never
attempt to write data to a data area designated "read/write disabled" or "read". If this is attempted, correct PID operation will
not be possible. Note that when control is to be started from the initial status, data must be cleared with a sequence
program.
If the number of device points used for the corresponding loops exceeds the last device number of the specified device, an
error occurs and processing is not performed. (Error code: 4101)
Where "write" is designated for a data area, it indicates that the data should be written with a user sequence program.
Where "read" is designated for a data area, it indicates that the data should be read with a user sequence program. Never
attempt to write data to a data area designated "read/write disabled" or "read". If this is attempted, correct PID operation will
not be possible. Note that when control is to be started from the initial status, data must be cleared with a sequence
program.
5
If the number of device points for the number of used loops exceeds the last device number of the specified device, an error
occurs and processing is not performed. (Error code: 4101)
*1 The devices that can be set are indicated in the "Constant" and "Other" columns.
*2 FX and FY can only be used with bit data, and FD can only be used with word data.
*3 Can be used with MELSECNET/G, MELSECNET/H and MELSECNET/10.
*4 For explanation of each device, refer to the User's Manual (Function Explanation, Program Fundamentals) of the CPU module used, or
the QnACPU Programming Manual (Fundamentals).
*5 T, ST and C can be used as the word devices only.
Indicates the expressions and instruction execution conditions in the ladder mode.
Execution Condition Executed while ON Executed once at OFF ON
Symbol used on the explanation page
7
Explains the set data for each instruction and indicates the data type.
Data Type Description
16-bit binary Indicates that binary 16-bit data or the first number of a word device can be used.
Applicable CPU
QCPU LCPU QnA Q4AR
Programmable controller CPU Process CPU Redundant CPU
Basic High Performance Universal
*1 *2
[SET DATA]
Description and data type
Set Data Description Data Type
S First number of devices in which data for PID control is set 16-bit binary
Usable device
Set Data Usable Devices
Internal Devices File Register MELSECNET/10 (H) Special Index Constant Other
(System, User) Direct J\ Function Register Zn
Bit Word Bit Word Module
U\G
S
[FUNCTIONS]
The PID control data for the number of loops to be used, which are set to the device number specified by S or later, are
entered in the CPU module in a batch, thereby making the PID control possible. ( Page 36 PID Control Data)
When the S(P).PIDINIT instruction is executed at more than one point within a scan, the setting value of the S(P).PIDINIT
instruction closest to the S(P).PIDCONT instruction is effective.
The S(P).PIDINIT instruction must be executed before the S(P).PIDCONT instruction. PID control is not possible if the
S(P).PIDINIT instruction has not been executed.
PID operation
Applicable CPU
QCPU LCPU QnA Q4AR
Programmable controller CPU Process CPU Redundant CPU
Basic High Performance Universal
*1 *2
[SET DATA]
Description and data type
Set Data Description Data Type
S First number of devices allocated to I/O device area 16-bit binary
Usable device
Set Data Usable Devices
Internal Devices File Register MELSECNET/10 (H) Special Index Constant Other
(System, User) Direct J\ Function Register Zn
Bit Word Bit Word Module
U\
S
[OPERATION ERRORS]
An operation error will occur, the error flag (SM0) will be turned ON, and an error code will be stored in SD0, in the following
cases.
Error code Description
4103 When the S(P).PIDINIT instruction is not executed before executing the S(P).PIDCONT instruction.
4100 When the value set as the PID control data is outside the allowable range.
4101 When the device range allocated to the PID control data area, designated with S , exceeds the last device number of the corresponding
device.
For details on the READY signals of the A/D converter module and D/A converter module, refer to the manual for the relevant
module.
Applicable CPU
QCPU LCPU QnA Q4AR
Programmable controller CPU Process CPU Redundant CPU
Basic High Performance Universal
*1 *2
[SET DATA]
Description and data type
Set Data Description Data Type
(n) Loop number at which start/stop is to be executed 16-bit binary
Usable device
8
Set Data Usable Devices
Internal Devices File Register MELSECNET/10 (H) Special Index Constant Other
(System, User) Direct J\ Function Register Zn K, H
Bit Word Bit Word Module
U\G
(n)
[FUNCTION]
S.PIDSTOP, SP.PIDSTOP
Stops the PID operation for the loop number designated by (n). The loop stopped by the S(P).PIDSTOP instruction does
not resume PID operation even if the S(P).PIDINIT instruction is executed.
Retains the operation data during the stop.
S.PIDRUN, SP.PIDRUN
Starts the PID operation of the loop No. specified by (n). This instruction is designed to re-execute PID operation of the loop
No. that has stopped with the S(P).PIDSTOP instruction.
This instruction will be ignored if the instruction is executed for the loop No. that is currently running PID operation.
[OPERATION ERRORS]
An operation error will occur and the error flag (SM0) will be turned ON in the following cases.
Error code Description
4100 When the loop number designated by (n) does not exist.
4100 When (n) is outside the range 1 to 8. (Basic model QCPU)
4100 When (n) is any other than 1 to 32. (High Performance model QCPU, Redundant CPU, Universal model QCPU, LCPU)
4103 When the S(P).PIDINIT and S(P).PIDCONT instructions have not been executed before execution of the S(P).PIDSTOP instruction.
4103 When the S(P).PIDINIT and S(P).PIDCONT instructions have not been executed before execution of the S(P).PIDRUN instruction.
Applicable CPU
QCPU LCPU QnA Q4AR
Programmable controller CPU Process CPU Redundant CPU
Basic High Performance Universal
*1 *2
[SET DATA]
Description and data type
Set Data Description Data Type
(n) Loop number for which change is to be made 16-bit binary
S First number of devices in which PID control data to be changed is stored
Usable device
Set Data Usable Devices
Internal Devices File Register MELSECNET/10 (H) Special Index Constant Other
(System, User) Direct J\ Function Register Zn K, H
Bit Word Bit Word Module
U\G
(n)
S
[FUNCTIONS]
Changes the operation parameter for the loop number designated by S to the PID control data stored in the devices
starting with the device number designated by S .
The configuration of the data for PID control which starts from the device number designated by S is shown below.For
details on PID control data, see Section 5.1. ( Page 36 PID Control Data)
Setting data Description
S +0 Selection of operational expression
S +1 Sampling cycle (TS)
S +2 Proportional constant (KP)
S +3 Integral constant (TI)
S +4 Derivative constant (TD)
S +5 Filter coefficient ()
S +6 MV lower limit (MVLL)
S +7 MV upper limit (MVHL)
S +8 MV change rate limit (MVL)
S +9 PV change rate limit (PVL)
S +10 0
S +11 Derivative gain (KD)
S +12 0
S +13 0
[PROGRAMMING CONDITIONS]
PID operation is executed for 2 loops.
The sampling cycle is 1 second.
The PID control data is set in the following devices: ( Page 36 PID Control Data)
PID control data Device name
Common data D500 to D501
Loop 1 data D502 to D515
Loop 2 data D516 to D529
The I/O data is set in the following devices: ( Page 51 I/O Data)
I/O data Device name
Common data D600 to D609
Loop 1 data D610 to D632
Loop 2 data D633 to D655
The following SV are set for loop 1 and loop 2 using a sequence program:
Loop SV
Loop 1 600
Loop 2 1000
The following devices are used for PID control start/stop commands.
Command Device name
PID control start command X0
PID control stop command X1
The digital values of the Q64AD and Q62DA are set within the range 0 to 2000.
[PROGRAMMINGCONDITIONS]
PID operation is executed for 1 loop.
The sampling cycle is 1 second.
The PID control data is set in the following devices:
PID control data Device name
Common data D500 to D501
Loop 1 data D502 to D515
The SV and MV in manual mode are set with external digital switches as follows:
Item Device name
SV X30 to X3F
MV (manual control mode) X20 to X2F
The following devices are used to start and stop PID control and the automatic/manual changeover command:
Command Device name 8
PID control start command X0
PID control stop command X1
SV setting command X3
MV setting command in manual mode X4
Automatic/manual mode changeover command X6 (OFF: Automatic mode, ON: Manual mode)
The digital values of the Q64AD and Q62DA are set within the range 0 to 2000.
The PID bumpless processing flag, SM794, is set to OFF. In the manual mode, the SV is automatically rewritten to the PV
when PID operation is performed. Therefore, when the manual mode is returned to the automatic mode, the SV must be
rewritten to the one used in the automatic mode before switching to the manual mode. The SV is rewritten step-by-step 10
times as illustrated below:*1
The incremental value obtained with the formula above is added to SV every second. The remainder is added in the first addition
operation.
Applicable CPU
QCPU LCPU QnA Q4AR
Programmable controller CPU Process CPU Redundant CPU
Basic High Performance Universal
*1
[SET DATA]
Description and data type
Set Data Description Data Type
S First number of devices in which data for PID control is set 16-bit binary
Usable device
Set Data Usable Devices
Internal Devices File Register MELSECNET/10 (H) Special Index Constant Other
(System, User) Direct J\ Function Register Zn
Bit Word Bit Word Module
U\G
S
[FUNCTIONS]
The PID control data for the number of loops to be used, which are set to the device number specified by S or later, are
entered in the CPU module in a batch, thereby making the PID control possible. ( Page 36 PID Control Data)
When the PIDINIT(P) instruction is executed at more than one point within a scan, the setting value of the PIDINIT(P)
instruction closest to the PIDCONT(P) instruction is effective.
The PIDINIT(P) instruction must be executed before the PIDCONT(P) instruction. PID control is not possible if the
PIDINIT(P) instruction has not been executed.
Applicable CPU
QCPU LCPU QnA Q4AR
Programmable controller CPU Process CPU Redundant CPU
Basic High Performance Universal
*1
[SET DATA]
Description and data type
Set Data Description Data Type
S First number of devices allocated to I/O device area 16-bit binary
Usable device
Set Data Usable Devices
Internal Devices File Register MELSECNET/10 (H) Special Index Constant Other
(System, User) Direct J\ Function Register Zn
Bit Word Bit Word Module
U\G
S
[FUNCTION]
When the PIDCONT(P) instruction is executed, the sampling cycle is measured and PID operation is performed.
With the PIDCONT(P) instruction, PID operation is carried out on the basis of the set value (SV) and process value (PV) in
the I/O data area set to the device number specified by S or later, and the operation result is stored into the automatically
manipulated value (MV) area of the I/O data area.
PID operation is executed in response to the execution of the PIDCONT(P) instruction appearing first after the set time for
sampling cycle has elapsed. ( Page 50 Sampling cycle)
During PID control, turn ON the control command to execute the PIDCONT(P) instruction in every scan. If not, PID
operation in a normal sampling cycle will not available. It is not possible to execute the PIDCONT(P) instruction more than
once in one scan. If it is executed more than once in one scan, PID operation cannot be performed in a normal sampling
cycle.
The PIDCONT(P) instruction is not available for use in an interrupt program, fixed scan execution type program or low
speed execution type program. If the PIDCONT(P) instruction has been used in an interrupt program, fixed scan execution
type program or low speed execution type program, PID operation cannot be performed in a normal sampling cycle.
For S , designate the first number of the device numbers that are designated as the I/O data area. If file registers (R) are
designated for the I/O data area, do not set memory protect ON for the file registers (R). If memory protect is set ON,
correct PID operation will be precluded, although no error will occur. ( Page 51 I/O Data)
Execute the PIDCONT(P) instruction in every scan even while the manual manipulated value (MVMAN) is being output in
the manual control mode. The bumpless function cannot be executed if the PIDCONT(P) instruction has not been
executed. ( Page 31 Bumpless changeover function)
[OPERATION ERRORS]
An operation error will occur, the error flag (SM0) will be turned ON, and an error code will be stored in SD0, in the following
cases.
Error code Description
4103 When the PIDINIT(P) instruction is not executed before executing the PIDCONT(P) instruction.
4100 When the value set as the PID control data is outside the allowable range.
4101 When the device range allocated to the PID control data area, designated with S , exceeds the last device number of the corresponding
device.
For details on the READY signals of the A/D converter module and D/A converter module, refer to the manual for the relevant
module.
Applicable CPU
QCPU LCPU QnA Q4AR
Programmable controller CPU Process CPU Redundant CPU
Basic High Performance Universal
[SET DATA]
Description and data type
Set Data Description Data Type
(n) First I/O number of the AD57(S1) used to monitor the PID control status 16-bit binary
S1 Screen number corresponding to the loop number to be monitored
S2 Initial screen display request
Usable device
Set Data Usable Devices
Internal Devices File Register MELSECNET/10 (H) Special Index Constant Other
(System, User) Direct J\ Function Register Zn K, H
Bit Word Bit Word Module
U\G
(n)
S1
S2
[FUNCTION]
The display unit of the AD57(S1) designated by (n) displays the PID control status of the loop number designated by S1 in
a bar graph. By executing the initial screen display request, designated by S2 , the characters in the still portion of the
monitor screen (with the exception of bar graphs and numerical data) are displayed in the initial state of PID control
monitoring.
Addresses 0 to 1599 in the VRAM area of the AD57(S1) are used for the PID control monitor. Therefore, these addresses
cannot be used by the user if PID control status monitoring is executed; if they are, the data stored in them will be lost.
Execute the CMODE instruction (AD57 command) to monitor the PID control status before executing the PID57 instruction.
If the CRT standard display mode, set with the CMODE instruction, has not been set for the AD57(S1), the display unit will
not be able to display anything.
Execute the PID57 instruction only after the PIDINIT(P) and PIDCONT(P) instructions have been executed. An error will
occur if the PID57 instruction is executed before the PIDINIT(P) and PIDCONT(P) instructions.
Designate the loop number indicated by S1 with a screen number from "1" to "4", as shown below:
Screen Number Loop Numbers to be Monitored
1 Loop 1 to loop 8
2 Loop 9 to loop 16
3 Loop 17 to loop 24
4 Loop 25 to loop 32
[OPERATION ERRORS]
An operation error will occur and the error flag (SM0) will be turned ON, and an error code will be stored in SD0, in the
following cases.
Error code Description
2110 When the CMODE instruction has not been executed for AD57(S1).
4103 When the PIDINIT(P) instruction has not been executed before the PID57 instruction.
4103 When the PIDCONT(P) instruction has not been executed before the PID57 instruction.
4100 When the screen number designated with S1 is outside the range of 1 to 4.
Applicable CPU
QCPU LCPU QnA Q4AR
Programmable controller CPU Process CPU Redundant CPU
Basic High Performance Universal
*1
[SET DATA]
Description and data type
Set Data Description Data Type
(n) Loop number at which start/stop is to be executed 16-bit binary
Usable device
Set Data Usable Devices
Internal Devices File Register MELSECNET/10 (H) Special Index Constant Other
(System, User) Direct J\ Function Register Zn K, H
Bit Word Bit Word Module
U\G
(n)
[FUNCTION]
PIDSTOP, PIDSTOPP
Stops the PID operation for the loop number designated by (n). The loop stopped by the PIDSTOP(P) instruction does not
resume PID operation even if the PIDINIT(P) instruction is executed.
Retains the operation data during the stop.
PIDRUN, PIDRUNP
Starts the PID operation of the loop No. specified by (n). This instruction is designed to re-execute PID operation of the loop
No. that has stopped with the PIDSTOP(P) instruction.
This instruction will be ignored if the instruction is executed for the loop No. that is currently running PID operation.
[OPERATION ERRORS]
An operation error will occur and the error flag (SM0) will be turned ON in the following cases.
Error code Description
4100 When the loop number designated by (n) does not exist.
4100 When (n) is outside the range 1 to 8 (Basic model QCPU).
4100 When (n) is any other than 1 to 32. (High Performance model QCPU, Redundant CPU, Universal model QCPU, LCPU, and QnACPU)
4103 When the PIDINIT(P) and PIDCONT(P) instructions have not been executed before execution of the PIDSTOP(P) instruction.
4103 When the PIDINIT(P) and PIDCONT(P) instructions have not been executed before execution of the PIDRUN(P) instruction.
[SET DATA]
Description and data type
Set Data Description Data Type
(n) Loop number for which change is to be made 16-bit binary
S First number of devices in which PID control data to be changed is stored
Usable device
Set Data Usable Devices
Internal Devices File Register MELSECNET/10 (H) Special Index Constant Other
(System, User) Direct J\ Function Register Zn K, H
Bit Word Bit Word Module
U\G
(n)
S
[FUNCTIONS]
Changes the operation parameter for the loop number designated by (n) to the PID control data stored in the devices
starting with the device number designated by S .
The configuration of the data for PID control which starts from the device number designated by S is shown below.For
details on PID control data, see Section 5.1. ( Page 36 PID Control Data)
Setting data Description
S +0 Selection of operation expression
S +1 Sampling cycle (TS)
S +2 Proportional constant (KP)
S +3 Integral constant (TI)
S +4 Derivative constant (TD)
S +5 Filter coefficient ()
S +6 MV lower limit (MVLL)
S +7 MV upper limit (MVHL)
S +8 MV change rate limit (MVL)
S +9 PV change rate limit (PVL)
[PROGRAMMING CONDITIONS]
PID operation is executed for 2 loops.
The sampling cycle is 1 second.
The PID control data is set in the following devices: ( Page 36 PID Control Data)
PID control data Device name
Common data D500 to D501
Loop 1 data D502 to D511
Loop 2 data D512 to D521
The I/O data is set in the following devices: ( Page 51 I/O Data)
I/O data Device name
Common data D600 to D609
Loop 1 data D610 to D627
Loop 2 data D628 to D645
The following SV are set for loop 1 and loop 2 using a sequence program:
Loop SV
Loop 1 600
Loop 2 1000
The following devices are used for PID control start/stop commands.
Command Device name
PID control start command X0
PID control stop command X1
The digital values of the Q64AD and Q62DA are set within the range 0 to 2000.
[PROGRAMMING CONDITIONS]
PID operation is executed for 1 loop.
The sampling cycle is 1 second.
The PID control data is set in the following devices:
PID control data Device name
Common data D500 to D501
Loop 1 data D502 to D511
The SV and MV in manual mode are set with external digital switches as follows:
Item Device name
SV X30 to X3F
MV (manual control mode) X20 to X2F
The following devices are used to start and stop PID control and the automatic/manual changeover command:
Command Device name
PID control start command X0
PID control stop command X1
SV setting command X3
MV setting command in manual mode X4
Automatic/manual mode changeover command X6 (OFF: Automatic mode, ON: Manual mode)
The digital values of the Q64AD and Q62DA are set within the range 0 to 2000.
The PID bumpless processing flag, SM774, is set to OFF. In the manual mode, the SV is automatically rewritten to the PV
when PID operation is performed. Therefore, when the manual mode is returned to the automatic mode, the SV must be
rewritten to the one used in the automatic mode before switching to the manual mode. The SV is rewritten step-by-step 10
times as illustrated below:*1
The incremental value obtained with the formula above is added to SV every second. The remainder is added in the first addition
operation.
[PROGRAMMING CONDITIONS]
PID operation is executed for 2 loops.
The sampling cycle is 1 second.
The PID control data is set in the following devices: ( Page 36 PID Control Data)
PID control data Device name
Common data D500 to D501
Loop 1 data D502 to D511
Loop 2 data D512 to D521
The I/O data is set in the following devices: ( Page 51 I/O Data)
I/O data Device name
Common data D600 to D609
Loop 1 data D610 to D627
Loop 2 data D628 to D645
The following SV are set for loop 1 and loop 2 using a sequence program:
Loop SV
Loop 1 600
Loop 2 1000
The following devices are used for PID control start/stop commands and the monitoring command with AD57.
Command Device name
PID control start command X0
PID control stop command X1
Monitoring command with AD57 X2
The digital values of the A68AD and A62DA are set within the range 0 to 2000.
*2
*1 It is also possible to create a program by using special function module devices. In this case the format in the ladder is as follows:
*2 It is also possible to create a program by using special function module devices. In this case the format in the ladder is as follows:
[PROGRAMMING CONDITIONS]
PID operation is executed for 1 loop.
The sampling cycle is 1 second.
The PID control data is set in the following devices:
PID control data Device name
Common data D500 to D501
Loop 1 data D502 to D511
The SV and MV in manual mode are set with external digital switches as follows:
Item Device name
SV X30 to X3F
MV (manual control mode) X20 to X2F
The following devices are used to start and stop PID control and the automatic/manual changeover command:
Command Device name
PID control start command X0
PID control stop command X1
Monitoring command with AD57 X2
SV setting command X3
MV setting command in manual mode X4
Automatic/manual mode changeover command X6 (OFF: Automatic mode, ON: Manual mode)
The digital values of the A68AD and A62DA are set within the range 0 to 2000.
The PID bumpless processing flag, SM774, is set to OFF. In the manual mode, the SV is automatically rewritten to the PV
when PID operation is performed. Therefore, when the manual mode is returned to the automatic mode, the SV must be
rewritten to the one used in the automatic mode before switching to the manual mode. The SV is rewritten step-by-step 10
times as illustrated below:*1
The incremental value obtained with the formula above is added to SV every second. The remainder is added in the first addition
operation.
APPENDICES
96 Appendix 1 Processing Time List
High-speed Universal model QCPU
Instruction Conditions Processing Time (s)
Name Q03UDVCPU Q04UDVCPU, Q06UDVCPU, Q13UDVCPU, A
Q26UDVCPU,
Min. Max. Min. Max. Min. Max.
S.PIDINIT 1 loop 4.1 15.2 4.1 15.2 4.1 15.2
8 loops
32 loops 54.0 59.8 54.0 59.8 54.0 59.8
S.PIDCONT 1 loop First 18.5 28.8 18.5 28.8 18.5 28.8
Others 16.5 28.3 16.5 28.3 16.5 28.3
8 loops First
Others
32 loops First 207.9 215.6 207.9 215.6 207.9 215.6
Others 173.2 184.8 173.2 184.8 173.2 184.8
S.PIDSTOP 1 loop 2.4 9.2 2.4 9.2 2.4 9.2
S.PIDRUN 1 loop 2.2 8.8 2.2 8.8 2.2 8.8
S.PIDPRMW 1 loop 4.5 16.0 4.5 16.0 4.5 16.0
LCPU
Instruction Conditions Processing Time (s)
Name L02SCPU, L02SCPU-P L02CPU, L02CPU-P L06CPU, L06CPU-P, L26CPU,
L26CPU-P, L26CPU-BT,
L26CPU-PBT
Min. Max. Min. Max. Min. Max.
S.PIDINIT 1 loop 17.5 39.9 14.0 27.3 11.4 18.8
8 loops
32 loops 295.0 376.0 244.3 277 164 183
S.PIDCONT 1 loop First 123.0 64.1 66.0 46.8 47.5
Others 90.4 53.0 55.5 35.8 42.1
8 loops First
Others
32 loops First 1121.0 1064.2 1069.5 927 931
Others 1046.0 863.2 889.8 728 744
S.PIDSTOP 1 loop 7.3 14.2 6.9 10.6 4.9 6.9
S.PIDRUN 1 loop 5.5 11.0 6.2 15.2 4.3 5.6
S.PIDPRMW 1 loop 18.7 62.4 14.7 28.9 10.7 14.5
APPENDICES
Appendix 1 Processing Time List 97
Processing times for complete derivative PID control instructions
Basic model QCPU, High Performance model QCPU, and Redundant CPU
Instruction Conditions Processing Time (s)
Name Q2ASCPU, Q3ACPU Q2ASHCPU Q00J Q00CPU Q01CPU Q02CPU QnHCPU QnPRH
Q2ACPU(S1) (S1), CPU CPU
Q4ACPU,
A4ARCPU
PIDINIT 1 loop 61 46 23 66.0 56.0 50.5 26.0 11.2 11.2
8 loops 170.0 145.0 130.0
32 loops 407 306 153 174.0 74.9 74.9
PIDCONT 1 loop First 211 159 80 325.0 275.0 245.0 86.6 37.3 37.3
Others 181 136 68 285.0 250.0 225.0 74.3 32.0 32.0
8 loops First 2000.0 1700.0 1500.0
Others 1700.0 1450.0 1300.0
32 loops First 5086 3824 1912 2102.5 904.9 904.9
Others 4894 3680 1840 2036.9 876.7 876.7
PID57 1 loop First 9629 7240 3620
Others 606 456 228
8 loops First 9669 7270 3635
Others 3719 2796 1398
PIDSTOP 1 loop 11.2 8.4 4.2 22.0 18.5 17.0 4.5 1.9 1.9
PIDRUN
PIDPRMW 1 loop 36 26 13 53.0 45.0 41.0 14.6 6.3 6.3
APPENDICES
98 Appendix 1 Processing Time List
High-speed Universal model QCPU
Instruction Conditions Processing Time (s)
Name Q03UDVCPU Q04UDVCPU, Q06UDVCPU, A
Q13UDVCPU,
Q26UDVCPU,
Min. Max. Min. Max. Min. Max.
PIDINIT 1 loop 2.7 9.3 2.7 9.3 2.7 9.3
8 loops
32 loops 35.6 39.9 35.6 39.9 35.6 39.9
PIDCONT 1 loop First 14.3 22.7 14.3 22.7 14.3 22.7
Others 11.9 21.3 11.9 21.3 11.9 21.3
8 loops First
Others
32 loops First 196.0 199.5 196.0 199.5 196.0 199.5
Others 160.8 167.5 160.8 167.5 160.8 167.5
PIDSTOP 1 loop 1.3 2.9 1.3 2.9 1.3 2.9
PIDRUN 1 loop 1.3 3.0 1.3 3.0 1.3 3.0
PIDPRMW 1 loop 2.8 3.7 2.8 3.7 2.8 3.7
LCPU
Instruction Conditions Processing Time (s)
Name L02SCPU, L02SCPU-P L02CPU, L02CPU-P L06CPU, L06CPU-P,
L26CPU, L26CPU-P,
L26CPU-BT, L26CPU-PBT
Min. Max. Min. Max. Min. Max.
PIDINIT 1 loop 10.3 60.7 8.6 14.6 6.3 10.9
8 loops
32 loops 162.0 227.0 131.2 136.7 98.7 122.6
PIDCONT 1 loop First 110.0 51.5 51.8 36.8
Others 95.5 50.0 50.4 35.8
8 loops First
Others
32 loops First 909.0 869.5 886.9 776.0 785.0
Others 914.0 746.2 750.3 622.0 645.0
PIDSTOP 1 loop 3.3 33.4 2.2 4.0 1.3 2.9
PIDRUN 1 loop 1.0 4.0 2.2 4.2 1.5 2.7
PIDPRMW 1 loop 9.4 23.0 8.0 12.0 5.9 8.9
APPENDICES
Appendix 1 Processing Time List 99
Appendix 2 Anti-Reset Windup Measure
A reset windup is a problem that an integral element keeps adding a deviation beyond a saturation limit. (It is also referred to
as an integrator windup.)
When a reset windup occurs, integral operation must be stopped to enable immediate response to the inversion of the
deviation.
Since the measure for the reset windup is taken in PID operation instructions (PIDCONT and S.PIDCONT) of the QCPU,
LCPU, and QnACPU, integral operation need not be stopped.
APPENDICES
100 Appendix 2 Anti-Reset Windup Measure
INDEX
A V
About the differences between complete derivative Velocity type operation . . . . . . . . . . . . . . . . . . . .26
and incomplete derivative . . . . . . . . . . . . . . . . . 30 I
Anti-reset windup measure . . . . . . . . . . . . . . . . 100
Applicable CPU . . . . . . . . . . . . . . . . . . . . . . . . 13
B
Bumpless changeover function . . . . . . . . . . . . . . 31
D
Derivative operation (D operation). . . . . . . . . . . . 29
F
Forward operation . . . . . . . . . . . . . . . . . . . . . . . 26
I
I/O Data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51
I/O data allocations . . . . . . . . . . . . . . . . . . . . . . 53
Integral operation (I operation) . . . . . . . . . . . . . . 28
M
MV upper/lower limit control function . . . . . . . . . . 31
O
Operation method . . . . . . . . . . . . . . . . . . . . . . . 26
Operation when PID operation instruction executed
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
Outline of PID control . . . . . . . . . . . . . . . . . . . . 25
Overview of PID control processing. . . . . . . . . . . 11
P
PID control data allocations . . . . . . . . . . . . . . . . 47
PID control instruction list. . . . . . . . . . . . . . . . 16,21
PID control procedure . . . . . . . . . . . . . . . . . . . . 34
PID operation . . . . . . . . . . . . . . . . . . . . . . . . . . 30
PID operation block diagram and operation
expressions . . . . . . . . . . . . . . . . . . . . . . . . . 15,20
Process value derivative type operation . . . . . . . . 26
Processing time list . . . . . . . . . . . . . . . . . . . . . . 96
Proportional operation (P operation) . . . . . . . . . . 27
R
Reverse operation . . . . . . . . . . . . . . . . . . . . . . . 26
S
Sampling cycle . . . . . . . . . . . . . . . . . . . . . . . . . 50
Settings of SV, PV, and MV used in the PID control
instructions . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
101
MEMO
102
INSTRUCTION INDEX
P
PID57 . . . . . . ......................... 76
PID57P . . . . . ......................... 76 I
PIDCONT. . . . ......................... 74
PIDCONTP . . ......................... 74
PIDINIT . . . . . ......................... 72
PIDINITP . . . . ......................... 72
PIDPRMW . . . ......................... 79
PIDPRMWP . . ......................... 79
PIDRUN . . . . . ......................... 78
PIDRUNP. . . . ......................... 78
PIDSTOP . . . . ......................... 78
PIDSTOPP . . . ......................... 78
S
S.PIDCONT . . ......................... 61
S.PIDINIT. . . . ......................... 60
S.PIDPRMW . ......................... 64
S.PIDRUN . . . ......................... 63
S.PIDSTOP . . ......................... 63
SP.PIDCONT . ......................... 61
SP.PIDINIT . . ......................... 60
SP.PIDPRMW ......................... 64
SP.PIDRUN . . ......................... 63
SP.PIDSTOP . ......................... 63
103
MEMO
104
REVISIONS
*The manual number is given on the bottom left of the back cover.
Revision date *Manual number Description
December 1999 SH(NA)-080040-A Due to the transition to the e-Manual, the details of revision have been deleted.
June 2013 SH(NA)-080040-Q
August 2015 SH(NA)-080040-R Complete revision (layout change)
105
WARRANTY
Please confirm the following product warranty details before using this product.
1. Gratis Warranty Term and Gratis Warranty Range
If any faults or defects (hereinafter "Failure") found to be the responsibility of Mitsubishi occurs during use of the product
within the gratis warranty term, the product shall be repaired at no cost via the sales representative or Mitsubishi Service
Company.
However, if repairs are required onsite at domestic or overseas location, expenses to send an engineer will be solely at
the customer's discretion. Mitsubishi shall not be held responsible for any re-commissioning, maintenance, or testing
on-site that involves replacement of the failed module.
[Gratis Warranty Term]
The gratis warranty term of the product shall be for one year after the date of purchase or delivery to a designated place.
Note that after manufacture and shipment from Mitsubishi, the maximum distribution period shall be six (6) months, and
the longest gratis warranty term after manufacturing shall be eighteen (18) months. The gratis warranty term of repair
parts shall not exceed the gratis warranty term before repairs.
[Gratis Warranty Range]
(1) The range shall be limited to normal use within the usage state, usage methods and usage environment, etc., which
follow the conditions and precautions, etc., given in the instruction manual, user's manual and caution labels on the
product.
(2) Even within the gratis warranty term, repairs shall be charged for in the following cases.
1. Failure occurring from inappropriate storage or handling, carelessness or negligence by the user. Failure caused
by the user's hardware or software design.
2. Failure caused by unapproved modifications, etc., to the product by the user.
3. When the Mitsubishi product is assembled into a user's device, Failure that could have been avoided if functions
or structures, judged as necessary in the legal safety measures the user's device is subject to or as necessary by
industry standards, had been provided.
4. Failure that could have been avoided if consumable parts (battery, backlight, fuse, etc.) designated in the
instruction manual had been correctly serviced or replaced.
5. Failure caused by external irresistible forces such as fires or abnormal voltages, and Failure caused by force
majeure such as earthquakes, lightning, wind and water damage.
6. Failure caused by reasons unpredictable by scientific technology standards at time of shipment from Mitsubishi.
7. Any other failure found not to be the responsibility of Mitsubishi or that admitted not to be so by the user.
2. Onerous repair term after discontinuation of production
(1) Mitsubishi shall accept onerous product repairs for seven (7) years after production of the product is discontinued.
Discontinuation of production shall be notified with Mitsubishi Technical Bulletins, etc.
(2) Product supply (including repair parts) is not available after production is discontinued.
3. Overseas service
Overseas, repairs shall be accepted by Mitsubishi's local overseas FA Center. Note that the repair conditions at each FA
Center may differ.
4. Exclusion of loss in opportunity and secondary loss from warranty liability
Regardless of the gratis warranty term, Mitsubishi shall not be liable for compensation of damages caused by any cause
found not to be the responsibility of Mitsubishi, loss in opportunity, lost profits incurred to the user by Failures of
Mitsubishi products, special damages and secondary damages whether foreseeable or not, compensation for accidents,
and compensation for damages to products other than Mitsubishi products, replacement by the user, maintenance of
on-site equipment, start-up test run and other tasks.
5. Changes in product specifications
The specifications given in the catalogs, manuals or technical documents are subject to change without prior notice.
106 SH(NA)-080040-R
SH(NA)-080040-R(1508)MEE
MODEL: QCPU(Q)-P(PI)-E
MODEL CODE: 13JF59
HEAD OFFICE : TOKYO BUILDING, 2-7-3 MARUNOUCHI, CHIYODA-KU, TOKYO 100-8310, JAPAN
NAGOYA WORKS : 1-14 , YADA-MINAMI 5-CHOME , HIGASHI-KU, NAGOYA , JAPAN
When exported from Japan, this manual does not require application to the
Ministry of Economy, Trade and Industry for service transaction permission.