Class TurnToAngle

All Implemented Interfaces:
Sendable

public class TurnToAngle extends Command
This command will turn the robot to a specified angle.
  • Constructor Details

    • TurnToAngle

      public TurnToAngle(Swerve swerve, Rotation2d angle)
      Turns robot to specified angle. Uses absolute rotation on field.
      Parameters:
      swerve - Swerve subsystem
      angle - Requested angle to turn to
  • Method Details

    • initialize

      public void initialize()
      Overrides:
      initialize in class Command
    • execute

      public void execute()
      Overrides:
      execute in class Command
    • end

      public void end(boolean interrupt)
      Overrides:
      end in class Command
    • isFinished

      public boolean isFinished()
      Overrides:
      isFinished in class Command