Searching \ for '7 -segment displays' 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/index.htm?key=segment+displays
Search entire site for: '7 -segment displays'.

Truncated match.
PICList Thread
'7 -segment displays'
1999\09\15@041741 by MILLERIO

flavicon
face
I'm a bit of a PIC newbie, but i need to learn fast for a school project.

I'm looking at designing a device which will time after being triggered, in
minutes and seconds. I therefore need to drive 4 seven segment displays (2
digits for minutes, 2 for seconds). I'd like to know if this is possible
using one 18 pin PIC (sorry, I can't remember the type that I have).

I have seen (and I think I understand) multiplexing, but I have only seen
it done with 2 7 segs. Has anyone had experience of multiplexing 4
displays, and if so how did you do it?

If this is impossible (it may be, I haven't a clue!) what chip do you
recommend that I get hold of?

Thanks in advance.
Ian Miller

1999\09\15@052514 by Stewart Pye

flavicon
face
Hi Ian,

Yeah you can do it with an 18 pin 16F84. If it's common cathode connect the
7 segments of each display together, and to 7 pins of the pic (RB0- RB6 for
example) through (maybe 390ohm) resistors. Use RA0 - RA3 to select the
display. The outputs of these will go to the base of the 4 NPN transistors,
emitters connected to ground, collectors to the cathode of the displays.
This will leave you with 2 spare pins for switches or whatever.

If you want to know how to do common anode displays or want to see some
code, just ask and I'll send it off list.

Regards,

Stewart Pye


At 08:38 AM 15/09/99 +0100, you wrote:
{Quote hidden}

1999\09\15@094450 by bowman

flavicon
face
MILLERIO wrote:
>
> I have seen (and I think I understand) multiplexing, but I have only seen
> it done with 2 7 segs. Has anyone had experience of multiplexing 4
> displays, and if so how did you do it?

In addition to the other posts, if you are running short of pins, take a
look at the LSxx164 family of serial in/ parallel out chips. You can
clock in the 7 segment pattern with two PIC pins, data and clock.
Visually, you won't see the bits go by. You don't really need the clr
pin, and can tie it to the bus. This will save 5 PIC pins, but add
another 14 pin chip.


--
Bear Technology  Making Montana safe for Grizzlies

http://people.montana.com/~bowman/

1999\09\15@101147 by Greg Brault

picon face
Hi Ian,
I just completed a circuit that multiplexed four 7 seg displays.  You connect 7
data wires going to one segment, and then just daisy chain to the next
segment.  So if you output a certain segment, it would light up on all four
segments.  However, for your common cathode (or anode), instead of just running
it to either pos or gnd, run them each to a data pin on the PIC.  This is a
total of 7+4 = 11 data lines to run 4 segments.  Whichever segment you want to
display data on, select that pin, and then put your data on the data lines.  If
you run a crystal, you can cycle through each segment fast enough that the eye
cannot tell only one segment is on at a time.  The code is up to you, I had a
variable for each segment, and when it came time to light up that segment... it
displayed whatever was in that variable.

MILLERIO wrote:

{Quote hidden}

1999\09\15@113535 by w. v. ooijen / f. hanneman

picon face
> Yeah you can do it with an 18 pin 16F84. If it's common cathode connect
the
> 7 segments of each display together, and to 7 pins of the pic (RB0- RB6
for
> example) through (maybe 390ohm) resistors. Use RA0 - RA3 to select the
> display. The outputs of these will go to the base of the 4 NPN
transistors,
> emitters connected to ground, collectors to the cathode of the displays.
> This will leave you with 2 spare pins for switches or whatever.

Actually you can drive 9 displays (of seven segments + point) with 9 pins.
But this takes a bit more code. The trick is to use both the high, low and
input states. I have a counter here on a breadboard that drives 4 displays.
The code is in Jal. Mail me privately if you want it.

Wouter.

1999\09\15@114537 by Harold M Hallikainen

picon face
On Wed, 15 Sep 1999 08:38:47 +0100 MILLERIO <spam_OUTMILLERIOTakeThisOuTspamKES.BHAM.SCH.UK>
writes:
>I'm a bit of a PIC newbie, but i need to learn fast for a school
>project.
>
>I'm looking at designing a device which will time after being
>triggered, in
>minutes and seconds. I therefore need to drive 4 seven segment
>displays (2
>digits for minutes, 2 for seconds). I'd like to know if this is
>possible
>using one 18 pin PIC (sorry, I can't remember the type that I have).
>
>I have seen (and I think I understand) multiplexing, but I have only
>seen
>it done with 2 7 segs. Has anyone had experience of multiplexing 4
>displays, and if so how did you do it?
>
>If this is impossible (it may be, I haven't a clue!) what chip do you
>recommend that I get hold of?
>

       I had a similar project.  I looked at directly driving the four
digits with a 16c74, but the required total current exceeded the maximum
current of the chip.  Multiplexing required external drivers to get
reasonable digit and segment currents.  The LED drivers that I found had
relatively low segment currents (something like 10mA peak), so they would
not adequately drive the large LEDs we used.  Finally ended up using an
Allegro UCN5832 to independently drive each segment through a 120 ohm
current limit resistor.  The UCN5832 is a serial in shift register,
latch, and 32 open collector outputs.  Each output can sink 100 to 200mA.
All the timing and switch scanning was done using a 16c221.  Data was
shifted out to the 5832 60 times each second (shifted out in software).

Harold


Harold Hallikainen
.....haroldKILLspamspam@spam@hallikainen.com
Hallikainen & Friends, Inc.
See the FCC Rules at http://hallikainen.com/FccRules and comments filed
in LPFM proceeding at http://hallikainen.com/lpfm

___________________________________________________________________
Get the Internet just the way you want it.
Free software, free e-mail, and free Internet access for a month!
Try Juno Web: dl.http://www.juno.com/dynoget/tagj.

1999\09\15@114541 by Harold M Hallikainen

picon face
On Wed, 15 Sep 1999 19:25:33 +1000 Stewart Pye <stewspamKILLspamUQ.NET.AU> writes:
>Hi Ian,
>
>Yeah you can do it with an 18 pin 16F84. If it's common cathode
>connect the
>7 segments of each display together, and to 7 pins of the pic (RB0-
>RB6 for
>example) through (maybe 390ohm) resistors. Use RA0 - RA3 to select the
>display. The outputs of these will go to the base of the 4 NPN
>transistors,
>emitters connected to ground, collectors to the cathode of the
>displays.
>This will leave you with 2 spare pins for switches or whatever.
>

       I agree this will work, but your average segment current will be
a bit low.  If we assume a 1.4V drop across the LED, we get a peak LED
current of 9.23mA.  Divide by 4 digits and get an average LED segment
current of 2.3mA.  Can this be read (even with a high efficiency LED) in
a well lit room?
       If the resistor is decreased to 150 ohms, I get a peak LED
current of 24mA, right at the current limit for a PIC output.  Dividing
by the four digits gives an average current of 6mA, still not terribly
bright, but possibly ok for a small high efficiency display.

Harold



Harold Hallikainen
.....haroldKILLspamspam.....hallikainen.com
Hallikainen & Friends, Inc.
See the FCC Rules at http://hallikainen.com/FccRules and comments filed
in LPFM proceeding at http://hallikainen.com/lpfm

___________________________________________________________________
Get the Internet just the way you want it.
Free software, free e-mail, and free Internet access for a month!
Try Juno Web: dl.http://www.juno.com/dynoget/tagj.

1999\09\15@133917 by Marcelo Yamamoto

flavicon
face
Hi,

You can even use a 100R network to drive the display. It will drive a
current that is over the limit of the pin, but you have to have in mind that
you are multiplexing the outputs so you average current will be lower. I
have a lot of applications using that and they are working pretty good. I
have some projects using Motorola and the outputs (with some exceptions)
source or sink only 100uA so then I multiplexed them to drive a Led display.
It will minimize a blinking effect if you use a time constant too high.

Marcelo
EraseMEmarcelospam_OUTspamTakeThisOuTicel.com.br


{Quote hidden}

1999\09\15@180911 by Andre Abelian

picon face
Ian,

using 18 pins pic you can drive 4 led displays. 2 or 4 has same Principe


Andre



> I'm a bit of a PIC newbie, but i need to learn fast for a school project.
>
> I'm looking at designing a device which will time after being triggered,
in
{Quote hidden}

1999\09\15@184625 by D. Schouten

picon face
I've used the Motorola MC14489 display driver. IIRC It can drive five
7 segment displays, uses an SPI serial interface and only one current
limit
resistor for all LEDs.

Daniel...


> I'm a bit of a PIC newbie, but i need to learn fast for a school
project.
>
> I'm looking at designing a device which will time after being
triggered, in
> minutes and seconds. I therefore need to drive 4 seven segment
displays (2
> digits for minutes, 2 for seconds). I'd like to know if this is
possible
> using one 18 pin PIC (sorry, I can't remember the type that I have).
>
> I have seen (and I think I understand) multiplexing, but I have only
seen
> it done with 2 7 segs. Has anyone had experience of multiplexing 4
> displays, and if so how did you do it?
>
> If this is impossible (it may be, I haven't a clue!) what chip do
you
> recommend that I get hold of?
>
> Thanks in advance.
> Ian Miller
>

1999\09\15@190118 by Matthew Fries

flavicon
face
I am working on using a 16f84 to display a 8 LED bargraph display. When I
used one pin per LED, I ran out of inputs for other functions, so I
decided to multiplex the outputs.
I am using the "I'm really cheap, and I don't have a lot of room for
parts in this project" philosophy.

Here is what I came up with:
I have 4 lines going to the first four LEDs from the anodes, then the
same lines to the cathodes of the next four. I can then use a 5th line as
the bank select, and connect it to the cathodes of the first bank of LEDS
and the anodes of the second.

The only trouble is, (aside from the fact that I wired the leds wrong so
they light out of order (duh)) I don't think that the line that I'm
using for the select can source enough current for up to 4 LEDs at a time.

If I exceed the rating, will I burn out the outputs on my PIC, or will one
bank of LEDs just be dimmer than the other?



On Wed, 15 Sep 1999, Greg Brault wrote:

{Quote hidden}

1999\09\15@191210 by William Henning

flavicon
face
Why not use a 3:8 demux (74hc138) to select one of eight LED's with
the cathode going to the mux, and run the anode's thru a current limiting resist
or to a pin on the f84? Total of four pins.

Or, use a serial in - parallel out shift register; depending on how you want to
drive it takes two or three pins (minimum: clk + data, or clk+data+load)

Regards,

Bill

{Quote hidden}

t 7
> > data wires going to one segment, and then just daisy chain to the next
> > segment.  So if you output a certain segment, it would light up on all four
> > segments.  However, for your common cathode (or anode), instead of just runn
ing
> > it to either pos or gnd, run them each to a data pin on the PIC.  This is a
> > total of 7+4 = 11 data lines to run 4 segments.  Whichever segment you want
to
> > display data on, select that pin, and then put your data on the data lines.
If
> > you run a crystal, you can cycle through each segment fast enough that the e
ye
> > cannot tell only one segment is on at a time.  The code is up to you, I had
a
> > variable for each segment, and when it came time to light up that segment...
it
{Quote hidden}

1999\09\15@203947 by Gennette Bruce

flavicon
face
part 0 1883 bytes
<<cntdn.zip>>
Bye.

{Quote hidden}

Attachment converted: wonderland:cntdn.zip (pZIP/pZIP) (0000C78F)

1999\09\15@205611 by Russell Hay

flavicon
face
I'm pretty new to all of this but for the bar graph, I would think that you
could use an 8-bit shift register (serial in - parallel out) and just use two
lines to control the whole bar graph.  All you would need to do (this would
require a bit more in programming, but it's pretty trivial) is strobe the
clock line with the serial input high to turn on (in order) the leds.  To turn
them off, just bring the serial input low and strobe the clock line 8 times to
ensure that the bar chart is off.  Depending on the application, this may or
may not be good.  Just depends on how fast the bar graph has to move.
It is cheap, and it requests very few parts fitting in really well with
your philosophy.

-r-

1999\09\15@212548 by Gennette Bruce

flavicon
face
{Quote hidden}

       [Bruce Gennette]   I think you missed the bit about him wanting to
multiplex the displays, at any one time only *one* of the displays will be
operating, the other 3 isolated via the NPN transistors on their common
cathodes being *off*. So each display will be getting 9mA for about a quater
of the time. Cycle through the displays faster than 100 times a second and
persistance of vision lets humans see them all continuously on.

       Bye.

1999\09\15@221052 by Gennette Bruce

flavicon
face
You are likely to burn out any PIC which is directly driving LEDs without
current limiting. You need to use 620 ohm resistors (if using 5V) between
each PIC pin and LED to keep the current down to about 7mA if you want to be
able to drive 4 of them through a single port (4*7mA=28mA). [with fast
switching at about 50% duty cycle you can exceed the 20mA limit by about
50%, but don't push it any further]

Alternatively you can fix the load problem completely by passing the LED
current through 2 cheap transistors, a NPN (for Hi) and a PNP (for Lo) and
then *all* of the LEDs can be connected PIC to 330 ohm resistor to LED
anode, the Hi and Lo output from your 5th pin alternatively switching the
transistors on to pass the current to 0V. (at 5V, 330R gives about 11mA
through each LED)

[hint - for reliable switching - switch the output to all off, then toggle
the transistor pin, then wait at least 1 nop for the change to take effect,
then output the pattern on the 4 pins]

Bye.

> {Original Message removed}

1999\09\16@005311 by Matthew Fries

flavicon
face
Yeah a shift register would reduce the number of lines alright, but I am
*REALLY* tight for space (I'm cramming this into an existing enclosure). Oh
yeah, did I mention too that this was a battery operated device? (I must be
out of my freakin mind for trying this!)

When I originally conceived this project, I had a decade up/down counter and
a multiplexer, and it didn't quite work right and had too many chips... etc.

Just a couple of months ago I got some 16F84s and a programmer and then the
whole thing seemed possible again.

I have an idea to just have the select line drive a transistor. It's smaller
than an output buffer, and simpler to incorporate.

Thanks for the ideas. I can't wait to work on this a little more...


At 06:08 PM 9/15/99 -0700, you wrote:
{Quote hidden}

Remove the BALONEY from my email address.
-----------------------------------------------------
Matthew Fries       Minneapolis, MN    USA
RemoveMEfreezespamTakeThisOuTbaloneyvisi.com

"Quit eating all my *STUFF*!" - The Tick

1999\09\16@010305 by CUTTLER!

flavicon
face
You might think about an LCD (Backlit?) if possible
Kind of a Win (power)  Win (size) right?
Microchip has PICs with built in LCD drivers don't they?



>Yeah a shift register would reduce the number of lines alright, but I am
>*REALLY* tight for space (I'm cramming this into an existing enclosure). Oh
>yeah, did I mention too that this was a battery operated device? (I must be
>out of my freakin mind for trying this!)

1999\09\16@013150 by Matthew Fries

flavicon
face
I do have resistors between the pic and leds. The value is smaller, but I am
running at a lower voltage. The dual transistor idea is the best yet, but I
was hoping that I might just be able to get away with just one (when select
is high).

Thanks for the hint.


At 11:58 AM 9/16/99 +1000, you wrote:
{Quote hidden}

>> {Original Message removed}

1999\09\16@103021 by Stevens, Kurt

flavicon
face
Another possibility is the TIL311. This is a segmented display that
incorporates it's own logic. You power it separately, so that should solve
the current draw problem. Each one uses four inputs in binary fashion to
display alphanumerics from 0 thru F. The only problem you would have left to
contend with (assuming your class would allow using these) is cost. I have
found them to be over $10 (US), but you may be able to find cheaper ones
somewhere. The segments (actually dot leds) have built in current limiting
resistors with the exception of the decimals. I smoked one playing with them
(touched the wrong chip leg with my test wire), and I must say they fail
spectacularly, at least with my 3 amp PS. Looked like a mini volcano, smoke
and all!

       Kurt Stevens

{Quote hidden}

1999\09\16@122346 by Harold M Hallikainen

picon face
On Thu, 16 Sep 1999 11:25:24 +1000 Gennette Bruce
<RemoveMEbruce.gennetteEraseMEspamEraseMETAFE.NSW.EDU.AU> writes:

>>
>        [Bruce Gennette]   I think you missed the bit about him
>wanting to
>multiplex the displays, at any one time only *one* of the displays
>will be
>operating, the other 3 isolated via the NPN transistors on their
>common
>cathodes being *off*. So each display will be getting 9mA for about a
>quater
>of the time. Cycle through the displays faster than 100 times a second
>and
>persistance of vision lets humans see them all continuously on.
>

       Don't think I missed it...  How bright will each segment be with
an AVERAGE current of 2.25mA?

Harold



Harold Hallikainen
RemoveMEharoldspam_OUTspamKILLspamhallikainen.com
Hallikainen & Friends, Inc.
See the FCC Rules at http://hallikainen.com/FccRules and comments filed
in LPFM proceeding at http://hallikainen.com/lpfm

___________________________________________________________________
Get the Internet just the way you want it.
Free software, free e-mail, and free Internet access for a month!
Try Juno Web: dl.http://www.juno.com/dynoget/tagj.

1999\09\19@233706 by Gennette Bruce

flavicon
face
{Quote hidden}

       You're missing another point here - when mixing engineering with
biology you have to remember that biology has (in most cases) found the best
way to get *RELEVANT* information to the decision making area (brain).
*WHEN* the LED is getting 9mA is glows with a certain brightness that human
eyes pick up and pass on to the brain where the brain checks against how
bright it was *ABOUT* a thirtieth of a second ago; if it was about the
*SAME* then that's how the brain sees it.

       In other words biology *SEES* what in fact isn't there, but because
it *IS* there *ENOUGH* it will appear to be bright enough, even though an
engineering evaluation says it shouldn't be.

       Why don't you try it, then you'll see it works, even though you're
sure it shouldn't.

       Bye.

1999\09\20@135706 by Harold M Hallikainen

picon face
On Mon, 20 Sep 1999 13:34:40 +1000 Gennette Bruce
<bruce.gennetteSTOPspamspamspam_OUTTAFE.NSW.EDU.AU> writes:

{Quote hidden}

       True, as I recall, a discussion here recently revealed that human
vision seems to be peak sensitive instead of average sensitive, so low
power but peaky light is seen as brighter than the same power but steady
light.
       Over the years, I've just had too much trouble with unreadable
displays, so my approach now is to "hit 'em hard."  Perhaps I don't need
to.

Harold



Harold Hallikainen
spamBeGoneharoldSTOPspamspamEraseMEhallikainen.com
Hallikainen & Friends, Inc.
See the FCC Rules at http://hallikainen.com/FccRules and comments filed
in LPFM proceeding at http://hallikainen.com/lpfm

___________________________________________________________________
Get the Internet just the way you want it.
Free software, free e-mail, and free Internet access for a month!
Try Juno Web: dl.http://www.juno.com/dynoget/tagj.

1999\09\20@192750 by paulb

flavicon
face
Harold M Hallikainen wrote:

>   True, as I recall, a discussion here recently revealed that human
> vision seems to be peak sensitive instead of average sensitive, so low
> power but peaky light is seen as brighter than the same power but
> steady light.

 Such an *assertion*, rather than a "revelation" was made, but I find
it hard to support.  What aspect of the biochemical process of light
detection would do that?
--
 Cheers,
       Paul B.

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