Skip to content

Commit

Permalink
More PID tuning
Browse files Browse the repository at this point in the history
Try to address the wobbles
  • Loading branch information
lamont-granquist committed Jun 17, 2023
1 parent 118a797 commit 2dbfcc6
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions MechJeb2/AttitudeControllers/BetterController.cs
Expand Up @@ -18,10 +18,10 @@ internal class BetterController : BaseAttitudeController
private readonly EditableDouble PosDeadband = new EditableDouble(0.0001);

[Persistent(pass = (int)(Pass.Type | Pass.Global))]
private readonly EditableDouble VelKp = new EditableDouble(35);
private readonly EditableDouble VelKp = new EditableDouble(10);

[Persistent(pass = (int)(Pass.Type | Pass.Global))]
private readonly EditableDouble VelKi = new EditableDouble(16.6);
private readonly EditableDouble VelKi = new EditableDouble(20);

[Persistent(pass = (int)(Pass.Type | Pass.Global))]
private readonly EditableDouble VelKd = new EditableDouble(0.425);
Expand Down Expand Up @@ -75,8 +75,8 @@ private void Defaults()
{
PosKp.val = 1.98;
PosDeadband.val = 0.0001;
VelKp.val = 35;
VelKi.val = 16.6;
VelKp.val = 10;
VelKi.val = 20;
VelKd.val = 0.425;
VelN.val = 84.1994541201249;
VelB.val = 0.994;
Expand All @@ -89,7 +89,7 @@ private void Defaults()
maxStoppingTime.val = 2;
minFlipTime.val = 120;
rollControlRange.val = 5;
_version = 3;
_version = 4;
}

private readonly PIDLoop[] _pid = { new PIDLoop(), new PIDLoop(), new PIDLoop() };
Expand Down

0 comments on commit 2dbfcc6

Please sign in to comment.