Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Driving higher voltages with p-type MOSFET

51 views
Skip to first unread message

eroml...@att.net

unread,
Aug 20, 2012, 10:16:13 PM8/20/12
to
Hi guys:

I'd like to control a 24Vdc load by sourcing with a p-type power MOSFET. I'm driving the gate directly from a mictrocontroller that uses +5 and ground. The problem is that I need +24 and +19. I looked into "high voltage level translators", but they have been discontinued or are a non-stock item.

Is there a simple, standard way that this is done? Thanks for any replies.

Don
Kansas City

Grant

unread,
Aug 21, 2012, 12:53:18 AM8/21/12
to
Safest is an optocoupler, you can get opto gate drivers; will
need a zener regulated supply hanging down from +24V.

If the switching speed allows, you could you a blocking capacitor
with a reset diode; no good for switched DC operation; beware the
power on charging of the blocking cap.

You could use an NPN transistor with a resistor up to the gate,
and a zener to limit gate voltage; fairly safe?

Lots of options, depending on desired switching rate and power.

Grant.
>
>Don
>Kansas City

fungus

unread,
Aug 21, 2012, 6:21:29 AM8/21/12
to
On Tuesday, August 21, 2012 4:16:13 AM UTC+2, Don Gilmore wrote:
>
> I'd like to control a 24Vdc load by sourcing with a p-type power MOSFET. I'm driving the gate directly from a mictrocontroller that uses +5 and ground. The problem is that I need +24 and +19. I looked into "high voltage level translators", but they have been discontinued or are a non-stock item.
>
> Is there a simple, standard way that this is done? Thanks for any replies.
>

Use a second transistor to control the voltage
to the MOSFET?

Don Gilmore

unread,
Aug 21, 2012, 8:50:39 AM8/21/12
to
Well, it's actually half of a PNP/NPN pair that is switching back and forth with a common gate at about 20 kHz. The NPN is no problem: I can switch it with +5. It's the PNP that's vexing me. The opto idea sounds good, if I can find one that can handle the current (20 amps) and has a low drain-to-source resistance. It also needs to be surface mount and the board is very tiny.

Thanks for the ideas so far!

Don

Don Gilmore

unread,
Aug 21, 2012, 9:08:19 AM8/21/12
to
On Tuesday, August 21, 2012 5:21:29 AM UTC-5, fungus wrote:
Use a second transistor to control the voltage to the MOSFET?

Yeah, but I need it to turn on the output on a "low" signal, so I'd still have to drive it with a PNP at +24 and +19, which presents the same problem.

It's part of a PNP/NPN pair and one circuit has to shut off when the other turns on with a common gate signal from the MCU. I could use two NPN's and invert one gate signal, but there are three of these pairs and I'm trying to keep my chip count down.

Don

George Herold

unread,
Aug 21, 2012, 10:20:02 AM8/21/12
to
On Aug 21, 9:08 am, Don Gilmore <eromlign...@att.net> wrote:
> On Tuesday, August 21, 2012 5:21:29 AM UTC-5, fungus wrote:
>
> Use a second transistor to control the voltage to the MOSFET?

A little resistor divider chain and npn at the bottom to switch it,
sounds easy.

>
> Yeah, but I need it to turn on the output on a "low" signal, so I'd still have to drive it with a PNP at +24 and +19, which presents the same problem.


Add an inverter between the micro and the npn as switch. Or code the
micro differently? ... or yet another transistor?

George H.

fungus

unread,
Aug 21, 2012, 11:08:05 AM8/21/12
to
On Tuesday, August 21, 2012 3:08:19 PM UTC+2, Don Gilmore wrote:
>
> It's part of a PNP/NPN pair and one circuit
> has to shut off when the other turns on with
> a common gate signal from the MCU.
>

Use a resistor inverter:

24V
|
R1
|
+---to MOSFET gate
|
BJT --R2--MCU
|
|
GND

When the MCU switches the BJT "on" the
gate of the MOSFET will go to ground.

When the MCU switches the BJT "off" the
gate of the MOSFET will go up to 24V.

It seems too simple, I must be missing
something...

Tim Wescott

unread,
Aug 21, 2012, 12:18:28 PM8/21/12
to
I'd use all N-channel parts and a half-bridge driver like the LM5109 or
any of the plethora of other parts out there.

--
My liberal friends think I'm a conservative kook.
My conservative friends think I'm a liberal kook.
Why am I not happy that they have found common ground?

Tim Wescott, Communications, Control, Circuits & Software
http://www.wescottdesign.com

