From 0e72ebe04916d9aafe8775192973afb91c4ef754 Mon Sep 17 00:00:00 2001 From: Antoine PerreaultE Date: Mon, 20 Mar 2023 18:04:30 -0400 Subject: [PATCH 1/2] nb --- src/main/java/frc/robot/RobotContainer.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/main/java/frc/robot/RobotContainer.java b/src/main/java/frc/robot/RobotContainer.java index 62f41f5..e9b16b9 100644 --- a/src/main/java/frc/robot/RobotContainer.java +++ b/src/main/java/frc/robot/RobotContainer.java @@ -146,13 +146,13 @@ public RobotContainer() { Map.entry(enbas,pivoteBrasBas), Map.entry(nulpart,pivotBrasRentre) ), chooser::getSelected), - ouvrePince.unless(()->chooser.getSelected().equals(nulpart)), + new OuvrePince(pince).unless(()->chooser.getSelected().equals(nulpart)), Commands.waitSeconds(1), - fermePince.unless(()->chooser.getSelected().equals(nulpart)), + new FermePince(pince).unless(()->chooser.getSelected().equals(nulpart)), new PivotBrasRentre(brasTelescopique , pivot).unless(()->chooser.getSelected().equals(nulpart)), Commands.waitSeconds(1), Commands.either(reculers, reculerb,()-> autosortir.getBoolean(true)), - avancer.unless(()->!autosortir.getBoolean(true)|| autobalance.getBoolean(false)), + new Avancer(basePilotable,()-> avancerdistance.getDouble(0)).unless(()->!autosortir.getBoolean(true)|| autobalance.getBoolean(false)), Commands.either(gyro, Commands.none(),()-> autobalance.getBoolean(true)) )).andThen(new InstantCommand(basePilotable::BrakeOuvre,basePilotable)); From 8ba1721503668b4263b4148385b2e47a7779498e Mon Sep 17 00:00:00 2001 From: Antoine PerreaultE Date: Mon, 20 Mar 2023 18:06:52 -0400 Subject: [PATCH 2/2] s --- src/main/java/frc/robot/RobotContainer.java | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/src/main/java/frc/robot/RobotContainer.java b/src/main/java/frc/robot/RobotContainer.java index 2d92961..92f0f89 100644 --- a/src/main/java/frc/robot/RobotContainer.java +++ b/src/main/java/frc/robot/RobotContainer.java @@ -99,16 +99,6 @@ Tape tape = new Tape(limelight, basePilotable, null); PivotManuel pivotManuel = new PivotManuel(pivot,manette2::getLeftX); BrasManuel brasManuel = new BrasManuel(brasTelescopique,manette2::getLeftY); - -SendableChooser chooser = new SendableChooser<>(); -String enhaut = "en bas"; -String aumilieux = "au milieux"; -String enbas = "en bas"; -String nulpart = "nul part"; -ShuffleboardLayout layoutauto = Shuffleboard.getTab("teb").getLayout("auto",BuiltInLayouts.kList) -.withSize(2,2).withProperties(Map.of("Label position","LEFT")); -GenericEntry autobalance = layoutauto.add("choix balance",true).withWidget(BuiltInWidgets.kToggleSwitch).getEntry(); -GenericEntry autosortir = layoutauto.add("choix sorit",false).withWidget(BuiltInWidgets.kToggleSwitch).getEntry(); public RobotContainer() { chooser.addOption(enhaut, enhaut); chooser.addOption(enbas, enbas);