Commit eb6de156 authored by yean's avatar yean
Browse files

Changed gain parameters to reflect what they were previously

parent 98ac13ed
......@@ -9,25 +9,25 @@ function [vehicle_params] = setPIDgains(vehicle_params)
vehicle_params.PIDctrl.y.kP = 1;
% z
vehicle_params.PIDctrl.z.kP = 1;
vehicle_params.PIDctrl.z.kP = 13;
vehicle_params.PIDctrl.z.kI = 0;
vehicle_params.PIDctrl.z.kD = 0;
%% Velocity -> Acceleration
% x-dot
vehicle_params.PIDctrl.x_dot.kP = 1;
vehicle_params.PIDctrl.x_dot.kP = 1.5;
vehicle_params.PIDctrl.x_dot.kI = 0;
vehicle_params.PIDctrl.x_dot.kD = 0;
vehicle_params.PIDctrl.x_dot.kD = 1;
% y-dot
vehicle_params.PIDctrl.y_dot.kP = 1;
vehicle_params.PIDctrl.y_dot.kP = 1.5;
vehicle_params.PIDctrl.y_dot.kI = 0;
vehicle_params.PIDctrl.y_dot.kD = 0;
vehicle_params.PIDctrl.y_dot.kD = 1;
% z-dot
vehicle_params.PIDctrl.z_dot.kP = 1;
vehicle_params.PIDctrl.z_dot.kP = 15;
vehicle_params.PIDctrl.z_dot.kI = 0;
vehicle_params.PIDctrl.z_dot.kD = 0;
vehicle_params.PIDctrl.z_dot.kD = 5;
%% Attitude -> Attitude Rate
% Roll
......@@ -48,18 +48,18 @@ function [vehicle_params] = setPIDgains(vehicle_params)
%% Attitude Rate -> Torques
% Roll Rate
vehicle_params.PIDctrl.roll_rate.kP = 1;
vehicle_params.PIDctrl.roll_rate.kI = 0;
vehicle_params.PIDctrl.roll_rate.kD = 0;
vehicle_params.PIDctrl.roll_rate.kI = 0.25;
vehicle_params.PIDctrl.roll_rate.kD = 0.25;
% Pitch Rate
vehicle_params.PIDctrl.pitch_rate.kP = 1;
vehicle_params.PIDctrl.pitch_rate.kI = 0;
vehicle_params.PIDctrl.pitch_rate.kD = 0;
vehicle_params.PIDctrl.pitch_rate.kI = 0.25;
vehicle_params.PIDctrl.pitch_rate.kD = 0.25;
% Yaw Rate
vehicle_params.PIDctrl.yaw_rate.kP = 1;
vehicle_params.PIDctrl.yaw_rate.kI = 0;
vehicle_params.PIDctrl.yaw_rate.kD = 0;
vehicle_params.PIDctrl.yaw_rate.kI = 0.25;
vehicle_params.PIDctrl.yaw_rate.kD = 0.25;
end
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment