Skip to content
This repository has been archived by the owner on Nov 2, 2024. It is now read-only.

Commit

Permalink
Fix!
Browse files Browse the repository at this point in the history
  • Loading branch information
owenflatman committed Oct 25, 2023
1 parent 2c63b9d commit 75eefaa
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions src/main/java/frc/robot/RobotContainer.java
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
import java.util.Map;
import edu.wpi.first.math.MathUtil;
import edu.wpi.first.networktables.GenericEntry;
import edu.wpi.first.wpilibj.DriverStation;
import edu.wpi.first.wpilibj.GenericHID;
import edu.wpi.first.wpilibj.PneumaticHub;
import edu.wpi.first.wpilibj.RobotBase;
import edu.wpi.first.wpilibj.XboxController;
import edu.wpi.first.wpilibj.shuffleboard.BuiltInLayouts;
import edu.wpi.first.wpilibj.shuffleboard.BuiltInWidgets;
Expand Down Expand Up @@ -135,7 +135,7 @@ public class RobotContainer {
/**
* The container for the robot. Contains subsystems, OI devices, and commands.
*/
public RobotContainer(RobotBase robotBase) {
public RobotContainer() {
ph.enableCompressorAnalog(90, 120);
s_Swerve.setDefaultCommand(new TeleopSwerve(s_Swerve, driver,
Constants.Swerve.IS_FIELD_RELATIVE, Constants.Swerve.IS_OPEN_LOOP, s_Arm));
Expand Down Expand Up @@ -174,7 +174,7 @@ public RobotContainer(RobotBase robotBase) {
autoWaitChooser.addOption(String.valueOf(i), i);
}
// Configure the button bindings
configureButtonBindings(robotBase);
configureButtonBindings();
}

/**
Expand All @@ -183,9 +183,10 @@ public RobotContainer(RobotBase robotBase) {
* ({@link edu.wpi.first.wpilibj.Joystick} or {@link XboxController}), and then passing it to a
* {@link edu.wpi.first.wpilibj2.command.button.JoystickButton}.
*/
private void configureButtonBindings(RobotBase robotBase) {
private void configureButtonBindings() {

Trigger armSensor = new Trigger(() -> this.s_Arm.armSense.get() && robotBase.isDisabled());
Trigger armSensor =
new Trigger(() -> this.s_Arm.armSense.get() && DriverStation.isDisabled());

armSensor.onTrue(new DisabledInstantCommand(() -> s_Arm.setCoastMode()));

Expand Down

0 comments on commit 75eefaa

Please sign in to comment.