Weird Sequence in Voltage of phase to phase in IGBT

Hi everyone,

We use an axial flux BLDC motor, and we drive it with a 3-phase inverter circuit using IGBTs and SimpleFOC.

Our motor produces a weird low-frequency sound, and we haven’t identified the cause. We used an isolation probe to measure the voltage phase-to-phase and captured this signal:

It is evident that in the positive cycle, there is a sequence where the signal is negative instead of positive. I think this is incorrect and could be causing the weird sound from the motor. Am I right?

Could you please circle on the picture where this is exactly happening?

Also please post details on the hardware driver, PCB design, MCU, etc. This doesn’t seem like a software problem. Also your code to drive the IGBTs. Driving IGBTs with SimpleFOC is a little tricky.

Cheers,
Valentine

Hi Valentine
Sorry for my mistake
I expected positive signal but an negative occurred as you shows in picture.
Our setup is like this :


We use fuji IGBT 2MBI100VA with 1uF snubber capacitor on DC link.
We use a current sensor for FOC current too.
I don’t have the schematic of my drive and I just can send a photo from it :


We use a stm32f4 for MCU. And the code is :


#include <SimpleFOC.h>


HardwareSerial Serial1(PB11, PB10);



/// F407VGT6 TIM1
#define PHA_H PE9 // TIM1
#define PHA_L PA7 // TIM1
#define PHB_H PE11 // TIM1
#define PHB_L PB0 // TIM1
#define PHC_H PE13 // TIM1
#define PHC_L PB1 // TIM1



// /SPI 1 (AS5048A)
#define MOSI_ENC PB5//    
#define MISO_ENC PB4//   
#define CLK_ENC  PB3//   
#define CS_ENC   PE3


MagneticSensorSPI sensor = MagneticSensorSPI(AS5147_SPI, CS_ENC);
SPIClass SPI_1(MOSI_ENC, MISO_ENC, CLK_ENC);  //(mosi, miso, sclk)





BLDCMotor motor = BLDCMotor(5);

BLDCDriver6PWM driver = BLDCDriver6PWM(PHA_H, PHA_L, PHB_H, PHB_L, PHC_H, PHC_L);


InlineCurrentSense current_sense  = InlineCurrentSense(16.33f,  PA0, PA1, PA2);





// velocity set point variable
float target_velocity = 0;

// instantiate the commander
// Commander command = Commander(Serial1);


Commander command = Commander(Serial1);
void doTarget(char* cmd) { command.scalar(&target_velocity, cmd); }

// void doMotor(char* cmd) { command.motor(&motor, cmd); }





void setup() {
  sensor.init(&SPI_1);

  motor.linkSensor(&sensor);
  motor.phase_resistance = 0.25;


  motor.zero_electric_angle = 1.925;
  motor.sensor_direction = Direction::CW;

  driver.voltage_power_supply = 96;
  driver.voltage_limit = 90;
  motor.voltage_limit = 90;
  
  driver.pwm_frequency = 10000;
  driver.dead_zone = 0.05;
  driver.init();

  

  motor.linkDriver(&driver);

  current_sense.linkDriver(&driver);

  current_sense.init();
  current_sense.gain_a *=-1;
  current_sense.gain_b *=-1;
  current_sense.gain_c *=-1;
  current_sense.skip_align = true;

  motor.linkCurrentSense(&current_sense);

  motor.voltage_sensor_align = 5;
  

  motor.controller = MotionControlType::velocity;

  motor.torque_controller = TorqueControlType::foc_current;
  motor.foc_modulation = FOCModulationType::SpaceVectorPWM;
  motor.modulation_centered =1;
  motor.motion_downsample = 10;
  motor.monitor_downsample = 200;
  


  motor.PID_velocity.P = 0.2;
  motor.PID_velocity.I = 4; 
  motor.PID_velocity.D = 0;

  motor.LPF_velocity.Tf = 0.05f;
  motor.LPF_angle.Tf = 0.05f;
  

  
  motor.PID_current_q.P = 0.15; //
  motor.PID_current_q.I= 0.4;   //

  motor.PID_current_d.P= 0.001;
  motor.PID_current_d.I = 0.001;
  

  motor.LPF_current_q.Tf = 0.01f;
  motor.LPF_current_d.Tf = 0.01f;
  



  motor.current_limit = 40; //
  

  motor.PID_velocity.output_ramp = 1000;

 

  Serial1.begin(115200);



  motor.useMonitoring(Serial1);




  
  
  

  motor.init();


  motor.initFOC();
  

  command.add('T', doTarget, "target velocity");

  Serial1.println(F("Motor ready."));
  Serial1.println(F("Set the target velocity using serial terminal:"));
  _delay(1000);

  
}

}
void loop() {

  motor.loopFOC();

  motor.move(target_velocity);
  
  

  motor.monitor();


  command.run();
  


}


