Enum Class MotorAlignmentValue
- All Implemented Interfaces:
Serializable, Comparable<MotorAlignmentValue>, Constable
The relationship between two motors in a mechanism. Depending on hardware
setup, one motor may be inverted relative to the other motor.
-
Nested Class Summary
Nested classes/interfaces inherited from class Enum
Enum.EnumDesc<E> -
Enum Constant Summary
Enum Constants -
Field Summary
FieldsModifier and TypeFieldDescriptionfinal intUnique integer value of this MotorAlignmentValue. -
Method Summary
Modifier and TypeMethodDescriptionstatic MotorAlignmentValuevalueOf(int value) Gets MotorAlignmentValue from specified valuestatic MotorAlignmentValueReturns the enum constant of this class with the specified name.static MotorAlignmentValue[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
Aligned
The two motor directions are aligned. Positive output on both motors moves the mechanism forward/backward. -
Opposed
The two motor directions are opposed. To move forward/backward, one motor needs positive output, and the other needs negative output.
-
-
Field Details
-
value
public final int valueUnique integer value of this MotorAlignmentValue.
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-
valueOf
Gets MotorAlignmentValue from specified value- Parameters:
value- Value of MotorAlignmentValue- Returns:
- MotorAlignmentValue of specified value
-