Brads H-Bridge

For some reason, search isn't easily finding my previous post on this topic, so I created a new one. Here's my first crack at an H-Bridge schematic, taking inspiration from several locations:

I would love to get some feedback and have a few questions...

  1. For the logic level N Channel MOSFETs, do I need a path to ground? Since the resistor limiting the current to the Arduino output is 47 kOhms, it seems like it would need to be more than that to avoid just sinking the current from the output.

  2. On the protection from the motor, I'm wondering if I need two of the big caps, or just one. These big ones are typically shown with a polarity, but I'm not sure why. I always thought they were symmetrical. If they're not, do they need to be in series with a diode to keep them out of the circuit when current is flowing one direction or the other?

Any other pointers? I haven't added any protection for my outputs yet, but would like to know if I have the basic Hbridge set properly, and also if the chosen resistance values make sense.

Thanks!

There are a couple of things that will need to be fixed before considering part values.

Your diodes are in the wrong place. They will conduct current instead of the motor. You want the diodes in parallel with the MOSFET's, not in series with them.

The MOSFET's on the right side are "upside down". Please try to redraw with +12V at the top and GND at the bottom. Seeing the H-bridge in this "standard form" will make it a lot easier to comment on.

The symbols for your 2N3904 transistors suggest PNP transistors, yet the 2N3904 is an NPN transistor. Please redraw.

The 470uF capacitor should be between +12V and GND. I don't think there's much benefit in putting it in parallel with the motor.

--
Beat707: MIDI drum machine / sequencer / groove-box for Arduino

That's a reasonable first attempt, but there are a couple of things wrong with it, as RuggestCircuits says. You need NPN transistors (not PNP as you have drawn). You don't want diodes across the motor. The body diodes of the MOSFETs will protect against back EMF from the motor.

Here is my suggestion. The N-channel mosfets need to be logic level but the P-channel mosfets don't. The diodes offer some protection against driving both Arduino pins high at the same time, which is something you should avoid.

For some reason, search isn't easily finding my previous post on this topic, so I created a new one.

Are these what you can't find? Just click on your name, go to the bottom of the page, and select the see previous post to see all your previous post.

Thanks zoomkat, didn't realize i could find my own posts in that way. Yes, the hbridge topic is what I was looking for, to link out to the transistors.

N Channel MOSFET: http://www.irf.com/product-info/datasheets/data/irlb8748pbf.pdf
P Channel MOSFET: Intelligent Power and Sensing Technologies | onsemi
NPN Driver for P Channel: Intelligent Power and Sensing Technologies | onsemi

dc42, yes, I have a logic level N Channel and a non-logic level P Channel, with a small NPN driver. I think I got that idea from you originally.

All, I have switched the diodes around and swapped out the transistor symbols for the correct one. That was causing some confusion with respect to which pins to connect to what!

How's this looking? I'm finding it difficult to "swap" the schematic as that would make lots of round the world routing of leads. Hope some comments can still be made in this format.

dc, your design looks very elegant -

  1. The 470uf cap across the motor is a bad idea, it will cause big current surges. Connect a 470uF cap across the 12v supply instead (from the source pins of the P-channel mosfets to the source pins of the n-channel mosfets). Likewise the 0.1uF cap.

  2. The 4 diodes are not needed, there are already better diodes built into the mosfets.

  3. 10k for the resistors connected to the collectors of the NPN transistors is too high. When the transistor switches off, the gate charge of the P-channel mosfet has to bleed through this resistor. The lower the resistor, the faster it bleeds, the faster the mosfet switches off and the cooler it runs. I suggest 1k or 470 ohms. You will need to reduce the base resistors in proportion.

  4. You can omit the 100 ohm resistors on the gates of the P-channel mosfets if the NPN transistors have a high peak current capability, such as the BC337 type that I use.

  5. As the circuit stands, you will fry the mosfets instantly if you accidentally make both Arduino pins high at the same time. That is why I added the 2 diodes (1N4148 or similar) in my design. You could also consider adding a fuse of some sort to the +12v supply.

OK, here's another version - hope I can get some comments.

I paid attention to the comments from the last version, hopefully this one's getting closer:

A couple of questions -

  1. Do I need to have a resistor to ground from the logic level N Channel Mosfets (lower left and upper right)?
  2. Have I placed the diodes correctly? I think as drawn they will prohibit current from flowing from +12 directly to ground i.e. short if both Arduino outputs mistakenly are high at once.
  3. dc, you mentioned I would need to reduce the resistance of the gate to +12v to speed the bleed of charge from the P Channel when turned off, which is done. Then you said the base resistor would need to be reduced in proportion. I assume you mean the base to the little NPNs. As I look at it, I'm not really sure what the relationship between those two resistors might be. It seems like the pull up on the P Channel is only in effect when the transistor is off.

Cheers -

Hi again,

You've got the 1n4148 diodes in the wrong place. See the schematic I posted in reply #2 for the correct placement.

The 47k base resistors driving the 2n3904 transistors are too high, now that the collector resistors are 470 ohm. You need to supply enough base current to the transistors to ensure they draw enough collector current through the 470 ohm resistors to pull the collectors (and hence the gates of the p-channel mosfets) to near ground. I suggest reducing the base resistors to 2k2.

I wouldn't put 0.1uF across the motor, it will lead to large current surges in the mosfet (and in that capacitor). If you really want to put a capacitor across the motor, make it much smaller, e.g. 1nF. I don't think you need it at all, because the mosfet body diodes and the capacitors across the 12v supply will absorb any back emf produced by the motor.

You don't need resistors from the gates of the n-channel mosfets to ground, because the base resistors connected to the npn transistors will serve to keep the gates low until the Arduino pins are configured as outputs.