2024-07-03 11:38 AM
Dear MCSDK,
Thnak you for your nice work with this project. I am trying to use the McSDK with ST eval board B-g431-sec to control the speed of a small brushless PMSM motor with sensorless FOC.
This motor with its load can rotate at approximately ~10k rpms (tested on another hardware using FOC with an encoder).
With the eval board and MCSDK, things are quite Ok at low speed but I am unable to go higher than ~7000 rpms. At this speed my phases duty cycles are close to 100% and my PI speed (iqref) isn’t saturated.
Configuration :
Motors :
R = 170mOHms (phase to phase)
L = 20uH (phase to phase)
pair poles = 7
elec max frequency : 10000*7/60 -> 1160Hz !!
kv = 0.67V(phase to phase) / krpm
MCSDK (6.3.0) :
PWM frequency : 64khz
FOC frequency : 32khz
sensorless : CORDIC with observer gains tuned
following Mcsdk documentation
Any idea ?
2024-07-04 06:11 AM
Hello @ANICO.1 ,
What is your VBus voltage of your the B-G431-ESC board ?
Did you try the STO-PLL instead of STO-CORDIC ?
Regards
Cedric
2024-07-04 06:19 AM
My VBus voltage is 12V.
I will try the STO-PLL.
Regards,
Antoine
2024-07-05 10:08 AM - edited 2024-07-05 10:09 AM
Dear Cedric,
Thank you for the STO-PLL advice, I tried it and it is in fact much more robust to current noise.
The PLL observer looks much more stable and I was able to go faster (up to ~8krpm with a load and 16krpm ) but it seems that current becomes really noisy when approaching high duty cycles.
I had a look to the r3_2_g4xx_pwm_curr_fdbk.c and added a few debug values. Noise appears when leaving the area where current can be sampled without switching phases. As soon as the current sampling algorithm leave the "sector 5" (phase A and B sampled), the current noise increase drastically.
I did some test at low speed (lower current) while forcing the sampling sector with my debugger and I can see that sector 1 and 2 (phase A and C sampled) is much more noisy than the other.
2024-07-11 05:16 AM
I did more tests. As my problem seems to be related to current sampling when the low sides MOSFET are ON I switched to Discontinuous modulation so my Toff will be slightly larger for all mosfets.
This allowed me to spin my motor to a slightly higher RPM but I am still confused if I am really at the maximum.
I did a benchmark for a given set up with 3 different solutions :
Solution 1 : A sensored FOC ESC for comparison
Solution 2 : my eval board b-g431-esc with overmodulation
Solution 3 : my eval board b-g431-esc with discontinuous modulation
The set up : a motor with its load, a power supply configured at 9.5V and max 15A
The test :
I increase the speed command until the ESC fail to regulate.
Results :
Solution 1 : 6800RPM
Solution 2 : 6100 RPM
Solution 3 : 6300 RPM
I am using this parameters for B-G431-ESC power stage parameters in the MCSDK (found empirically) :
TNOISE : 250ns (was 1000ns per default)
DEADTIME_NS : 80ns (was 1000ns per default)
2024-07-11 05:26 AM
I also tried to :
- increase the sampling time of the ADCs
- change the opamp op speed from "NORMAL" to "FAST"
- reduce the gain of the op amp to lower the amplification of noises (at the cost of a lower resolution on my ADC)
The gain reducing seems to give a slightly better solution but mind-blowing.
I join a few graph of current and rpm made with cubeMonitor.
2024-07-11 06:58 AM
One last thing.
In another thread from this forum, you said "the polarization of our amplification circuit is not the state of the art in this schematic. You could improve it to reduce the common-mode noise rejection."
Could you point me to state of the art polarization circuit ?
Thanks
Antoine