Twinling LEDs?

Hi.

I got a bunch (around 100) of white LEDs. I'd like to build a small disc with twinkling LEDs. How would I do this?

I've hunted around the forums and found references to using 555 timers. However, I would imagine that to cut down on the number of 555s I'd have to drive a number of LEDs off of each one, thus loosing the randomness that I'm looking for.

I'm good at following circuit diagrams provided everything is labelled but suck at understanding behind some of the more complex workings! (I didn't always pay attention in electronics class)

Are there any websites with circuits depiciting what I want?

Thanks,

Al.

Reply to
key130
Loading thread data ...

There's a 556 dual 555, and I think even a quad version (557?)

There were also some special LED flasher chips simpler than the 555.

Some of the self-flashing LED's could handle a few additional LED's in series.

Other ideas might be a random number generator chip, or some kind of simple ring or ripple counter driving a small rom chip.

Smallest physical solution is probably to get a bunch of small microncontrollers (PIC, basic stamp, etc) and use each one to drive as many unique signals as possible. That could be an interesting learning experience.

Reply to
cs_posting

Google on "PN sequence". With a few feedback taps (exclusive or gates) you can make a shift register produce a pseudorandom sequence. Drive each LED off a stage of the shift register. A

53-stage maximal length sequence would have about 9 quadrillion states. If clocked twice a second it would go for 142 years without repeating.

You could also use several shorter PN sequences, say 16-stage that would repeat about every 2 minutes -- and drive them with separate clocks whose frequency will vary slightly from one another. That would make it "twinkle" more because the switching times would look more random.

You might use inverters with an N-stage PN generator, driving half of the LED's directly and the other half with the compliments. Then every state would illuminate half of the LED's.

Reply to
Don Foreman

PS

Many years ago I made my 8-year-old son a "robot" Hallowe'en constume based on this. We covered a cardboard box with foil, said box having two armholes and a head hole. The "sleeves" were made of flexible dryer vent. There was a little aluminum box on his chest with 7 or 8 LED's and a little speaker. A PN sequence (7 or 8 stages IIRC, one or two CMOS packages) drove the LED's, also frequency-shifted a simple audio oscillator so it made tones that changed randomly. I think I only used 3 bits for the sound, giving 8 different notes. Sometimes a note would "hold" for two or more clock periods as the sequence progressed thru states where there were more than 3 contiguous 1's in the register.

I wish I had video of him walking stiffly (like a robot), flashing and beeping away.....

Reply to
Don Foreman

First, define 'twinkle'. From a human perception perspective, I believe a twinkle is on most of the time with off durations following a random pattern governed by some rule with a decreasing off duration as the time between off events decreases. Some astronomical web sites might lead you to the characteristic for star twinkling.

Any kind of flashing circuit may suffer from fixed off durations even if the intervals are random. The human eye (and mind) can pick this pattern up pretty easily.

If you want to go to this length to get an authentic looking effect, probably the best way to do it would be with a microcontroller.[1]

You would have a table of variables, one set for each LED and a loop to run though the table, applying the appropriate randomization formula for each. The output can be fed out in a serial format to drive a demultplexer/LED driver chip. These are designed to drive 8x8 arrays of LEDs and include constant current outputs. They can be chained to drive multiples of 64 LEDs.

The microcontroller will give you the ability of testing the 'twinkle' parameters to optimize the effect without changing hardware. If you go with a hardware solution (555s or whatever) breadboard a single LED twinkler and play with component values until you get a pleasing looking twinkle.

From a circuit standpoint, the microcontroller and LED driver will be the easiest to build. It has the lowest parts count. Its the software complexity that is important, if that's a skill you have or are willing to learn.

[1] There was a Circuit Cellar article on building an animated LED display of the 'Life' game a year or so ago that uses this approach. The layout and s/w will be different, but the basic design concept may be a starting point.
--
Paul Hovnanian     mailto:Paul@Hovnanian.com
------------------------------------------------------------------
Speed is n0 subsittute fo accurancy.
Reply to
Paul Hovnanian P.E.

famous last words....

Reply to
Fred Bloggs

Seeing as how you're going to get a bunch of stupid suggestions, the simplest approach is to us a bunch 74HCT393 dual 4-bit counters ( total

8-bits), hit them with random high frequencies clock bursts of unnoticeable duration like 10ms at your twinkle frequency. You can mix up the counters that get bursted so they all do not twinkle at once. The '393 is a low cost 14-pin chip. The end result is that the counters randomize the LED drives. The schematic shows 8 of them twinkling at once- you may want to experiment with 16, 24, 32, 40, 48, etc- just join the AND gate inputs together and shorten the 74HCT4017 cycle. View in a fixed-width font such as Courier.

. . 74HCT08's . STORE BOUGHT gated 10MHz . JOB AND 5V . +-----+ GATEs |||| 74HCT393 | . |10MHZ| __ - - ---- | . | |----------| \\ __ | | | . |OSC | | >--------+-| \\ | |-R--|---CLK | | . | +-----|__/ | | . | . | | | | | . | . | | | | | . | . | | | | |-R--|

Reply to
Fred Bloggs

There was a recent artlce in Nuts & Volts magazine for controlling a set of LED to flicker like a candel for Halloween....used a microcontroller to randomize the process.

October 2005 Issue STAMP APPLICATIONS Tricks and Treats With LEDs

formatting link
formatting link

Reply to
AntiSPAM_g9u5dd43

If you're a stickler for glare, you can use the other half of the

74HCT123 to CLEAR the unselected counters- turning all of them on. View in a fixed-width font such as Courier.

