Author Topic: MOSFET driver (push-pull bjt output)  (Read 36900 times)

0 Members and 1 Guest are viewing this topic.

Offline npelovTopic starter

  • Frequent Contributor
  • **
  • Posts: 330
  • Country: bg
    • Microlab.info
Re: MOSFET driver (push-pull bjt output)
« Reply #25 on: October 13, 2016, 05:46:56 pm »
What I'm really worried about is the output of the MCU. It has protection diodes clamping higher voltage to Vdd. I still think it's within spec because clamping diode absolute maximum current is 20mA.

What MCU is that?

PIC12F1501. Yes, I know PICs are quite tough. In fact this pic took Vdd=12V (by mistake of course) from lead acid battery for 5-10 seconds and it's still working fine.


I managed to test the second circuit that Hero999 suggested. Here are the results:
Yellow - input
Cyan - MOSFET gate


This is the original circuit with schottky. I also tried it without schottky - it does delay the back slope (input falling, gate rising):



With 200pF (not 220) cap in parallel with the input resistor. The base resistor is 1.8k - maybe that's why it doesn't make much difference. Rising the capacitance too much overloads the PIC output pin



The third transistor made more difference that I expected:
« Last Edit: October 13, 2016, 05:56:53 pm by npelov »
 

Offline npelovTopic starter

  • Frequent Contributor
  • **
  • Posts: 330
  • Country: bg
    • Microlab.info
Re: MOSFET driver (push-pull bjt output)
« Reply #26 on: October 13, 2016, 06:07:12 pm »
Note that you need to use well-filtered supplies for cap-coupled circuits like this.

You can avoid that by using constant current drive (essentially, the input signal goes to a diff pair, which starts with a constant emitter current, then steers it out one or the other collector), and using those currents to control the turn-on and turn-off transistors local to the MOSFET.

But again, more bias current and more complexity.  Always a tradeoff.  It gets harder and harder to beat an IC. ;)

Tim

I suspect that the supply will jump quite a bit. There will be 220uF low ESR cap on the input, same on the output and 100nF ceramics everywhere. I hope it'll be enough. I would like to avoid continuous currents >=1mA if possible. There will be about 1.5-2 mA from the MCU already. I want it to work even with 18V/1.5W solar cell - 80mA peak, probably 30-50mA  average over the whole day. 3-5mA might not be too much if you have 1A, but if all you have is 50mA then it's something.
 

Offline npelovTopic starter

  • Frequent Contributor
  • **
  • Posts: 330
  • Country: bg
    • Microlab.info
Re: MOSFET driver (push-pull bjt output)
« Reply #27 on: October 13, 2016, 07:16:43 pm »
8.2k on the input doesn't make a difference. Probably the zenner has something to do with it.

Well, this is much worse case than the final design. The transistor for the tests is IRF4905 - a nasty little thing with 3400pF typical input capacitance. The transistor I plan to use in the final design won't have more than 700-1000pF. I might even increase some resistors.

However I must be doing something wrong because if I short the zenner the MOS doesn't turn off. There is 400mV on the collector of input transistor and it doesn't change - it's constantly on. I removed the third transistor and the input cap - same. And I know the circuit should work fine if zener is shorted because I used it before. I reduced the resistor between base of Q1 and Vin to 1k - no effect. I stripped it down to this circuit (except that bottom transistor is BJT), but the MOS doesn't turn off:

« Last Edit: October 13, 2016, 07:18:35 pm by npelov »
 

Offline Zero999

  • Super Contributor
  • ***
  • Posts: 19491
  • Country: gb
  • 0999
Re: MOSFET driver (push-pull bjt output)
« Reply #28 on: October 13, 2016, 08:20:03 pm »
What I'm really worried about is the output of the MCU. It has protection diodes clamping higher voltage to Vdd. I still think it's within spec because clamping diode absolute maximum current is 20mA.

What MCU is that?

PIC12F1501. Yes, I know PICs are quite tough. In fact this pic took Vdd=12V (by mistake of course) from lead acid battery for 5-10 seconds and it's still working fine.
Good, you're lucky all is still well. I wouldn't advise using that same IC, as you applied 12V to, in the real thing because it might be damaged and prone to failure, even though it still works perfectly now.

Quote
With 200pF (not 220) cap in parallel with the input resistor. The base resistor is 1.8k - maybe that's why it doesn't make much difference. Rising the capacitance too much overloads the PIC output pin
Yes, reducing the base resistor will help to speed things up, at the expense of more current being drawn from the MCU's output.


Quote
The third transistor made more difference that I expected:


Notice how the turn on time is still a little sluggish? This is because Q2 (on my schematic) has to charge the MOSFET's gate via D1 and D3. If you have room for another transistor, to pass the current for charging the MOSFET, then it should speed up the on time. LTSpice showed ringing on the waveform after adding the extra transistor (this might not happen in real life) which will be due to the MOSFET's gate inductance so I added a gate resistor: R5.
« Last Edit: October 13, 2016, 08:21:35 pm by Hero999 »
 

