Class FovParamsConfigs

java.lang.Object
com.ctre.phoenix6.configs.FovParamsConfigs
All Implemented Interfaces:
ParentConfiguration, Cloneable

public class FovParamsConfigs extends Object implements ParentConfiguration, Cloneable
Configs that affect the ToF Field of View

Includes range and center configs

  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    double
    Specifies the target center of the Field of View in the X direction.
    double
    Specifies the target center of the Field of View in the Y direction.
    double
    Specifies the target range of the Field of View in the X direction.
    double
    Specifies the target range of the Field of View in the Y direction.
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
     
    deserialize(String to_deserialize)
    Take a string and deserialize it to this configuration group.
    final Angle
    Helper method to get this configuration's FOVCenterX parameter converted to a unit type.
    final Angle
    Helper method to get this configuration's FOVCenterY parameter converted to a unit type.
    final Angle
    Helper method to get this configuration's FOVRangeX parameter converted to a unit type.
    final Angle
    Helper method to get this configuration's FOVRangeY parameter converted to a unit type.
    final String
    Get the serialized form of this configuration group.
     
    withFOVCenterX(double newFOVCenterX)
    Modifies this configuration's FOVCenterX parameter and returns itself for method-chaining and easier to use config API.
    withFOVCenterX(Angle newFOVCenterX)
    Modifies this configuration's FOVCenterX parameter and returns itself for method-chaining and easier to use config API.
    withFOVCenterY(double newFOVCenterY)
    Modifies this configuration's FOVCenterY parameter and returns itself for method-chaining and easier to use config API.
    withFOVCenterY(Angle newFOVCenterY)
    Modifies this configuration's FOVCenterY parameter and returns itself for method-chaining and easier to use config API.
    withFOVRangeX(double newFOVRangeX)
    Modifies this configuration's FOVRangeX parameter and returns itself for method-chaining and easier to use config API.
    withFOVRangeX(Angle newFOVRangeX)
    Modifies this configuration's FOVRangeX parameter and returns itself for method-chaining and easier to use config API.
    withFOVRangeY(double newFOVRangeY)
    Modifies this configuration's FOVRangeY parameter and returns itself for method-chaining and easier to use config API.
    withFOVRangeY(Angle newFOVRangeY)
    Modifies this configuration's FOVRangeY parameter and returns itself for method-chaining and easier to use config API.

    Methods inherited from class Object

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

    • FOVCenterX

      public double FOVCenterX
      Specifies the target center of the Field of View in the X direction.

      The exact value may be different for different CANrange devices due to imperfections in the sensing silicon.

      • Minimum Value: -11.8
      • Maximum Value: 11.8
      • Default Value: 0
      • Units: deg
    • FOVCenterY

      public double FOVCenterY
      Specifies the target center of the Field of View in the Y direction.

      The exact value may be different for different CANrange devices due to imperfections in the sensing silicon.

      • Minimum Value: -11.8
      • Maximum Value: 11.8
      • Default Value: 0
      • Units: deg
    • FOVRangeX

      public double FOVRangeX
      Specifies the target range of the Field of View in the X direction. This is the full range of the FOV.

      The magnitude of this is capped to abs(27 - 2*FOVCenterX).

      The exact value may be different for different CANrange devices due to imperfections in the sensing silicon.

      • Minimum Value: 6.75
      • Maximum Value: 27
      • Default Value: 27
      • Units: deg
    • FOVRangeY

      public double FOVRangeY
      Specifies the target range of the Field of View in the Y direction. This is the full range of the FOV.

      The magnitude of this is capped to abs(27 - 2*FOVCenterY).

      The exact value may be different for different CANrange devices due to imperfections in the sensing silicon.

      • Minimum Value: 6.75
      • Maximum Value: 27
      • Default Value: 27
      • Units: deg
  • Constructor Details

    • FovParamsConfigs

      public FovParamsConfigs()
  • Method Details

    • withFOVCenterX

      public final FovParamsConfigs withFOVCenterX(double newFOVCenterX)
      Modifies this configuration's FOVCenterX parameter and returns itself for method-chaining and easier to use config API.

      Specifies the target center of the Field of View in the X direction.

      The exact value may be different for different CANrange devices due to imperfections in the sensing silicon.

      • Minimum Value: -11.8
      • Maximum Value: 11.8
      • Default Value: 0
      • Units: deg
      Parameters:
      newFOVCenterX - Parameter to modify
      Returns:
      Itself
    • withFOVCenterX

      public final FovParamsConfigs withFOVCenterX(Angle newFOVCenterX)
      Modifies this configuration's FOVCenterX parameter and returns itself for method-chaining and easier to use config API.

      Specifies the target center of the Field of View in the X direction.

      The exact value may be different for different CANrange devices due to imperfections in the sensing silicon.

      • Minimum Value: -11.8
      • Maximum Value: 11.8
      • Default Value: 0
      • Units: deg
      Parameters:
      newFOVCenterX - Parameter to modify
      Returns:
      Itself
    • getFOVCenterXMeasure

      public final Angle getFOVCenterXMeasure()
      Helper method to get this configuration's FOVCenterX parameter converted to a unit type. If not using the Java units library, FOVCenterX can be accessed directly instead.

      Specifies the target center of the Field of View in the X direction.

      The exact value may be different for different CANrange devices due to imperfections in the sensing silicon.

      • Minimum Value: -11.8
      • Maximum Value: 11.8
      • Default Value: 0
      • Units: deg
      Returns:
      FOVCenterX
    • withFOVCenterY

      public final FovParamsConfigs withFOVCenterY(double newFOVCenterY)
      Modifies this configuration's FOVCenterY parameter and returns itself for method-chaining and easier to use config API.

      Specifies the target center of the Field of View in the Y direction.

      The exact value may be different for different CANrange devices due to imperfections in the sensing silicon.

      • Minimum Value: -11.8
      • Maximum Value: 11.8
      • Default Value: 0
      • Units: deg
      Parameters:
      newFOVCenterY - Parameter to modify
      Returns:
      Itself
    • withFOVCenterY

      public final FovParamsConfigs withFOVCenterY(Angle newFOVCenterY)
      Modifies this configuration's FOVCenterY parameter and returns itself for method-chaining and easier to use config API.

      Specifies the target center of the Field of View in the Y direction.

      The exact value may be different for different CANrange devices due to imperfections in the sensing silicon.

      • Minimum Value: -11.8
      • Maximum Value: 11.8
      • Default Value: 0
      • Units: deg
      Parameters:
      newFOVCenterY - Parameter to modify
      Returns:
      Itself
    • getFOVCenterYMeasure

      public final Angle getFOVCenterYMeasure()
      Helper method to get this configuration's FOVCenterY parameter converted to a unit type. If not using the Java units library, FOVCenterY can be accessed directly instead.

      Specifies the target center of the Field of View in the Y direction.

      The exact value may be different for different CANrange devices due to imperfections in the sensing silicon.

      • Minimum Value: -11.8
      • Maximum Value: 11.8
      • Default Value: 0
      • Units: deg
      Returns:
      FOVCenterY
    • withFOVRangeX

      public final FovParamsConfigs withFOVRangeX(double newFOVRangeX)
      Modifies this configuration's FOVRangeX parameter and returns itself for method-chaining and easier to use config API.

      Specifies the target range of the Field of View in the X direction. This is the full range of the FOV.

      The magnitude of this is capped to abs(27 - 2*FOVCenterX).

      The exact value may be different for different CANrange devices due to imperfections in the sensing silicon.

      • Minimum Value: 6.75
      • Maximum Value: 27
      • Default Value: 27
      • Units: deg
      Parameters:
      newFOVRangeX - Parameter to modify
      Returns:
      Itself
    • withFOVRangeX

      public final FovParamsConfigs withFOVRangeX(Angle newFOVRangeX)
      Modifies this configuration's FOVRangeX parameter and returns itself for method-chaining and easier to use config API.

      Specifies the target range of the Field of View in the X direction. This is the full range of the FOV.

      The magnitude of this is capped to abs(27 - 2*FOVCenterX).

      The exact value may be different for different CANrange devices due to imperfections in the sensing silicon.

      • Minimum Value: 6.75
      • Maximum Value: 27
      • Default Value: 27
      • Units: deg
      Parameters:
      newFOVRangeX - Parameter to modify
      Returns:
      Itself
    • getFOVRangeXMeasure

      public final Angle getFOVRangeXMeasure()
      Helper method to get this configuration's FOVRangeX parameter converted to a unit type. If not using the Java units library, FOVRangeX can be accessed directly instead.

      Specifies the target range of the Field of View in the X direction. This is the full range of the FOV.

      The magnitude of this is capped to abs(27 - 2*FOVCenterX).

      The exact value may be different for different CANrange devices due to imperfections in the sensing silicon.

      • Minimum Value: 6.75
      • Maximum Value: 27
      • Default Value: 27
      • Units: deg
      Returns:
      FOVRangeX
    • withFOVRangeY

      public final FovParamsConfigs withFOVRangeY(double newFOVRangeY)
      Modifies this configuration's FOVRangeY parameter and returns itself for method-chaining and easier to use config API.

      Specifies the target range of the Field of View in the Y direction. This is the full range of the FOV.

      The magnitude of this is capped to abs(27 - 2*FOVCenterY).

      The exact value may be different for different CANrange devices due to imperfections in the sensing silicon.

      • Minimum Value: 6.75
      • Maximum Value: 27
      • Default Value: 27
      • Units: deg
      Parameters:
      newFOVRangeY - Parameter to modify
      Returns:
      Itself
    • withFOVRangeY

      public final FovParamsConfigs withFOVRangeY(Angle newFOVRangeY)
      Modifies this configuration's FOVRangeY parameter and returns itself for method-chaining and easier to use config API.

      Specifies the target range of the Field of View in the Y direction. This is the full range of the FOV.

      The magnitude of this is capped to abs(27 - 2*FOVCenterY).

      The exact value may be different for different CANrange devices due to imperfections in the sensing silicon.

      • Minimum Value: 6.75
      • Maximum Value: 27
      • Default Value: 27
      • Units: deg
      Parameters:
      newFOVRangeY - Parameter to modify
      Returns:
      Itself
    • getFOVRangeYMeasure

      public final Angle getFOVRangeYMeasure()
      Helper method to get this configuration's FOVRangeY parameter converted to a unit type. If not using the Java units library, FOVRangeY can be accessed directly instead.

      Specifies the target range of the Field of View in the Y direction. This is the full range of the FOV.

      The magnitude of this is capped to abs(27 - 2*FOVCenterY).

      The exact value may be different for different CANrange devices due to imperfections in the sensing silicon.

      • Minimum Value: 6.75
      • Maximum Value: 27
      • Default Value: 27
      • Units: deg
      Returns:
      FOVRangeY
    • toString

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

      public final String serialize()
      Get the serialized form of this configuration group.
      Specified by:
      serialize in interface ParentConfiguration
      Returns:
      Serialized form of this config group
    • deserialize

      public final StatusCode deserialize(String to_deserialize)
      Take a string and deserialize it to this configuration group.
      Specified by:
      deserialize in interface ParentConfiguration
      Parameters:
      to_deserialize - The serialized configuration
      Returns:
      Return code of the deserialize method
    • clone

      public FovParamsConfigs clone()
      Overrides:
      clone in class Object