Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

H-Bridge

Status
Not open for further replies.
I am a bit confused still about the use of resistors in a circuit and their effect on one another. This time I'm not quite certain of how resistors R24 (470 Ohm) and R35 (5K6 Ohm) are working together. The moment the opto output is on and Q27 is high and therefore has a base -emitter path, don't they form a parallel circuit? Or to put it another way, how much current is being applied to the base of Q27?

Hi kal,

Once again, being confused, as you put it, is a good thing (not meant to be condescending). The reason: R35 (5K6) and R24 (470R) do not do anything in terms of the basic function of the circuit at DC and are really a nuisance, especially R24. So, why are they there?

(1) R24 is only there for protection:
(1.1) if the current transfer ratio (CTR) of the particular 4N25 fitted is very high, R24 limits IE from the opto receiving transistor (OTR) to around 24V/470 mA. That current is on the high side, but I did not want to make R24 to big as it slows Q27 turn off.
(1.2) Also R24 limits the current, as mentioned for previous circuits, in the case of extraordinary events.

(2) R35 serves two purposes:
(2.1) R35 makes sure that any leakage current (dark current) from the ORT does not turn Q27 on
(2.2) R35 provides a discharge path to 0V for the voltages stored on the parasitic capacitances, both real and virtual, at the base of Q27. Without R35, Q27 would turn on faster, but it would take an age to turn off. The ORT would also take an age to turn off. In fact, in the interests of speed it would be good to make R35 as low as possible: 100R would be ideal, but 5K6 is as low as I could go and still have the ORT drive Q27 sufficiently, in the case of a low CTR 4N25.

(3) Speed
As you intend to switch the motor on and off at relatively high frequencies, speed become an important aspect of the design. Specifically, in this application, how fast the transistors and optocoupler will turn on and off.

(3.1) Optocoupler
While on the subject of speed, the 4N25 optocoupler, although an industry standard, is fairly slow. Had I been fully aware of the speed requirements I would have probably specified the much faster HCPL4562 optocoupler, even though it is more expensive (£2.50 UK). Incidentally, operating an optocoupler ORT in common collector configuration, as in the present circuits, is faster than common emitter.

HCPL4526 Data Sheet: https://www.avagotech.com/docs/AV02-1361EN

(3.2) Logic Gate
The latest circuit of post #40, with the logic gate in the micro side, is much, much faster and better characterized than saturating transistors and is thus the recommended approach. Arguably, it is also the simpler approach.

(3.3) Capacitance
In a nutshell, capacitance generally slows a circuit because capacitors have to be charged and discharged with a current in order to generate a voltage. The lower the capacitance and the higher the available charging/discharging current, the faster the circuit. Incidentally, voltage saturating a transistor collector also slows it. The more excess base current, the longer a BJT takes to turn off.

Even though all the transistors, including MOSFETs, in your circuit are theoretically either on or off, in the finite time when they are transitioning between the two states they are acting as common emitter/source linear amplifiers. While in this transition region, the MOSFETs will be dissipating significant power, so it is important, for efficiency, that the MOSFEts are snapped on and off as rapidly as possible.

What is a parasitic capacitance? There are unintended capacitors, inductors and resistors literally everywhere in the real world. The theoretical schematics that you see, in no way represent the actual physical circuit. This is why simulators can be very misleading if not used carefully. All this may sound complex and, when you get into very high frequencies, it is. But, at frequencies below about 10K Hz (it varies), you can generally ignore parasitics. With a BJT the two most important internal parasitic capacitors are Cbe and Ccb. If you look into the base of a BJT, the input capacitance, is very roughly, Cbe + (A*Ccb), where A is the voltage gain of the BJT in common emitter configuration. How do you know what A is. A BJT has an internal emitter resistor re which roughly = 25/Ic in Ohms, where IC is in mA.

