Sanity check - FET H-Bridge circuit - Page 1
Forum section: electronics / beginners

author: danners430
author_rank: Regular Contributor
timestamp: September 12, 2018, 09:56:46 am
content: Hey folks,Can I just ask for a quick sanity check - I've never worked with H-Bridges before, and have found it easier to simply construct my own instead of using driver ICs. This circuit I designed with shoot-through mitigation in mind, the 250r resistor effectively limiting the shoot-through current to 20mA (in theory), which is easily manageable. Does this make sense, or should I stick to having individual control over the FETs?Just for info, all FETs are enhancement mode, and VCC is 5V.Cheers

author: Alex Nikitin
author_rank: Super Contributor
timestamp: September 12, 2018, 10:08:30 am
content: Hmm, how much current do you need for the motor to operate?CheersAlex

author: danners430
author_rank: Regular Contributor
timestamp: September 12, 2018, 10:15:12 am
content: The motor is just there as a placeholder for now :-) it's easier to identify than the bi-colour LED that will actually take its place :-)There will be a variety of this that will power a motor (25mA at 16V), but for that I'll get rid of the resistors and go back to directly driving each FET from 4 GPIO pins, and programmatically eliminating shoot-through by adding a few milliseconds delay between switching the P-Channel FETs off and switching the N-Channel FETs on :-)

author: exe
author_rank: Unknown
timestamp: September 12, 2018, 10:19:43 am
content: Why not using an IC which would significantly lower BOM, protect from short-through and easier to control (with one or two pins, one for enable/disable, another one could "direction")?

author: danners430
author_rank: Regular Contributor
timestamp: September 12, 2018, 10:22:35 am
content: I've had a look, and honestly the only advantage seems to be PCB space... the main problem is that the motor is a point motor for a model railway, which is switched simply by reversing the current flow - I'm not 100% sure whether a traditional motor control IC would work - although I'm very open to suggestions!If an IC would work, does anyone have any suggestions for what to look for? there's a confusing number of different types and ratings out there!Cheers :-)

author: Circlotron
author_rank: Super Contributor
timestamp: September 12, 2018, 10:44:40 am
content: Just make your H-bridge out of a single relay with two sets of changeover contacts and a single mosfet at the bottom for on/off and so you can PWM it if you like.

author: danners430
author_rank: Regular Contributor
timestamp: September 12, 2018, 10:48:29 am
content: Don't relays use up power when constantly turned on? For the motor, it's essentially gonna be 50% of the time on, and 50% off... wouldn't FETs use less power?Only reason I'm concerned with power is because this is going on a model railway, which is designed to be portable - all the power is getting rectified from the main DCC supply for the trains, and that's got a limit on how much current can be supplied.

author: NivagSwerdna
author_rank: Super Contributor
timestamp: September 12, 2018, 12:28:27 pm
content: Quote from: danners430 on September 12, 2018, 10:48:29 amLatching relays don't. They are fun things. (They do have a reasonable cost though due to their mechanical nature)

author: danners430
author_rank: Regular Contributor
timestamp: September 12, 2018, 12:31:09 pm
content: Quote from: NivagSwerdna on September 12, 2018, 12:28:27 pmOooh...Uh oh, NivagSwerdna, you have just committed a cardinal sin... You've piqued my curiosity, and that's never a good thing... I'd advise running for cover at the earliest opportunityI'll have a look just now though, that does seem like a good solution... in terms of cost though, would a single latching relay be cheaper than an H-Bridge? I am looking to make a large number of these sometime in the future, so cost would be a factor :-)

author: NivagSwerdna
author_rank: Super Contributor
timestamp: September 12, 2018, 12:35:43 pm
content: Quote from: danners430 on September 12, 2018, 12:31:09 pmHa!I've used one for a circuit that consumes zero power in standby (starts when latched on, and turns itself off).... there was probably a better way (e.g. Iq < self-discharge rate of cells) but it worked.

author: danners430
author_rank: Regular Contributor
timestamp: September 12, 2018, 01:14:05 pm
content: Hey guys,I've done a bit of research, and a normal relay only draws 2 LEDs worth of power - I can survive that :-) I'll use that for the motor, but would still like to use an H-Bridge for the LEDs - if nothing else to gain experience using them. To go back to my original question, would that circuit work in limiting shoot-through currents, while controlling a bi-colour LED (in place of the motor) with only a single I/O pin (if I replaced two FETs with depletion mode devices)?

