Enum ControlMode

java.lang.Object
java.lang.Enum<ControlMode>
frc.team670.pi.ControlMode
All Implemented Interfaces:
java.io.Serializable, java.lang.Comparable<ControlMode>, java.lang.constant.Constable

public enum ControlMode
extends java.lang.Enum<ControlMode>
Possible control modes for a motor.
Author:
ctychen
  • Nested Class Summary

    Nested classes/interfaces inherited from class java.lang.Enum

    java.lang.Enum.EnumDesc<E extends java.lang.Enum<E>>
  • Enum Constant Summary

    Enum Constants 
    Enum Constant Description
    Current
    Input current closed loop
    Disabled
    Disable Motor Controller
    Follower
    Follow other motor controller
    MotionProfile
    Motion Profile
    PercentOutput
    Percent output [-1.0, +1.0]
    Position
    Position closed loop
    Velocity
    Velocity closed loop
  • Field Summary

    Fields 
    Modifier and Type Field Description
    int value
    Value of control mode
  • Method Summary

    Modifier and Type Method Description
    static ControlMode valueOf​(java.lang.String name)
    Returns the enum constant of this type with the specified name.
    static ControlMode[] values()
    Returns an array containing the constants of this enum type, in the order they are declared.

    Methods inherited from class java.lang.Enum

    compareTo, describeConstable, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf

    Methods inherited from class java.lang.Object

    getClass, notify, notifyAll, wait, wait, wait
  • Enum Constant Details

  • Field Details

    • value

      public final int value
      Value of control mode
  • Method Details

    • values

      public static ControlMode[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      Returns:
      an array containing the constants of this enum type, in the order they are declared
    • valueOf

      public static ControlMode valueOf​(java.lang.String name)
      Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
      java.lang.NullPointerException - if the argument is null