6
\$\begingroup\$

I am currently working on some hobby project. I have a 24V 2A DC motor that I want to drive. I designed a board with a designated IC on it to drive the motor, it wirked just fine. But then I thought that I would try to design my own H-bridge motor driver so that I am not bound by the parameters of the IC (current limit of 4A, it gets overheated easily, etc.)

So my question is: is this a good H-bridge design?

enter image description here

I am not looking for a 3 pin design, so my question is not regarding that. I want a 4 pin H-bridge, where I can control each pin with an MCU. I have seen some designs over the internet, nearly all of them agree on the N-channel MOSFET on the low side, and the P-channel MOSFET on the high side, with the flyback diodes parallel to each MOSFET.

But what about the BJT? Is it a good idea to drive the P-MOSFET through BJTs? Let's assume an STM32 3.3V MCU as the control unit, the pins that you can see here are directly connected to the GPIO pins of the MCU. Are the resistors of the correct value?

As I understand, R15 and R42 are "used" as current limiting resistors, but there is not so much current flowing that way, so small values like a 100ohm or 1k is okay?

R31 and R40 are pull down resistors, they need a high value like 10k, 100k to have only a small current there?

R17 and R22 are pull-up resistors when the BJT is off, same large values as the previous pull-down resistors?

I guess that R1 and R39 also limit the current, but I have no idea what is a good size there.

What else should I pay attention to? I guess I should choose P channel transistors that can handle high currents and high voltages, also the 24V gate voltage. N channel MOSFETs to be able to handle large currents. And what about the BJT? How do I choose that one?

So yeah, alltogether my question is: is this a good circuit, will it work, how to choose resistor sizes and BJT?

EDIT!

Based on the comments that I got (thank you very much), I re-designed the schematic:

enter image description here

The low-side PWM was a good suggestion, I did not think about that. I reduced the pull-down resistor sizes to make the switching faster. Based on an other very useful comment, I introduced a 15V zener diode to both sides to protect my MOSFET's gate from over-voltage. I also replaced the BJT with the exact same N-MOSFET switch that I use on the low side.

