From 526cee4c0f71740839b42161d1902a97a8916765 Mon Sep 17 00:00:00 2001 From: EmanuelFeru Date: Tue, 23 Jun 2020 20:13:05 +0200 Subject: [PATCH] Lowered pwm_margin by 10 - to avoid virbation at maximum PWM = 1000, due to reduced Phase current accuracy, the pwm margin is lowered by 10. Fixed #69 --- Src/bldc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Src/bldc.c b/Src/bldc.c index cb57ba4..639d8bd 100644 --- a/Src/bldc.c +++ b/Src/bldc.c @@ -45,7 +45,7 @@ extern ExtU rtU_Right; /* External inputs */ extern ExtY rtY_Right; /* External outputs */ // ############################################################################### -static int16_t pwm_margin = 100; /* This margin allows to always have a window in the PWM signal for proper Phase currents measurement */ +static int16_t pwm_margin = 110; /* This margin allows to always have a window in the PWM signal for proper Phase currents measurement */ extern uint8_t ctrlModReq; static int16_t curDC_max = (I_DC_MAX * A2BIT_CONV);