So suppose you had a BC546 configured as a common emitter amplifier with a collector load of 2K2 + 2K2 = 4K4 Ohms and a collector current of 2.73mA, re would be 25/2.73 = 9.16 Ohms. The voltage gain of a common emitter BJT amplifier is RC/re. Thus, the voltage gain would be 4K4/9.16 Ohms = 480 (it would not be quite that high in practice but do not worry about that for the moment). This means that Ccb would appear (virtually) at the base as Ccb * 480. The Ccb of a BC546 would probably be around 10pF. so the virtual base capacitance would be 480 * 10pF= 4.8nF: massive in fact. This multiplying of the the Ccb is known as the Miller effect, after the chap who defined it way back in the valve (tube) days.

In common cathode/emitter/source amplifiers, the Miller effect dominates the input capacitance of the amplifier. Power MOSFETS, with their massive Cdg are quite difficult to use as amplifiers at higher frequencies. For example, a power MOSFET could have a Cdg as high as 500pF.

(4) General Note
As a general note, just be aware of speed issues, but don't let them distract you from your initial objective of fully understanding the basic DC circuit function. Just in case you feel overwhelmed by it all, as I did, be assured that it is not all that complicated, at a working level that is. :happy:
 
Last edited:
Hi again kal:

Here is a faster version of the opto coupled MOSFET H bridge. It uses four optocouplers with built-in MOSFET drivers (link to data sheet below). Once again, this is an off-the-boards design, so look for obvious errors. I couldn't find the actual optocoupler in the EAGLE library so I used the closest, but some of the pin numbers are not correct.

spec

ETO_2016_02_14_Iss02-02_KAL_QUAD_DRIVER_OPTO_LOGIC_H_BRIDGE.png

ERRATA


Optocoupler data sheet:
https://www.mouser.co.uk/ds/2/38/acplk34t-267604.pdf
 
Last edited:
I wasn't able to find the optos locally but I found some nand gates that are not exact but hopefully will work.
I got MM74C00N and MC14012B The first is Motorola but the second I'm not sure of the make but it has the logo like this one here. I got two of each so I can use to of the latter of they're better.
I believe the MC1402B is dual not quad nand gate and they're both CMOS whatever that means. Still reading to find out the difference. Cheap though.
 
Hi spec,

I decided to go with the schematic in post #40 until I can source the ACPL-K34Te opto. I'm leaving the power supply out for now as it won"t fit on the same board anyway.
I will have to supplies as you show on the schematic but both will be 24V.
So I wired the whole thing excluding the power supply to the CMOS and the inputs as I wasn't sure of the current requirement for the CMOS and I'm guessing the pulse and direction inputs will also have to logic level voltage of 5+.
So I'm inclined to put a voltage divider to power up the CMOS and for the inputs I will have a 2K2 for each of them.
Let me know what you think.

Kal
 
Morning from the UK (7am) kal,

Afraid the 74C00N, while it has the correct logic function, does not have enough output sink current capacity. 10mA is required by the transmitting LED in the Avago ACPL-K347 optocoupler. That is just the DC conditions though. To get a fast signal transfer across the optocoupler, you need to hit the transmitting LED hard and fast. Ideally a sink current around 30mA would be good and a source current of around 20 mA. This may sound odd, but the excess current is required to charge and discharge those little buggers, the parasitic capacitors.

The logo that you show is for National Semiconductor, one of the best semiconductor manufacturers who, sadly, were taken over by Texas Instruments in 2011 (Texas are a very good semi company too). You also mention Motorola, another top-line semi manufacturer. Their semi operations were spun-off and renamed ON Semiconductor in 1999.

There are two main logic families: TTL (Transistor Transistor Logic) (74xxx) and CMOS (Complementary Metal Oxide Silicon/Semiconductor) (14xxx). TTL is fast and high power consumption. CMOS is relatively slow and very low power, if it is not switching almost zero power. The other logic family, which is not very common, is Emitter Coupled Logic (ECL) and its close relation PECLE (Positive ECL). This logic family is blindingly fast and chews up current like nobody's business, although PECL is less power hungry. ECL needs a perfect PCB layout, using high-speed strip-line techniques and proper termination. Only real men mess with ECL. :D

The 74xxx family predominated so the 74Cxxx family was brought out which is essentially 14xxx CMOS, but with the same pin out as 74xxx family chips.

