From 26fa458c76160b26ad31bbf675bfc80dc1858f29 Mon Sep 17 00:00:00 2001 From: Rowan Flood <121908273+rflood07@users.noreply.github.com> Date: Sat, 24 Feb 2024 09:45:53 -0600 Subject: [PATCH 1/4] chagned som euatos and updated subwoofer angle --- src/main/deploy/pathplanner/autos/FleeAmp.auto | 2 +- src/main/deploy/pathplanner/autos/FleeMid.auto | 2 +- src/main/deploy/pathplanner/autos/FleeSource.auto | 2 +- src/main/java/frc/robot/RobotContainer.java | 4 ++-- src/main/java/frc/robot/settings/Constants.java | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/main/deploy/pathplanner/autos/FleeAmp.auto b/src/main/deploy/pathplanner/autos/FleeAmp.auto index d1e40a9a..7af2fc37 100644 --- a/src/main/deploy/pathplanner/autos/FleeAmp.auto +++ b/src/main/deploy/pathplanner/autos/FleeAmp.auto @@ -20,7 +20,7 @@ { "type": "wait", "data": { - "waitTime": 1.0 + "waitTime": 3.0 } }, { diff --git a/src/main/deploy/pathplanner/autos/FleeMid.auto b/src/main/deploy/pathplanner/autos/FleeMid.auto index 359f79c4..50fb4a78 100644 --- a/src/main/deploy/pathplanner/autos/FleeMid.auto +++ b/src/main/deploy/pathplanner/autos/FleeMid.auto @@ -20,7 +20,7 @@ { "type": "wait", "data": { - "waitTime": 1.25 + "waitTime": 3.0 } }, { diff --git a/src/main/deploy/pathplanner/autos/FleeSource.auto b/src/main/deploy/pathplanner/autos/FleeSource.auto index b687d9d8..f4069c20 100644 --- a/src/main/deploy/pathplanner/autos/FleeSource.auto +++ b/src/main/deploy/pathplanner/autos/FleeSource.auto @@ -20,7 +20,7 @@ { "type": "wait", "data": { - "waitTime": 1.25 + "waitTime": 3.0 } }, { diff --git a/src/main/java/frc/robot/RobotContainer.java b/src/main/java/frc/robot/RobotContainer.java index 8ae12889..8d21cc77 100644 --- a/src/main/java/frc/robot/RobotContainer.java +++ b/src/main/java/frc/robot/RobotContainer.java @@ -136,7 +136,7 @@ public class RobotContainer { /** The container for the robot. Contains subsystems, OI devices, and commands. */ public RobotContainer() { //preferences are initialized IF they don't already exist on the Rio - Preferences.initBoolean("Brushes", false); + Preferences.setBoolean("Brushes", false); Preferences.initBoolean("Intake", false); Preferences.initBoolean("Climber", false); Preferences.initBoolean("Shooter", false); @@ -410,7 +410,7 @@ private void registerNamedCommands() { NamedCommands.registerCommand("intakeOn", new InstantCommand(()-> intake.intakeYes(1))); } if(indexerExists&&shooterExists) { - NamedCommands.registerCommand("initialShot", new initialShot(shooter, indexer, 0.75, 0.5)); + NamedCommands.registerCommand("initialShot", new initialShot(shooter, indexer, 1.0, 2.0)); NamedCommands.registerCommand("shootNote", new shootNote(indexer, 1)); NamedCommands.registerCommand("shootNote", new shootNote(indexer, 1)); NamedCommands.registerCommand("setFeedTrue", new InstantCommand(()->SmartDashboard.putBoolean("feedMotor", true))); diff --git a/src/main/java/frc/robot/settings/Constants.java b/src/main/java/frc/robot/settings/Constants.java index 1c7c3e0a..53ada3d3 100644 --- a/src/main/java/frc/robot/settings/Constants.java +++ b/src/main/java/frc/robot/settings/Constants.java @@ -430,7 +430,7 @@ public final class Field{ public static final double SHORT_RANGE_SHOOTING_DIST = 3; public static final double AMPLIFIER_ANGLE = 101; - public static final double SUBWOOFER_ANGLE = 80; + public static final double SUBWOOFER_ANGLE = 55; //angle at 60 for bounce techinque, didn't work } From f44a242fc63c8a44a07a45df4003ba3ceff73d0e Mon Sep 17 00:00:00 2001 From: Rowan Flood <121908273+rflood07@users.noreply.github.com> Date: Mon, 26 Feb 2024 17:23:54 -0600 Subject: [PATCH 2/4] fixed initialShot --- src/main/java/frc/robot/RobotContainer.java | 2 +- .../java/frc/robot/commands/NamedCommands/initialShot.java | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/main/java/frc/robot/RobotContainer.java b/src/main/java/frc/robot/RobotContainer.java index 8d21cc77..3375de87 100644 --- a/src/main/java/frc/robot/RobotContainer.java +++ b/src/main/java/frc/robot/RobotContainer.java @@ -410,7 +410,7 @@ private void registerNamedCommands() { NamedCommands.registerCommand("intakeOn", new InstantCommand(()-> intake.intakeYes(1))); } if(indexerExists&&shooterExists) { - NamedCommands.registerCommand("initialShot", new initialShot(shooter, indexer, 1.0, 2.0)); + NamedCommands.registerCommand("initialShot", new initialShot(shooter, indexer, 2.0, 2.25)); NamedCommands.registerCommand("shootNote", new shootNote(indexer, 1)); NamedCommands.registerCommand("shootNote", new shootNote(indexer, 1)); NamedCommands.registerCommand("setFeedTrue", new InstantCommand(()->SmartDashboard.putBoolean("feedMotor", true))); diff --git a/src/main/java/frc/robot/commands/NamedCommands/initialShot.java b/src/main/java/frc/robot/commands/NamedCommands/initialShot.java index 55be77ab..685da08a 100644 --- a/src/main/java/frc/robot/commands/NamedCommands/initialShot.java +++ b/src/main/java/frc/robot/commands/NamedCommands/initialShot.java @@ -20,7 +20,7 @@ public class initialShot extends Command { public initialShot(ShooterSubsystem shooter, IndexerSubsystem indexer, double revTime, double shootTime) { this.indexer = indexer; this.shooter = shooter; - this.revtime = revtime; + this.revtime = revTime; this.shootTime = shootTime; timer = new Timer(); addRequirements(shooter, indexer); @@ -30,7 +30,9 @@ public initialShot(ShooterSubsystem shooter, IndexerSubsystem indexer, double re // Called when the command is initially scheduled. @Override public void initialize() { + timer.reset(); timer.start(); + indexer.off(); shooter.shootRPS(ShooterConstants.SHORT_SHOOTING_RPS); } From 0a17b12537954e91663866d3f8f0590989006da8 Mon Sep 17 00:00:00 2001 From: Rowan Flood <121908273+rflood07@users.noreply.github.com> Date: Mon, 26 Feb 2024 17:25:02 -0600 Subject: [PATCH 3/4] lowered shooter current limit --- src/main/java/frc/robot/settings/Constants.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/frc/robot/settings/Constants.java b/src/main/java/frc/robot/settings/Constants.java index 53ada3d3..1a790452 100644 --- a/src/main/java/frc/robot/settings/Constants.java +++ b/src/main/java/frc/robot/settings/Constants.java @@ -269,7 +269,7 @@ public static final class ShooterConstants{ public static final double ALLOWED_ANGLE_ERROR = 1.5; public static final double ALLOWED_SPEED_ERROR = 4; - public static final double CURRENT_LIMIT = 200; //amps the motor is limited to + public static final double CURRENT_LIMIT = 100; //amps the motor is limited to public static final double AUTO_AIM_ROBOT_kP = 0.125; public static final double AUTO_AIM_ROBOT_kI = 0.00; From 285aa0a594abd6c83acd48e5f4a8d3a42fce661f Mon Sep 17 00:00:00 2001 From: Serena <90427548+Serena1528@users.noreply.github.com> Date: Mon, 26 Feb 2024 17:28:10 -0600 Subject: [PATCH 4/4] created brushes preference --- src/main/java/frc/robot/RobotContainer.java | 1 + 1 file changed, 1 insertion(+) diff --git a/src/main/java/frc/robot/RobotContainer.java b/src/main/java/frc/robot/RobotContainer.java index 3c452cf0..e888c2eb 100644 --- a/src/main/java/frc/robot/RobotContainer.java +++ b/src/main/java/frc/robot/RobotContainer.java @@ -100,6 +100,7 @@ public class RobotContainer { /** The container for the robot. Contains subsystems, OI devices, and commands. */ public RobotContainer() { //preferences are initialized IF they don't already exist on the Rio + Preferences.initBoolean("Brushes", false); Preferences.setBoolean("Brushes", false); Preferences.initBoolean("Intake", false); Preferences.initBoolean("Climber", false);