Searching \ for '[PIC]: On the subject of LED drivers...' 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: 'On the subject of LED drivers...'.

Exact match. Not showing close matches.
PICList Thread
'[PIC]: On the subject of LED drivers...'
2002\05\19@204211 by Pic Dude

flavicon
face
Just started looking thru my bin of old TTL parts for a 74xx244 or some
other driver to experiment with driving a higher current thru my 4 mux'ed
LED's.  But then I thought -- if I have extra ports on the PIC, why can't
I run these in pairs for each LED segment?  At 25mA max source/sink
on a 16F872, I could get 50mA to the LED's.  And to prevent the
condition of 2 pins of a pair being out of sync, I would use 2 pins on the
same port for each LED ... RB0 and RB1 for segment a, RB2 and RB3
for segment b, etc.

Am I out of whack here?
-Neil.

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


2002\05\19@220044 by Bob Ammerman

picon face
> Just started looking thru my bin of old TTL parts for a 74xx244 or some
> other driver to experiment with driving a higher current thru my 4 mux'ed
> LED's.  But then I thought -- if I have extra ports on the PIC, why can't
> I run these in pairs for each LED segment?  At 25mA max source/sink
> on a 16F872, I could get 50mA to the LED's.  And to prevent the
> condition of 2 pins of a pair being out of sync, I would use 2 pins on the
> same port for each LED ... RB0 and RB1 for segment a, RB2 and RB3
> for segment b, etc.
>
> Am I out of whack here?
> -Neil.
>

Nope, this should work fine. Just make sure you NEVER drive the outputs in
the opposite directions. Thus this would be bad:

   bsf    PORTB,2
   bsf    PORTB,3

This would be good

   movf    PORTB,W
   iorlw    (1<<2) | (1 << 3)
   movwf  PORTB

If you really want some substantial drive then use a transistor: NPN for
low-side drive or PNP on the high side.

Low-side:

NPN - emitter to GND, collector via resistor to LED, base via resistor to
PIC

High side:

PNP - emitter to Vdd, collector via resistor to LED, base via resistor to
PIC

Remember that the signals will be inverted by the transistors.

Also, if you are using transistors for both the high side and low side drive
you would typically only include resistors between the segment drives and
LED array, but not between the digit drives and the LED. This is because
each segment driver is driving a single LED at once, but the digit drivers
are driving however many segments happen to be on in that digit, and so the
available current would be split among the lit segments.

Bob Ammerman
RAm Systems


----- Original Message -----
From: "Pic Dude" <spam_OUTpicdudeTakeThisOuTspamAVN-TECH.COM>
To: <.....PICLISTKILLspamspam@spam@MITVMA.MIT.EDU>
Sent: Sunday, May 19, 2002 8:40 PM
Subject: [PIC]: On the subject of LED drivers...


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

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


2002\05\19@220301 by Spehro Pefhany

picon face
At 07:40 PM 5/19/02 -0500, you wrote:
>Just started looking thru my bin of old TTL parts for a 74xx244 or some
>other driver to experiment with driving a higher current thru my 4 mux'ed
>LED's.  But then I thought -- if I have extra ports on the PIC, why can't
>I run these in pairs for each LED segment?  At 25mA max source/sink
>on a 16F872, I could get 50mA to the LED's.  And to prevent the
>condition of 2 pins of a pair being out of sync, I would use 2 pins on the
>same port for each LED ... RB0 and RB1 for segment a, RB2 and RB3
>for segment b, etc.

Yes, you could do that.. But I'd suggest getting a brighter display,
port pins are generally too valuable to waste 8 of them (the driver
would be cheaper). There is some worry about what could happen if the
port (through noise or whatever) gets set so the outputs are fighting
each other, but you'll be updating the port every few milliseconds
anyway.

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
9/11 United we Stand

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


2002\05\19@224525 by Pic Dude

flavicon
face
Yeah, but transistors mean more components and I think
we all know how I feel about that. :-)

Generally, I don't like to bcf/bsf port pins -- I usually
have a bunch of different things going on on each port, so
I use extra registers called SHADOW_A, SHADOW_B, etc.  I
set the pins on the SHADOW_x registers and then dump that
register to the port as a whole.  If I change something for
the multiplexed LED's on a port, the other devices on the
port stay untouched.  Just a habit I guess.

Thanks,
-Neil.



{Original Message removed}

2002\05\19@225740 by Pic Dude

flavicon
face
Very true, but I was speculating for a device I created a couple
months ago that needed one A/D, so I used a 16F872, but then had
a bunch of other I/O left over, so I thought I could make use of
them to get some real power into the LED's.  Those were run at
20% duty-cycle (2x5 multiplexed bargraph).

I also use SIP resistors with a single common on the common side
of the mux, but if I used DIP resistor networks, I could run say
R1 from RB0 to LED anode, R2 from RB1 to the same LED anode, then
the common to the transitor, etc.  This way, any brief unexpected
moment of conflicting outputs to a single LED would have the
protection of 2R between them.

