|
|
@@ -1552,6 +1552,7 @@ static void mc_motor_runstop(void) {
|
|
|
cpu_exit_critical(mask);
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
static void mc_process_throttle_torque(float vol) __attribute__((unused));
|
|
|
static void mc_process_throttle_torque(float vol) {
|
|
|
float torque = throttle_get_torque(&motor.controller, vol);
|
|
|
@@ -1562,7 +1563,7 @@ static void mc_process_throttle_torque(float vol) {
|
|
|
return;
|
|
|
}
|
|
|
#endif
|
|
|
- if (mot_contrl_set_ebreak(&motor.controller, true)) {
|
|
|
+ if (!mot_contrl_ebrk_is_running(&motor.controller) && mot_contrl_set_ebreak(&motor.controller, true)) {
|
|
|
return;
|
|
|
}
|
|
|
}
|