Interface Motor

All Known Subinterfaces:
PIDMotor
All Known Implementing Classes:
MotorSubsystem.ControlledMotor

public interface Motor
  • Method Summary

    Modifier and Type
    Method
    Description
    Gets the current that is being applied onto the motor
    void
    set(ControlMode mode, double demand)
    Sets the motor to run with a specified mode of control.
    void
    set(ControlMode mode, double demand, double feedForward)
    Sets the motor to run with a specified mode of control, and feedForward.
    default void
    Stops the motor.
  • Method Details

    • set

      void set(ControlMode mode, double demand)
      Sets the motor to run with a specified mode of control.
      Parameters:
      mode - The mode to control the motor with
      demand - The demand of the motor. differentiating meaning with each control mode
    • set

      void set(ControlMode mode, double demand, double feedForward)
      Sets the motor to run with a specified mode of control, and feedForward.
      Parameters:
      mode - The mode to control the motor with
      demand - The demand of the motor. differentiating meaning with each control mode
      feedForward - The feedForward to apply to the motor
    • getAppliedCurrent

      Current getAppliedCurrent()
      Gets the current that is being applied onto the motor
      Returns:
      The current applied current
      Since:
      2.0.0
    • stopMotor

      default void stopMotor()
      Stops the motor.
      Since:
      2.0.0