disable PWM straight away on motor error

This commit is contained in:
Oskar Weigl
2018-10-07 13:12:37 -07:00
parent 5a22821bcd
commit 26eb4e7765
+2
View File
@@ -136,6 +136,8 @@ bool Motor::check_DRV_fault() {
void Motor::set_error(Motor::Error_t error){
error_ |= error;
axis_->error_ |= Axis::ERROR_MOTOR_FAILED;
safety_critical_disarm_motor_pwm(*this);
update_brake_current();
}
bool Motor::do_checks() {