Arduino Forum

Using Arduino => LEDs and Multiplexing => Topic started by: pgmartin on Jul 11, 2011, 12:59 am

Title: Double Digit 7-Segment Multiplexing
Post by: pgmartin on Jul 11, 2011, 12:59 am
I have some Common Anode 7-Segment LED diplays. Is there any library to run them?
Title: Re: Double Digit 7-Segment Multiplexing
Post by: CrossRoads on Jul 11, 2011, 01:51 am
Sure. Did you search for any?
How many is "some"?
Someone posted very recently even a sketch to multiplex 3 digits, part of a 900 second countdown timer.
http://arduino.cc/forum/index.php/topic,65026.15.html

Did you want to control them via shift register to save pins? (1 register per digit)
Did you want to multiplex them? (7 IO pins, plus anode control per digit, perhaps a compination of shift register & anode contriol/digit?)

Scroll down here to LED stuff
http://arduino.cc/playground/Main/InterfacingWithHardware#Output, see if anything suit your fancy.
Title: Re: Double Digit 7-Segment Multiplexing
Post by: pgmartin on Jul 11, 2011, 02:24 am

I have 2 digits displays, common annode, and my idea was to multiplex them using PNP transistors, without a shift register.
This links you sent are enough help.
Now I´ll have to strat experimenting with the timer interrupt code.
Thanks!
Title: Re: Double Digit 7-Segment Multiplexing
Post by: CrossRoads on Jul 11, 2011, 02:42 am
Timer interrupt? Seems like overkill.
Use blink without delay, every pass thru loop see if 5-10-15mS have gone by and drive the other digit if it has.
Title: Re: Double Digit 7-Segment Multiplexing
Post by: mkrumpus on Jul 11, 2011, 09:13 pm
@pgmartin,
You could look at the library I provide with the Digit Shield.  I use timer interrupts to automatically handle the multiplexing so that your Arduino sketch can do other useful things without worrying about the timing of the multiplexing.
http://nootropicdesign.com/digitshield/ (http://nootropicdesign.com/digitshield/)
Title: Re: Double Digit 7-Segment Multiplexing
Post by: Techone on Jul 12, 2011, 05:20 am
Hi guys; I just post a program to multiplex 2 digit. It count from 0 to 99 and repeat. Not test yet. It use a 7447 BCD to display decoder. Here the link.
http://arduino.cc/forum/index.php/topic,65026.30.html (http://arduino.cc/forum/index.php/topic,65026.30.html)
Title: Re: Double Digit 7-Segment Multiplexing
Post by: Techone on Jul 13, 2011, 05:58 pm
@ pgmartin

I just finish testing and refine my 2 digit multiplex program. It work fine. Check the new post up. Same link of July 11 post.
Title: Re: Double Digit 7-Segment Multiplexing
Post by: pgmartin on Jul 15, 2011, 05:36 pm
@Techone: Will, do. Thanks!