
blockPIDWithOperatingMode
PID controller with operating mode input
Information
This block adds the following features to
Buildings.Controls.OBC.CDL.Reals.PIDWithReset.
-
Based on the constants defined within
Buildings.Fluid.HydronicConfigurations.Controls.OperatingModes
the block allows the controller to be either disabled or switched
to a change-over mode.
-
When the controller is disabled, the controller output is forced to
y_neutral and the tracking error is zeroed out to prevent windup.
Typically this neutral value should correspond to a condition that
applies the minimum control effect, i.e., valves/dampers closed,
VFDs at minimum speed, etc.
-
When operated under the mode
enabled
the controller behaves exactly as
Buildings.Controls.OBC.CDL.Reals.PIDWithReset.
Furthermore, the controller output is reset to y_reset at enable
time.
-
When operated under the mode
heating
the controller behaves as
Buildings.Controls.OBC.CDL.Reals.PIDWithReset
except that the sign of the measured and set point variables is reversed
so that the controller may for instance provide a heating function if
it was originally configured for a cooling function.
Furthermore, the controller output is reset to y_reset at
the time the operating mode changes.
Parameters
| Type | Name | Default | Description |
| Buildings.Controls.OBC.CDL.Types.SimpleController | controllerType | Buildings.Controls.OBC.CDL.Types.SimpleController.PI | Type of controller |
| Real | r | 1 | Typical range of control error, used for scaling the control error |
| Boolean | reverseActing | true | Set to true for reverse acting, or false for direct acting control action |
| Real | y_neutral | 0 | Value to which the controller output is reset at disable time |
| Control gains |
| Real | k | 1 | Gain of controller |
| Real | Ti | 0.5 | Time constant of integrator block |
| Real | Td | 0.1 | Time constant of derivative block |
| Limits |
| Real | yMax | 1 | Upper limit of output |
| Real | yMin | 0 | Lower limit of output |
| Advanced › Integrator anti-windup |
| Real | Ni | 0.9 | Ni*Ti is time constant of anti-windup compensation |
| Advanced › Derivative block |
| Real | Nd | 10 | The higher Nd, the more ideal the derivative block |
| Integrator reset |
| Real | y_reset | y_neutral | Value to which the controller output is reset at enable time or change-over switch |
Revisions
-
June 30, 2022, by Antoine Gautier:
First implementation.