diff --git a/src/main/java/frc/robot/RobotContainer.java b/src/main/java/frc/robot/RobotContainer.java index 493cfbe..eef6f29 100644 --- a/src/main/java/frc/robot/RobotContainer.java +++ b/src/main/java/frc/robot/RobotContainer.java @@ -76,7 +76,6 @@ public RobotContainer() { manette1.a().toggleOnTrue(Commands.startEnd(pince::ouvrir, pince::fermer,pince)); manette1.x().toggleOnTrue(Commands.startEnd(basePilotable::BrakeFerme,basePilotable::BrakeOuvre,basePilotable)); manette1.y().whileTrue(gyro); - // manette1.b().toggleOnTrue(Commands.startEnd(gratte::baiser, gratte::Lever,gratte)); manette1.start().toggleOnTrue(Commands.startEnd(basePilotable::resetGyro, basePilotable::resetGyro, basePilotable)); manette1.b().toggleOnTrue(Commands.startEnd(gratte::baiser, gratte::Lever,gratte)); // manette 2 @@ -87,7 +86,7 @@ public RobotContainer() { manette2.povRight().toggleOnTrue(Commands.startEnd(brasTelescopique::PivotChercheBas, brasTelescopique::PivotChercheBas, brasTelescopique)); manette2.povLeft().toggleOnTrue(Commands.startEnd(brasTelescopique::PivotChercheHaut, brasTelescopique::PivotChercheHaut, brasTelescopique)); manette2.rightBumper().toggleOnTrue(Commands.startEnd(null, null, null)); - manette2.leftBumper().toggleOnTrue(Commands.startEnd(null, null, null)); + manette2.leftBumper().toggleOnTrue(Commands.startEnd(null, null, null)); } diff --git a/src/main/java/frc/robot/commands/GratteBaisser.java b/src/main/java/frc/robot/commands/GratteBaisser.java index de68b8f..0e79838 100644 --- a/src/main/java/frc/robot/commands/GratteBaisser.java +++ b/src/main/java/frc/robot/commands/GratteBaisser.java @@ -9,6 +9,7 @@ import frc.robot.subsystems.Gratte; public class GratteBaisser extends CommandBase { private Gratte gratte; + private int vitesse; /** Creates a new GratteBaisser. */ public GratteBaisser(Gratte gratte) { this.gratte = gratte; @@ -41,7 +42,9 @@ public class GratteBaisser extends CommandBase { // Called once the command ends or is interrupted. @Override - public void end(boolean interrupted) {} + public void end(boolean interrupted) { + + } // Returns true when the command should end. @Override diff --git a/src/main/java/frc/robot/subsystems/Gratte.java b/src/main/java/frc/robot/subsystems/Gratte.java index 8707d45..3f727ef 100644 --- a/src/main/java/frc/robot/subsystems/Gratte.java +++ b/src/main/java/frc/robot/subsystems/Gratte.java @@ -25,6 +25,7 @@ ShuffleboardLayout limitswitchgratte = Shuffleboard.getTab("teb") private DigitalInput limithg = new DigitalInput(Constants.limithg); private DigitalInput limitbd = new DigitalInput(Constants.limitbd); private DigitalInput limitbg = new DigitalInput(Constants.limitbg); +public boolean baiser; public boolean hautd(){ return limithd.get(); @@ -34,7 +35,7 @@ ShuffleboardLayout limitswitchgratte = Shuffleboard.getTab("teb") return limithg.get(); } - public boolean basd(){ + public boolean basd(int i, String string){ return limitbd.get(); } public boolean basg(){ @@ -61,4 +62,8 @@ ShuffleboardLayout limitswitchgratte = Shuffleboard.getTab("teb") limitswitchgratte.add ("limithd", 0.1); limitswitchgratte.add ("limitbg", 0.1); } + +public boolean basd() { + return false; +} }