Skip to content

Commit 5783633

Browse files
committed
Make ResetHeading() a two button action.
Rename NewAuto to NewFiveBallAuto().
1 parent 7091049 commit 5783633

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

src/main/java/frc/robot/RobotContainer.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@
4343
import frc.robot.Constants.OIConstants;
4444
import frc.robot.auto.groups.FiveBallAuto;
4545
import frc.robot.auto.groups.FourBallAuto;
46-
import frc.robot.auto.groups.NewAuto;
46+
import frc.robot.auto.groups.NewFiveBallAuto;
4747
import frc.robot.auto.groups.TwoBallEastAuto;
4848
import frc.robot.auto.groups.TwoBallSouthAuto;
4949
import frc.robot.climber.Climber;
@@ -163,7 +163,7 @@ public Command getAutonomousCommand() {
163163
*/
164164
}
165165
// return autoCommand;
166-
return new NewAuto(mDrive, mShooter, mIntake);
166+
return new NewFiveBallAuto(mDrive, mShooter, mIntake);
167167
}
168168

169169
public void displaySwitch() {
@@ -238,8 +238,8 @@ public void configureButtonBindings() {
238238
new JoystickButton(driver, RMZ_D_IN).whenPressed(new PullTrigger(mShooter));
239239
new JoystickButton(driver, RMZ_D_IN).whenReleased(new StopTrigger(mShooter));
240240

241-
new JoystickButton(driver, RMZ_H_IN).whenPressed(new ResetHood(mShooter));
242-
new JoystickButton(driver, RMZ_G_IN).whenReleased(new ZeroHeading(mDrive));
241+
// new JoystickButton(driver, RMZ_H_IN).whenPressed(new ResetHood(mShooter));
242+
new JoystickButton(driver, RMZ_G_IN).and(new JoystickButton(driver, RMZ_H_IN).whenPressed(new ZeroHeading(mDrive)));
243243

244244

245245
new JoystickButton(driver, RMZ_F_UP).whenHeld(new AbsoluteOrientation(mDrive, joysticks));

src/main/java/frc/robot/auto/groups/NewAuto.java renamed to src/main/java/frc/robot/auto/groups/NewFiveBallAuto.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,9 @@
3333
// NOTE: Consider using this command inline, rather than writing a subclass. For more
3434
// information, see:
3535
// https://docs.wpilib.org/en/stable/docs/software/commandbased/convenience-features.html
36-
public class NewAuto extends SequentialCommandGroup {
36+
public class NewFiveBallAuto extends SequentialCommandGroup {
3737
/** Creates a new NewAuto. */
38-
public NewAuto(Drivetrain drive, Shooter shooter, Intake intake) {
38+
public NewFiveBallAuto(Drivetrain drive, Shooter shooter, Intake intake) {
3939
addCommands(
4040
new ResetOdometry(drive, new Pose2d(new Translation2d(0,0), new Rotation2d(-2.35))),
4141
new ResetEncoder(shooter),

0 commit comments

Comments
 (0)