Package ftclib.motor
Class FtcMotorActuator
java.lang.Object
ftclib.motor.FtcMotorActuator
This class creates an FTC platform specific motor with the specified parameters.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enum
static class
This class contains all the parameters for creating the motor. -
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionConstructor: Create an instance of the object. -
Method Summary
Modifier and TypeMethodDescriptioncreateMotor
(String name, FtcMotorActuator.MotorType motorType, TrcMotor.ExternalSensors sensors) This method creates a motor with the specified parameters and initializes it.getMotor()
This method returns the created primary motor.
-
Field Details
-
-
Constructor Details
-
FtcMotorActuator
Constructor: Create an instance of the object.- Parameters:
params
- specifies the motor parameters.
-
-
Method Details
-
getMotor
This method returns the created primary motor.- Returns:
- primary motor.
-
createMotor
public TrcMotor createMotor(String name, FtcMotorActuator.MotorType motorType, TrcMotor.ExternalSensors sensors) This method creates a motor with the specified parameters and initializes it.- Parameters:
name
- specifies the instance name of the motor.motorType
- specifies the motor type.sensors
- specifies external sensors, can be null if none.- Returns:
- created motor.
-