Class MountPoseConfigs

java.lang.Object
com.ctre.phoenix6.configs.MountPoseConfigs
All Implemented Interfaces:
ParentConfiguration, ISerializable

public class MountPoseConfigs extends Object implements ParentConfiguration
Configs for Pigeon 2's Mount Pose configuration.

These configs allow the Pigeon2 to be mounted in whatever orientation that's desired and ensure the reported Yaw/Pitch/Roll is from the robot's reference.

  • Field Details

    • MountPoseYaw

      public double MountPoseYaw
      The mounting calibration yaw-component.
      • Minimum Value: -360
      • Maximum Value: 360
      • Default Value: 0
      • Units: deg
    • MountPosePitch

      public double MountPosePitch
      The mounting calibration pitch-component.
      • Minimum Value: -360
      • Maximum Value: 360
      • Default Value: 0
      • Units: deg
    • MountPoseRoll

      public double MountPoseRoll
      The mounting calibration roll-component.
      • Minimum Value: -360
      • Maximum Value: 360
      • Default Value: 0
      • Units: deg
  • Constructor Details

  • Method Details

    • withMountPoseYaw

      public MountPoseConfigs withMountPoseYaw(double newMountPoseYaw)
      Modifies this configuration's MountPoseYaw parameter and returns itself for method-chaining and easier to use config API.

      The mounting calibration yaw-component.

      • Minimum Value: -360
      • Maximum Value: 360
      • Default Value: 0
      • Units: deg
      Parameters:
      newMountPoseYaw - Parameter to modify
      Returns:
      Itself
    • withMountPoseYaw

      public MountPoseConfigs withMountPoseYaw(Angle newMountPoseYaw)
      Modifies this configuration's MountPoseYaw parameter and returns itself for method-chaining and easier to use config API.

      The mounting calibration yaw-component.

      • Minimum Value: -360
      • Maximum Value: 360
      • Default Value: 0
      • Units: deg
      Parameters:
      newMountPoseYaw - Parameter to modify
      Returns:
      Itself
    • getMountPoseYawMeasure

      Helper method to get this configuration's MountPoseYaw parameter converted to a unit type. If not using the Java units library, MountPoseYaw can be accessed directly instead.

      The mounting calibration yaw-component.

      • Minimum Value: -360
      • Maximum Value: 360
      • Default Value: 0
      • Units: deg
      Returns:
      MountPoseYaw
    • withMountPosePitch

      public MountPoseConfigs withMountPosePitch(double newMountPosePitch)
      Modifies this configuration's MountPosePitch parameter and returns itself for method-chaining and easier to use config API.

      The mounting calibration pitch-component.

      • Minimum Value: -360
      • Maximum Value: 360
      • Default Value: 0
      • Units: deg
      Parameters:
      newMountPosePitch - Parameter to modify
      Returns:
      Itself
    • withMountPosePitch

      public MountPoseConfigs withMountPosePitch(Angle newMountPosePitch)
      Modifies this configuration's MountPosePitch parameter and returns itself for method-chaining and easier to use config API.

      The mounting calibration pitch-component.

      • Minimum Value: -360
      • Maximum Value: 360
      • Default Value: 0
      • Units: deg
      Parameters:
      newMountPosePitch - Parameter to modify
      Returns:
      Itself
    • getMountPosePitchMeasure

      Helper method to get this configuration's MountPosePitch parameter converted to a unit type. If not using the Java units library, MountPosePitch can be accessed directly instead.

      The mounting calibration pitch-component.

      • Minimum Value: -360
      • Maximum Value: 360
      • Default Value: 0
      • Units: deg
      Returns:
      MountPosePitch
    • withMountPoseRoll

      public MountPoseConfigs withMountPoseRoll(double newMountPoseRoll)
      Modifies this configuration's MountPoseRoll parameter and returns itself for method-chaining and easier to use config API.

      The mounting calibration roll-component.

      • Minimum Value: -360
      • Maximum Value: 360
      • Default Value: 0
      • Units: deg
      Parameters:
      newMountPoseRoll - Parameter to modify
      Returns:
      Itself
    • withMountPoseRoll

      public MountPoseConfigs withMountPoseRoll(Angle newMountPoseRoll)
      Modifies this configuration's MountPoseRoll parameter and returns itself for method-chaining and easier to use config API.

      The mounting calibration roll-component.

      • Minimum Value: -360
      • Maximum Value: 360
      • Default Value: 0
      • Units: deg
      Parameters:
      newMountPoseRoll - Parameter to modify
      Returns:
      Itself
    • getMountPoseRollMeasure

      Helper method to get this configuration's MountPoseRoll parameter converted to a unit type. If not using the Java units library, MountPoseRoll can be accessed directly instead.

      The mounting calibration roll-component.

      • Minimum Value: -360
      • Maximum Value: 360
      • Default Value: 0
      • Units: deg
      Returns:
      MountPoseRoll
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • deserialize

      public StatusCode deserialize(String to_deserialize)
      Specified by:
      deserialize in interface ParentConfiguration
    • serialize

      public String serialize()
      Specified by:
      serialize in interface ISerializable