Class REVDevices
java.lang.Object
swervelib.core.parser.deserializer.reflections.REVDevices
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumAbsolute encoder types.static enumMotor controller types. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetAbsoluteEncoder(int canid, String canbus, boolean inverted) Get theAngleSupplierand the encoder object.getAttachedAbsoluteEncoder(String attachType, Object motorController, boolean inverted) Get the attached absolute encoder.static SmartMotorControllergetMotorController(int canid, String canbus, SmartMotorControllerConfig config, org.wpilib.math.system.DCMotor motor, String motorControllerType) Get theSparkBaseas aSmartMotorController.
-
Constructor Details
-
REVDevices
public REVDevices()
-
-
Method Details
-
getMotorController
public static SmartMotorController getMotorController(int canid, String canbus, SmartMotorControllerConfig config, org.wpilib.math.system.DCMotor motor, String motorControllerType) Get theSparkBaseas aSmartMotorController.- Parameters:
canid- CAN ID of theSparkBasecanbus- CAN bus number of theSparkBase, seeCANBusesconfig-SmartMotorControllerConfigto apply to theSmartMotorControllermotor-DCMotorto use with theSmartMotorControllermotorControllerType- Motor controller type.- Returns:
SmartMotorController
-
getAbsoluteEncoder
-
getAttachedAbsoluteEncoder
-