But's it's all speculation for now, and just my mind working
overtime on a boring Sunday.

Cheers,
-Neil.




{Original Message removed}

2002\05\19@233627 by Spehro Pefhany

picon face
At 09:56 PM 5/19/02 -0500, you wrote:

>I also use SIP resistors with a single common on the common side
>of the mux, but if I used DIP resistor networks, I could run say
>R1 from RB0 to LED anode, R2 from RB1 to the same LED anode, then
>the common to the transitor, etc.  This way, any brief unexpected
>moment of conflicting outputs to a single LED would have the
>protection of 2R between them.

I can't see anything wrong with this method. Good thinking.
DIP resistor arrays are expensive, but SMT DIP networks are cheap.
You also double up on the available resistor power dissipation that way.

Best regards,

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

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


2002\05\20@065410 by Bob Ammerman

picon face
> Generally, I don't like to bcf/bsf port pins -- I usually
> have a bunch of different things going on on each port, so
> I use extra registers called SHADOW_A, SHADOW_B, etc.  I
> set the pins on the SHADOW_x registers and then dump that
> register to the port as a whole.  If I change something for
> the multiplexed LED's on a port, the other devices on the
> port stay untouched.  Just a habit I guess.
>
> Thanks,
> -Neil.

Not all habits are bad ones. Just be aware of the times when direct port I/O
makes more sense (generally when  cycles/instructions are very critical).

Bob Ammerman
RAm Systems

--
http://www.piclist.com#nomail Going offline? Don't AutoReply us!
email EraseMElistservspam_OUTspamTakeThisOuTmitvma.mit.edu with SET PICList DIGEST in the body


2002\05\20@083543 by Olin Lathrop

face picon face
> Just started looking thru my bin of old TTL parts for a 74xx244 or some
> other driver to experiment with driving a higher current thru my 4 mux'ed
> LED's.  But then I thought -- if I have extra ports on the PIC, why can't
> I run these in pairs for each LED segment?  At 25mA max source/sink
> on a 16F872, I could get 50mA to the LED's.  And to prevent the
> condition of 2 pins of a pair being out of sync, I would use 2 pins on the
> same port for each LED ... RB0 and RB1 for segment a, RB2 and RB3
> for segment b, etc.
>
> Am I out of whack here?

No, that should work, but there are some things to watch out for.  There is
a maximum port current spec for the whole PIC, and you have to make sure the
two port pins for one LED share the current equally.  This means you can't
just tie them together, but need to give each its own resistor.


*****************************************************************
Embed Inc, embedded system specialists in Littleton Massachusetts
(978) 742-9014, http://www.embedinc.com

--
http://www.piclist.com#nomail Going offline? Don't AutoReply us!
email listservspamspam_OUTmitvma.mit.edu with SET PICList DIGEST in the body


2002\05\20@093553 by Edson Brusque

face
flavicon
face
Hello,

   while we're "on the subject" I want to say that I've used 6 I/O pins (4
on PORTB and the 2 XTAL pins) on a PIC16F628 to light 8 LEDs.

   I've multiplexed the 8 LEDS with 4 470R resistor on the 6 pins without
burning anything. When all LEDs (PORTB pins to resistors to anodes) are on,
I have (5-1.7)/470=7.021mA on each PORTB pin and 7.021x4=28.09mA on each
XTAL pin (RA6, RA7). As RA6 and RA7 are on for 50% of the time, it does have
sufficient time to recover from the high current.

   No damaged pin untill now.

   Best regards,

   Brusque

-----------------------------------------------------------------
Edson Brusque                 C.I.Tronics Lighting Designers Ltda
Researcher and Developer               Blumenau  -  SC  -  Brazil
Say NO to HTML mail                          http://www.citronics.com.br
-----------------------------------------------------------------

--
http://www.piclist.com#nomail Going offline? Don't AutoReply us!
email @spam@listservKILLspamspammitvma.mit.edu with SET PICList DIGEST in the body


2002\05\21@121716 by Harold M Hallikainen

picon face
       The PIC18 series solves this problem by putting the output latches
themselves in the memory map. So, you can do something like bsf latb,3
and know it will work.


Harold


On Mon, 20 May 2002 06:49:57 -0400 Bob Ammerman <KILLspamrammermanKILLspamspamADELPHIA.NET>
writes:
{Quote hidden}

FCC Rules Online at http://hallikainen.com/FccRules
Lighting control for theatre and television at http://www.dovesystems.com


________________________________________________________________
GET INTERNET ACCESS FROM JUNO!
Juno offers FREE or PREMIUM Internet access for less!
Join Juno today!  For your FREE software, visit:
dl.http://www.juno.com/get/web/.

--
http://www.piclist.com hint: To leave the PICList
spamBeGonepiclist-unsubscribe-requestspamBeGonespammitvma.mit.edu


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