author: Kjelt
author_rank: Super Contributor
timestamp: September 12, 2018, 01:21:16 pm
content: A normal relay has an activating current (usually the nominal Voltage / coil resistance) and a holding current ( a lot less than the activating current).Now the trick is to experimentally find out the holding current and add a safe margin on top and keep it at that value after activation.In the 90s Elektor had a clever schematic for it in one of their summer issues , using just two transistors but I can not find/remember it, if anyone has it please post it.

author: exe
author_rank: Unknown
timestamp: September 12, 2018, 01:24:30 pm
content: Quote from: danners430 on September 12, 2018, 01:14:05 pmUhm, it may work. But what depletion fets do you keep in mind? Are you sure they are easy to buy? The world is ruled by "normal" mosfets, exotic devices are not widely on sale...I'd say a common approach is to use only jelly bean parts unless absolutely needed. But for fun and experiments I think any parts is fine.

author: danners430
author_rank: Regular Contributor
timestamp: September 12, 2018, 01:34:20 pm
content: Quote from: exe on September 12, 2018, 01:24:30 pmOK, you got me... just checked after seeing your post, and I can't see any P-channel FETs out there :-( I suppose I could always use a PNP transistor to "invert" the gate voltage... or, of course, a traditional NOT gate...

author: exe
author_rank: Unknown
timestamp: September 12, 2018, 02:28:54 pm
content: Quote from: danners430 on September 12, 2018, 01:34:20 pmYep, this whitepaper says "P-channel depletion mode devices are not generally available":https://www.aldinc.com/pdf/IntroDepletionModeMOSFET.pdf.Concerning inverting, etc, I think it's a viable solution. All four mosfets would be identical which is nice. Or, may be, you can just use a bridge with mixed P-channel and N-channel mosfets? So, they will open at oposite input levels (but please check, I can be wrong).

author: danners430
author_rank: Regular Contributor
timestamp: September 12, 2018, 02:51:28 pm
content: Quote from: exe on September 12, 2018, 02:28:54 pmI think you may be wrong (but it could also be me!) - from my perspective, an H-Bridge would always need 2 P-Channel and 2 N-Channel devices - the P-channels to source the current, and the N-channels to sink the current... but at the same time, I was under the impression that all enhancement mode FETs were normally-off, with V+ "switching" the device "on"...

author: Alex Nikitin
author_rank: Super Contributor
timestamp: September 12, 2018, 03:06:34 pm
content: If you have a somewhat higher voltage available, here is a very simple bridge circuit, safe to operate. The choice of MOSFETs / diodes is up to you, the IRL530N and MBR1100 are used only as an example, many other devices would be suitable.CheersAlex

author: Zero999
author_rank: Super Contributor
timestamp: September 12, 2018, 03:09:12 pm
content: Depletion mode MOSFETs would be no good anyway. The P-channel devices, on the top would need a higher voltage, than the motor supply to turn off and the N-channel devices, would need a negative voltage to turn off.I doubt 25mA would be enough to power a motor. If that's all you need, you're better off just using the IO pin of the MCU directly or a logic buffer, such as the 74AC240.http://www.mouser.com/ds/2/149/74ACT240-888464.pdf

author: danners430
author_rank: Regular Contributor
timestamp: September 12, 2018, 03:27:29 pm
content: Quote from: Hero999 on September 12, 2018, 03:09:12 pmBelieve it or not, 25mA was the figure I was quoted by DCC Concepts when asking them... however, they also say that current increases as voltage increases... hang on!?At the same time, however, I can't afford to drive anything directly from the MCU pins, as the MCU I'm using can only supply a total of 20mA per pin, and 70mA total for the whole device. I still need to be able to drive a whole host of other devices, so I'd risk going over the power limit.However, some of the products from DCC Concepts use a higher current, sometimes as high as 75mA and above, and sometimes it's necessary to connect multiple devices together, hence my preference for FET drivers.Quote from: Alex Nikitin on September 12, 2018, 03:06:34 pmThe motor would be driven off a rectified 16V supply, but the LEDs will be driven by the 5V supply, as I really want to minimize the "spread" of the higher voltage over my PCB... but it could work.Also, I'm afraid you'd have to explain that circuit... I can't seem to fathom how it works!

