cancel
Showing results for 
Search instead for 
Did you mean: 

ST Motor Pilot V6.4 Nominal Current is not following MC Workbench Project current rating

fmariz
Associate II

Hello and good day. I am doing a project of running a motor using 6-Step with Hall Sensor.

I am facing an Overcurrent issue while using Motor Pilot V6.4 in 6-Step + Hall Sensor mode. In MC Workbench, the current limit is set to 15A but the Nominal Current is shown as 2.16A in the Motor Pilot GUI. No matter what I do in MC Workbench, the Nominal Current doesn't change and always shows as 2.16A. Consequently, I can't start the motor as it there is always Over Current fault as the motor needs more than 2.16 to start.

I know that it's not a limitation of my Power Board as it is rated at 20A.

fmariz_1-1753865018916.png

 

In MC Workbench, it's clearly stated 15 Apk is set and is within specification of Power Board.

fmariz_1-1753862394542.png

The strange this is, when I try FOC + Hall Sensor mode, this doesn't happen and the Motor Pilot GUI is showing the correct Nominal Current limit (15A) below. Somehow, this issue only happens in 6-Step + Hall Sensor mode.

fmariz_0-1753864814460.png

May I know why this Nominal Current setting is different between FOC and 6-Step GUI?

Here are the details of the project:

  • BLDC Motor rating: 15A
  • Control Board: B-G473E-ZEST1S
  • Adapter: X-NUCLEO-IHM09M2
  • Power board: EVALSTDRIVE101
  • Software: ST MC Workbench v.6.4 and Motor Pilot v6.40

Edit: Added more details

 

6 REPLIES 6
Fabrice LOUBEYRE
ST Employee

Hi fmariz, I suggest you first to check this post:

hall-sensor-not-working-on-6-4

From my point of view, the problem you raised is only a display issue.

The firmware does not retrieve the current information from the MCSDK Workbench, and it is not displayed on the Motor Pilot (the default value of 2.16 A is shown).

Best regards.

Fabrice

 

 

 

fmariz
Associate II

Thanks for the reply @Fabrice LOUBEYRE 

In that case, I am trying to think why my 6-Step design is causing the Over Current fault.

I have limited my power supply to just 5A peak and there's no Over Current option is unsupported anyway with my setup: 6-Step + Hall.

fmariz_0-1753944936675.png

Do you know how to solve this issue? I have attached my MCSDK Workbench project for your reference.

 

Hi Fmariz, can you confirm that you have considered the modifications in your code regarding the "placement electrical angle" parameter.

To properly set the placement electrical angle parameter, update your code with the following:

1. The two defines into drive_parameters.h

#define STEP_SHIFT (HALL_PHASE_SHIFT / 60) /*!< Number of steps (60 degrees) into the Placement electrical angle. */
#define PHASE_SHIFT_DEG (HALL_PHASE_SHIFT - (STEP_SHIFT * 60)) /*!< Number of degrees remaining after STEP_SHIFT. */

2. The corresponding HALL_PHASE_SHIFT value of your HALL sensor into  pmsm_motor_parameters.h

#define HALL_PHASE_SHIFT  238

3. Update the management of the STEP_SHIFT parameter at the end of the function HALL_TIMx_CC_IRQHandler embedded into the file hall_speed_pos_fdbk_sixstep.c

...
if (0U == pHandle->PhaseShift)
{
LL_TIM_DisableIT_CC2(pHandle->TIMx);
}
else
{
/* Set the remaining degrees after STEP_SHIFT set up into HALL_State2Step. */
/* Compute the counter value % to speed vs 60 degrees (step). */
uint32_t PhaseShiftTemp = ((pHandle->PhaseShift * hHighSpeedCapture) / 60U);
LL_TIM_OC_SetCompareCH2(pHandle->TIMx, PhaseShiftTemp);
LL_TIM_EnableIT_CC2(pHandle->TIMx);
}

 

You can also generate your project with the new MCSDK 6.4.1, which integrates the fix.

Best Regards.

Fabrice

 

 

fmariz
Associate II

Hi @Fabrice LOUBEYRE. Thanks for the suggestion. I'll let you know once I've tried it.

fmariz
Associate II

Hi @Fabrice LOUBEYRE. I have upgraded to MCSDK 6.4.1 and confirmed that the generated code matches the changes you suggested. However, I still get the same Over Current fault.

Do you have any other ideas that I can try?

fmariz
Associate II

@Fabrice LOUBEYRE I've found out that the fault is actually from the Driver Protection fault from STDRIVE101's nFault pin, and not Over Current fault as indicated. I've confirmed this by manually shorting the nFault Test Point to GND.

There's a bug with the Motor Pilot software.