This commit is contained in:
Aarav Shah
2020-03-02 17:12:20 -07:00
parent 36e1534a8f
commit 85e0e798a2
2 changed files with 5 additions and 3 deletions
@@ -42,6 +42,8 @@ public final class Constants {
public static final SupplyCurrentLimitConfiguration SUPPLY_CURRENT_LIMIT_CONFIG =
new SupplyCurrentLimitConfiguration(false, 60, 40, 2);
public static final int CLOSED_LOOP_TIME_MS = 1; // Higher numbers mean slower control loops
public static final double COS_MULTIPLIER_LOW_DRIVE_STRAIGHT = 0.7;
public static final double COS_MULTIPLIER_HIGH_DRIVE_STRAIGHT = 0.7;
/* Drive Train Characteristics */
public static final double MOTOR_ROT_PER_WHEEL_ROT_HIGH = 5.13;
@@ -92,14 +92,14 @@ public class DriveWithJoystickDriveStraight extends CommandBase {
private void runDriveWithInput(double move, double steer) {
double cosMultiplier = 0.7;
double cosMultiplier;
double steerOutput = 0;
double deadzone = .1;
if (m_pneumatics.m_isSpeedShiftHigh) {
cosMultiplier = 0.7;
cosMultiplier = DriveConstants.COS_MULTIPLIER_HIGH_DRIVE_STRAIGHT;
} else {
cosMultiplier = 0.7;
cosMultiplier = DriveConstants.COS_MULTIPLIER_LOW_DRIVE_STRAIGHT;
}
/* Curves the steer output to be similarily gradual */