22
Wir schaffen Wissen – heute für morgen 20. Juni 2022 PSI, 20. Juni 2022 PSI, Paul Scherrer Institut Basic powersupply control – Digital implementation of analog controllers Hans Jäckle

Wir schaffen Wissen – heute für morgen 9. September 2015PSI,9. September 2015PSI, Paul Scherrer Institut Basic powersupply control – Digital implementation

Embed Size (px)

Citation preview

Page 1: Wir schaffen Wissen – heute für morgen 9. September 2015PSI,9. September 2015PSI, Paul Scherrer Institut Basic powersupply control – Digital implementation

Wir schaffen Wissen – heute für morgen

21. April 2023PSI, 21. April 2023PSI,

Paul Scherrer Institut

Basic powersupply control – Digital implementation of analog controllers

Hans Jäckle

Page 2: Wir schaffen Wissen – heute für morgen 9. September 2015PSI,9. September 2015PSI, Paul Scherrer Institut Basic powersupply control – Digital implementation

Topics

Digital implementation of analog controllers

Part 1: Basic Powersupply Controller- Essential Tasks of a basic powersupply controller and how to achieve them

Part 2: Discretization- Paths to discrete controller- Methods of discretization- Effects of SamplingTime

Page 3: Wir schaffen Wissen – heute für morgen 9. September 2015PSI,9. September 2015PSI, Paul Scherrer Institut Basic powersupply control – Digital implementation

Tasks of controller

• Achieve zero steady-state error-> Integral action

Page 4: Wir schaffen Wissen – heute für morgen 9. September 2015PSI,9. September 2015PSI, Paul Scherrer Institut Basic powersupply control – Digital implementation

PI Controller

• Ki = 1 / TMagnet

-> experimentally (step response in open loop) -> Ki = RMagnet / LMagnet

• Kp can be found manually, starting value: Kp_init = RMagnet / UDC_Link * ωCL / Ki

Page 5: Wir schaffen Wissen – heute für morgen 9. September 2015PSI,9. September 2015PSI, Paul Scherrer Institut Basic powersupply control – Digital implementation

Tasks of controller

• Achieve zero steady-state error-> Integral action

• keep operation of controller linear (avoid limitations)-> Limit diRef / dt-> Anti-Windup

Page 6: Wir schaffen Wissen – heute für morgen 9. September 2015PSI,9. September 2015PSI, Paul Scherrer Institut Basic powersupply control – Digital implementation

dI/dt Limiter

• Keeps the controller in the linear regime by preventing actuator saturation

• Anti-Windup is a remedy in case of actuator saturation

MAGNET

MAXMAGNETNOMCONVMINDC

MAX L

RIUU

dt

dI __ *

Page 7: Wir schaffen Wissen – heute für morgen 9. September 2015PSI,9. September 2015PSI, Paul Scherrer Institut Basic powersupply control – Digital implementation

Tasks of controller

• Achieve zero error-> Integral action

• Stay in linear region-> Limit diRef / dt-> Anti-Windup

• Suppress dc-link voltage disturbances (e.g. 300Hz Ripple)->feedforward the dc-link disturbances

Page 8: Wir schaffen Wissen – heute für morgen 9. September 2015PSI,9. September 2015PSI, Paul Scherrer Institut Basic powersupply control – Digital implementation

DC-Link Feedforwards

Page 9: Wir schaffen Wissen – heute für morgen 9. September 2015PSI,9. September 2015PSI, Paul Scherrer Institut Basic powersupply control – Digital implementation

DC-Link Feedforward

Page 10: Wir schaffen Wissen – heute für morgen 9. September 2015PSI,9. September 2015PSI, Paul Scherrer Institut Basic powersupply control – Digital implementation

DC-Link Feedforward + Delay

0 100 200 300 400 500 600-45

-40

-35

-30

-25

-20

-15

-10

-5

0

5

Delay [us]

gai

n [

dB

]Suppression of 300Hz ripple by a dc-link voltage feedforward

Example:fPWM = 20kHz

PWM-Delay = 1/(4* fPWM) = 12.5usMeasurement delay = 20usControl cycle = 10usTotal delay = 42.5us

-> min. gain: -20dB

Page 11: Wir schaffen Wissen – heute für morgen 9. September 2015PSI,9. September 2015PSI, Paul Scherrer Institut Basic powersupply control – Digital implementation

Tasks of controller

• Achieve zero error-> Integral action

•Stay in linear region-> Limit diRef / dt-> Anti-Windup

