Class NathanGain

java.lang.Object
lib.humaninput.HumanInput
lib.humaninput.Driver
robot.humaninterface.drivers.NathanGain
All Implemented Interfaces:
Nameable

public class NathanGain extends Driver
  • Field Details

    • isFlippy

      public static boolean isFlippy
    • SPEED_EXP

      public static final double SPEED_EXP
      See Also:
    • Y_SPEED_SCALE

      public static final double Y_SPEED_SCALE
      See Also:
    • TURN_EXP

      public static final double TURN_EXP
      See Also:
    • TURN_SPEED_SCALE

      public static final double TURN_SPEED_SCALE
      See Also:
    • NORMAL_SPEED_GAIN

      public static final double NORMAL_SPEED_GAIN
      See Also:
    • NORMAL_TURN_GAIN

      public static final double NORMAL_TURN_GAIN
      See Also:
    • PRECISE_SPEED_SCALE

      public static final double PRECISE_SPEED_SCALE
      See Also:
    • PRECISE_TURN_SCALE

      public static final double PRECISE_TURN_SCALE
      See Also:
    • precisionScaleY

      public static double precisionScaleY
    • precisionScaleTurn

      public static double precisionScaleTurn
  • Constructor Details

    • NathanGain

      public NathanGain()
  • Method Details

    • scaleGain

      protected double scaleGain(double input, double gain, double exp)
    • bindCommands

      public void bindCommands()
      Description copied from class: HumanInput
      A function where the driver's and operator's controls are bound to commands

      Can't be done in the constructor because constructors are called too early

      Specified by:
      bindCommands in class HumanInput
    • getTranslation

      public edu.wpi.first.math.geometry.Translation2d getTranslation()
      Specified by:
      getTranslation in class Driver
      Returns:
      Speed that the driver wants, in wpilib field-relative coordinates (forward, left). Length of translation vector should not exceed 1
    • getTurnSpeed

      public double getTurnSpeed()
      Specified by:
      getTurnSpeed in class Driver
      Returns:
      Turn speed that the driver wants in the range [-1, 1], positive = counterclockwise