+
+ runIntake = new JoystickButton(leftJoystick,
+ Constants.OI.TOGGLE_INTAKE_PORT);
+ runIntake.whileHeld(new RunIntakeContinuous());
+
+ reverseIntake = new JoystickButton(leftJoystick,
+ Constants.OI.REVERSE_INTAKE_PORT);
+ reverseIntake.whileHeld(new ReverseIntakeContinuous());
+
+ toggleWinch = new JoystickButton(leftJoystick,
+ Constants.OI.TOGGLE_WINCH_PORT);
+ if (!isClimbing) {
+ toggleWinch.whenPressed(new RunWinchContinuous());
+ isClimbing = true;
+ } else {
+ toggleWinch.whenPressed(new MaintainClimbedPosition());
+ isClimbing = false;
+ }