Package frc.robot.subsystems.swervedrive2.swervelib.imu

## Class SwerveIMU

- java.lang.Object
- - frc.robot.subsystems.swervedrive2.swervelib.imu.SwerveIMU

- Direct Known Subclasses:
    `NavXSwerve`, `Pigeon2Swerve`, `PigeonSwerve`

      public abstract class SwerveIMU
      extends Object

  Swerve IMU abstraction to define a standard interface with a swerve drive.

- - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `SwerveIMU()` |

  - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `abstract void` | `clearStickyFaults()` | Clear sticky faults on IMU.
    `abstract void` | `factoryDefault()` | Reset IMU to factory default.
    `abstract Object` | `getIMU()` | Get the instantiated IMU object.
    `abstract void` | `getYawPitchRoll​(double[] yprArray)` | Fetch the yaw/pitch/roll from the IMU.
    `abstract void` | `setYaw​(double yaw)` | Set the yaw in degrees.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### SwerveIMU

          public SwerveIMU()

  - ### Method Detail

    - #### factoryDefault

          public abstract void factoryDefault()

      Reset IMU to factory default.

    - #### clearStickyFaults

          public abstract void clearStickyFaults()

      Clear sticky faults on IMU.

    - #### setYaw

          public abstract void setYaw​(double yaw)

      Set the yaw in degrees.
      Parameters:
        `yaw` - Yaw angle in degrees.

    - #### getYawPitchRoll

          public abstract void getYawPitchRoll​(double[] yprArray)

      Fetch the yaw/pitch/roll from the IMU.
      Parameters:
        `yprArray` - Array which will be filled with {yaw, pitch, roll} in degrees.

    - #### getIMU

          public abstract Object getIMU()

      Get the instantiated IMU object.
      Returns:
        IMU object.