extender fix

This commit is contained in:
aarav18
2022-03-18 11:31:28 -06:00
parent 18e7c336ec
commit fbd74f72ce
3 changed files with 7 additions and 2 deletions
+1 -1
View File
@@ -151,7 +151,7 @@ public final class Constants {
}
public static final class ExtenderConstants {
public static final double EXTENDER_FORWARD_LIMIT = 250.0;
public static final double EXTENDER_FORWARD_LIMIT = 235.0;//250.0;
public static final double EXTENDER_REVERSE_LIMIT = 0.0;
}
@@ -357,7 +357,8 @@ public class RobotContainer {
.whenReleased(new InstantCommand(() -> m_robotTurret.m_boomBoomRotateEncoder.setPosition(0), m_robotTurret))
.whenReleased(new InstantCommand(() -> m_robotHood.m_angleEncoder.setPosition(0), m_robotHood))
.whenReleased(new InstantCommand(() -> m_robotExtender.setEncoder(0), m_robotExtender));
.whenReleased(new InstantCommand(() -> m_robotExtender.setEncoder(0), m_robotExtender))
.whenReleased(new InstantCommand(() -> ExtenderIntakeGroup.setDirectionToOut(), m_robotIntake, m_robotExtender));
// new JoystickButton(getButtonBox(), ButtonBox.Button.kLeftSwitch.value)
// .whileHeld(new RunCommand(() -> RunMiddleSwitch.setManual(true)))
@@ -24,6 +24,10 @@ public class ExtenderIntakeGroup extends ParallelRaceGroup {
addCommands(new RunIntakeConditionally(intake), new RunExtender(extender));
}
public static void setDirectionToOut() {
ExtenderIntakeGroup.direction = 1;
}
public static void changeDirection() { // Never implemented?
ExtenderIntakeGroup.direction *= -1;
}