2025-05-19 4:24 PM - edited 2025-05-20 12:49 AM
Hi,
I designed a custom inverter, based on G473VE, external amplifier and compare, use TIM8 to generate PWM wave, use IR2101S to drive MOSFET. When I try to profile the motor(based on HSO), I get the error: ERROR_DC_AC.
I have upload the screenshot(90e0d582f6e2fb5d5043ff325aab241.png), stwb6 file(MCV1_HSO_PROFILE.rar) and schematic files(MC_V1.pdf). Could you help me please? Thanks a lot!
I have tried frequency from 20hz to 100hz, and power from 2w to 5w. but no use...
2025-05-20 12:48 AM
Is this error caused by the negetive Ls? I have used PLL to profile the same motor, the Ls is about 0.55mH.
2025-05-22 6:26 AM
Hello ZHOUXIANG,
Have you tried to look at the current waveforms via Datalog ? Is everything behaving correctly ? Can you send pictures please ?
You could also have a look at Open Loop currents.
2025-05-23 12:07 AM
phase voltage and current when profiling(above)
for power of phase U, 2.5A*0.36V=0.9w, for power of phase V and W, both seem to be half of phase U, so the total power is about 2w. It seems to be right.
phase voltage and current when "open loop current"(above)
I zoom in the Y scale, I can see many peek on current, but very very week near zero.
Then, I measure the current on Rshunt by multimeter, about 1.2A, not 2.5A, this is weird. I am trying to check this.
Also, I measure the phase voltage of U, the value is about 10.5V before starting profile, and raise up to about 10.8V during profile, 10.8-10.5=0.3V vs 0.36V above, that seems right.
Finally, I check the profile result, Rs is about 0.2 Ohm, but 0.36V/2.5A=0.14 Ohm, this is weird again.
I still do not know much about HSO, so I need more advise and notice. Thanks a lot!
2025-05-24 5:32 AM
I check current sensing setting, are there some wrong below?
M1_MAX_READABLE_CURRENT is OK, but M1_MAX_READABLE_CURRENT do not have /2, just ADC_REFERENCE_VOLTAGE. please help me check the setting, thanks a lot.
2025-05-30 12:03 AM - edited 2025-05-31 8:10 PM
According to the datalog above, the phase voltage seems ok, but the phase current is not. I check the related code, found something below:
I use cubemonitor to trace some values in function OVERSAMPLING_getMeasurements
I check 3 points and get different results.
ai = (aovs*acf)>>16 = (50400 * (-268435456))>>16 = -13,529,146,982,400 >> 16 = -206,438,400 ≠ -206503936.
ai = (aovs*acf)>>16 = (50384 * (-268435456))>>16 = -13,524,852,015,104 >> 16 = -206,372,864 == -206372864.
ai = (aovs*acf)>>16 = (50480 * (-268435456))>>16 = -13,550,621,818,880 >> 16 = --206,766,080 ≠-206635008.
what's wrong?
2025-06-05 12:17 AM - edited 2025-06-05 6:10 PM
@Gael A I check the current wave of phase U again, the current seems OK.
Rshunt Voltage of phase U = (1.65-1.24)/15= 27mV ≈ 26mV
Current of phase U = 27mV/10mΩ = 2.7A
The datalog indicate that current of phase U is about 2.58A. Everything seems OK.
Also, I check the OpenLoop Current, it is OK. So, what else can I do now?
2025-06-06 1:31 AM
Do you have any ideas about this issue? I am going to give up the HSO.
2025-06-06 2:23 AM
Hello ZHOUXIANG,
On your latest datalog screenshot, I cannot see any current flowing, is this intended behaviour ?
Also, surely you will understand that we cannot provide support on custom boards, so you will have to check your settings and hardware by yourself.
Concerning the current's behaviour, could you do the following experiment :
- Switch to Open Loop Duty
- Input a small percentage value, with a small rotation speed value and try to find a setting that makes your motor work
- Have a look at Ialpha and Ibeta using Datalog, and extract a picture in XY plot.
If this works, you can switch to OpenLoopCurrent, and see for all three phases if the level of current is correct. (0°, 120° and 240°). Please rapidly tune your current PID before doing this. You can also try using the profiled values from the Legacy Profiler and generate an HSO project that way to have a guess on your current PID.