Class QuestNavIO

java.lang.Object
frc.robot.subsystems.vision.QuestNavIO
All Implemented Interfaces:
QuestNavControl, PoseSourceIO

public class QuestNavIO extends Object implements PoseSourceIO, QuestNavControl
Meta Quest running QuestNav, over NetworkTables table QuestNav.

QuestNav reports the headset's pose in a field frame that the robot sets by sending a pose-reset command (resetPose(Pose2d)). This IO converts it to a robot pose with the inverse of robotToQuest, and records the time and count of resets so the QuestNav gates (see Vision) can reject frames from before the first reset or just after one.

Frame timestamps are the NetworkTables server time at which the frame arrived, as QuestNavLib uses; the Quest app's own clock is kept in PoseSourceInputs.health for latency analysis.

Health values: [appTimestamp, frameCount, batteryPercent, trackingLostCounter, resetCount, lastResetTime].