This commit is contained in:
Shikhar
2026-04-04 13:02:50 -06:00
parent 6d55c96f6a
commit 2d56e5eeff
4 changed files with 12 additions and 12 deletions
@@ -330,6 +330,7 @@ public class RobotContainer {
new Trigger(() -> getDeadbandedOperatorController().getRightTriggerAxis() >= 0.5) new Trigger(() -> getDeadbandedOperatorController().getRightTriggerAxis() >= 0.5)
.onTrue(new InstantCommand(() -> { .onTrue(new InstantCommand(() -> {
m_robotShooter.allowShooting(); m_robotShooter.allowShooting();
m_robotIntake.rollerStop();
})).onFalse(new InstantCommand(() -> { })).onFalse(new InstantCommand(() -> {
m_robotShooter.denyShooting(); m_robotShooter.denyShooting();
})); }));
@@ -350,7 +351,6 @@ public class RobotContainer {
new Trigger(() -> getDeadbandedOperatorController().getLeftTriggerAxis() >= 0.5) new Trigger(() -> getDeadbandedOperatorController().getLeftTriggerAxis() >= 0.5)
.onTrue(new InstantCommand(() -> { .onTrue(new InstantCommand(() -> {
m_robotIntake.setMode(IntakeMode.Idle); m_robotIntake.setMode(IntakeMode.Idle);
m_robotIntake.rollerStop();
m_robotShooter.spinUpShooting(); m_robotShooter.spinUpShooting();
})) }))
.onFalse(new InstantCommand(() -> { .onFalse(new InstantCommand(() -> {
@@ -370,14 +370,11 @@ public class RobotContainer {
new JoystickButton(getDeadbandedOperatorController(), XboxController.X_BUTTON) new JoystickButton(getDeadbandedOperatorController(), XboxController.X_BUTTON)
.onTrue(new InstantCommand(() -> { .onTrue(new InstantCommand(() -> {
m_robotIntake.setMode(IntakeMode.ExtendingRolling); m_robotIntake.setMode(IntakeMode.ExtendingRolling);
}))
.onFalse(new InstantCommand(() -> {
m_robotIntake.setMode(IntakeMode.ExtendingIdle);
})); }));
new JoystickButton(getDeadbandedOperatorController(), XboxController.Y_BUTTON) new JoystickButton(getDeadbandedOperatorController(), XboxController.Y_BUTTON)
.onTrue(new InstantCommand(() -> { .onTrue(new InstantCommand(() -> {
m_robotIntake.setMode(IntakeMode.RectractTorque); m_robotIntake.setMode(IntakeMode.Retracting);
})) }))
.onFalse(new InstantCommand(() -> { .onFalse(new InstantCommand(() -> {
m_robotIntake.setMode(IntakeMode.Idle); m_robotIntake.setMode(IntakeMode.Idle);
@@ -7,12 +7,12 @@ public final class BuildConstants {
public static final String MAVEN_GROUP = ""; public static final String MAVEN_GROUP = "";
public static final String MAVEN_NAME = "2026KPopRobotHunters"; public static final String MAVEN_NAME = "2026KPopRobotHunters";
public static final String VERSION = "unspecified"; public static final String VERSION = "unspecified";
public static final int GIT_REVISION = 200; public static final int GIT_REVISION = 210;
public static final String GIT_SHA = "3750a97424bfa4c90fc68b8db323029cdbb55452"; public static final String GIT_SHA = "6d55c96f6a6109aa09daad379d5483f9fa52ac7e";
public static final String GIT_DATE = "2026-04-02 18:27:51 MDT"; public static final String GIT_DATE = "2026-04-04 11:16:38 MDT";
public static final String GIT_BRANCH = "New-Intake"; public static final String GIT_BRANCH = "New-Intake";
public static final String BUILD_DATE = "2026-04-03 20:54:00 MDT"; public static final String BUILD_DATE = "2026-04-04 13:02:09 MDT";
public static final long BUILD_UNIX_TIME = 1775271240963L; public static final long BUILD_UNIX_TIME = 1775329329859L;
public static final int DIRTY = 1; public static final int DIRTY = 1;
private BuildConstants(){} private BuildConstants(){}
@@ -66,7 +66,8 @@ public class Intake extends SubsystemBase {
} }
public void rollerStop(){ public void rollerStop(){
io.setRollerOutput(state, 0); this.mode = IntakeMode.Idle;
// io.setRollerOutput(state, 0);
} }
public double getRollerTarget() { public double getRollerTarget() {
@@ -190,7 +191,7 @@ public class Intake extends SubsystemBase {
case ExpelBalls: case ExpelBalls:
io.armOutput(0); io.armOutput(0);
io.setRollerOutput(state, -0.2); io.setRollerOutput(state, IntakeConstants.ROLLER_EJECT_PERCENT_OUTPUT.get());
break; break;
} }
// if (state.retractedLimit){ // if (state.retractedLimit){
@@ -63,6 +63,8 @@ public class IntakeConstants {
public static final ConfigurableDouble ARM_REVERSE_ROLLER_RANGE = new ConfigurableDouble("Arm reverse roller range", 1.17); public static final ConfigurableDouble ARM_REVERSE_ROLLER_RANGE = new ConfigurableDouble("Arm reverse roller range", 1.17);
public static final ConfigurableDouble ROLLER_PERCENT_OUTPUT = new ConfigurableDouble("Roller Percent Output", .50); public static final ConfigurableDouble ROLLER_PERCENT_OUTPUT = new ConfigurableDouble("Roller Percent Output", .50);
public static final ConfigurableDouble ROLLER_EJECT_PERCENT_OUTPUT = new ConfigurableDouble("Roller eject Percent Output", -.20);
public static final ConfigurableDouble ROLLER_IDLE_PERCENT_OUTPUT = new ConfigurableDouble("Roller IDLE Percent Output", .20);
public static final ConfigurableDouble ROLLER_RETRACT_PERCENT_OUTPUT = new ConfigurableDouble("Roller Retract Output", .40); public static final ConfigurableDouble ROLLER_RETRACT_PERCENT_OUTPUT = new ConfigurableDouble("Roller Retract Output", .40);
public static final ConfigurableDouble ROLLER_MULTIPLIER_CONST = new ConfigurableDouble("Roller Multiplier Constant", 0.4); public static final ConfigurableDouble ROLLER_MULTIPLIER_CONST = new ConfigurableDouble("Roller Multiplier Constant", 0.4);