2025-05-30 7:37 AM
I have a custom board (G491) with a 1-shunt driver and Hall sensors I have been using with MCSDK 6.3.2 with no issue.
When I saw the Release Notes of 6.4.0 I decided to give it a try, I wanted to try out the current monitoring.
The workspace project was created from scratch with the same configuration as it worked on 6.3.2 (6-step, hall sensor as speed sensor), but, when I tried to start the motor, it didn't start. When I manually moved the shaft, speed control got crazy and started spinning at max speed.
In idle, I realized that the UI reports 30 rpm when not in movement. I can move the motor forward and it reports some speed but, if I turn it backwards, speed is reported as 30 rpm. HALL_EL_ANGLE register is stuck at 0, when it should change.
I went back to a nucleo-G431 with a IHM08M1 and a different motor, and the behavior is exactly the same.
It looks like the logic for the Hall sensor is broken.
Has anybody experienced anything like that?
2025-06-05 12:02 AM
Hi,
Same issue with me. Tested with NUCLEO-G431+IHM16M1+ PMSM with HALL.
Work perfectly with X-CUBE-MCSDK v6.3.2 but not working with the latest version.
Can't control the speed through GUI. When start, motor spin at full speed.
2025-06-05 9:42 AM
Hi All, one of the changes made into the new MCSDK WB 6.4.0, is the ability to choose the timer number used to catch the HALL inputs
By default, the timer selected is the Timer 2, that could be different of the one used into MCSDK WB 6.3.2.
Naturally, another timer choice will generate different PINs for the H1, H2 and H3 signals, and in consequence a problem of connection if boards have been modified in desoldering access to the unused HALL signal connections for example.
MCSDK WB 6.4.0 HALL timer setection
i.e IHM16M1 HALL possible connections
Best regards.
Fabrice
2025-06-06 3:11 AM
I checked and that's not the issue for me. In either my custom board or IHM08M1 the Hall inputs can only be connected to a timer so there is no choice.
In fact, I compared TIM3 initialization code (in my custom board Hall sensors are connected to TIM3) from the previous working project v6.3.2 and the new using v6.4.0 and there is no difference.
There is a minor difference in TIM3 initialization inside HALL_Init(, this might be a bug in v6.4.0 but I doubt it has relevance, ICF1 filter seems wrong:
/* Set IC filter for Channel 1 (ICF1). */
LL_TIM_IC_SetFilter(TIMx, LL_TIM_CHANNEL_CH1, (uint32_t)(pHandle->ICx_Filter) << 20U);
vs the old code in v6.3.2:
/* Set IC filter for Channel 1 (ICF1) */
LL_TIM_IC_SetFilter(TIMx, LL_TIM_CHANNEL_CH1, (uint32_t)(pHandle->ICx_Filter));
But mayor difference is the ISR management:
What should be the values of HALL_PHASE_SHIFT and PHASE_SHIFT_DEG when Hall sensor placement electrical angle (measured as described in the documentation) is 108 or 120 degrees?