Skip to content

Commit

Permalink
updated presets and mapped more buttons
Browse files Browse the repository at this point in the history
  • Loading branch information
Liammurray19 committed Feb 8, 2025
1 parent 67ff978 commit e0d3208
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
5 changes: 3 additions & 2 deletions src/main/java/frc/robot/Robot.java
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ public void configureButtonBindings() {
driveController.leftBumper()
.whileTrue(drive.robotCentricDrive());

copilotController.a().onTrue(coralManip.intake());
copilotController.a().onTrue(commandSequences.intake());

copilotController.x().whileTrue(commandSequences.moveElevator(ElevatorPresets.SCOREL1))
.onFalse(commandSequences.scoreL1());
Expand All @@ -136,7 +136,8 @@ public void configureButtonBindings() {

copilotController.y().whileTrue(commandSequences.moveElevator(ElevatorPresets.SCOREL3))
.onFalse(commandSequences.score());

copilotController.leftBumper().whileTrue(commandSequences.moveElevator(ElevatorPresets.SCOREL4))
.onFalse(commandSequences.scoreL4());
copilotController.back().onTrue(elevator.resetCmd());
copilotController.start().onTrue(elevator.zero());

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/frc/robot/maps/ColdStart.java
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ public ElevatorMap getElevatorMap() {
ElevatorFeedforward feedForward = new ElevatorFeedforward(0, 0.01, 0);

return new ElevatorMap(leftMotor, leftMotor.getEncoder(),
new ElevatorMap.ElevatorPresetValues(19.5, 5, 18, 38, 0, 0, 0),
new ElevatorMap.ElevatorPresetValues(16, 5, 14, 29, 56, 57.5, 1),
new ValueRange(0, 57.5), new ValueRange(3, 53), pid, feedForward);
}

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/frc/robot/subsystems/Drive.java
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ public class Drive extends LoggedSubsystem<SwerveDriveData, SwerveDriveMap> {
private final double ROTATION_COEFFICIENT = 1;
private final double ROTATION_KP = 0.05;
private final double ROTATION_KS = 0.19;
final Modifier DEADBAND = Modifier.scalingDeadband(0.05);
final Modifier DEADBAND = Modifier.scalingDeadband(0.1);

ProfiledPIDController rotationPID = new ProfiledPIDController(0.05, 0.0002, 0.000, new Constraints(240, 270));
DoubleSupplier xSpeedSupplier;
Expand Down

0 comments on commit e0d3208

Please sign in to comment.