Class FieldConstants

java.lang.Object
frc.robot.constants.FieldConstants

public final class FieldConstants extends Object
Field-level constants for the 2026 REBUILT game.

All dimensions are sourced from the maple-sim Arena2026Rebuilt field geometry and the official FRC Game Manual to ensure simulation-to-reality parity.

  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final edu.wpi.first.math.geometry.Translation3d
    Blue hub 3D target for shooter math (top opening, meters).
    static final edu.wpi.first.math.geometry.Translation2d
    Blue alliance hub center position (meters).
    static final edu.wpi.first.math.geometry.Pose2d
     
    static final edu.wpi.first.math.geometry.Pose2d
     
    static final double
    Standard FRC field length (meters).
    static final double
    Standard FRC field width (meters).
    static final double
    Mass of a single Rebuilt Fuel ball (kg).
    static final double
    Radius of a single Rebuilt Fuel ball (meters).
    static final double
    Height above the field surface at which game pieces rest in 3D visualization (meters).
    static final double
    Approximate side length of the hub structures (meters).
    static final double
    Intake collection radius (meters) for swallowing pieces in simulation.
    static final boolean
    Controls whether the maple-sim arena runs in efficiency mode.
    static final edu.wpi.first.math.geometry.Translation3d
    Red hub 3D target for shooter math (top opening, meters).
    static final edu.wpi.first.math.geometry.Translation2d
    Red alliance hub center position (meters).
    static final edu.wpi.first.math.geometry.Pose2d
     
    static final edu.wpi.first.math.geometry.Pose2d
     
    static final double
    Coulomb friction coefficient for field boundary walls and obstacles.
    static final double
    Coefficient of restitution (bounciness) for field boundary walls and obstacles.
    static final double
    Thickness of simulated field boundary walls (meters).
  • Method Summary

    Modifier and Type
    Method
    Description
    static edu.wpi.first.math.geometry.Pose2d
    getClosestClimbingPosition(edu.wpi.first.math.geometry.Pose2d currentRobotPose)
    Returns the closest climbing position to the robot based on current alliance.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • FIELD_LENGTH_METERS

      public static final double FIELD_LENGTH_METERS
      Standard FRC field length (meters). Matches maple-sim Arena2026Rebuilt.
      See Also:
    • FIELD_WIDTH_METERS

      public static final double FIELD_WIDTH_METERS
      Standard FRC field width (meters). Matches maple-sim Arena2026Rebuilt.
      See Also:
    • WALL_THICKNESS_METERS

      public static final double WALL_THICKNESS_METERS
      Thickness of simulated field boundary walls (meters).
      See Also:
    • GAME_PIECE_RADIUS_METERS

      public static final double GAME_PIECE_RADIUS_METERS
      Radius of a single Rebuilt Fuel ball (meters). 15 cm diameter = 7.5 cm radius. Source: RebuiltFuelOnField.REBUILT_FUEL_INFO
      See Also:
    • GAME_PIECE_REST_HEIGHT_METERS

      public static final double GAME_PIECE_REST_HEIGHT_METERS
      Height above the field surface at which game pieces rest in 3D visualization (meters).
      See Also:
    • GAME_PIECE_MASS_KG

      public static final double GAME_PIECE_MASS_KG
      Mass of a single Rebuilt Fuel ball (kg). 0.5 lbs = 0.2268 kg. Source: RebuiltFuelOnField.REBUILT_FUEL_INFO
      See Also:
    • WALL_FRICTION

      public static final double WALL_FRICTION
      Coulomb friction coefficient for field boundary walls and obstacles.
      See Also:
    • WALL_RESTITUTION

      public static final double WALL_RESTITUTION
      Coefficient of restitution (bounciness) for field boundary walls and obstacles.
      See Also:
    • HUB_SIZE_METERS

      public static final double HUB_SIZE_METERS
      Approximate side length of the hub structures (meters).
      See Also:
    • BLUE_HUB_POS

      public static final edu.wpi.first.math.geometry.Translation2d BLUE_HUB_POS
      Blue alliance hub center position (meters).
    • RED_HUB_POS

      public static final edu.wpi.first.math.geometry.Translation2d RED_HUB_POS
      Red alliance hub center position (meters).
    • BLUE_HUB_3D

      public static final edu.wpi.first.math.geometry.Translation3d BLUE_HUB_3D
      Blue hub 3D target for shooter math (top opening, meters).
    • RED_HUB_3D

      public static final edu.wpi.first.math.geometry.Translation3d RED_HUB_3D
      Red hub 3D target for shooter math (top opening, meters).
    • INTAKE_COLLECTION_RADIUS_METERS

      public static final double INTAKE_COLLECTION_RADIUS_METERS
      Intake collection radius (meters) for swallowing pieces in simulation.
      See Also:
    • BLUE_NEARDEPOT_CLIMB_POSE

      public static final edu.wpi.first.math.geometry.Pose2d BLUE_NEARDEPOT_CLIMB_POSE
    • BLUE_OUTPOST_CLIMB_POSE

      public static final edu.wpi.first.math.geometry.Pose2d BLUE_OUTPOST_CLIMB_POSE
    • RED_NEARDEPOT_CLIMB_POSE

      public static final edu.wpi.first.math.geometry.Pose2d RED_NEARDEPOT_CLIMB_POSE
    • RED_NEAROUTPOST_CLIMB_POSE

      public static final edu.wpi.first.math.geometry.Pose2d RED_NEAROUTPOST_CLIMB_POSE
    • MAPLE_SIM_EFFICIENCY_MODE

      public static final boolean MAPLE_SIM_EFFICIENCY_MODE
      Controls whether the maple-sim arena runs in efficiency mode.

      OFF (false): Full realism — all game pieces spawned, both depots, all center field pieces. Recommended for match-accurate simulation and autonomous testing.

      ON (true): Reduced piece count — only 1/3 of center pieces and only your alliance's depot. Useful for faster iteration during mechanism development when full field population is unnecessary.

      See Also:
  • Method Details

    • getClosestClimbingPosition

      public static edu.wpi.first.math.geometry.Pose2d getClosestClimbingPosition(edu.wpi.first.math.geometry.Pose2d currentRobotPose)
      Returns the closest climbing position to the robot based on current alliance.
      Parameters:
      currentRobotPose - The robot's current field-relative pose.
      Returns:
      The nearest climb approach pose.