author: Zero999
author_rank: Super Contributor
timestamp: September 12, 2018, 03:34:26 pm
content: The problem with a series resistor is the voltage drop. You have a 250R, so the maximum current your circuit can supply into a short circuit at 5V is 20mA. When the voltage across the load is 2.5V it can deliver just 10mA.

author: danners430
author_rank: Regular Contributor
timestamp: September 12, 2018, 03:38:05 pm
content: Quote from: Hero999 on September 12, 2018, 03:34:26 pmThe series resistor would be necessary anyway for a bi-colour LED - I always go on the safe side, and say 20mA, no voltage drop. I never need LEDs that are uber bright anyway :-)I'm not sure where you got 2.5V from....Finally, when I use it for an actual motor, I'll eliminate the resistors, and simply drive all four outputs directly from the MCU, or use the circuit posted by Alex earlier... if I can work out how it works :-)

author: Alex Nikitin
author_rank: Super Contributor
timestamp: September 12, 2018, 04:01:10 pm
content: Quote from: danners430 on September 12, 2018, 03:38:05 pmIs it that difficult? If both inputs are at 0V, M2 and M4 are conducting and on both sides of the load voltage is close to 5V. If, say, the input 1 is at 3-5V, M1 is conducting, at the same time M2 is switched off, as the voltage on the gate is close to 0. The load current goes from +5V supply through M4, R load, D1 and M1 to ground. If the input 2 is at 3-5V, the current in the load goes in the opposite direction through M2, R load, D2 and M3. If both inputs are at 3-5V, M2 and M4 are off and no current goes through them or the load, so the circuit is safe if you drive both inputs high.CheersAlex

author: T3sl4co1l
author_rank: Super Contributor
timestamp: September 12, 2018, 07:20:19 pm
content: No one has so far noticed(?) that the P-channel transistors are upside-down.H-bridge is perfectly fine with all N-channel, you just need a bootstrap driver. These are particularly abundant for low supply voltages like this.You can even get drivers with dead-time protection built in, so that you can drive each side of the H-bridge as a logic inverter and not worry about shoot-through.Tim

author: boB
author_rank: Frequent Contributor
timestamp: September 12, 2018, 07:45:54 pm
content: If Vcc is only 5 volts and you are just driving a Bi-color LED, why not just use a TTL logic gate of some sort ?Then just one limiting resistor and now worry about shoot through.Could make use of a hex inverter (eg. 74HC14) and would also include the extra inverters to drivethe opposite side inputs. OR, almost any 4 gate TTL chip for control of the LED.boB

author: max_torque
author_rank: Super Contributor
timestamp: September 12, 2018, 07:59:57 pm
content: in this day and age, i have NO IDEA why you'd want to roll your own H bridge, other than for personal learning reasons?You can buy lots of smart H bridge IC in lots of different voltage and current flavours, and they have lots of safety, diagnostics and feedback built into them, and are fully proven and certified.ie :http://www.infineon.com/cms/en/product/power/motor-control-ics/intelligent-motor-control-ics/The only reason not to use one i can think of is because you want to save every last $ from your BOM, and are happy to spend many $$ during development to roll your own solution. (and even then, you'll still find it hard to get to any significantly lower cost with a much larger BOM parts count)

author: exe
author_rank: Unknown
timestamp: September 12, 2018, 08:19:00 pm
content: Another question is why bi-color LED requires inverting voltage across it. Never seen such.Also, not all LEDs sustain reverse voltage. Some break down at around 5V. Worse yet, most datasheets don't provide such information.

author: danners430
author_rank: Regular Contributor
timestamp: September 12, 2018, 11:02:01 pm
content: Quote from: exe on September 12, 2018, 08:19:00 pmLook up any 2 lead bi-colour LED :-) it's literally how they're designed to be operated.I'm really wanting to use the H-Bridge to learn about them; aye, I could go with driver ICs etc, but I'm on a learning curve and would prefer to learn how things operate before using ICs for everything. For example up until now I've gone with transistor outputs for every LED channel, and it's only now I'm using a multiplex IC to drive them instead :-)Sent from my ONEPLUS A3003 using Tapatalk