FB_BA_PID
The template is a universal PID controller.
The PID controller is enabled via the input variable bEn.
The initialization of the template takes place within the method FB_Init. |
Block diagram
Syntax
FUNCTION_BLOCK FB_BA_PID EXTENDS FB_BA_View
VAR_INPUT
bEn : BOOL;
fW : REAL;
fX : REAL;
bSync : BOOL;
fSync : REAL;
END_VAR
VAR_OUTPUT
fY : REAL;
fMax : REAL;
fMin : REAL;
END_VAR
VAR_INPUT CONSTANT
Ctrl : FB_BA_Loop;
END_VAR
Inputs
Name | Type | Description |
---|---|---|
bEn | BOOL | General enable of the template |
fW | REAL | Setpoint |
fX | REAL | Actual value |
bSync | BOOL | A rising edge at this input triggers synchronization of the loop object to the value of fSync. |
fSync | REAL | Synchronization value |
Outputs
Name | Type | Description |
---|---|---|
fY | REAL | Control value output |
fMax | REAL | Maximum controller value |
fMin | REAL | Minimum controller value |
Requirements
Development environment | Necessary function |
---|---|
TwinCAT from v3.1.4024.35 | TF8040 | TwinCAT Building Automation from V5.0.0.0 |