The minimum sink current for a 7400 gate is 16mA compared to a sink current of around 1mA for a 74C00 gate.

74xxx logic can be quite confusing, because there are so many variants with different speed and power characteristics: 74CTxxx, 74HC, 74Lxxx, 74ALxxx, 74ALSxx, 74xxx, 74ASxxx, 74Sxxx. The good thing is that, in general, the logic functions, and pin-outs, are all the same, although 74Cxxx and 74xxx will not interoperate. Just to confuse the picture more, the 74CTxxx logic family is designed to operate with 74xxx.

spec

References
https://en.wikipedia.org/wiki/List_of_7400_series_integrated_circuits
https://en.wikipedia.org/wiki/7400_series
 
Last edited:
Good morning spec, I think were posting at the same time.

I will change the CMOS then and look in the morning (our morning) for a TTL chip but I will not be using the ACPL-K347 for this one. I already wired it with transistors but will use the nand gate.

Thanks
Kal
 
Good morning spec, I think were posting at the same time.

I will change the CMOS then and look in the morning (our morning) for a TTL chip but I will not be using the ACPL-K347 for this one. I already wired it with transistors but will use the nand gate.

Thanks
Kal

No worries kal

All good experience- I wish I could have a twidle with some electronic hardware . But no facilities at the moment.:wideyed:

By the way the transistor version of the H bridge circuit will probably be fast enough anyway. It can be speeded up here and there too.

spec
 
Hi spec,

I don't see in the datasheet where it specifies the output current, is it the IOH and IOL ? I was comparing what ICs I found locally to determine if they would work and wasn't sure of what specs to compare.
I found a SN74LS38 by Texas Instruments with IOL of 24mA and another SN74LS00 which has IOL of 16 mA but both of them seem to have loser switching speed than the one you suggested.
Do you think on of them would do a decent enough?

Thanks
Kal
 
Hi spec,

I don't see in the datasheet where it specifies the output current, is it the IOH and IOL ? I was comparing what ICs I found locally to determine if they would work and wasn't sure of what specs to compare.
I found a SN74LS38 by Texas Instruments with IOL of 24mA and another SN74LS00 which has IOL of 16 mA but both of them seem to have loser switching speed than the one you suggested.
Do you think on of them would do a decent enough?

Thanks
Kal

Hi kal,

(1) Yes, IOL is the parameter that you are looking for. In other words, when the output of the gate is low, what is the minimum current that the chip output stage will conduct down to 0V from the 5V rail. Don't connect the output directly to the 5V line though or you will probably blow the chip output transistors. Instead connect a resistor equal to 5V/IOL between the gate output and 5V. So if you had a chip with an IOL of 10 mA, the pull up resistor would be 5V/10mA = 500R.

(2) The 74LS36 has the right logic function and is a good find because having open collector outputs it has many uses, especially interfacing to non TTL level devices. It is always a good move to have a few 74LS38 chips in your parts store.

The only problem with the bridge application is that the 74LS38 output stage would turn the optocoupler LED on fast, but it would not turn the LED off very fast. The reason is that the output is not active high (totem pole) but merely goes open circuit (open collector). This means that the parasitic capacitors around the LED have no discharge route. You could speed up the LED turn off greatly by adding a 470R resistor between the 74LS38 out put and 5V (known as a pull up resistor).

The other thing is that, if you wanted to feed the output of a 74LS38 into the input of another 74xxx gate, you would need to add a pull up resistor between the 74LS38 output and 5V. A pull up resistor value of 1K Ohms would be about right for driving up to a couple of inputs, but any more inputs and the pull up resistor would be best reduced to 470R.

(3) When you say the 74LS00 has an IOL of 16 mA, I think you are looking at the IOL for a 74S00 not a 74LS00 which only has an IOL of 8mA. As far as I know only the 7400 and 74S00 have an IOL of 10mA or greater. One solution is to put two 74LS chips in parallel: connect the two 'a' inputs together and 'b' inputs together and both outputs together, but that is not ideal and it means an extra 74LS chip.

(4) Speed
Yes the 74LSxxx logic family is slower than the 74xxx and much slower than the super fast 74ALSxxx and super, super fast 74Sxxx. But the 74LSxxx logic family should be fast enough for the bridge application.

