Custom H Bridge Design

The tricky part of the design is getting the high-side driver to 'float' with the output signal (which might be a 24V, 50V or whatever switching waveform) AND have it controlled from some circuitry at ground potential. Typically current-control (or opto isolation) is used.

The h-bridge in the below schematic is an interesting design.

http://www.openservo.com/moin.cgi/Schematic2

Ok. I managed to get a look at Intermediate Robot Building by Robert Cook, which I looked at following this article:

There was alot of good information in the book.

What put me off the P-types was the fact their gate voltage was listed as negative. That made me think you required a negative voltage at the gate and so i though i'd require an inverting mosfet driver. But I realise now that wouldn't be necessary.

If I used the two P-type Mosfets I mentioned earlier on the high side, and the two low N-types on the low side I should (according to the book) be able to use a MIC4426.

I use 2 resistors in the logic lines. Rugged you suggested using 2k2 ohm resistors, any reasons why so high? I'm assuming this is to automatically tie down the inputs and so set the initial state of the h driver. The two high side mosfets are initially closed (i.e. on). Supplying a voltage to them will turn them off. The opposite is true of the N-type. To prevent shoot through (essentially a short circuit) I have to make sure there's a suitable delay between opening and closing each side of the driver.

If i use one MIC4426 chip, and tie the highside and lowside inputs together for the left and right side of the bridge, according to Mr Cook, there will be a brief period of shoot through as the Ptype turns off and the Ntype comes online. This is only a real problem, however, if I'm making use of PWM. (I think that's what Mark was trying to explain?).

I'll post a revised schematic later tonight.

Anyone have any ideas how much current a standard breadboard can handle :P?

The protection resistor is meant to protect the Arduino pin being fried if full motor voltage reaches the other end. At the Arduino end that current will flow through the pin's protection diode - too much current and that diode will fry. 2k2 is a guestimate, datasheet may give you enough info.

Don't they also act as pull down resistors? They prevent the gates of the Mosfets from floating and becoming unpredictable, keeping them off/on until the micro controller 'wakes up' and can set the appropriate voltages??

sigh

3rd time I've written this post...

I finally got around to breadboarding the H bridge today. It works! I tested it using 3x 1.5v batteries for logic control, taking terminals from the power/ground rails. Used P types for the high side and N types for the lowside. I've attached a picture (note the DS0026 and resistors aren't connected).

I was hoping to use the DS0026 and test with the arduino today but I don't have the software on these computers. I'll hopefully be able to do that tomorrow. I need to buy some more mosfet drivers anyway, as the DS0026 is obsolete, and was thinking that this would be a good replacement:

http://docs-europe.electrocomponents.com/webdocs/0d0d/0900766b80d0d8a8.pdf

Lowside, 1.5A Peak Current, Non inverting. Good choice to drive the mosfets you think?

I think the diodes I'm using for the h-bridge are a bit too beefy. Their forward current rating is 7.5A. I chose them because, as the motors are likely to draw 5~6.5A, I thought 7.5A rated diodes would be a safe choice. But it's occured to me that, as the diodes are in place to prevent back emf from the motors, it may be possible to use lower rated (and therefore, cheaper) diodes for this purpose? I've attached the datasheet for the diodes I'm using at present. Any feedback on this would be brilliant.

I'm looking to get PCB boards made up for the motor driver circuits. Any general advice to follow / pot holes to avoid on this one? I've made the track widths as large as possible to accomodate the high current draw.

Cheers folks.

7.5A diode.pdf (134 KB)

AUV_140x75_small (PCB).pdf (5.86 KB)

Why not just use the arduino to drive 4 pins in various configurations?

Because one day, probably the first time you run the code, you'll get the order of digital writes wrong and poof :slight_smile:


Rob

Ha, yeah, true.

Any information with regards to my latest questions chaps? If all looks good I'm going to order the rest of my components tomorrow.

Jesus.

Tried to power the motors using a 12v lead acid battery and do the H bridge logic using 3 x 1.5v batteries.

2 of my mosfets melted :stuck_out_tongue: The p and n types on the right hand side of the bridge...

And so the fun starts...!

Probably because I don't think you can turn the p-channels off with 12v on the source and 4.5 on the gate. So they were always on and then at some point you also turned on the n-channels and the electrons hit warp 9.

Even when you start using logic or the Arduino you'll have to level shift the p-channel's gate signal with another transistor AFIAK. Or get the special ones with the internal charge pump.

BTW the above is why I counseled against using 4 pins from an Arduino with no logic, it's only a matter of time before things go poof.


Rob

I had a think about what happened to my bridge as I drowned my sorrows over a few lunchtime pints.

