I am using the TI's microcontroller with the BOOSTXL-3PHGANINV driver.
I'm running a sensorless brushless motor using FOC.
Looking at the schematic of the BOOSTXL-3PHGANINV, an INA240A1 produces on one of the three phases a Vout=Ia * Rsense * gain - Vref which sends to pin 27 "Analog_In/I2S_WS."
So I connected that pin to the oscilloscope and displayed the motor phase waveform by inverse mathematical formula: Ia=(Vout-Vref) / (gain*Vdiff)
This is phase A current "Ia":


The motor turns correctly, with a Hall I verified that the set speed is the speed actually achieved by the motor. However, I do not understand why the current on the phase (top photo) is NOT sinusoidal.
Am I missing something at the theoretical level? Or is something wrong in the code? It should be sinusoidal, rigth?
The code has thousands of lines and it'is already written by TI, it makes it available to you officially with its software (c2000ware-MotorControl). The algorithm is already all written by TI, I just set the parameters of my engine. I will not upload it because I would like more of a "theoretical" answer to:
what are the reasons why the phase current is so distorted and not a sinewave?
Consider that the motor I am testing is this one and its parameters (inductance, resistance, etc.) were estimated by TI software, which provides an automated parameter recognition procedure. I hope it is reliable.
I'm running a sensorless brushless motor using FOC.
Looking at the schematic of the BOOSTXL-3PHGANINV, an INA240A1 produces on one of the three phases a Vout=Ia * Rsense * gain - Vref which sends to pin 27 "Analog_In/I2S_WS."
So I connected that pin to the oscilloscope and displayed the motor phase waveform by inverse mathematical formula: Ia=(Vout-Vref) / (gain*Vdiff)
This is phase A current "Ia":


The motor turns correctly, with a Hall I verified that the set speed is the speed actually achieved by the motor. However, I do not understand why the current on the phase (top photo) is NOT sinusoidal.
Am I missing something at the theoretical level? Or is something wrong in the code? It should be sinusoidal, rigth?
The code has thousands of lines and it'is already written by TI, it makes it available to you officially with its software (c2000ware-MotorControl). The algorithm is already all written by TI, I just set the parameters of my engine. I will not upload it because I would like more of a "theoretical" answer to:
what are the reasons why the phase current is so distorted and not a sinewave?
Consider that the motor I am testing is this one and its parameters (inductance, resistance, etc.) were estimated by TI software, which provides an automated parameter recognition procedure. I hope it is reliable.