All the best

spec
 
Last edited:
Hi spec,

I got it **broken link removed**and it's working well (haven't tested for high frequencies). I couldn't find the IC so I did with **broken link removed** and will definitely do the next with the IC and optocouplers. I made a simple power supply **broken link removed** for a 1Amp load with is working fine with the motor not connected to a load. That's do for now and will work and a beefier supply for the next.

Thanks so much.
Kal
 
Hi spec,

I got it **broken link removed**and it's working well (haven't tested for high frequencies). I couldn't find the IC so I did with **broken link removed** and will definitely do the next with the IC and optocouplers. I made a simple power supply **broken link removed** for a 1Amp load with is working fine with the motor not connected to a load. That's do for now and will work and a beefier supply for the next.

Thanks so much.
Kal

Great news kal,

You are an old hand now

Glad all went well

spec
 
Hi spec,

I hope you don't mind me bringing this thread up again.
I'm starting to work on another H-Bridge to drive another motor and would like the control voltage to be independent of the motor voltage (Source-Drain) voltage. The idea is to be able to drive different motors with different voltage rating but with the current and power rating of the H-Bridge.
So the gate of the MOSFET will need to have a path to the drain and I'm guessing that that means I would have to share ground between the two supplies or can I do it like in this **broken link removed**? (this is only half of the schematic the control side is not showing but it will be exactly like yours).

Thanks
Kal
 
Hi spec,

I hope you don't mind me bringing this thread up again.
I'm starting to work on another H-Bridge to drive another motor and would like the control voltage to be independent of the motor voltage (Source-Drain) voltage. The idea is to be able to drive different motors with different voltage rating but with the current and power rating of the H-Bridge.
So the gate of the MOSFET will need to have a path to the drain and I'm guessing that that means I would have to share ground between the two supplies or can I do it like in this **broken link removed**? (this is only half of the schematic the control side is not showing but it will be exactly like yours).

Thanks
Kal

Hy kal,

I don't mind in the least- it would be a very odd situation for me to mind about discussing electronics. :happy:

I understand that you want to dive a motor with a different V/I characteristic, but I can't quite understand your approach. My thought in the example you showed is why not just change the supply line from 24V to 20V and call it a day. I'm pretty sure that the original circuit will work fine, although, from a purist point of view, a few resistor values should be adjusted here and there.

If you needed a bridge circuit to operate over a wider range of voltages, the design could be changed from ratio-metric to absolute without too much bother. Just let me know if that is what you want and I will look into it.

But to answer your question about the posted circuit: afraid no, it will not work. As you say, it needs a common 0V line between the 24V (0V) supply line and the 20V (0V) supply line, plus two other mods. Here is what needs to be done:
(1) Connect 0V (24V) to 0V (20V)
(2) Remove R13 top from 24V line and connect R13 top to 20V line
(3) Remove R11 top from 24V line and connect R11 top to 20V line

Cheers

spec
 
Last edited:
Thanks a lot.


Unfortunately I have have so many schematics going at the sa time Iposted the wrong one again. But to answer your question I have a 36VDC motor that I'd like to run and I though why not design a circuit to handle multi voltage. So I wanted to h h drain-source of t MOSFETS independent of their gates so that I I still use the rest of you circuit a is.


Cheers
Kal
 
Hi kal,
Just to clarify, can you point exactly to the one of my circuits you are discussing and then I will have a go at making it multi voltage.
It needs to be one of my circuits, because then I can work on it in Eagle without too much fuss.
Cheers,
spec
 
Hi spec,

I was having problems posting with my Blackberry , I had to get to my PC.

I was referring to the one in post #40. I'm still learning to use Eagle and it takes me forever to draw the schematic. The way I understand how MOSFETS work is that they need gate-drain current (gate voltage) to tun on the drain source current.
My thinking is to have the gate supply voltage separate from the drain-soruce.

Thanks
 
Hy kal,

I was referring to the one at post #40.

OK will have a think about circuit at post #40