. . 74HCT08's . STORE BOUGHT gated 10MHz . JOB AND 5V . +-----+ GATEs |||| 74HCT393 | . |10MHZ| __ - - ---- | . | |----------| \\ __ | | | . |OSC | | >--------+-| \\ | |-R--|---CLK | | . | +-----|__/ | | . | . +----------+ | | | | . | . | | | | | . | . +----------+ +----------+ | | | MR |-R--|

Reply to
Fred Bloggs

If you do that then you lose the randomization- so the '123 10ms one-shot must be noised up. This is done with a cheap zener based current source into its RC timing node. View in a fixed-width font such as Courier.

. . 74HCT08's . STORE BOUGHT gated 10MHz . JOB AND 5V . +-----+ GATEs |||| 74HCT393 | . |10MHZ| __ - - ---- | . | |----------| \\ __ | | | . |OSC | | >--------+-| \\ | |-R--|---CLK | | . | +-----|__/ | | . | . +----------+ | | | | . | . | | | | | . | . +----------+ +----------+ | | | MR |-R--|

Reply to
Fred Bloggs

It is simpler to use a second 555 to randomize the 10MHz gate duration from 1-10ms like so: View in a fixed-width font such as Courier.

. . 74HCT08's random . STORE BOUGHT gated 10MHz . JOB AND 5V . +-----+ GATEs |||| 74HCT393 | . |10MHZ| __ - - ---- | . | |----------| \\ __ | | | . |OSC | | >--------+-| \\ | |-R--|---CLK | | | +-----|__/ | | . | 10ms | | | | | . | --- 9ms -| | | | | . | | |___| | | | | MR |-R--|-+ +-|---|-----------+. | | | +-|__/ | | | . | | | | | | | . | +-----+ | | | | . | | | | | . | . | | | | . | . +----------+ +----------+ | | | . | . | 10MS | | 1US | | | | 12x '393 | . | ONE SHOT | | ONE SHOT | | | | 96 LEDs | . | EDGE TRGD| | EDGE TRGD|-+ | | . | . +----------+ +----------+ | | | . | . | 74HCT123 | | | | . | . | | | | | . | . +----------+ | | | | . | | | | 74HCT393 | . +--555 --+ | | | | ---- | . | | | | | | __ | | | . | TWINKLE|-----+ | | +-| \\ | |-R--|---CLK | | . | CLOCK | | | | .+-|__/ | | . | . | | | | | | | | . | . | 1HZ ? | | | | | | | . | . +--------+ | | | | | MR |-R--|

Reply to
Fred Bloggs

What's wrong with just a whole lot of self flashing LEDs? They won't stay in sync long after powerup.

--
Dirk

The Consensus:-
The political party for the new millenium
http://www.theconsensus.org
Reply to
Dirk Bruere at Neopax

You can buy a twinkling LED (electronic tea light) with LR44 batteries at Michaels for a few dollars. Probably uses a tiny COB ASIC.

Best regards, Spehro Pefhany

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

Wow!. Thanks for the useful replies - an active newsgroup!

Need to do some research on PN Sequence as I have no idea what that is. I'm not going to use a microcontroller at this stage as it's way beyond what I want to learn, but maybe for the future. And to define twinkling - the usual effect of a light being bright then less bright and varying inbetween.

Regards, Al.

Reply to
key130

How hard is it to understand "twinkling star"? He wants something that looks like what about six billion people on the Earth recognize as stars twinkling.

Twinkling is scintillation (aka fluctuation) of the apparent brightness of the star caused by gaseous atmospheric turbulence re-directing the light flux off pupil. The statistical characterization of the scintillation distribution is a subject of cutting edge research for purposes of devising signal processing algorithms to increase SNR in astronomical photometry measurements. It is an intractable problem complicated by all sorts of nonstationarity against every variable known to influence it, and not likely to be of much use any time soon. I'm sure the bit heads at CC did the log normal amplitude randomization of LED brightness with realistic variation of the autocorrelation over a thousand to one range while using calendar data for best seasonal effect- not.

Reply to
Fred Bloggs

As you might expect from the word, digital, most circuits turn the LEDs on and off, this is not a varying brightness. To vary the brightness, the LEDs would have to be PWM'ed, and since star scintillation is usually independent, you will need 100 PWM'ers. The LEDs cannot be time shared with a single PWM because that would restrict the PWM control to only 1/100th the revisit time. If you break the LEDs down into say 8 groups of 12, total 96, and position the LEDs from a single group evenly among the LEDs from the other groups, then this should be effect enough when you modulate the brightness of the groups independently with 8 PWM'ers.

Reply to
Fred Bloggs

In article , Dirk Bruere at Neopax wrote: [...]

Make sure you bypass the supply or the silly things may stay in sync.

--
--
kensmith@rahul.net   forging knowledge
Reply to
Ken Smith

Not very easy, according to what you wrote below.

But for the purpose of human perception, there is probably a characteristic amplitude vs frequency modulation that will produce a suitable twinkling effect. They do this in planetariums and I doubt they go through all the trouble of modeling the actual atmospheric effects as you described above.

Heck, they don't even try to model it for astronomical purposes. They just measure it in real time and apply suitable corrections to the telescope optics. The same thing is done with spy satellites looking down through the atmosphere.

--
Paul Hovnanian     mailto:Paul@Hovnanian.com
------------------------------------------------------------------
Hit any user to continue.
Reply to
Paul Hovnanian P.E.

Speaking of that, what's in a flashing LED anyway?

Thanks, Rich

Reply to
Rich, Under the Affluence

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.