• Suppress dc-link voltage disturbances ->feedforward the dc-link disturbances

Protect Output Filter Resistor-> Output limiter

• Reduce measurement noise-> Lowpass-filter for the measured value

• Reduce overshoot-> Lowpass-filter for the reference value

Page 12: Wir schaffen Wissen – heute für morgen 9. September 2015PSI,9. September 2015PSI, Paul Scherrer Institut Basic powersupply control – Digital implementation

Beyond PI

• Compensation of higher order plant dynamics e.g. the output filter • 2-DOF structure to seperately tune reference tracking and disturbance rejection

K(s) G(s) R(s) K(s) G(s)

R(s) K(s) G(s)

H(s)

Page 13: Wir schaffen Wissen – heute für morgen 9. September 2015PSI,9. September 2015PSI, Paul Scherrer Institut Basic powersupply control – Digital implementation

PI

Analog:

Page 14: Wir schaffen Wissen – heute für morgen 9. September 2015PSI,9. September 2015PSI, Paul Scherrer Institut Basic powersupply control – Digital implementation

Paths to discrete controller

Physical Model

SamplingAnalog controller

design

Behavioural Model

Experimental (Ziegler-Nichols,)

Discretization Digital controller design

Harmonic response

Sampled Harmonic response

digital

analog

System to control

Source: Commande numérique de systèmes dynamiques, R. Longchamp

Page 15: Wir schaffen Wissen – heute für morgen 9. September 2015PSI,9. September 2015PSI, Paul Scherrer Institut Basic powersupply control – Digital implementation

Types of discretizations

Area based approximations:- Forward difference - Backward difference- Trapezoidal (Tustin, bilinear)

Response Invariant transforms:- Step response (zero-order hold)- Ramp response- Impulse response Pole-zero mapping

Page 16: Wir schaffen Wissen – heute für morgen 9. September 2015PSI,9. September 2015PSI, Paul Scherrer Institut Basic powersupply control – Digital implementation

Area based approximations

Forward Euler:

Backward Euler:

Trapezoidal:

Page 17: Wir schaffen Wissen – heute für morgen 9. September 2015PSI,9. September 2015PSI, Paul Scherrer Institut Basic powersupply control – Digital implementation

PI

Analog:

Discrete:

Page 18: Wir schaffen Wissen – heute für morgen 9. September 2015PSI,9. September 2015PSI, Paul Scherrer Institut Basic powersupply control – Digital implementation

Approximations z <--> s

Source: Theorie der Regelungstechnik, Hugo Gassmann

Page 19: Wir schaffen Wissen – heute für morgen 9. September 2015PSI,9. September 2015PSI, Paul Scherrer Institut Basic powersupply control – Digital implementation

Bode plot of integrators

-40

-30

-20

-10

0

10

Mag

nit

ud

e (d

B)

100

101

102

-180

-135

-90

-45

0

45

Ph

ase

(deg

)

Bode plot of discretized integrators

Frequency (rad/s)

analog

backward

forward

-40

-30

-20

-10

0

10

Mag

nit

ud

e (d

B)

100

101

102

-180

-135

-90

-45

0

45

Ph

ase

(deg

)

Bode plot of discretized integrators

Frequency (rad/s)

analog

tustin

Page 20: Wir schaffen Wissen – heute für morgen 9. September 2015PSI,9. September 2015PSI, Paul Scherrer Institut Basic powersupply control – Digital implementation

How to choose sampling time

• too large -> loss of information• too small -> loss of precision (numerical issues) / computational overload

• No absolute truth -> rules of thumb:– 10x faster than Shannons sampling theorem– Fs = 10 – 30x system bandwidth– Loss of phase margin not more than 5°-15° compared to the continuous system

Page 21: Wir schaffen Wissen – heute für morgen 9. September 2015PSI,9. September 2015PSI, Paul Scherrer Institut Basic powersupply control – Digital implementation

Summary

• PI controller for magnet powersupplies is a good choice:– can be manually tuned (only two parameters Kp & Ki)– good static performance (zero error)– reasonable dynamic performance

• Fast enough sampling rate allows to regard the discrete PI controller as a (quasi-)continous controller.

• High frequency behaviour not compensated (output filter resonance)

Page 22: Wir schaffen Wissen – heute für morgen 9. September 2015PSI,9. September 2015PSI, Paul Scherrer Institut Basic powersupply control – Digital implementation

21. April 2023PSI, 21. April 2023PSI, Seite 22