I'm still learning to use Eagle and it takes me forever to draw the schematic.

Hmm, EAGLE circuit capture is dead easy, although the component libraries are a mess. EAGLE is by far one of the easiest in my experience and I have used/evaluated a number of ECAD systems. Some of the more advanced/expensive packages are a pig because it takes an age to set them up. Mind you once you get that done and have gained some miles, they are very powerful and accurate, especially the error checking and digital sim. EAGLE 7.5 is better to use than 7.4 but the user interface symbols are pants.

The way I understand how MOSFETS work is that they need gate-drain current (gate voltage) to tun on the drain source current.

That is not correct kal. The drain source current is proportional to gate drain voltage. No current flows into the gate. In fact, there is a layer of highly insulating silicon compound between the gate and the silicon channel (silicon between the drain and source).

One complication about driving the gate of a MOSFET are the massive parasitic capacitances. This means that, at DC and very low frequencies, you can control a MOSFET gate with a voltage with a very high source impedance, say 1M Ohm. But for any higher frequencies you need a lot of current to charge up and down the parasitic capacitors so you need a low impedance voltage source to drive the gate.
 
Last edited:
I have two problems with it, one I can't find the components and two I still can't figure out simulation. But I have to say I haven't spent enough time on it to get a good handle.
 
I have two problems with it, one I can't find the components and two I still can't figure out simulation. But I have to say I haven't spent enough time on it to get a good handle.
Fist I would suggest that you forget everything, except circuit capture (drawing a circuit in EAGLE) to get started. That is as far as I have got.

Yes, getting components is confusing initially. The first thing to do is to configure a new project sheet (xxx.sch) and open it. Then go to Library> Use. You will see a list of component folders in the left hand column. lclk on the first folder at the top. Then select all the component folders by scrolling down the folder list and press and hold the shift key and then lclk on the last folder at the bottom left. Relese the shift key. Once all the component folders are highlighted, lclk OK at bottom right. You will have then loaded the whole component library into your project sheet and all of the components will be available to that project sheet. Before you do this none of the components in the library will be available to place on your project sheet.

To put a component symbol on your project sheet, lclck on the 'add' icon (DRAW> Add) on the toolbar on the top left of the project page screen. The same list of component folders will open again. lclk a folder and you will be presented with a list of all the components in that folder. lclk on any component and it will be shown in a box top right. lclk OK, bottom right and your component will be on the end of the mouse cursor in the project sheet. Move the component to the position required and lclck and you component will be placed on your schematic. You can continue moving the cursor and lclking and placing the same component type as many times as you like. When you have finished placing the components, press escape and you will be returned to the library window and can select another component, but if you wish to exit the component library, press escape again to close the library window and return to the project sheet.

The component library is an absolute shambles- there is no other way to put it. The best solution is to put commonly used components at the top edge of your drawing sheet blank so that you can quickly copy them without bothering with the library. One day I may produce a custom rationalised library of the most common parts.

One thing worth doing is to change the grid from 0.1 inch to 0.05 inch. Don't be tempted to use a mm grid as this can cause all sorts of problems, I understand.

spec
 
Last edited:
That is not correct kal. The drain source current is proportional to gate drain voltage. No current flows into the gate. In fact, there is a layer of highly insulating silicon compound between the gate and the silicon channel (silicon between the drain and source).

One complication about driving the gate of a MOSFET are the massive parasitic capacitances. This means that, at DC and very low frequencies, you can control a MOSFET gate with a voltage with a very high source impedance, say 1M Ohm. But for any higher frequencies you need a lot of current to charge up and down the parasitic capacitors so you need a low impedance voltage source to drive the gate.


You mean a potential difference between gate and drain? I see, it's coming back to me now how you explained it before.
So if I have 36V at the drain of Q22 there will be two scenarios for its gate, The first is when Q26 is low there will be 24 volt and 36-24=12 which means the Q22 will be turned on and current will be conducting through drain-source. The second scenario is when Q26 is high, there will be 12V at Q22 gate and 36-12=24 which means it will be on even harder (or may be exceeding its limit, I have to look at the datasheet).

Well, back to the drawing board :D
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top