I thought it must have been a short circuit given it was one side of the bridge that melted. I also think I've damaged the breadboard, as even when I changed out the two dud components, the bridge still wouldn't work. I think i'll rebuild from scratch tomorrow.

Hmm. Would the arduino 5V logic be enough to turn off the p-type if i was using a mosfet driver, such as this:

http://docs-europe.electrocomponents.com/webdocs/0d0d/0900766b80d0d8a8.pdf

That driver should run up to 18V supply and still work from 5V logic input OK. Shame it blew up - you don't appear to have heat sinks on the FETs, this is not good...

I warned earlier about testing with limited current and watching for problems before applying heavy current. A lead acid battery can source huge currents and won't forgive any mistake. Suggest testing with a more modest voltage and current limiting, then if all well increase voltage, then increase the current limit and test again.

A series of 12V car bulbs can be used as current-limiters - 5W for low current, higher wattage (like headlamp bulb) for higher current testing.

Well, originally I tested using a small motor (few milliamps) and ran both the bridge and the logic from the same 4.5V supply. The bridge ran fine on multiple occasions - no indication of overheating of any sort.

I then connected my lead acid to the source of the H bridge and used my 4.5v to simulate logic (although I didn't use a mosfet driver) - and it completely melted one side. If I understand Graynomad correctly the 4.5v was incapable of opening the p-types and so they remained closed, n types opened, short circuit...

Following Graynomads advice earlier, I am now worried that the p-type's won't be responsive if I'm using 5v logic and a 12 supply, and I'll end up frying more mosfets. Do I still require to 'level shift' using a transistor for the P-types, even though I'm using a mosfet driver for the logic?

HBRIDGE SCHEMATIC (Schematic).pdf (17 KB)

I'm not even vaguely a MosFET expert but that's how I understand it. In the same way that you pull the gate to 0v to turn off an n-ch you raise the gate to +V to turn off a p-ch.

Anything less than the V on the gate and it starts to turn on.


Rob

Well, I had a chat with one of the technicians today. Basically, the following diagrams summed up the problem for me and the potential solution.

Fortunately, the mosfet driver I'd chosen will do the job apparently and, as long as I power it from the 12v power rail, will provide the 12v to the mosfets.

He also suggested I add 1 ohm resistors into the gate lines to prevent the mosfets 'ringing'. (no idea what he meant there, but I'll probably do it anyway).

I suppose my remaining question would be regarding the diodes. Do i need diodes of that rating?

I hold my hands up.

I'm beat.

I made up PCB boards, soldered one of the bridges up, put the 12v supply onto the bridge and one of the tracks popped.

The motor wasn't even running. Shorted again. Had the TC4427A in place as well - it should've been in default 'off'.

Don't know what I'm going to do now.

Is there a chance that I damaged the mosfets/diodes when I soldered them?

The source of the "control" FET and therefore the gates of the other two are floating. So the 5v control voltage has no reference, Vgs is not known so who knows what that FET is doing. If it doesn't turn on the other gates are floating as I said and who know what the other FETs will do.

I wish someone who knows more about FETs would step in, but meanwhile I'd pull the gates of the two power FETs down to 0v with a resistor to give that control voltage a reference.

And put a load between the two power FETs, if there's a resistor in there you can measure the voltage across it to see which way the FETs are switched, and you won't blow things if they are both on.

It's too late to think about this any more. See if that makes a difference.


Rob

Thanks for the suggestions Graynomad, but I think I'm going to cut my losses. I've learned alot about the subject area but I just lack knowledge of the overall subject to get it working in time.

Regardless, onto plan b. I've ordered diodes, transistors and resistors, and SPDT relays for making an h bridge that way. I've attached the schematic diagram I'm going to follow and (hopefully) succeed in making.

I'll let you know how it goes.

MotorReverseTransistorRelay.PNG

Did you ever try the h-bridge design in the below post?

I know this is a very old thread, but I've seen it referenced at least once. And there is a bit of this that cries out for clarification/correction.

BrIDo:
Hello folk,

I'm trying to design a custom H bridge to drive my motors.

They draw atleast 6.5 amps, running off a 12v supply.

I keep seeing this particular mistake - it does not matter what the no-load current is, it does not matter if they draw "at least" some current. You want to know the stall current. The current drawn when full voltage is applied and the motor is stalled, not allowed to move. That is the worst case current.

Unless, in a particular configuration, it is possible that the motor may already be moving in the opposite direction. For instance, if you reverse direction without first breaking. Or if it is something that could already start moving and you attempt to reverse direction, like a robot or electric car on an incline.

I watched a friend of mine blow his motor drivers when his R2 replica started rolling backwards down an incline, and he hit Forward instead of braking first. He had bought motor drivers rated for only a bit more than his motor's stall current.