diff --git a/simPrototypeSTART.m b/simPrototypeSTART.m index cba9664..165366f 100644 --- a/simPrototypeSTART.m +++ b/simPrototypeSTART.m @@ -3,17 +3,17 @@ close all; clear all; clc; %% User Defined Values % Initial Conditions -Kp = -2^3; -Ki = -2^-2; -Kd = -2^0.75; +Kp = -8; +Ki = -0.25; +Kd = -1.6818; v0 = 0; % Initial Velocity (z) [m/s] M0 = 1.2; % Initial Mass [kg] yaw0 = 75; % Initial Yaw [deg] -pitch0 = 50; % Initial Pitch [deg] +pitch0 = 0; % Initial Pitch [deg] roll0 = 0; % Initial Roll [deg] p0 = 0; % Initial Angular Velocity (x) [deg/s] -q0 = 0; % Initial Angular Velocity (y) [deg/s] +q0 = 0; % Initial Angular Velocity (y) [deg/s] r0 = 0; % Initial Angular Velocity (z) [deg/s] Tcurve = readmatrix('F15_thrustCurve.txt'); % Thrust Curve from .txt [t, N] @@ -26,7 +26,7 @@ tb = Tcurve(end, 1) - Tcurve(1, 1); % Bu mdot = Mp / tb; % Mass Flow Rate [kg/s] D = 0; % Drag [N] stepSize = 0.001; % Simulation Step Size [s] -maxServo = 15; % Max Servo Rotation [deg] +maxServo = 7.5; % Max Servo Rotation [deg] % Moment of Inertia / Mass I11 = (1/12) * 0.5318^2 + 0.25 * 0.05105^2; % (1/12) * h^2 + 0.25 * r^2