John Fields

unread,
Aug 21, 2012, 5:50:04 PM8/21/12
to
On Mon, 20 Aug 2012 19:16:13 -0700 (PDT), eroml...@att.net wrote:

I think this is the simplest implementation:

PNP
24VDC>-----+--E B C-+
| | |
[R1] | |
| | |
+----+ |
| |
[3.9R1] [LOAD]
| |
C |
MCU>-[R2]--B NPN |
E |
| |
GND--------+--------+

--
JF

John Fields

unread,
Aug 21, 2012, 5:55:36 PM8/21/12
to
On Tue, 21 Aug 2012 08:08:05 -0700 (PDT), fungus <to...@artlum.com>
wrote:
---
Yup, you punched through the MOSFET's gate oxide.

--
JF

John Fields

unread,
Aug 21, 2012, 6:03:05 PM8/21/12
to
---
Oops, PNP should read "PMOS".


--
JF

whit3rd

unread,
Aug 22, 2012, 12:30:44 AM8/22/12
to
On Monday, August 20, 2012 7:16:13 PM UTC-7, Don Gilmore wrote:

> I'd like to control a 24Vdc load by sourcing with a p-type power MOSFET. I'm driving the gate directly from a mictrocontroller that uses +5 and ground.

Why do you want to use a PMOS? If you want to switch a 24V circuit ON with 5V logic low,
the PMOS is going to be inconvenient (the gate and source which control its
conduction are up at the +24V side of the circuit).

I'll assume that you want the load to always have one pin grounded, and want to
do a high-side switch between +24V and its other pin; that's a good reason to
switch with a PMOS device.

So, PMOS high-side switch, with source connected to +24, gate pullup resistor
to source, and gate pulldown with an NPN transistor, base connected to +5V, emitter
through resistor to your logic pin. You can put a resistor from NPN collector to the
gate, instead of straight connection, if the PMOS gate doesn't tolerate 19V.

Optoisolators are expensive and low-performance by comparison with even the lowliest
simple transistor.

fungus

unread,
Aug 22, 2012, 5:47:36 AM8/22/12
to
On Tuesday, August 21, 2012 11:55:36 PM UTC+2, John Fields wrote:
>
> >It seems too simple, I must be missing
> >something...
>
> ---
>
> Yup, you punched through the MOSFET's gate oxide.
>

Oh, yes... :-(

Ok, add an extra resistor in parallel with
the BJT.

24V
|
R1
|
+---to MOSFET gate
|
/-+-\
| |
R3 |
| |
| BJT --R2--MCU
| |
\ /
GND

Now when the BJT is closed the voltage
at the MOSFET gate is proportional to
the values of R1 and R3 (hopefully low
enough to keep the magic smoke inside
the MOSFET).

John Fields

unread,
Aug 22, 2012, 7:41:03 AM8/22/12
to
On Wed, 22 Aug 2012 02:47:36 -0700 (PDT), fungus <to...@artlum.com>
wrote:
---
No.

When the BJT is open the MOSFET's gate will see

(24V * R3) / (R1 + R3)

but when the BJT is conducting, the MOSFET's gate will be sitting at
about 0.3V above ground.

That means that the drain-to-gate voltage will be about 23.7V, which
is higher than the usual +/- 20V spec.

The right way to do it, I think, is like this:

. PMOS
.24VDC>-----+--D G S-+
. | | |
. [R1] | |
. | | |
. +----+ |
. | |
. [3.9R1] [LOAD]
. | |
. C |
.MCU>-[R2]--B NPN |
. E |
. | |
.GND--------+--------+

That way, when the input from the MPU is low the NPN won't be
conducting, the PMOS gate will be at 24V and so will the drain, so the
MOSFET will be off.

Then, when the MCU output goes high the NPN will turn on, connecting
3.9R1 to ground.

That'll pull the gate voltage down to about 19V, 5 volts lower than
the drain voltage, which is what Don asked for. :-)

--
JF

John Fields

unread,
Aug 22, 2012, 8:05:42 AM8/22/12
to
On Wed, 22 Aug 2012 06:41:03 -0500, John Fields
<jfi...@austininstruments.com> wrote:


>The right way to do it, I think, is like this:
>
>. PMOS
>.24VDC>-----+--D G S-+
>. | | |
>. [R1] | |
>. | | |
>. +----+ |
>. | |
>. [3.9R1] [LOAD]
>. | |
>. C |
>.MCU>-[R2]--B NPN |
>. E |
>. | |
>.GND--------+--------+

