This commit is contained in:
66945
2023-02-25 14:16:32 -07:00
parent 2031ace204
commit e3c8011e5e
2 changed files with 87 additions and 0 deletions
@@ -104,6 +104,15 @@ public class RobotContainer {
chooser.addOption("Taxi", taxi);
SmartDashboard.putData(chooser);
PlaybackChooser playbackChooser = new PlaybackChooser(m_robotSwerveDrive,
"Balance", new AutoBalance(m_robotMap.gyro, m_robotSwerveDrive));
new JoystickButton(getDeadbandedDriverController(), XboxController.X_BUTTON)
.onTrue(new InstantCommand(() -> playbackChooser.appendCommand()));
new JoystickButton(getDeadbandedDriverController(), XboxController.B_BUTTON)
.onTrue(new InstantCommand(() -> playbackChooser.appendPlayback()));
}