Simulink Control Design™ - MathWorks

(Tuis.) #1
% Replace "Controls Selector" by CS
BlockSub2 = struct('Name','csthl20_control/Flight Control System/Controls Selector','Value',CS);

% Replace "Actuators" by direct feedthrough (ignore saturations and second-order actuator dynamics)
BlockSub3 = struct('Name','csthl20_control/Actuators','Value',eye(6));

ST0.BlockSubstitutions = [BlockSub1 ; BlockSub2 ; BlockSub3];

You are now ready for the control design part.

Closing the Inner Loops

Begin with the three inner loops controlling the angular rates p,q,r. To get oriented, plot
the open-loop transfer function from deflections (da,de,dr) to angular rates (p,q,r). With
the slTuner interface, you can query the model for any transfer function of interest.

% NOTE: The second 'da;de;dr' opens all feedback loops at the plant input
Gpqr = getIOTransfer(ST0,'da;de;dr','pqr','da;de;dr');

bode(Gpqr(1,1),Gpqr(2,2),Gpqr(3,3),{1e-1,1e3}), grid
legend('da to p','de to q','dr to r')

11 Gain-Scheduled Controllers

Free download pdf