From 6ae5b63f616f043b2b4cf5da3f60bf63e3e21735 Mon Sep 17 00:00:00 2001 From: Euan Mutch Date: Tue, 26 Sep 2023 09:41:07 +0100 Subject: [PATCH] Don't calibrate undriven --- conf_general.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/conf_general.c b/conf_general.c index 8bfa1100..f5c6855a 100644 --- a/conf_general.c +++ b/conf_general.c @@ -1652,9 +1652,9 @@ int conf_general_detect_apply_all_foc(float max_power_loss, int faultM1 = FAULT_CODE_NONE; int faultM2 = FAULT_CODE_NONE; - // Measure DC offsets including undriven + // Measure DC offsets // Needs to be done before getting the motor configuration - if(mcpwm_foc_dc_cal(true) == -1) { + if(mcpwm_foc_dc_cal(false) == -1) { return mc_interface_get_fault() - 100; // Offset fault by -100 }