Re: 300 mA from a microcontroller pin
- From: Mark Borgerson <mborgerson@xxxxxxxxxxx>
- Date: Fri, 30 Nov 2007 07:57:17 -0800
In article <KdD3j.23516$j7.444069@xxxxxxxxxxxxxx>, toe@xxxxxxxxxxx
says...
Arlet Ottens:
What are you driving that you need 3-state 300 mA outputs ? Depending on
the application, there may be alternative solutions.
A bi-colour LED that has only two pins (they're in parallel facing in
different directions). If the microcontroller pin is high, then it'll be
red. If low, it'll be green. If high impedance, it'll be off.
Are you assuming that you can control this LED with just one pin? The
only way I can see to do that is like
P1.1---- LED --- R1 ---- 2.5V
Then alternating P1.1 between 0 and 5V would change the direction of
current flow. However, selecting R1 and getting a stable 2.5V
current source/sink is another set of problems.
The maximum current rating for the LED package is 30 mA... except I'mYou don't really need a tri-state driver, then. If both LED pins are
flashing a display and will only have them lit one sixteenth of the time,
so I'm gonna put a burst of 300 mA through them. (I've seen experiments
where people flashed an LED putting an entire amp through it, so I don't
think 300 mA will be a problem for a duty cycle of one sixteenth).
at the same level (either high or low), the LED will be off.
If total power dissipation isn't a concern, your circuit could
simplify to:
+5 +5
| |
R1 R2
| |
|---- LED ----|
| |
P1.1---T1 P1.2---T2
| |
| |
gnd gnd
T1 and T2 are logic-level N-channel mosfets controlled by
your MPU pins.
R1 and R2 are current-limiting resistors---and can be different
to balance the apparent brightness of the LEDs
When P1.1 and P1.2 are low, T1 and T2 are off and the LED is
off.
When P1.1 is high and P1.2 is low, current flows through
R2 and the LED to ground. Current also flows through
R1 to ground---wasted power, essentially. Assume that this
is the Green direction of the LED.
When P1.2 is high and P1.1 is low, current flows through
R1 and the LED to ground. Current also flows through
R2 to ground---wasted power, essentially. Assume that
this is the RED direction of the LED.
When both P1.1 and P1.2 are high, the LED is off and
current flow through R1 and R2 keeps your circuit board
warm! ;-)
If you don't want to warm the PC board as much, you can replace
R1 and R2 with a combination of a P-Channel mosfet and a resistor.
+5 +5
| |
P1.1---T3 P1.2---T4
| |
R1 R2
| |
|---- LED ----|
| |
P1.1---T1 P1.2---T2
| |
| |
gnd gnd
You can probably find small packages with two or
more integrated transistors in the Digi-Key catalog.
You will have to do a bit of research on gate voltages
and current handling, though.
Mark Borgerson
.
- Follow-Ups:
- Re: 300 mA from a microcontroller pin
- From: CBFalconer
- Re: 300 mA from a microcontroller pin
- References:
- 300 mA from a microcontroller pin
- From: Tomás Ó hÉilidhe
- Re: 300 mA from a microcontroller pin
- From: Arlet Ottens
- Re: 300 mA from a microcontroller pin
- From: Tomás Ó hÉilidhe
- 300 mA from a microcontroller pin
- Prev by Date: Re: Cooperative multitasking OS-??
- Next by Date: Re: TCP/ IP, USB stacks and ThreadX
- Previous by thread: Re: 300 mA from a microcontroller pin
- Next by thread: Re: 300 mA from a microcontroller pin
- Index(es):
Relevant Pages
|