This is another picture from phase-to-phase voltage that is captured :


As you can see this unmatched sequence (directed with blue) is occurring and I don’t know why this is happening.
Do you need any other information ?

Thanks.

1 Like

So the spikes occur at random?

Educated guess, this seems like a hardware issue, not software. Something is shooting through the gate and not clear what. Please trace the signal back to the MCU, I suppose, you will see the spurious signal occurring on the gates but not on the driver MCU PWM control input.

Also, I don’t think this noise is due to the spikes. Please comment out the

motor.monitor();

This consumes a lot of resources and on a smaller MCUs this will create a low-frequency humming due to holding the motor while the software monitor is working.

F4 should be probably good enough but you need to find another way to control the motor speed, Serial monitor holds / blocks the closed loop and this is probably the humming you hear.

Extreme case, you may want to introduce a “gap” and read the serial monitor only every tenth of a second or so, this will create a very low frequency infrasound not hearable by human ears.

Put this inside the code to read every 1/10’th of a second:

In setup() :

unsigned long prev = millis();
unsigned long current = millis();
unsigned long threshold = 100; // Occurs every 100 milliseconds

In loop () :

  current = millis();
  if ((current - prev) > threshold) {
    prev = current;
    motor.monitor();
    }

So you got two problems to solve.

Last but not least, you set the PWM frequency to 10khz, this will blow the ears of young people and dogs and cats (any small animal), they can hear 10k really easy, go for at least 16k, this will create a little more heat loss inside the IGBT but your ears will be better off.

Cheers,
Valentine

So the spikes occur at random?
Yes it seems.
It is another signal:

If you set the resolution high, freeze the frame and zoom into the spike what do you see?

Valentine

Please trace the signal back to the MCU, I suppose, you will see the spurious signal occurring on the gates but not on the driver MCU PWM control input.

This the signal of phase-to-phase with corresponding control signal of one leg of IGBT :

Yellow : phase-to-phase voltage
Blue : Gate_Emiiter High
Purple : Gate_Emiiter Low

This is the zoom of the signal :

Interesting. Those seem like shoot-throughs the fets, since on the other picture I don’t see matching control signal to support the software hypothesis. I’m guessing since I don’t have my hands/eye there.

Please increase the dead-time on the drivers and SimpleFOC to at least double, may be triple what it is now and see what happens.

Other hypothesis is that the gate gets triggered by noise. That’s extremely hard to debug.

Cheers,
Valentine

Which signal is that? Hard to tell without the other channels.

Ideally if you manage to get the two PWM, the two driver controls and the phase output would be ideal.

That’s 5 signals, not sure if your Rigol can mix that many.

Valentine

Please increase the dead-time on the drivers and SimpleFOC to at least double, may be triple what it is now and see what happens.

The initial value of dead-time is 0.05f but now it is 0.1f and I remove monitor too. This signal is captured :

This signal captured from these sources:

What happens when you overlay all 6 and zoom in?

Those really seem like shoot-throughs. S1 and S4 are open simultaneously and current flows directly through, and you see the BEMF shoots the other direction.

This is speculation.

Valentine

With RIGOL I cant capture all 6 signals together.

Can you explain this part ?
Thanks.

When S1 and S4 open at the same time due to overlap in the gate driver signal (why they overlap is the real reason?), then the power shorts and you see the stored BEMF going back into the (-).

Zoom into the S1 and S4 gate driver signal going into the fets to see if there is any overlap.

You should see a clean PWM F4 driver signal but overlapping gate drive signals, i.e. they will be a little off-phase.

This is a guess.

Valentine

This is gate_emitter of S1 and S4 :


and this is the zoom of signal :

Is this overlap or not ?

No it is not, so your task gets even harder. Everything on that phase looks good. PWM from the MCU are correct, and the gate signal seems fine.

Can you increate the dead time even more?

driver.dead_zone = 0.2;

Please also check the same thing for the other two phases.

There has to be something triggering the error because this more and more seems like a driver issue. Something in the driver creates a gate signal where it should not.

Valentine

You also want to check the electrical integrity of the motor, perhaps you are leaking current from an internal motor short on the coils. Disconnect the phases, and measure the resistance across each phase pair, you must get exactly (or nearly) the same. Perhaps in extreme case the coils energize and short due to bad wiring inside the motor. The coils of the high power motors get a lot of stress and damage all the time.

Change the motor with a new good motor and check again.

The more I think the more I believe the problem is after the driver, anywhere from the igbt gates to the motor coils, as a really simple electrical issue somewhere.

Valentine

We tested the insulation resistance of the phases with the Megger and found no leakage.