Class PID.PIDConstants

java.lang.Object
org.chsrobotics.lib.controllers.feedback.PID.PIDConstants
Enclosing class:
PID

public static class PID.PIDConstants extends Object
Data class for holding the gains to a PID controller.
  • Constructor Summary

    Constructors
    Constructor
    Description
    PIDConstants(double kP, double kI, double kD)
    Constructs a PIDConstants out of provided gains.
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    equals(Object other)
     
    double
    Returns the derivative gain.
    double
    Returns the integral gain.
    double
    Returns the proportional gain.
    int
     
     

    Methods inherited from class java.lang.Object

    getClass, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • PIDConstants

      public PIDConstants(double kP, double kI, double kD)
      Constructs a PIDConstants out of provided gains.
      Parameters:
      kP - The proportional gain.
      kI - The integral gain.
      kD - The derivative gain.
  • Method Details

    • getkP

      public double getkP()
      Returns the proportional gain.
      Returns:
      The kP of the constants.
    • getkI

      public double getkI()
      Returns the integral gain.
      Returns:
      The kI of the constants.
    • getkD

      public double getkD()
      Returns the derivative gain.
      Returns:
      The kD of the constants.
    • equals

      public boolean equals(Object other)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object