2025-08-04 2:06 AM
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!