Package frc.reefscape

Class Zones

java.lang.Object
frc.reefscape.Zones

public class Zones extends Object
  • Field Details

    • blueFieldSide

      public static final Trigger blueFieldSide
    • opponentFieldSide

      public static final Trigger opponentFieldSide
    • topLeftZone

      public static final Trigger topLeftZone
    • topRightZone

      public static final Trigger topRightZone
    • bottomLeftZone

      public static final Trigger bottomLeftZone
    • bottomRightZone

      public static final Trigger bottomRightZone
    • netAlgaeZone

      public static final Trigger netAlgaeZone
    • isCloseToReef

      public static final Trigger isCloseToReef
  • Constructor Details

    • Zones

      public Zones()
  • Method Details

    • getTagOffset

      public double getTagOffset(int tag)
      Depending on the offsets file used, change the tag offsets here.

      getTagOffset automatically checks if the offset taken is < 0 or greater than the given tag limit. If the tag is blue (> 16), it subtracts 17 from the given tag

      Parameters:
      tag -
      Returns:
    • getTagAngleOffset

      public double getTagAngleOffset(int tag)
    • getScoreReefPoseX

      public double getScoreReefPoseX()
      Calls ScoreReefPose to get Pose of Target Reef
      Returns:
      X of Target Reef
    • getScoreReefPoseY

      public double getScoreReefPoseY()
      Calls ScoreReefPose to get Pose of Target Reef
      Returns:
      Y of Target Reef
    • getScoreReefPoseAngle

      public double getScoreReefPoseAngle()
      Calls ScoreReefPose to get Pose of Target Reef
      Returns:
      Returns Target Reef Pose Angle value based on robot heading hence adding PI is needed since the target reef face is pi radians from robot heading
    • atReef

      public static boolean atReef()
    • withinReefRange

      public static boolean withinReefRange(double range)
    • getAtReefXYTolerance

      public static double getAtReefXYTolerance()
    • getAtReefRotationTolerance

      public static double getAtReefRotationTolerance()
    • getNetAlgaeX

      public static double getNetAlgaeX()
    • getNetAlgaeZoneTolerance

      public static double getNetAlgaeZoneTolerance()