From e557d1bc6c0c3cd5da9a10e2bb6b28c8d07d02d5 Mon Sep 17 00:00:00 2001 From: OlivierDubois Date: Wed, 22 Feb 2023 18:50:04 -0500 Subject: [PATCH] commitrewsedrtyygfdf --- .../java/frc/robot/subsystems/BasePilotable.java | 4 +++- src/main/java/frc/robot/subsystems/Gratte.java | 10 ++++++---- src/main/java/frc/robot/subsystems/Limelight.java | 5 ++++- .../frc/robot/subsystems/bras/BrasTelescopique.java | 12 ++++-------- src/main/java/frc/robot/subsystems/bras/Pince.java | 6 ++++-- src/main/java/frc/robot/subsystems/bras/Pivot.java | 12 +++--------- 6 files changed, 24 insertions(+), 25 deletions(-) diff --git a/src/main/java/frc/robot/subsystems/BasePilotable.java b/src/main/java/frc/robot/subsystems/BasePilotable.java index 6ed4487..9a53bac 100644 --- a/src/main/java/frc/robot/subsystems/BasePilotable.java +++ b/src/main/java/frc/robot/subsystems/BasePilotable.java @@ -76,5 +76,7 @@ public void resetGyro(){ teb .add("encodeurarrieredroit",0.1); teb .add("encodeuravantgauche",0.1); teb .add("distance",0.1); + teb .add("brakedroit",0.1); + teb .add("brakegauche", 0.1); } -} +} \ No newline at end of file diff --git a/src/main/java/frc/robot/subsystems/Gratte.java b/src/main/java/frc/robot/subsystems/Gratte.java index 4cefbae..0332f41 100644 --- a/src/main/java/frc/robot/subsystems/Gratte.java +++ b/src/main/java/frc/robot/subsystems/Gratte.java @@ -8,9 +8,11 @@ import edu.wpi.first.wpilibj2.command.SubsystemBase; import com.ctre.phoenix.motorcontrol.can.WPI_TalonSRX; import edu.wpi.first.wpilibj.DigitalInput; import edu.wpi.first.wpilibj.shuffleboard.Shuffleboard; +import edu.wpi.first.wpilibj.shuffleboard.ShuffleboardTab; import frc.robot.Constants; public class Gratte extends SubsystemBase { + ShuffleboardTab teb = Shuffleboard.getTab("teb"); private WPI_TalonSRX Gratted = new WPI_TalonSRX(Constants.leverGratte); private WPI_TalonSRX Gratteg = new WPI_TalonSRX(Constants.baisserGratte); private DigitalInput limithd = new DigitalInput(Constants.limithd); @@ -44,9 +46,9 @@ public class Gratte extends SubsystemBase { } @Override public void periodic() { - Shuffleboard.getTab("SmartDashBoard") .add("limithd",0.1); - Shuffleboard.getTab("SmartDashBoard") .add("limitbd",0.1); - Shuffleboard.getTab("SmartDashBoard") .add("limithg",0.1); - Shuffleboard.getTab("SmartDashBoard") .add("limitbg",0.1); + teb .add("limithd", 0.1); + teb .add("limithg", 0.1); + teb .add("limitbd", 0.1); + teb .add("limitbg", 0.1); } } diff --git a/src/main/java/frc/robot/subsystems/Limelight.java b/src/main/java/frc/robot/subsystems/Limelight.java index a17900b..5a4f7fc 100644 --- a/src/main/java/frc/robot/subsystems/Limelight.java +++ b/src/main/java/frc/robot/subsystems/Limelight.java @@ -6,6 +6,8 @@ package frc.robot.subsystems; import edu.wpi.first.cameraserver.CameraServer; import edu.wpi.first.wpilibj.shuffleboard.Shuffleboard; +import edu.wpi.first.wpilibj.shuffleboard.ShuffleboardTab; + import org.photonvision.PhotonCamera; import org.photonvision.common.hardware.VisionLEDMode; import org.photonvision.targeting.PhotonTrackedTarget; @@ -15,6 +17,7 @@ import edu.wpi.first.wpilibj2.command.SubsystemBase; public class Limelight extends SubsystemBase { + ShuffleboardTab teb = Shuffleboard.getTab("teb"); PhotonCamera limelight = new PhotonCamera("limelight"); /** Creates a new Limelight. */ public Limelight() { @@ -56,6 +59,6 @@ public class Limelight extends SubsystemBase { @Override public void periodic() { CameraServer.startAutomaticCapture(); - Shuffleboard.getTab("SmartDashBoard") .add("limelight",0.1); + teb .add("limelight", 0.1); } } diff --git a/src/main/java/frc/robot/subsystems/bras/BrasTelescopique.java b/src/main/java/frc/robot/subsystems/bras/BrasTelescopique.java index 08f983b..7334c0b 100644 --- a/src/main/java/frc/robot/subsystems/bras/BrasTelescopique.java +++ b/src/main/java/frc/robot/subsystems/bras/BrasTelescopique.java @@ -8,15 +8,14 @@ package frc.robot.subsystems.bras; import com.revrobotics.CANSparkMax; import com.revrobotics.CANSparkMaxLowLevel.MotorType; -<<<<<<< HEAD import edu.wpi.first.wpilibj.DigitalInput; -======= ->>>>>>> Dash import edu.wpi.first.wpilibj.shuffleboard.Shuffleboard; +import edu.wpi.first.wpilibj.shuffleboard.ShuffleboardTab; import edu.wpi.first.wpilibj2.command.SubsystemBase; import frc.robot.Constants; public class BrasTelescopique extends SubsystemBase { + ShuffleboardTab teb = Shuffleboard.getTab("teb"); /** Creates a new BrasTelescopique. */ public BrasTelescopique() {} final CANSparkMax Winch = new CANSparkMax(Constants.BrasTelescopique,MotorType.kBrushless); @@ -35,10 +34,7 @@ public class BrasTelescopique extends SubsystemBase { } @Override public void periodic() { -<<<<<<< HEAD - Shuffleboard.getTab("SmartDashBoard") .add("photocell",0.1); -======= - Shuffleboard.getTab("SmartDashBoard") .add("winch",0.1); ->>>>>>> Dash + teb .add("``photocell``",0.1); + teb .add("winch",0.1); } } diff --git a/src/main/java/frc/robot/subsystems/bras/Pince.java b/src/main/java/frc/robot/subsystems/bras/Pince.java index 2aa6540..62022de 100644 --- a/src/main/java/frc/robot/subsystems/bras/Pince.java +++ b/src/main/java/frc/robot/subsystems/bras/Pince.java @@ -8,9 +8,12 @@ import edu.wpi.first.wpilibj.DoubleSolenoid; import edu.wpi.first.wpilibj.PneumaticsModuleType; import edu.wpi.first.wpilibj2.command.SubsystemBase; import edu.wpi.first.wpilibj.DoubleSolenoid.Value; +import edu.wpi.first.wpilibj.shuffleboard.Shuffleboard; +import edu.wpi.first.wpilibj.shuffleboard.ShuffleboardTab; import frc.robot.Constants; -public class Pince extends SubsystemBase { + +public class Pince extends SubsystemBase{ private DoubleSolenoid pistonPince = new DoubleSolenoid(PneumaticsModuleType.CTREPCM,Constants.pistonpinceouvre, Constants.pistonpinceferme); /** Creates a new Pince. */ public Pince() { @@ -23,6 +26,5 @@ public class Pince extends SubsystemBase { } @Override public void periodic() { - } } diff --git a/src/main/java/frc/robot/subsystems/bras/Pivot.java b/src/main/java/frc/robot/subsystems/bras/Pivot.java index b2494d0..e4ea340 100644 --- a/src/main/java/frc/robot/subsystems/bras/Pivot.java +++ b/src/main/java/frc/robot/subsystems/bras/Pivot.java @@ -4,11 +4,9 @@ package frc.robot.subsystems.bras; -<<<<<<< HEAD import edu.wpi.first.wpilibj.DigitalInput; -======= ->>>>>>> Dash import edu.wpi.first.wpilibj.shuffleboard.Shuffleboard; +import edu.wpi.first.wpilibj.shuffleboard.ShuffleboardTab; import edu.wpi.first.wpilibj2.command.SubsystemBase; import frc.robot.Constants; @@ -16,6 +14,7 @@ import com.revrobotics.CANSparkMax; import com.revrobotics.CANSparkMaxLowLevel.MotorType; public class Pivot extends SubsystemBase { + ShuffleboardTab teb = Shuffleboard.getTab("teb"); // moteur private CANSparkMax pivot = new CANSparkMax(Constants.pivot,MotorType.kBrushless); private DigitalInput limitpivot = new DigitalInput(Constants.limitpivot); @@ -37,11 +36,6 @@ public class Pivot extends SubsystemBase { } @Override public void periodic() { -<<<<<<< HEAD - Shuffleboard.getTab("SmartDashBoard") .add("limitpivot",0.1); + teb .add("encodeur", 0.1); } -======= - Shuffleboard.getTab("SmartDashBoard") .add("pivot encodeur",0.1); - } ->>>>>>> Dash }