From 25a11282e5c06b90a6fa56de914ace7e1939df1b Mon Sep 17 00:00:00 2001 From: EdwardFaucher Date: Mon, 20 Mar 2023 19:17:21 -0400 Subject: [PATCH] sdfg --- src/main/java/frc/robot/RobotContainer.java | 8 ++++---- src/main/java/frc/robot/commands/bras/PivoteBrasHaut.java | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/main/java/frc/robot/RobotContainer.java b/src/main/java/frc/robot/RobotContainer.java index 908d820..151c2cf 100644 --- a/src/main/java/frc/robot/RobotContainer.java +++ b/src/main/java/frc/robot/RobotContainer.java @@ -88,8 +88,8 @@ public class RobotContainer { Cube cube = new Cube(limelight, basePilotable, () -> manette1.getLeftY()); Apriltag aprilTag = new Apriltag(limelight, basePilotable, () -> manette1.getLeftY()); Tape tape = new Tape(limelight, basePilotable, () -> manette1.getLeftY()); - PivotManuel pivotManuel = new PivotManuel(pivot, manette1::getLeftY); - BrasManuel brasManuel = new BrasManuel(brasTelescopique, manette1::getLeftX); + PivotManuel pivotManuel = new PivotManuel(pivot, manette1::getRightY); + BrasManuel brasManuel = new BrasManuel(brasTelescopique, manette1::getRightX); public RobotContainer() { chooser.addOption(enhaut, enhaut); @@ -118,8 +118,8 @@ public class RobotContainer { manette1.povRight().whileTrue(creerCommandBras(44, -17)); manette1.povLeft().whileTrue(creerCommandBras(0, 0)); // manette 2 - manette2.povDown().onTrue(creerCommandBras(9, -18)); - manette2.povUp().onTrue(creerCommandBras(44, 0)); + manette2.povDown().whileTrue(creerCommandBras(9, -18)); + manette2.povUp().whileTrue(creerCommandBras(44, 0)); manette2.rightBumper().whileTrue(cube); manette2.leftBumper().whileTrue(cone); manette2.y().whileTrue(gyro); diff --git a/src/main/java/frc/robot/commands/bras/PivoteBrasHaut.java b/src/main/java/frc/robot/commands/bras/PivoteBrasHaut.java index c670121..831991a 100644 --- a/src/main/java/frc/robot/commands/bras/PivoteBrasHaut.java +++ b/src/main/java/frc/robot/commands/bras/PivoteBrasHaut.java @@ -29,21 +29,21 @@ public class PivoteBrasHaut extends CommandBase { // Called every time the scheduler runs while the command is scheduled. @Override public void execute() { - if(brasTelescopique.distance()>-39.5){ + if(brasTelescopique.distance()>-36.5){ brasTelescopique.AvanceRecule(-0.15); brasTelescopique.fermer(); } - else if(brasTelescopique.distance()<-41.5) { + else if(brasTelescopique.distance()<-37.5) { brasTelescopique.AvanceRecule(-0.15); } else { brasTelescopique.AvanceRecule(0); brasTelescopique.ouvrir(); } - if (pivot.distance()<50.5){ + if (pivot.distance()<52.5){ pivot.monteDescendre(0.5); } - else if(pivot.distance()>52.5) { + else if(pivot.distance()>53.5) { pivot.monteDescendre(-0.5); } else{