DFIG control 1: rotor side converter control

Doubly-fed generator control 1: rotor-side converter control
Software version: MATLAB Simulink R2022b
References:

  1. DFIM Tutorial 1 – Implementation and Control of a DFIM in Matlab-Simulink
  2. H. Abu-Rub, M. Malinowski, and K. Al-Haddad, Power Electronics for Renewable Energy Systems, Transportation and Industrial Applications. John Wiley & amp; Sons, 2014.
  3. G. Abad, J. Lopez, M. Rodriguez, L. Marroyo, and G. Iwanski, Doubly Fed Induction Machine: Modeling and Control for Wind Energy Generation. John Wiley & amp; Sons, 2011.

Recently, I need to learn about fans. I can’t read the book, so there is this tutorial, let’s try a simulation first. Doubly-fed asynchronous generator DFIG is often used in wind power generation, learn the most basic control method.

This is the simulation model built according to the above tutorial. It mainly introduces the entire simulation model and some places that are worth recording. Most of them are operated according to the video, and a few are adjusted according to their own ideas. The final simulation results are the same.
The first part, the control of the rotor side converter.

Main circuit and top layer

The main circuit of DFIG system is as follows. In the first part, we only look at the Rotor-side VSC, so replace the Vbus with a DC source, and delete the Grid-side VSC.

The top level of the simulation, including:

  1. Main circuit, only rotor-side converter RSC and constant DC-link voltage
  2. controller. The input of the controller is added with a first-order keeper.
  3. Motor model, common asynchronous motor. Constant torque input (you can pause during the simulation, change the value, and then continue to see the transient waveform)
  4. Oscilloscope to observe key waveforms. Here the goto module corresponding to the from module is set to global, so it can be connected from any position, which is quite convenient.

Three-phase power supply, connected to the stator.

The three-phase measurement module, which is the stator side, measures the grid voltage Vs and current Is.
Here use a label, you can directly use the from module with the same name to connect to the oscilloscope, which is also very convenient.

Universal bridge, three-phase two-level converter.

motor module

For the measurement of the motor, the motor model outputs many signals, and a few of them are selected using the bus selector.

PWM modulation module, input modulation wave amplitude range [-1,1], output PWM signal, frequency is fsw. –I was used to building it by myself before, and this is actually quite easy to use.

Control section

enter:

  1. Speed reference, give a fixed value
  2. d-axis current reference, set to 0
  3. Rotor current Ir
  4. Stator voltage Vs
  5. The mechanical angle theta of the motor
  6. Motor mechanical angular velocity omega_m (actually the differential of theta)

Output: modulation signal of three-phase two-level converter Vabc_ref

Control strategy

Refer to the control strategy in the figure below, the crossed part is not used, that is, the reactive power cannot be adjusted.
So in the end there are 3 PI controllers:

  1. Speed outer ring speed PI
  2. d-axis current loop id PI, do not adjust reactive power, only set idr=0
  3. q-axis current loop iq PI

Other modules include:

  1. Coordinate transformation, abc-αβ0-dq (this picture is called abc-DQ-dq, it feels weird, is it marked with this for motor related?)
  2. For angle calculation, the most basic method is used in the simulation.
  3. dq decoupling is actually based on the model of the motor, adding something to the output of the id and iq controllers

Simulation model

Corresponding to the control strategy, the simulation model is as follows.
Matlab function is used for coordinate transformation (The Fcn module in the video tutorial is not recommended in R2022b) – but there should be ready-made modules that can be used.

PI Controller

The main thing is to pay attention to the limit of PI output.

speed PI

id PI

iq PI

Coordinate transformation

See code below.

Angle calculation

Referring to the block diagram below, the angle is calculated directly with atan2 without using the PLL.

dq decoupling

In fact, it is the two formulas in the control strategy diagram, built with modules.

Simulation waveform

The reference values of speed and torque were changed, and several controllers were verified to work normally.
Practical applications will not use such control, without soft start, the transient current is too large.

Code involved

Initialization

clear

% DFIG parameters -> Rotor parameters referred to the stator side
f = 50; % Stator frequency (Hz)
Ps = 2e6; % Rated stator power (W)
n = 1500; % Rated rotational speed (rev/min)
Vs = 690; % Rated stator voltage (V)
Is = 1760; % Rated stator current (A)
Tem = 12732; % Rated torque (N.m)

p=2; % Pole pair

u = 1/3; % Stator/rotor turns ratio
Vr = 2070; % Rated rotor voltage (non-reached) (V)
smax = 1/3; % Maximum slip
Vr_stator = (Vr*smax) *u; % Rated rotor voltage referred to stator (V)
Rs = 2.6e-3; % Stator resistance(ohm)
Lsi = 0.087e-3; % Leakage inductance (stator & amp; rotor) (H)
Lm = 2.5e-3; % Magnetizing inductance (H)
Rr = 2.9e-3; % Rotor resistance referred to stator (ohm)
Ls = Lm + Lsi; % Stator inductance (H)
Lr = Lm + Lsi; % Rotor inductance (H)
Vbus = Vr_stator*sqrt(2); % DC de bus voltage referred to stator (V)

sigma = 1-Lm^2/(Ls*Lr);

Fs = Vs*sqrt(2/3)/(2*pi*f); % Stator Flux (aprox.) (Wb)
J = 127; % Inertia
D = 1e-3;

fsw = 4e3;
Ts = 1/fsw/50;

kT = -1.5*p*(Lm/Ls)*Fs; % kT, coef of output of the speed controller

tau_i = (sigma*Lr)/Rr;
tau_n = 0.05;
wni = 100*(1/tau_i);
wnn = 1/tau_n;

kp_id = (2*wni*sigma*Lr)-Rr;
kp_iq = kp_id;

ki_id = (wni^2)*Lr*sigma;
ki_iq = ki_id;

kp_n = (2*wnn*J)/p; %kp_n = (2*wnn*J)/p;
ki_n = (wnn^2)*J/p; %ki_n = (wnn^2)*J/p;

abc-αβ0

function ab0 = abc_to_ab0(abc)
ab0 = zeros(2,1);
ab0(1) = 2/3 * (abc(1) - abc(2)/2 - abc(3)/2);
ab0(2) = 2/3 * ( (sqrt(3)/2)*abc(2) - (sqrt(3)/2)*abc(3));
end

αβ0-dq

function dq = ab0_to_dq(ab0, theta)
dq = zeros(2,1);
dq(1) = cos(theta)*ab0(1) + sin(theta)*ab0(2);
dq(2) = -sin(theta)*ab0(1) + cos(theta)*ab0(2);
end

dq-αβ0

function ab0 = dq_to_ab0(dq, theta)
ab0 = zeros(2,1);
ab0(1) = dq(1) * cos(theta) - dq(2) * sin(theta);
ab0(2) = dq(1) * sin(theta) + dq(2) * cos(theta);
end

αβ0-abc

function abc = ab0_to_abc(ab0)
abc = zeros(3,1);
abc(1) = ab0(1);
abc(2) = -1/2 * ab0(1) + sqrt(3)/2 * ab0(2);
abc(3) = -1/2 * ab0(1) - sqrt(3)/2 * ab0(2);
end

Some remaining questions

There are still some places that I don’t understand. I feel that I can read the book now.

  1. Doubly-fed machine model and dq decoupling principle
  2. The principle of the angle calculation module
  3. Selection of individual PI controller parameters