MOSFET H-Bridge Not Behaving as Expected

Thread Starter

qrb14143

Joined Mar 6, 2017
112
Hello,

I have built a MOSFET based H Bridge to control a 250W 24V DC motor that I have. The circuit is more or less lifted from the datasheet of the gate drive IC I'm using, the LT1160. I have attached the circuit diagram, the PCB layout and an image of the completed board.

To test the circuit, I used a pair of lead acid batteries in series to get 24V and controlled the circuit from an Arduino. I applied 5V to switch one of the bottom MOSFETs on all the time and used PWM at various duty cycles to switch the opposite top switch on. The problem is that the motor does not reach anywhere near its top speed even at very high duty cycles. This has lead me to think that maybe something is not right with my gate drive circuit and the top MOSFET is not turning fully on. My main suspicion is with the bootstrap capacitors, I had only aluminium electrolytic capacitors laying around. Could this cause a problem?

I am an electronic engineering student but I am new to the field of motor drives so any help would be much appreciated. I have an oscilloscope and various DMMs so if someone could advise on where to begin in terms of troubleshooting that would be great.

Since this is my first attempt at a motor drive PCB, any feedback on the circuit and/or the PCB layout would be very welcome.

Thanks for your help and please ask if you need any more information.

upload_2018-1-23_13-9-3.png

Motor Drive Schematic PDF_png.png
 

Attachments

dendad

Joined Feb 20, 2016
4,635
It is the wee small hour of the morning here so I should be asleep. But a quick look, for one thing, the tracks on the PCB are not heavy enough for 10 amps I think.
It is a good idea to make the high current tracks as big and short as you can.
Are the FETs turning fully on?
With your Oscilloscope, measure the volts on both sides of the motor. See if you are getting close to full volts across the motor when it is on.
Remember that the FETs will drop a little across them so the motor will not run quite as fast as straight on the battery.
 

Thread Starter

qrb14143

Joined Mar 6, 2017
112
It is the wee small hour of the morning here so I should be asleep. But a quick look, for one thing, the tracks on the PCB are not heavy enough for 10 amps I think.
It is a good idea to make the high current tracks as big and short as you can.
Are the FETs turning fully on?
With your Oscilloscope, measure the volts on both sides of the motor. See if you are getting close to full volts across the motor when it is on.
Remember that the FETs will drop a little across them so the motor will not run quite as fast as straight on the battery.
Thanks for the reply. I will measure the voltage across the motor with the scope and see what I get.

I am aware that the tracks are too thin at a glance. I turned off the "filled zones" display in the interest of clarity in the picture. In actual fact, all of the current carrying paths are large filled areas of copper. These have also been filled up significantly with wire and solder since they are on the bottom of the PCB.

The FETs are physically as close together as I can get them without the heat sinks getting in the way.
 

kubeek

Joined Sep 20, 2005
5,796
The first problem is that you need to alternately drive both fets on one side, otherwise C4 gets discharged and the result is very weak gate drive for the top fet, if even any drive.
Second thing is that since you need to drive the fets alternately, you also need to provide enough dead time between turning the other fet on, otherwise both could be on and short you supply (this is called shoot through). Achieveng this is not entierly trivial, and it is better to use a driver that also provides dead time.
 

Thread Starter

qrb14143

Joined Mar 6, 2017
112
The first problem is that you need to alternately drive both fets on one side, otherwise C4 gets discharged and the result is very weak gate drive for the top fet, if even any drive.
Second thing is that since you need to drive the fets alternately, you also need to provide enough dead time between turning the other fet on, otherwise both could be on and short you supply (this is called shoot through). Achieveng this is not entierly trivial, and it is better to use a driver that also provides dead time.
Can you expand on your first point a bit for me? As I understand it, the bottom side switch Q2 can be switched on indefinitely since no bootstrap is required to charge its gate. Therefore, I apply a logic high to its control input all the time. If Q2 is on, then I want to switch on Q3 to allow current to flow from right to left through the motor. Since the bootstrap circuit is used to charge the gate of Q3, it cannot be switched on at a 100% duty cycle otherwise C4 discharges. Is this correct? I therefore applied a square wave with an 80% duty cycle to its control input. Naturally, Q1 and Q4 were left switched off to avoid a shoot through.

