mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-29 02:21:44 +00:00
[wpilib] Call set(0) rather than disable for stopMotor (#4763)
For PWM motor controllers, this is going to be the fastest way to stop the motor, as disabling the PWM output will have a small delay due to the motor controller needing to detect the missing signal. Note Set(0) is not a safe approach for CAN motor controllers, which may have closed loop operation, non-% output set() calls, etc.
This commit is contained in:
@@ -78,7 +78,7 @@ public abstract class PWMMotorController extends MotorSafety
|
||||
|
||||
@Override
|
||||
public void stopMotor() {
|
||||
disable();
|
||||
set(0);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Reference in New Issue
Block a user