Skip to main content
Associate III
August 4, 2025
Solved

The starter motor failed to start

  • August 4, 2025
  • 1 reply
  • 435 views

Dear ST motor control experts:
      I am currently debugging a PMSM using MCSDK6.3.2, with the following components: MCU: STM32G473QET6, control board: B-G473E-ZEST1S, power board: STEVEL-LVLP01. However, the motor fails to start. Upon inspection, it was found that the issue is caused by the R3_GetMeasurements() function. After MCI_START == Mci[M1].DirectCommand, the PWM is initiated, and when sampling and saving data for current and voltage, many function addresses change. Specifically, in the function R3_GetMeasurements(), there is a line of code: PWMC_R3_Handle_t * pHandle = (PWMC_R3_Handle_t *)pHdl. Is there a problem here? Because performing a cast on a pointer may cause memory boundary errors. Is this the reason?
I hope to receive a reply.
Thanks!

Best answer by GMA

Hello @quanhongwei,

On MC Pilot tool, what is the reported error? 
For Error description and management, refer to documentation available through "Workbench tool">About>Documentations>Documentation>"User manual" tab, "(FOC) Firmware errors" link.

1 reply

GMA
Technical Moderator
August 5, 2025

Hello @quanhongwei,

What do you mean by "the motor fails to start"?
Do you have a reported error?

If you agree with the answer, please accept it by clicking on 'Accept as solution'.Best regards.GMA
Associate III
August 6, 2025
HI,Thank you for your reply!

Yes. After starting the motor, the program crashed and jumped to the hardware fault. During debugging, it was found that the address of the internal structural variable Mci[M1] kept changing, eventually leading to a jump to the hardware fault interrupt. It is suspected that the boundary error in the statement PWMC_R3_Handle_t * pHandle = (PWMC_R3_Handle_t *) pHdl in the function R3_GetMeasurements() during typecasting caused the program to crash。
GMA
GMABest answer
Technical Moderator
August 6, 2025

Hello @quanhongwei,

On MC Pilot tool, what is the reported error? 
For Error description and management, refer to documentation available through "Workbench tool">About>Documentations>Documentation>"User manual" tab, "(FOC) Firmware errors" link.

If you agree with the answer, please accept it by clicking on 'Accept as solution'.Best regards.GMA