The LT1160 driver chip I am using is designed to control a half bridge so it contains internal logic to prevent both MOSFETs on one side of the bridge from being turned on simultaneously. I am intending to have four states for my motor, clockwise rotation, counterclockwise rotation, freewheeling or braking. I will apply a dead time in software when changing between these states.
 

kubeek

Joined Sep 20, 2005
5,796
Yes you got it right, but for the bootstrap cap to charge you I think have to turn on Q4 as well, when Q3 is off (maybe the freewheeling diode in the fet will be enough, but I am not sure).And any way you want Q3 to be on to minimize losses.

The internal logic prevents both outputs being high at the same time, but it does not provide dead time between them. At the transition between the two fets alternating, the gate of one will start discharging and the gate of the other will start charging, and for some time in the middle they will be both partially on at the same time.
 

Thread Starter

qrb14143

Joined Mar 6, 2017
112
250W at 24V is 10.4A.

IRF540 on resistance is 0.077 Ohms. There are two of them in series, so you are losing 1.6V out of 24.

I don't think that explains "not reaching anywhere near its top speed". But I would still use a better MOSFET than that. You can get ones that have < 10 mOhms on resistance.

The bootstrap capacitor seems high. It might not be fully charging at higher duty cycles. What frequency are you using for PWM?

Bob
I find that the internet is absolutely littered with H-Bridge circuits that simply don't work or worse, develop a shoot through the instant they're turned on. I chose this circuit and components because it appears on page one of the datasheet for the LT1160 so I thought I couldn't go wrong!
upload_2018-1-23_14-37-23.png
I was using 20kHz because I thought that would keep me out of the audible range whilst avoiding the higher losses associated with more switching operations per second. I see on another thread on here SgtWookie says that 0.1uF should suffice in all but exceptional circumstances. I think I'll see if I have any 0.1uF ceramic capacitors in my collection and try those.
 

cmartinez

Joined Jan 17, 2007
8,727
Hello,

I have built a MOSFET based H Bridge to control a 250W 24V DC motor that I have. The circuit is more or less lifted from the datasheet of the gate drive IC I'm using, the LT1160. I have attached the circuit diagram, the PCB layout and an image of the completed board.

To test the circuit, I used a pair of lead acid batteries in series to get 24V and controlled the circuit from an Arduino. I applied 5V to switch one of the bottom MOSFETs on all the time and used PWM at various duty cycles to switch the opposite top switch on. The problem is that the motor does not reach anywhere near its top speed even at very high duty cycles. This has lead me to think that maybe something is not right with my gate drive circuit and the top MOSFET is not turning fully on. My main suspicion is with the bootstrap capacitors, I had only aluminium electrolytic capacitors laying around. Could this cause a problem?

I am an electronic engineering student but I am new to the field of motor drives so any help would be much appreciated. I have an oscilloscope and various DMMs so if someone could advise on where to begin in terms of troubleshooting that would be great.

Since this is my first attempt at a motor drive PCB, any feedback on the circuit and/or the PCB layout would be very welcome.

Thanks for your help and please ask if you need any more information.

View attachment 144277

View attachment 144280
Take a look at this thread. It might help you understand some of the issues that you're having.
 

shortbus

Joined Sep 30, 2009
10,050
The first problem is that you need to alternately drive both fets on one side,
Are you sure about that? It has been my understanding the the opposite low side, say Q1 and Q3 will still charge the bootstrap cap. I think his problem is he is pulsing/PWM the highside and not the low side of the H-bridge. Isn't that the normal way it's done?

I applied 5V to switch one of the bottom MOSFETs on all the time and used PWM at various duty cycles to switch the opposite top switch on.
 

Thread Starter

qrb14143

Joined Mar 6, 2017
112
Are you sure about that? It has been my understanding the the opposite low side, say Q1 and Q3 will still charge the bootstrap cap. I think his problem is he is pulsing/PWM the highside and not the low side of the H-bridge. Isn't that the normal way it's done?
I was of the impression that I had to PWM the top side as it's the PWM low period that gives the bootstrap capacitor time to recharge?
 

kubeek

Joined Sep 20, 2005
5,796
Are you sure about that? It has been my understanding the the opposite low side, say Q1 and Q3 will still charge the bootstrap cap. I think his problem is he is pulsing/PWM the highside and not the low side of the H-bridge. Isn't that the normal way it's done?
The normal way is to keep Q2 on all the time, and switch between Q3 and Q4. I think that the way a motor produces back EMF the voltage between Q3 and Q4 will not drop to low values and the bootstrap cap will not be recharged.
 

