How to find your mechanism circumference?
Last updated
Last updated
SmartMotorControllerConfig smcConfig = new SmartMotorControllerConfig(this)
.withControlMode(ControlMode.CLOSED_LOOP)
// Mechanism Circumference is the distance traveled by each mechanism rotation converting rotations to meters.
.withMechanismCircumference(Meters.of(Inches.of(0.25).times(22).in(Meters)))
.withMechanismCircumference(Inches.of(4).times(Math.PI)) // 4in * PI
.withWheelDiameter(Inches.of(4)) // Same as above
.withWheelRadius(Inches.of(2)) // Same as above
.withStartingPosition(Meters.of(0));