Offline Zero999

  • Super Contributor
  • ***
  • Posts: 19491
  • Country: gb
  • 0999
Re: MOSFET driver (push-pull bjt output)
« Reply #29 on: October 14, 2016, 08:20:10 am »
8.2k on the input doesn't make a difference. Probably the zenner has something to do with it.

Well, this is much worse case than the final design. The transistor for the tests is IRF4905 - a nasty little thing with 3400pF typical input capacitance. The transistor I plan to use in the final design won't have more than 700-1000pF. I might even increase some resistors.

However I must be doing something wrong because if I short the zenner the MOS doesn't turn off. There is 400mV on the collector of input transistor and it doesn't change - it's constantly on. I removed the third transistor and the input cap - same. And I know the circuit should work fine if zener is shorted because I used it before. I reduced the resistor between base of Q1 and Vin to 1k - no effect. I stripped it down to this circuit (except that bottom transistor is BJT), but the MOS doesn't turn off:


Perhaps you've destroyed the MOSFET or reversed the source and drain connections so the body diode conducts? Try connecting the source and gate, then checking it doesn't conduct.
 

Offline npelovTopic starter

  • Frequent Contributor
  • **
  • Posts: 330
  • Country: bg
    • Microlab.info
Re: MOSFET driver (push-pull bjt output)
« Reply #30 on: October 14, 2016, 11:31:01 am »
I don't know what was wrong. All the transistors are fine - measured them. There was shortcut or a capacitor I couldn't see - the 200pF capacitors are 0603 gray and the pcb doesn't have soldermask so they are hard to see. I desoldered everything and started from scratch. I switched to IRF9640 which has a bit less gate capacitance - 1200pF typical.

I decided to measure while I'm building it. I added single transistor and 1k resistor on G-S to monitor the fall time. It was >400ns!!!. I switched to PN2222A because of it's current capability but no change (first attachement).
After adding 33pF cap it dropped to 340ns (sorry about the noise - forgot to connect blue probe ground).
330pF - 84ns
200pF - 96 (smd cap)

Although with 200+ cap it drops with 9V for 34ns, so the MOSFET will be hard on for <40nS. However Vpp = 21.40V with 330 cap and 17.6V supply which is just over GS voltage. I need to limit the gate voltage somehow, but zenners want so much current. Most zenners work relatively fine with at least 1mA.
 

Offline Zero999

  • Super Contributor
  • ***
  • Posts: 19491
  • Country: gb
  • 0999
Re: MOSFET driver (push-pull bjt output)
« Reply #31 on: October 14, 2016, 02:22:53 pm »
I don't know what was wrong. All the transistors are fine - measured them. There was shortcut or a capacitor I couldn't see - the 200pF capacitors are 0603 gray and the pcb doesn't have soldermask so they are hard to see. I desoldered everything and started from scratch. I switched to IRF9640 which has a bit less gate capacitance - 1200pF typical.

I decided to measure while I'm building it. I added single transistor and 1k resistor on G-S to monitor the fall time. It was >400ns!!!. I switched to PN2222A because of it's current capability but no change (first attachement).
After adding 33pF cap it dropped to 340ns (sorry about the noise - forgot to connect blue probe ground).
330pF - 84ns
200pF - 96 (smd cap)

Although with 200+ cap it drops with 9V for 34ns, so the MOSFET will be hard on for <40nS. However Vpp = 21.40V with 330 cap and 17.6V supply which is just over GS voltage.
Which circuit are you talking about here?

Quote
I need to limit the gate voltage somehow, but zenners want so much current. Most zenners work relatively fine with at least 1mA.
I hope you realise that the zener doesn't have to continuously conduct. It's just there to clamp the voltage to a safe level.

Take the attached circuit for example. Q1, R1 & R2 form a common emitter amplifier. Ignoring the loading effects and C1 (assume a steady state), the voltage across R2 is approximately equal to: (V2 - Vbe)*R2/R1

Vbe is the transistor's base emitter voltage, typically 0.6V, so with 5V from V2:
V(R2) = (5-0.6)*10/4.7 = 9.4V.

Regardless of V1, when V2 = 5V, the gate voltage to the MOSFET will be 9.4V. The current through R1 (therefore R2 as well) is about (5-Vbe)/4700 = 450µA, which is much less than your requirements. Of course 9.4V is too low for D2 to conduct so it does nothing at this point.

Unfortunately with only 450µA driving Q1 & Q2, the current into the MOSFET will still be too low (45mA at most) to charge/discharge the gate quickly. This is why we have C1. When V2 suddenly changes from 0V to 5V, C1 will be at 0V and as it charges there will be a current surge, causing close to the full supply voltage to be applied across R2, which will be clamped to 15V by D2. The current will fall as C1 is charged towards 4.4V and D1 will stop conducting. Now if V2 is held at 5V, the current through R1 & R2 will remain at 450µA.

Note for this to work, D2 needs to have a low capacitance, so should be a small zener diode. If it slows the circuit down too much then you can put it across the MOSFETs gate and source but it will pass much more current and dissipate more power. You may be able to get away with omitting the zenner if C1 is reduced or the MOSFET has a high capacitance because charging up the gate will reduce the voltage surge.
« Last Edit: October 14, 2016, 02:24:26 pm by Hero999 »
 