I did not get the boost-capacitor thing though :(

What do you think now?

\$\endgroup\$
13
  • 1
    \$\begingroup\$ I think the more common solution is to use all Nch with enable on top for direction and PWM on the bottom with the boost cap for gate voltage on top for greater speeds from lower Rdson and thus R/L ratios and lower losses. But deadtime depends on this time constant as well \$\endgroup\$
    – D.A.S.
    Commented Jun 21, 2021 at 16:44
  • 1
    \$\begingroup\$ Are the P-FETs ok with 24 V + margin on the gate? I would put a zener across it. \$\endgroup\$
    – winny
    Commented Jun 21, 2021 at 16:59
  • 1
    \$\begingroup\$ If one use 2N3904 for "digital" command, use a schematic with 2 anti-saturation diodes. Will be faster commutation. \$\endgroup\$
    – user288518
    Commented Jun 21, 2021 at 18:46
  • 1
    \$\begingroup\$ Well. Simulation done. Diodes seems not necessary. Sorry. \$\endgroup\$
    – user288518
    Commented Jun 21, 2021 at 19:08
  • 1
    \$\begingroup\$ Anyway, be aware that there an input capacitor of the MosFet that is about 1500pF. So commutation will be slowest. My evaluation of 45us in time. R17 & R22 may be lower. (1k) \$\endgroup\$
    – user288518
    Commented Jun 21, 2021 at 19:22

3 Answers 3

3
\$\begingroup\$

But what about the BJT? Is it a good idea to drive the P-MOSFET through BJTs?

It is fine, it doesn't matter what you use to drive the h-bridge mosfets as much as the time it takes to change the gate voltage.

There are two problems:

  1. Long switching times
  2. The high and the low side being on at the same time

Long switching times dissipate heat in the mosfet. If the mosfet is fully off it has really low current/high resistance, and there is little power dissipation. If the mosfet is fully on it has high current/low resisance and more power dissipation, but form many fets the Rdson is lower than 1Ω or in the mΩ range, so large currents will still dissipate heats that the package can handle.

The problem when the gate voltage is somewhere in the middle, and the resistance in the mosfet is equal to the load. At that point the fet will dissipate the same half of the power in the load (and is the peak power point). This can only happen for a short time, which will depend on a large variety of factors, the current, resistance of the fet and the gate capacitance and the other capacitances of the fet if switching fast.

The other thing you want to avoid is the high side and low side being on at the same time, this can be more difficult with using p-ch and n-ch at the same time (I usually use all n-ch, on the high side it becomes difficult to turn on the gate, but there are many ways to overcome this problem).

At the end of the day a spice simulation is best to verify that the fets are not burning up.

\$\endgroup\$
2
\$\begingroup\$

What do you think now?

I think you should probably simulate it in a spice package LT spice usually the one that I go to. Over all the design looks much better, and the high section of the bridge should switch faster.

The reason is there are many problems that are easier to spot. It's much easier to see if both and high and low sides are off at the same time.

Make sure you check power dissipation of parts. It's also good to simulate loads, especially loads that can change the inrush current. The inductance of wire or capacitive elements can cause issues for an h bridge.

Another problem that you may face is switching direction of the motor, because the motor is large inductive element and can also be affected by back EMF and the mechanical load. Would probably be wise to not immediately switch direction as that would generate large amounts of current and burn elements out, I also depends on the motor. If you are switching direction you could wait for a period of time for the motor to slow down and then turn on the other side.

\$\endgroup\$
4
  • \$\begingroup\$ If this is a one or two thing take a look at a BTS7960 Bridge module. It has a lot of bells and whistles that you may or may not want but they work great, I have used over a dozen of them. I purchased two dozen maye two years ago for less then $8.00 US delivered to my door. \$\endgroup\$
    – Gil
    Commented Jul 30, 2022 at 20:37
  • 1
    \$\begingroup\$ Beware when simulating, that you can easily miss the average power dissipation of a circuit. The time scales are much shorter (~ms/s or less of simulation speed) and devices don't blow up when they are abused; the simulator merely assumes you know what you're doing. :) \$\endgroup\$ Commented Jul 30, 2022 at 23:00
  • \$\begingroup\$ @TimWilliams -- is there a command-line option to start having devices blow up when they should? ;-} That would be really useful, though, don't you think? \$\endgroup\$ Commented Aug 1, 2022 at 13:03
  • 1
    \$\begingroup\$ @MicroservicesOnDDD You jest, but some simulators in the past, I think, have provided visual indication of things like that. Downside: it ends up more of an intrusive gimmick, than useful modelling; e.g., a fuse based on absolute current, rather than a real thermal model. \$\endgroup\$ Commented Aug 1, 2022 at 13:03
1
\$\begingroup\$

I built your circuit (in real life) but changed the resistance values for both High/Low sides to 10k/460 (instead of 100K/10K for High side, and 10K/100 for Low side, respectively), and it works well. I did the resistance change in order to be able to use an LTV-846 opto-coupler for control, and not worry about putting in BJT's and their circuitry.

In general, it worked as intended at 12V, but I don't think you can go to 24V. I measured with a scope and noticed that the "blocking" High-side P-MOSFET sees a Gate to Drain voltage equal to the voltage applied to the load. So, if the conducting branch applies 24V to the load, the blocking P-MOSFET sees those 24V from Gate to Drain.

I know the 20V gate limit is supposed to be from Gate to Source (which in your design is protected by the Zenner), but this Gate to Drain voltage somehow anyway destroyed one of my High-side MOSFETs. I did measure the voltage across the Zenner and it's very fuzzy but stays at 5V or so. Everything is peachy at 12V.

\$\endgroup\$
1
  • \$\begingroup\$ the blocking P-MOSFET sees those 24 V from Gate to Drain Where's the problem? Are you referring to the initial schematic or the one "with the Zener diodes"? There is a 60 Volt limit to \$V_{DSS}\$, and I'd fully expect the gate may be biased to the max in the opposite direction for a total of 85 Volts. The Zener diode limits \$V_{GS}\$ to well within ±25 V - which happens to be more than 24 Volts, anyway. \$\endgroup\$
    – greybeard
    Commented Dec 16, 2022 at 4:34

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.