Noobie problem driving multiplexed LED array with P-channel mosfet

I am confused, looking for some clarification....

I have a multiplexed LED array that uses constant current shift registers on the cathodes, and PNP transistors on the anodes.

The microcontroller power supply is independent from the LED power supply. Previously I was using a 5V microcontroller and a supply voltage of 4.2V for the blue LED's. This worked OK.

I changed to a different microcontroller that only runs on 3.3V, and of course I can't turn off the PNP transistor because I can only put

3.3V to the base through the microcontroller.

I thought I can change to P-channel MOSFETS with a logic drive. I bought some Diodes Inc DMG6968U (P-channel enhancement mode mosfet). On my board, the drain is connected to the LED's, the source is connected to the 4.2V supply... the problem is that the MOSFETs never turn off, so any column I try to light up, it will be lit up for all the rows, not just the one row.

I haven't used MOSFETS before, so I am sure there is something really basic I am missing. I thought a logic level drive MOSFET would let me control the 4.2V LED voltage with the 3.3V microcontroller voltage.

I thought of adding a "pull up" resistor between the gate and source, but then I'm putting 4.2V into the microcontroller, and the datasheet says it can only handle Vcc+0.5V, which would be 3.8V.

What is is that I am missing and what is the best solution?

Thanks!

CJ

Reply to
CJ
Loading thread data ...

"CJ"

** Never thought of placing a diode between the uC and the base of each PNP ??
** That number is for an N channel fet.

.... Phil

Reply to
Phil Allison

NP

On the diode, I thought about it, but the transistor is a PNP driving the high side, and it's 4.2V in vs 3.3V on the uC, so in order to turn it off I would need to pull it high with a resistor to the high side supply... but then when I try to drive it low with the uC, the diode is going to prevent that, isn't it?

I made a mistake on the part number, the PN of the MOSFET is AO3415 (Alpha Omega Semi).

Reply to
CJ

"CJ" "Phil Allison"

On the diode, I thought about it,

** Shame you did not TRY it instead of inventing false theories.!!

but the transistor is a PNP driving the high side, and it's 4.2V in vs 3.3V on the uC, so in order to turn it off I would need to pull it high with a resistor to the high side supply...

** Nonsense.

but then when I try to drive it low with the uC, the diode is going to prevent that, isn't it?

** Draw the circuit - imbecile.

I made a mistake on the part number, the PN of the MOSFET is AO3415 (Alpha Omega Semi).

** Bloody BIG mistake - wrong brand and wrong number entirely.

The GS threshold voltage is catching you out - at 0.9 volts, Id is up to almost 1 amp.

formatting link

Do read the data.

..... Phil

Reply to
Phil Allison

PNP

Even with a pull-up, you might exceed the absmax of the uP. and that is assuming there is no protection diode on the uP to the + rail. Why don't you just buy a driver chip? MAX7219 for example.

Even if you get the voltages figured out, all that external crap will probably lead to ghosting as you multiplex.

Reply to
miso

Install the two diodes in series with cathodes toward the uC - this will allow the PNP base to go up to ~ 4.7 volts when the uC output is high. A pull-up resistor on the base will ensure that the PNP turns off. You should probably also have a resistor in series with the diodes.

--
Peter Bennett, VE7CEI  
peterbb4 (at) interchange.ubc.ca  
GPS and NMEA info: http://vancouver-webpages.com/peter
Vancouver Power Squadron: http://vancouver.powersquadron.ca
Reply to
Peter Bennett

You need to get the gate voltage to within a couple hundred mV of the source to make sure it's turned off completely (but need a couple of volts to make sure it is turned on). That spells a bunch of additional parts.

Why don't you use a complimentary PNP/NPN pair with internal resistors in SOT-23-6 or smaller (reversed logic)? No external parts... assuming your current is low enough for those parts to handle it.

That should NEVER happen if the firmware is written properly.

Best regards, Spehro Pefhany

--
"it's the network..."                          "The Journey is the reward"
speff@interlog.com             Info for manufacturers: http://www.trexon.com
Embedded software/hardware/analog  Info for designers:  http://www.speff.com
Reply to
Spehro Pefhany

y
d
t

ach PNP

=A0I

).

"The Journey is the reward"

formatting link

eff.com

Regarding ghosting, you add a dead cycle in the muxing, which is what the MAX7219 does. However, this guy is a self-professed newbie.

Reply to
miso

Peter Bennett a écrit :

Just use a common gate NMOS as a level shifter.

------+---------+-------- | | .-. | | | | | | | '-' | | | +------||-+ | ||->

||-+ ||-+ ||

Reply to
Fred Bartoli

--
If you can drive the shift register with the µC 3.3V I/O's, this should
work: (View in Courier)


5v>---------------+---------+----------------+
                  |         |                |
                 [R]*       |                |
                  |   *     E                |
3.3V>-+           +--[R]--B PNP/PCH          |
      |           |         C                |
    +---+   *     C         |             +--+--+
    |µC |--[R]--B NPN*      +---[LED1>]---|     |
    |   |         E         .             .     .
    |   |         |         .             .     .
    |   |         |         .             .     .
    |   |         |         +---[LEDn>]---|     |
    |   |         |                       |     |
    |   |===============/CONTROL/========>|     |
    |   |         |                       +--+--+
    +-+-+         |                          |
      |           |                          |
GND>--+-----------+--------------------------+

* Additional parts per channel

JF
Reply to
John Fields

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.