---
Aarghhh...

. PMOS
.24VDC>-----+--S G D-+
. | | |
. [R1] | |
. | | |
. +----+ |
. | |
. [3.9R1] [LOAD]
. | |
. C |
.MCU>-[R2]--B NPN |
. E |
. | |
.GND--------+--------+

That way, when the input from the MPU is low, the NPN won't be
conducting, the PMOS gate will be at 24V and so will its source, so
the MOSFET will be off.

Then, when the MCU output goes high the NPN will turn on, connecting
3.9R1 to ground.

That'll pull the gate voltage down to about 19V, 5 volts lower than
the source voltage, which is what Don asked for. :-)

--
JF

Don Gilmore

unread,
Aug 22, 2012, 8:27:19 AM8/22/12
to
On Wednesday, August 22, 2012 7:05:42 AM UTC-5, John Fields wrote:
> On Wed, 22 Aug 2012 06:41:03 -0500, John Fields <jfi...@austininstruments.com> wrote: >The right way to do it, I think, is like this: > >. PMOS >.24VDC>-----+--D G S-+ >. | | | >. [R1] | | >. | | | >. +----+ | >. | | >. [3.9R1] [LOAD] >. | | >. C | >.MCU>-[R2]--B NPN | >. E | >. | | >.GND--------+--------+ --- Aarghhh... . PMOS .24VDC>-----+--S G D-+ . | | | . [R1] | | . | | | . +----+ | . | | . [3.9R1] [LOAD] . | | . C | .MCU>-[R2]--B NPN | . E | . | | .GND--------+--------+ That way, when the input from the MPU is low, the NPN won't be conducting, the PMOS gate will be at 24V and so will its source, so the MOSFET will be off. Then, when the MCU output goes high the NPN will turn on, connecting 3.9R1 to ground. That'll pull the gate voltage down to about 19V, 5 volts lower than the source voltage, which is what Don asked for. :-) -- JF


Yes, this is what I was looking for. Thanks John.

Don

John Fields

unread,
Aug 22, 2012, 2:55:26 PM8/22/12
to
On Wed, 22 Aug 2012 05:27:19 -0700 (PDT), Don Gilmore
<eroml...@att.net> wrote:


>Yes, this is what I was looking for. Thanks John.
>
>Don

---
My pleasure. :-)

--
JF

Don Gilmore

unread,
Aug 22, 2012, 8:17:33 PM8/22/12
to
On Wednesday, August 22, 2012 1:55:26 PM UTC-5, John Fields wrote:
> On Wed, 22 Aug 2012 05:27:19 -0700 (PDT), Don Gilmore wrote: >Yes, this is what I was looking for. Thanks John. > >Don --- My pleasure. :-) -- JF

Well, wait. I guess this works, but it still doesn't do what I want.

This switches on the load when the output is HIGH. If I wanted to that, I could have just used an n-type MOSFET and controlled it directly with the MCU.

What I need is for the load to switch on when I give it a LOW. And as soon as you start thinking about using a PNP to switch it, you run into the same problem.

Am I stuck with an inverter?

Don

Grant

unread,
Aug 22, 2012, 10:34:43 PM8/22/12
to
+24 o--------------o---.-. .----
| | A |
| =====
| |
| | |
| | |
|_| |
| |
o-----'
|
| |
| |
|_|
|
|/
+Vdd o-----o-----|
| |>
| |
------- |
| | |
| CPU |o--'
| |
-------
|
0V o-------o---------

Now high on CPU output turns off the transistor, thus no gate voltage?

You might want a b-e resistor so the circuit is failsafe off while CPU
starts, before the outputs are enabled. Voltage divider to prevent
excess gate voltage as in other posts.

Grant.
>
>Don

Jasen Betts

unread,
Aug 23, 2012, 4:10:33 AM8/23/12
to
connect the NPN base resistor to the +5V supply and the NPN emitter to the
MCU output.






> Don


--
⚂⚃ 100% natural

--- Posted via news://freenews.netfront.net/ - Complaints to ne...@netfront.net ---

Jasen Betts

unread,
Aug 23, 2012, 4:30:54 AM8/23/12
to
On 2012-08-23, Don Gilmore <eroml...@att.net> wrote:
no, not stuck, you can use the NPN in common-base mode.

+24
---------+------. .---
| | |
| | ====
| | |
| | |
|_|1.5K |
| |
+------'
/
+5 |/
-+----|
| |\|
| ~\
| |
| | |
| | | 470 Ohms
| | |
_|__ |_|
| |
mcu|----'
____|
|
--+--- 0V