Thread Starter

qrb14143

Joined Mar 6, 2017
112
The normal way is to keep Q2 on all the time, and switch between Q3 and Q4. I think that the way a motor produces back EMF the voltage between Q3 and Q4 will not drop to low values and the bootstrap cap will not be recharged.
If I switch both Q2 and Q4 on at once though, it will short out the motor and cause a braking effect will it not?
 

kubeek

Joined Sep 20, 2005
5,796
If I switch both Q2 and Q4 on at once though, it will short out the motor and cause a braking effect will it not?
Not really. The inductance of the motor will keep the current flowing in the same direction as if Q2 and Q3 were on. Only if you held Q4 on for long enough time to deplete the energy stored in the inductance would the motor start braking and slowing down.
 

Thread Starter

qrb14143

Joined Mar 6, 2017
112
Thanks for all of the input so far. It looks as though I'm going to have to put more thought into my uC code to control this thing so that I can turn one of the bottom MOSFETS on to charge my bootstrap capacitor.

Would the learned people of this forum say that this is a good approach in general or are there easier ways to build a motor drive? (I know I could probably buy one from any number of outlets for not very much money but I'm learning a lot as I go along so I'd prefer not to!)
 

cmartinez

Joined Jan 17, 2007
8,727
I was of the impression that I had to PWM the top side as it's the PWM low period that gives the bootstrap capacitor time to recharge?
You're right. The top side is the one that's normally pwm'd for the reason you've just described.

But deadtimes and gate rise times are also important. They're also mentioned in the thread that I pointed you to.
 

kubeek

Joined Sep 20, 2005
5,796
I would use for example IR21844 which has configurable dead time. This will greatly simplify your driving logic in the uC.
 

be80be

Joined Jul 5, 2008
2,394
If you read on down the datasheet you come to this
In applications where rotation is always in the same direction, a single LT1160 controlling a half-bridge can be used to drive a DC motor. One end of the motor may be connected either to supply or to ground as seen on Figure 3. A motor in this configuration is controlled by its inputs which give three alternatives: run, free running stop (coasting) and fast stop (“plugging” braking, with the motor shorted by one of the MOSFETs). To drive a DC motor in both directions the LT1162 can be used to drive an H-bridge output stage. In this configuration the motor can be made to run clockwise, counterclockwise, stop rapidly (“plugging” braking) or free run (coast) to a stop. A very rapid stop may be achieved by reversing the current, though this requires more careful design to stop the motor dead. In practice a closed-loop control system with tachometric feedback is usually necessary
You using this for full H-bridge looks to me the boost cap would need to cross
the one on the right would need to be hooked on the left side of the motor.
The left would hook on the right side.
The top of the cap stays as is.
If you under stand what i'm saying .
 

Thread Starter

qrb14143

Joined Mar 6, 2017
112
I would use for example IR21844 which has configurable dead time. This will greatly simplify your driving logic in the uC.
That IC is a bit cheaper than the LT1160 as well and I do love a bargain ;)

I'm just a bit worried that it uses exactly the same method of bootstrapping as the LT1160 so I fear I will run into exactly the same problem.
 

Thread Starter

qrb14143

Joined Mar 6, 2017
112
If you read on down the datasheet you come to this


You using this for full H-bridge looks to me the boost cap would need to cross
the one on the right would need to be hooked on the left side of the motor.
The left would hook on the right side.
The top of the cap stays as is.
If you under stand what i'm saying .
I see exactly what you mean. In theory this would surely cure my problem as the bootstrap capacitor could always recharge through the adjacent MOSFET rather than through the one below it. Better fire up LT Spice again for some investigation methinks! If this method works in simulation, I could run some wires across my prototype PCB to try it out.
 

Thread Starter

qrb14143

Joined Mar 6, 2017
112
Well now I'm more confused. My LT Spice simulation shows that it should work perfectly well AS IS. It does not appear to work if I "cross over" the bootstrap capacitors. I have represented the motor with a simple resistance here. As can be seen, applying PWM to the top left FET and turning the bottom right FET on, produces a square current through the load.
upload_2018-1-23_20-10-56.png
 

Attachments

Top