From 63aad0f693f87fe31d2460de83485b524a2f3e07 Mon Sep 17 00:00:00 2001 From: OlivierDubois Date: Mon, 12 Feb 2024 19:13:25 -0500 Subject: [PATCH 1/5] k --- src/main/java/frc/robot/RobotContainer.java | 2 +- src/main/java/frc/robot/command/AllumeLED.java | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/frc/robot/RobotContainer.java b/src/main/java/frc/robot/RobotContainer.java index 9461c4a..5a715bb 100644 --- a/src/main/java/frc/robot/RobotContainer.java +++ b/src/main/java/frc/robot/RobotContainer.java @@ -71,7 +71,7 @@ public class RobotContainer { Lancerampli lancerampli = new Lancerampli(lanceur,limelight); GrimpeurDroit grimpeurDroit = new GrimpeurDroit(grimpeur, manette::getLeftX); GrimpeurGauche grimpeurGauche = new GrimpeurGauche(grimpeur, manette::getLeftY); - AllumeLED allumeLED = new AllumeLED(LED); + AllumeLED allumeLED = new AllumeLED(LED,accumulateur); Pistongrimpeur pistongrimpeur = new Pistongrimpeur(grimpeur, LED); public RobotContainer() { dashboard.addCamera("limelight", "limelight","limelight.local:5800"); diff --git a/src/main/java/frc/robot/command/AllumeLED.java b/src/main/java/frc/robot/command/AllumeLED.java index dd1d09e..484ecb3 100644 --- a/src/main/java/frc/robot/command/AllumeLED.java +++ b/src/main/java/frc/robot/command/AllumeLED.java @@ -12,7 +12,7 @@ public class AllumeLED extends Command { private LED led; private Accumulateur accumulateur; /** Creates a new AllumeLED. */ - public AllumeLED(LED led) { + public AllumeLED(LED led,Accumulateur accumulateur) { this.accumulateur = accumulateur; this.led = led; addRequirements(led); From 7a8dfb3a1318b8c4449473a1d3a948eb66213a3c Mon Sep 17 00:00:00 2001 From: OlivierDubois Date: Mon, 12 Feb 2024 19:15:10 -0500 Subject: [PATCH 2/5] s --- src/main/java/frc/robot/RobotContainer.java | 5 ----- 1 file changed, 5 deletions(-) diff --git a/src/main/java/frc/robot/RobotContainer.java b/src/main/java/frc/robot/RobotContainer.java index 1e54a52..cfde281 100644 --- a/src/main/java/frc/robot/RobotContainer.java +++ b/src/main/java/frc/robot/RobotContainer.java @@ -71,13 +71,8 @@ public class RobotContainer { LancerNote lancernote = new LancerNote(lanceur, accumulateur); Lancerampli lancerampli = new Lancerampli(lanceur,limelight); GrimpeurDroit grimpeurDroit = new GrimpeurDroit(grimpeur, manette::getLeftX); -<<<<<<< HEAD - GrimpeurGauche grimpeurGauche = new GrimpeurGauche(grimpeur, manette::getLeftY); - AllumeLED allumeLED = new AllumeLED(LED,accumulateur); -======= GrimpeurGauche grimpeurGauche = new GrimpeurGauche(grimpeur, manette::getRightX); AllumeLED allumeLED = new AllumeLED(LED, accumulateur); ->>>>>>> 7a37782ca19fb71cb842174cd8fcd536eda825a9 Pistongrimpeur pistongrimpeur = new Pistongrimpeur(grimpeur, LED); public RobotContainer() { dashboard.addCamera("limelight", "limelight","limelight.local:5800"); From 4ab1e6a5f0547a2cddaf98bff216a3cd1aaa2abd Mon Sep 17 00:00:00 2001 From: Antoine PerreaultE Date: Tue, 13 Feb 2024 17:50:06 -0500 Subject: [PATCH 3/5] ji --- src/main/java/frc/robot/RobotContainer.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/main/java/frc/robot/RobotContainer.java b/src/main/java/frc/robot/RobotContainer.java index cfde281..ae2b771 100644 --- a/src/main/java/frc/robot/RobotContainer.java +++ b/src/main/java/frc/robot/RobotContainer.java @@ -18,9 +18,8 @@ import edu.wpi.first.wpilibj2.command.Command; import edu.wpi.first.wpilibj2.command.ParallelCommandGroup; import edu.wpi.first.wpilibj2.command.RunCommand; import edu.wpi.first.wpilibj2.command.SequentialCommandGroup; -// Manette -import edu.wpi.first.wpilibj2.command.WaitCommand; // Manettes +import edu.wpi.first.wpilibj2.command.WaitCommand; import edu.wpi.first.wpilibj2.command.button.CommandJoystick; import edu.wpi.first.wpilibj2.command.button.CommandXboxController; From dcfd6b3a4ebcc9b1a9fdedad10ff34dd9ef17f59 Mon Sep 17 00:00:00 2001 From: Antoine PerreaultE Date: Tue, 13 Feb 2024 18:08:55 -0500 Subject: [PATCH 4/5] nh --- src/main/java/frc/robot/RobotContainer.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/main/java/frc/robot/RobotContainer.java b/src/main/java/frc/robot/RobotContainer.java index ae2b771..402659f 100644 --- a/src/main/java/frc/robot/RobotContainer.java +++ b/src/main/java/frc/robot/RobotContainer.java @@ -45,7 +45,6 @@ import frc.robot.subsystem.Guideur; import frc.robot.subsystem.LED; import frc.robot.subsystem.Lanceur; import frc.robot.subsystem.Limelight; -import frc.robot.subsystem.Pixy; public class RobotContainer { @@ -59,7 +58,6 @@ public class RobotContainer { Lanceur lanceur = new Lanceur(); Limelight limelight = new Limelight(); LED LED = new LED(); - Pixy pixy = new Pixy(); CommandJoystick joystick = new CommandJoystick(0); CommandXboxController manette = new CommandXboxController(1); //command @@ -87,10 +85,14 @@ public class RobotContainer { joystick.button(1).whileTrue(new LancerNote(lanceur, accumulateur)); joystick.button(4).whileTrue(new ParallelCommandGroup(new Lancer(lanceur,limelight),new Limelight_tracker(limelight,drive))); joystick.button(2).whileTrue(new ParallelCommandGroup(new Lancerampli(lanceur,limelight),new Limelight_tracker(limelight,drive),new GuiderHaut(guideur))); + + // deplacement configureBindings(); drive.setDefaultCommand(new RunCommand(()->{ drive.drive(-MathUtil.applyDeadband(joystick.getY(),0.2), MathUtil.applyDeadband(-joystick.getX(),0.2), MathUtil.applyDeadband(-joystick.getZ(), 0.2)); },drive)); + + // grimpeur manuel grimpeur.setDefaultCommand(new RunCommand(()->{ grimpeur.droit(manette.getLeftX()); grimpeur.gauche(manette.getRightX());} From 4606a410015c4037832d1748e8f935a48ac59a21 Mon Sep 17 00:00:00 2001 From: Antoine PerreaultE Date: Tue, 13 Feb 2024 18:17:38 -0500 Subject: [PATCH 5/5] k --- src/main/java/frc/robot/RobotContainer.java | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/src/main/java/frc/robot/RobotContainer.java b/src/main/java/frc/robot/RobotContainer.java index 402659f..3083a2f 100644 --- a/src/main/java/frc/robot/RobotContainer.java +++ b/src/main/java/frc/robot/RobotContainer.java @@ -6,20 +6,16 @@ package frc.robot; import com.pathplanner.lib.auto.AutoBuilder; import com.pathplanner.lib.auto.NamedCommands; -import com.pathplanner.lib.commands.PathPlannerAuto; - import edu.wpi.first.cameraserver.CameraServer; import edu.wpi.first.math.MathUtil; import edu.wpi.first.wpilibj.shuffleboard.Shuffleboard; import edu.wpi.first.wpilibj.shuffleboard.ShuffleboardTab; import edu.wpi.first.wpilibj.smartdashboard.SendableChooser; -import edu.wpi.first.wpilibj.smartdashboard.SmartDashboard; import edu.wpi.first.wpilibj2.command.Command; import edu.wpi.first.wpilibj2.command.ParallelCommandGroup; import edu.wpi.first.wpilibj2.command.RunCommand; -import edu.wpi.first.wpilibj2.command.SequentialCommandGroup; + // Manettes -import edu.wpi.first.wpilibj2.command.WaitCommand; import edu.wpi.first.wpilibj2.command.button.CommandJoystick; import edu.wpi.first.wpilibj2.command.button.CommandXboxController; @@ -36,6 +32,7 @@ import frc.robot.command.Lancerampli; import frc.robot.command.Limelight_tracker; import frc.robot.command.PistonFerme; import frc.robot.command.Pistongrimpeur; + // Subsystems import frc.robot.subsystem.Accumulateur; import frc.robot.subsystem.Balayeuse; @@ -60,6 +57,7 @@ public class RobotContainer { LED LED = new LED(); CommandJoystick joystick = new CommandJoystick(0); CommandXboxController manette = new CommandXboxController(1); + //command PistonFerme pistonFerme = new PistonFerme(grimpeur); Balayer balayer = new Balayer(balayeuse, accumulateur); @@ -104,12 +102,9 @@ public class RobotContainer { .withPosition(1,1); } - private void configureBindings() { - - } + private void configureBindings() {} public Command getAutonomousCommand(){ - return autoChooser.getSelected(); - + return autoChooser.getSelected(); } }