Searching \ for '[PIC]: Driving a single bicolor LED' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page: www.piclist.com/techref/displays.htm?key=led
Search entire site for: 'Driving a single bicolor LED'.

Exact match. Not showing close matches.
PICList Thread
'[PIC]: Driving a single bicolor LED'
2004\04\18@082530 by Chris Oesterling

flavicon
face
All,
I'm hoping to find a simpler solution to what I thought would be a
simple task of driving a single green/red bicolor LED from a PIC.
Reversing polarity isn't easy!  I have found an old article that uses a
relay or suggests a better solution of using a couple of transistors and
resistors.  Sorry for such a basic question.  I searched the archives
and only found a matrix solution.
Thank you!
- Chris

--
http://www.piclist.com hint: The PICList is archived three different
ways.  See http://www.piclist.com/#archives for details.

2004\04\18@083020 by Wouter van Ooijen

face picon face
> I'm hoping to find a simpler solution to what I thought would be a
> simple task of driving a single green/red bicolor LED from a PIC.
> Reversing polarity isn't easy!

What about connecting the LED (with appropriate resistor) to two output
pins?

Wouter van Ooijen

-- -------------------------------------------
Van Ooijen Technische Informatica: http://www.voti.nl
consultancy, development, PICmicro products

--
http://www.piclist.com hint: The PICList is archived three different
ways.  See http://www.piclist.com/#archives for details.

2004\04\18@083229 by Edward Gisske

flavicon
face
Use two port lines. Connect the led (in series with a resistor) between the
port lines. With one line up and the other down, the led is green. With the
state of the lines reversed, the led is red. With both lines up (or down)
the led is off. The moral equivalent of a bridge circuit...
Edward Gisske, P.E.
Gisske Engineering
608-523-1900
spam_OUTgisskeTakeThisOuTspamoffex.com

{Original Message removed}

2004\04\18@083525 by Rick C.

flavicon
face
Only if you have a little power to spare, you can just use a two resistor
voltage divider. Center point to one leg of the LED and the other leg to the
output of the PIC.
Rick

Chris Oesterling wrote:

{Quote hidden}

--
http://www.piclist.com hint: The PICList is archived three different
ways.  See http://www.piclist.com/#archives for details.

2004\04\18@083939 by Spehro Pefhany

picon face
At 08:26 AM 4/18/2004 -0400, you wrote:
>All,
>I'm hoping to find a simpler solution to what I thought would be a
>simple task of driving a single green/red bicolor LED from a PIC.
>Reversing polarity isn't easy!  I have found an old article that uses a
>relay or suggests a better solution of using a couple of transistors and
>resistors.  Sorry for such a basic question.  I searched the archives
>and only found a matrix solution.
>Thank you!
>- Chris

There are a couple methods shown in this short little article on page98
(written by some hack).

http://www.reed-electronics.com/ednmag/contents/images/112201di.pdf

Alternately, you can use one resistor and two port pins to reverse
voltage, which is simpler (but uses two port pins).

Best regards,

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

--
http://www.piclist.com hint: The PICList is archived three different
ways.  See http://www.piclist.com/#archives for details.

2004\04\18@090054 by Spehro Pefhany

picon face
At 08:48 AM 4/18/2004 -0400, you wrote:
>At 08:26 AM 4/18/2004 -0400, you wrote:
>>All,
>>I'm hoping to find a simpler solution to what I thought would be a
>>simple task of driving a single green/red bicolor LED from a PIC.
>>Reversing polarity isn't easy!  I have found an old article that uses a
>>relay or suggests a better solution of using a couple of transistors and
>>resistors.  Sorry for such a basic question.  I searched the archives
>>and only found a matrix solution.
>>Thank you!
>>- Chris
>
>There are a couple methods shown in this short little article on page98
>(written by some hack).
>
>http://www.reed-electronics.com/ednmag/contents/images/112201di.pdf

Here is another article, specifically for micro port pins, written by
the same hack:

http://www.elecdesign.com/Articles/ArticleID/1683/1683.html

Best regards,

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

--
http://www.piclist.com hint: The PICList is archived three different
ways.  See http://www.piclist.com/#archives for details.

2004\04\18@143959 by Chris Oesterling

flavicon
face
Thank you!
- Chris

Edward Gisske wrote:
>
> Use two port lines. Connect the led (in series with a resistor) between the
> port lines. With one line up and the other down, the led is green. With the
> state of the lines reversed, the led is red. With both lines up (or down)
> the led is off. The moral equivalent of a bridge circuit...
> Edward Gisske, P.E.
> Gisske Engineering
> 608-523-1900
> .....gisskeKILLspamspam.....offex.com
>
> {Original Message removed}

2004\04\18@145905 by Byron A Jeff

face picon face
On Sun, Apr 18, 2004 at 08:26:08AM -0400, Chris Oesterling wrote:
> All,
> I'm hoping to find a simpler solution to what I thought would be a
> simple task of driving a single green/red bicolor LED from a PIC.

It is a simple task.

> Reversing polarity isn't easy!

Sure it is! You just have to be able to control both legs of the LED.

>  I have found an old article that uses a
> relay

Yuck!

> or suggests a better solution of using a couple of transistors and
> resistors.

Not much better. It really requires some parts and work to get it going.

>  Sorry for such a basic question.

Not basic at all. Fortunately the PIC can help you.

>  I searched the archives and only found a matrix solution.

Simple solution: 2 I/O pins each tied to a leg, with a current limiting
resistor between one pin and a leg. Then you can control the LED simply
by having opposite values on the the pins. So a 0 on pin A and a 1 on pin B
will light the LED with one color, while a 1 on pin A and a 0 on pin B will
light it the other. If the pins are the same value, the LED is off. If you
oscillate the pins, you get the blended yellow/orange color.

BAJ

--
http://www.piclist.com hint: The PICList is archived three different
ways.  See http://www.piclist.com/#archives for details.

More... (looser matching)
- Last day of these posts
- In 2004 , 2005 only
- Today
- New search...