Offline npelovTopic starter

  • Frequent Contributor
  • **
  • Posts: 330
  • Country: bg
    • Microlab.info
Re: MOSFET driver (push-pull bjt output)
« Reply #32 on: October 14, 2016, 08:16:57 pm »
Quote
I need to limit the gate voltage somehow, but zenners want so much current. Most zenners work relatively fine with at least 1mA.
I hope you realise that the zener doesn't have to continuously conduct. It's just there to clamp the voltage to a safe level.

Not really. The mosfet is on all the time, except when battery is fully charged. Then it'll maintain 13.8V. So I only care that current is low on the ON time of the mosfet. If the mosfet starts PWM switching then battery is full and only topping charge is needed. In this case it's ok to waste few mA.


I'll try this one later (in real circuit) because I really want to find a way to drive mosfets in general. Most drivers that are locally available are  limited to 20V. There is one at 30V which is still not enough for 36V solar panel (I want to try to do MPPT later).

 For now I'm satisfied with the results that 3 transistor schematic show. I found a low gate charge fet (FDC658AP) that can take 25V on the gate so I'll remove the zenner. I also realized that using 24V solar panel for charging 12V battery is not a good idea using PWM charger. It needs some DC-DC conversion to not waste so much power (MPPT). The 18V panel has open circuit voltage 20-21V - I can clamp the panel with SMBJ20A - max clamping voltage 24.5, working voltage 20V and low leakage current of 1uA.
I also realize that in this case voltage of solar panel will drop down to battery voltage and the whole circuit will work between 11 and 14V most of the time.

Also rise and fall time is only important in the region between 1 and 10V. Well let's say 0.8V for some logic level mosfets. After 10V the ON-resistance change is very little.


Btw you mentioned that smaller zenners have lower capacitance. Do you mean low power zenners - like 200mW?


Also about the latest circuit. Zenner capacitance can be compensated by rizing C1. Also BC557 has quite large beta. 1k is not needed for R3. The circuit works fine with 10k. It'll actually help reducing the effect of zenner capacitance - at least according to emulation. I added 50pF in parallel with the zenner. If you have1k for R3 the gate voltage quickly falls to 16.9V(GS = -6.6V) and then slowly goes to 15.2(GS=-8.3V). If you have 10k for R3 the fast drop is to 16.1V (GS=-7.4V) - almost a volt more. I have no idea why this is happening. Maybe because input current is split between C1 and C2 when input voltage rises. Rising R3 allows more current to turn Q1 harder.
 

Offline Zero999

  • Super Contributor
  • ***
  • Posts: 19491
  • Country: gb
  • 0999
Re: MOSFET driver (push-pull bjt output)
« Reply #33 on: October 14, 2016, 10:57:08 pm »
Yes, I meant low power, when I talked about small zeners.

I haven't really thought about the other things you've mentioned because I don't have time at the moment.
 

Offline npelovTopic starter

  • Frequent Contributor
  • **
  • Posts: 330
  • Country: bg
    • Microlab.info
Re: MOSFET driver (push-pull bjt output)
« Reply #34 on: October 15, 2016, 09:34:13 am »
Well thanks for your help. I got what I needed - a working schematic and understanding how it works.
 

Offline julian1

  • Frequent Contributor
  • **
  • Posts: 731
  • Country: au
Re: MOSFET driver (push-pull bjt output)
« Reply #35 on: April 07, 2017, 07:51:00 pm »
 
An example from my collection:


 

What is the quiescent current, with the 47ohm and two-diode voltage drop?

And is there an easy approximate calculation?

Is there any advantage to do this versus a current mirror (eg. two transistors + one resistor) like current source?
 

Offline T3sl4co1l

  • Super Contributor
  • ***
  • Posts: 21657
  • Country: us
  • Expert, Analog Electronics, PCB Layout, EMC
    • Seven Transistor Labs
Re: MOSFET driver (push-pull bjt output)
« Reply #36 on: April 08, 2017, 06:10:40 pm »
At 9V,

V(10k) = (9V - 2 * (0.7V)) = 7.6V
I(10k) = 7.6V / 10k = 0.76mA
V(47) = 2 * (0.7V) - (0.7V) = 0.7V
I(47) = 0.7V / 47 = 14.9mA

So the total is 15.6mA when "In" is active, and 0.76mA when not.

"In" should be driven by a Thevenin equivalent source of about 1.4V/0V (on/off), and 1kohm.  Usually this is arranged with a current sourcing output and B-E resistor, or a higher voltage (logic) source with a voltage divider.

You could also use a small MOSFET (smaller than 2N7000, which is huge and slow) instead of 2N3904, for direct logic level interface (say, anything from 1.8V to 5V CMOS and TTL).

Tim
Seven Transistor Labs, LLC
Electronic design, from concept to prototype.
Bringing a project to life?  Send me a message!
 
The following users thanked this post: julian1


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf