Class AprilTagVisionSubsystemConfig

java.lang.Object
frc.robot.shared.config.AbstractConfig
frc.robot.shared.config.AbstractSubsystemConfig
frc.robot.subsystems.apriltagvision.config.AprilTagVisionSubsystemConfig

public class AprilTagVisionSubsystemConfig extends AbstractSubsystemConfig
Configuration bundle for the AprilTag vision subsystem. Values are mirrored to SmartDashboard so they can be tuned live without redeploying firmware.

Includes the field layout type selector so each robot variant (competition, test, sim) can specify its own AprilTag field layout in the subsystems JSON file.

  • Field Details

  • Constructor Details

    • AprilTagVisionSubsystemConfig

      public AprilTagVisionSubsystemConfig()
  • Method Details

    • getCameras

      Returns the configured camera map.
      Returns:
      map of camera names to robot-to-camera transforms
    • getPoseFilter

      public PoseFilterConfig getPoseFilter()
      Returns the pose filter configuration.
      Returns:
      pose filter sub-config with all filtering thresholds
    • getFieldType

      Returns the configured field type selector.

      Use this to determine which AprilTag field layout is loaded for pose estimation.

      Returns:
      selected field layout type
    • loadLayout

      public edu.wpi.first.apriltag.AprilTagFieldLayout loadLayout()
      Builds an AprilTag field layout using the configured field type and origin.

      Call this once during subsystem construction so tags can be accessed with getTagPose(int) for navigation targets.

      Returns:
      loaded AprilTag field layout with the configured origin applied
      Throws:
      IllegalArgumentException - when the configured enum names are invalid