Main Content

Discrete PI Controller with anti-windup and reset

Implement discrete PI controller with anti-windup and reset functionality

  • Library:
  • Motor Control Blockset / Controls / Controllers

Description

The Discrete PI Controller with anti-windup and reset block performs discrete-time PI controller computation using the error signal and proportional and integral gain inputs. The error signal is the difference between the reference signal and the measured feedback. The block outputs a weighted sum of the input error signal and the integral of the input error signal.

You can tune the Discrete PI Controller coefficients (Kp and Ki) either manually or automatically. Automatic tuning requires Simulink® Control Design™ software.

The block also supports anti-windup functionality, which makes the block output to comply with the register size of the processor. You can reset the integrator to the initial condition (y0).

We recommend that you use fixed-step discrete solver for this block to enable code generation and ensure accurate simulation.

Ports

Input

expand all

Difference between a reference signal and the system output.

Data Types: single | double | fixed point

Proportional gain value that you can compute either manually or automatically.

Data Types: single | double | fixed point

Integral gain input that you can compute either manually or automatically. You must premultiply the integral gain value by the integrator sample time (Ts) for the block to execute within asynchronous interrupts.

Data Types: single | double | fixed point

External pulse that resets the block output to the value of the initial output from the integrator (y0).

Data Types: single | double | fixed point

Initial value of the integrator or block output after receiving a reset pulse.

Data Types: single | double | fixed point

Output

expand all

Control signal that is identical to the reference signal.

Data Types: single | double | fixed point

Parameters

expand all

The block holds the output at the Upper saturation limit whenever the weighted sum of the proportional and integral actions exceeds this value.

The block holds the output at the Lower saturation limit whenever the weighted sum of the proportional and integral actions goes below this value.

Extended Capabilities

C/C++ Code Generation
Generate C and C++ code using Simulink® Coder™.

Fixed-Point Conversion
Design and simulate fixed-point systems using Fixed-Point Designer™.

Introduced in R2020a