Skip to content

Commit

Permalink
Merge pull request #16 from ddjoshua01/main
Browse files Browse the repository at this point in the history
Swerve Fixes
  • Loading branch information
zaneal authored Jan 27, 2024
2 parents 6accd84 + 04cb45c commit e8dccf9
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions src/main/java/frc/robot/RobotContainer.java
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,9 @@ public void configureButtonBindings(){

swerveSubsystem.setDefaultCommand(new DriveCommands(
swerveSubsystem,
() -> primaryController.getLeftY() * DrivetrainConstants.drivingSpeedScalar / 4.0,
() -> primaryController.getLeftX() * DrivetrainConstants.drivingSpeedScalar / 4.0,
() -> primaryController.getRightX() * DrivetrainConstants.rotationSpeedScalar / 4.0,
() -> primaryController.getLeftY() * DrivetrainConstants.drivingSpeedScalar / 1.0,
() -> primaryController.getLeftX() * DrivetrainConstants.drivingSpeedScalar / 1.0,
() -> primaryController.getRightX() * DrivetrainConstants.rotationSpeedScalar / 1.0,
true,
true
));
Expand Down
6 changes: 3 additions & 3 deletions src/main/java/frc/robot/constants/DrivetrainConstants.java
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ public class DrivetrainConstants {
public static final double drivingSpeedScalar = -1.0;
public static final double rotationSpeedScalar = 2.0;

public static final double trackWidth = Units.inchesToMeters(22);
public static final double trackWidth = Units.inchesToMeters(18);
public static final double wheelBase = Units.inchesToMeters(22.5);

public static final SwerveDriveKinematics driveKinematics = new SwerveDriveKinematics(
Expand All @@ -29,8 +29,8 @@ public class DrivetrainConstants {

public static final double frontLeftChassisAngularOffset = -0.57 + Math.PI;
public static final double frontRightChassisAngularOffset = 0.874 + Math.PI;
public static final double rearLeftChassisAngularOffset = 6.089;
public static final double rearRightChassisAngularOffset = 2.428 + Math.PI/2;
public static final double rearLeftChassisAngularOffset = 6.098;
public static final double rearRightChassisAngularOffset = 5.52 - Math.PI/2;

public static final int frontLeftDrivingPort = 1;
public static final int rearLeftDrivingPort = 5;
Expand Down

0 comments on commit e8dccf9

Please sign in to comment.