AdCtrlPidt1 (FB)

FUNCTION_BLOCK AdCtrlPidt1

The Pid controller changes its output Y (control variable) until input X (controlled variable) is equal to input W (command variable). The block is used AdCtrlCascade function Block. It does the basic Pid control including
  • Anti wind-up for integrating part

  • Limitation for Cv

  • Bumpless setting of Cv to InitCV

  • First order filter for derivative part

All times are scaled to cycles, block requires to be called in a cyclic PLC task

Additional pre-Filter for DT1-Component available is also available within the block

InOut:

Scope

Name

Type

Initial

Comment

Input

Sp

REAL

0

1: Command variable (set point)

Pv

REAL

0

2: ProcessValue, Actual Value

Kp

REAL

0

3: Proportional coefficient, specified as a percentage value (100% =1).

TiCycles

REAL

0

4: Integral action time scaled to the PLC cycle time

TdCycles

REAL

0

5: Derivative action time scaled to the PLC cycle time

T1Cycles

REAL

0

6: Returning time scaled to the PLC cycle time (Filter Time).

MaxCv

REAL

0

7: High limit for the control variable Cv

MinCv

REAL

0

8: Low limit for the control variable Cv

Set

BOOL

FALSE

9: Enable for setting Cv to InitCV, COntroller is stpped otherwise

InitCv

REAL

0

10:Initial value for the control variable Cv

Reset

BOOL

FALSE

11:Reset of the control variable Cv to 0, controller is stopped.

Output

Cv

REAL

0

1: Output for the control variable Control Value

StateMax

BOOL

FALSE

2: High limit has been reached

StateMin

BOOL

FALSE

3: Low limit has been reached

Structure: