Interface JetsonIO

All Known Implementing Classes:
JetsonNTIO

public interface JetsonIO
Hardware layer for the Jetson Orin itself (not one camera): its health and Rewind topics in, and the robot's commands to it out. Everything that talks to NetworkTables for the Jetson is here, so replay swaps it for NONE and stays clean.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final JetsonIO
    Replay / detached: reports nothing and ignores commands.
  • Method Summary

    Modifier and Type
    Method
    Description
    default void
    publishFieldMap(String name, String hash, String json)
    Publishes the robot's AprilTag field map under /SpectrumVision/FieldMap/, for the Jetson to load and to report back the hash of what it loaded.
    default void
    Publishes the robot's wall clock (/photonvision/clock/unixMs) if it has been set, so the Jetson, which has no clock battery, gets the date (section 6).
    default void
    setExcludedTags(long[] tagIds)
    Publishes the tags every camera's multi-tag solve should ignore ( /photonvision/excludedTags, sections 11b and 12).
    default void
    setRewind(boolean record, String label)
    Sets Rewind's recording name and whether it records.
    void
    Fills inputs with the Jetson's latest values.
  • Field Details

    • NONE

      static final JetsonIO NONE
      Replay / detached: reports nothing and ignores commands.
  • Method Details

    • updateInputs

      void updateInputs(JetsonInputs inputs)
      Fills inputs with the Jetson's latest values.
      Parameters:
      inputs - the inputs to overwrite
    • setRewind

      default void setRewind(boolean record, String label)
      Sets Rewind's recording name and whether it records. The label is published first: the Jetson reads it when a recording starts (issue #10, section 4).
      Parameters:
      record - record while true
      label - recording name; empty lets the Jetson name it
    • publishRobotClock

      default void publishRobotClock()
      Publishes the robot's wall clock (/photonvision/clock/unixMs) if it has been set, so the Jetson, which has no clock battery, gets the date (section 6). Reads the clock itself so no wall-clock time reaches robot logic.
    • setExcludedTags

      default void setExcludedTags(long[] tagIds)
      Publishes the tags every camera's multi-tag solve should ignore ( /photonvision/excludedTags, sections 11b and 12).
      Parameters:
      tagIds - tag ids to exclude
    • publishFieldMap

      default void publishFieldMap(String name, String hash, String json)
      Publishes the robot's AprilTag field map under /SpectrumVision/FieldMap/, for the Jetson to load and to report back the hash of what it loaded.
      Parameters:
      name - the WPILib field's name, or "custom"
      hash - the canonical hash (FieldMapHash)
      json - the layout as WPILib AprilTagFieldLayout JSON