Part Number: TMS320F28069M
Hello,
I am using TI InstaSpin FOC on the MCU TMS320F28069M to calculate the supply current.
I followed this thread to calculate it:
Using the solution that it seems to work,
// calculate inverter output power in kW
gMotorVars.Power_coef = _IQmpy(_IQ(1.0*1.5/0.96), gMotorVars.VdcBus_kV); // _IQ(1.0*1.5/0.96) for MW16
gMotorVars.Power_kW = _IQmpy((_IQabs(_IQmpy(gMotorVars.Vd, gMotorVars.Id_A)) + _IQabs(_IQmpy(gMotorVars.Vq, gMotorVars.Iq_A))), gMotorVars.Power_coef);
gMotorVars.Iin_A = _IQdiv(gMotorVars.Power_kW, gMotorVars.VdcBus_kV);
I observed that the current is almost twice compared to the current read from a power supply.
Why to convert gMotorVars.Vd and gMotorVars.Vq to real voltage value, it uses gMotorVars.VdcBus_kV and not USER_IQ_FULL_SCALE_VOLTAGE_V as it does with the current?
I've implemented this option and the results are not the expected one too.
Best Regards,
Gorka