This commit is contained in:
2025-12-31 16:39:43 -06:00
parent 61f314d71d
commit 713bafd9b4

View File

@@ -73,13 +73,13 @@ public final class MecanumDrive {
public double kA = 0.000046;
// path profile parameters (in inches)
public double maxWheelVel = 120;
public double minProfileAccel = -30;
public double maxProfileAccel = 120;
public double maxWheelVel = 180;
public double minProfileAccel = -40;
public double maxProfileAccel = 180;
// turn profile parameters (in radians)
public double maxAngVel = 2* Math.PI; // shared with path
public double maxAngAccel = 2* Math.PI;
public double maxAngVel = 4* Math.PI; // shared with path
public double maxAngAccel = 4* Math.PI;
// path controller gains
public double axialGain = 4;
@@ -185,19 +185,19 @@ public final class MecanumDrive {
new DualNum<Time>(new double[]{
(leftFrontPosVel.position - lastLeftFrontPos),
leftFrontPosVel.velocity,
}).times(PARAMS.inPerTick),
}).times(PARAMS.inPerTick),
new DualNum<Time>(new double[]{
(leftBackPosVel.position - lastLeftBackPos),
leftBackPosVel.velocity,
}).times(PARAMS.inPerTick),
}).times(PARAMS.inPerTick),
new DualNum<Time>(new double[]{
(rightBackPosVel.position - lastRightBackPos),
rightBackPosVel.velocity,
}).times(PARAMS.inPerTick),
}).times(PARAMS.inPerTick),
new DualNum<Time>(new double[]{
(rightFrontPosVel.position - lastRightFrontPos),
rightFrontPosVel.velocity,
}).times(PARAMS.inPerTick)
}).times(PARAMS.inPerTick)
));
lastLeftFrontPos = leftFrontPosVel.position;