The 470R puts about 9mA through the transistor, dependant on how
strong the MCU output is, across the i.5K that's about 13V to
turn the mosfet on, which sould be about right..














> Don


--
⚂⚃ 100% natural

Jasen Betts

unread,
Aug 23, 2012, 4:48:08 AM8/23/12
to
Nothing will put the emitter voltage higher than the base, the B-C
diode is plenty strong enough. puwer up isnt going to be crazy.
But you've got a base current problem when you try to turn the
transistor on.

Grant

unread,
Aug 23, 2012, 7:44:17 PM8/23/12
to
Oops! Needs a base or emitter resistor?

Grant.

Jamie

unread,
Aug 23, 2012, 8:40:07 PM8/23/12
to
For you, a Base R would be the simplest approach..
----
Using a E R is going to to force you to subtract the
Vcc-.7 volts for example, from the upper divider..

I don't know what your VDD is but maybe it's 5 volts? If
so, this would mean, you need to subtract ~ 4.3 volts from
the 24+ up above which leads you to just under 20 volts to
play with. This may work for you as a direct driving approach
instead of using the voltage divider above. So select such a
R for this, one suitable for putting the transistor into saturation
would be enough I would say.. The one problem that may result from this
is if the uP when in the high state does not meet the VDD of the
uP. If it falls more than a diode drop below the Vdd, then it'll put the
transistor into conduction state and slightly pull it down. That may not
be a problem but something to look at..

If you want to experiment with emitter R's, try a 5k in yours..

Jamie

John Larkin

unread,
Aug 23, 2012, 11:09:54 PM8/23/12
to
Simpler:

> PNP or PFET
>24VDC>-----+--E B C-+
> | | |
> [R1] | |
> | | |
> +----+ |
> | |
> | [LOAD]
> | |
> C |
>+3.3------B NPN |
> E |
> | |
> R2 |
> | |
uP gnd
port

where the uP port is active low, 3.3v logic.


--

John Larkin Highland Technology Inc
www.highlandtechnology.com jlarkin at highlandtechnology dot com

Precision electronic instrumentation
Picosecond-resolution Digital Delay and Pulse generators
Custom timing and laser controllers
Photonics and fiberoptic TTL data links
VME analog, thermocouple, LVDT, synchro, tachometer
Multichannel arbitrary waveform generators

John Fields

unread,
Aug 24, 2012, 6:46:16 AM8/24/12
to
---
Don specified that he wanted to drive a PFET gate with 24V and 19V and
that his signal source was 5V logic.

Your 3.3V logic ignores his 5V request and, with R2 in the emitter of
the NPN, makes it impossible for its collector to get to his requested
19V.

--
JF

John Larkin

unread,
Aug 24, 2012, 3:42:53 PM8/24/12
to
On Fri, 24 Aug 2012 05:46:16 -0500, John Fields
I think he can handle that difference. 5 volt logic is getting pretty
rare these days!

with R2 in the emitter of
>the NPN, makes it impossible for its collector to get to his requested
>19V.

Why impossible? This circuit allows any desired drop across R1, up
until the NPN saturates. With a 24 volt supply, 5 or maybe 10 volts
across R1 is easy.

The nice thing about this topology, besides the simplicity, is that
the NPN is a constant current sink, so the drive to the upper pnp/pfet
is independent of changes in the +24 supply.

To flip the control polarity, just do this:


>>> PNP or PFET
>>>24VDC>-----+--E B C-+
>>> | | |
>>> [R1] | |
>>> | | |
>>> +----+ |
>>> | |
>>> | [LOAD]
>>> | |
>>> C |
>>>uP--------B NPN |
>>> E |
>>> | |
>>> R2 |
>>> | |
>> gnd gnd
>>

The R1/R2 math is the same, but the uP port can be wimpier, since it
doesn't have to sink the drive up into R1.



--

John Larkin Highland Technology, Inc

jlarkin at highlandtechnology dot com
http://www.highlandtechnology.com

Precision electronic instrumentation
Picosecond-resolution Digital Delay and Pulse generators
Custom laser drivers and controllers
Photonics and fiberoptic TTL data links
VME thermocouple, LVDT, synchro acquisition and simulation

John Fields

unread,
Aug 25, 2012, 6:30:10 PM8/25/12
to
---
Nicely done.

--
JF

Don Gilmore

unread,
Aug 26, 2012, 1:59:39 PM8/26/12
to
Thanks John.

Don
0 new messages