308
4
4 Instructions4.12.1 PID Calculation
●
Incremental PID instruction
The following table lists the functions and setting methods of the parameters from head address S3.
Unit Function Setting
S3 Sampling time (TS)
The sampling time ranges from 1 ms to 32,767 ms and must be greater
than the PLC's scan cycle.
S3+1 Action direction (ACT)
Bit 0 = 0: forward action; bit 0 = 1: reverse action
Bit 1 = 0: input variable alarm disabled; bit 1 = 1: input variable alarm
enabled
Bit 2 = 0: output variable alarm disabled; bit 2 = 1: output variable alarm
enabled
Bit 3: unavailable
Bit 4 = 0: auto-tuning not executed; bit 4 = 1: auto-tuning executed (The
current version does not provide auto-tuning for the moment.)
Bit 5 = 0: upper/lower output limits invalid; bit 5 = 1: upper/lower output
limits valid
Bits 6 to 15: unavailable
Do not set both bits 5 and 2 to ON.
S3+2 Input lter constant (α)
Value range: 0 to 99, in percent. When it is set to 0, no input lter is
processed.
S3+3 Proportional gain (Kp) Value range: 1 to 32,767, in percent.
S3+4 Integral time (T1)
Value range: 0 to 32,767 (x 100 ms). When it is set to 0, it is processed as
∞ (no integral).
S3+5 Differential gain (KD)
Value range: 0 to 100, in percent. When it is set to 0, no differential gain is
processed.
S3+6 Differential time (TD)
Value range: 0 to 32,767 (x 10 ms). When it is set to 0, no differential is
processed.
S3+(7–19) Occupied by the internal processing of PID calculation. Clear these units before initial running.
When bit 1 = 1 and bit 2 or bit 5 = 1 in <ACT>, S3+(20–24) are occupied and dened as follows:
S3+20
Input variable (incremental)
alarm value
Value range: 0 to 32,767. This parameter is valid when bit 1 = 1 in <ACT>.
S3+21
Input variable (decremental)
alarm value
Value range: 0 to 32,767. This parameter is valid when bit 1 = 1 in <ACT>.
S3+22
Output variable (incremental)
alarm value
Value range: 0 to 32,767. This parameter is valid when bit 2 = 1 and bit 5 =
0 in <ACT>.
Value range of the upper output limit: –32,768 to +32,767. This parameter
is valid when bit 1 = 0 and bit 5 = 1 in <ACT>.
S3+23
Output variable (decremental)
alarm value
Value range: 0 to 32,767. This parameter is valid when bit 2 = 1 and bit 5 =
0 in <ACT> of S3+1.
Value range of the lower output limit: –32,768 to +32,767. This parameter
is valid when bit 1 = 0 and bit 5 = 1 in <ACT>.
S3+24 Alarm output
Bit 0 input variable (incremental) overow
Bit 1 input variable (decremental) overow
Bit 2 output variable (incremental) overow
Bit 3 output variable (decremental) overow
This parameter is valid when bit 1 = 1 or bit 2 = 1 in <ACT>.
S3+25 Occupied by the internal processing of PID calculation