This Simulated LED Flame Flicker project is just the thing that is needed for all of those pumpkins that will be put out this year. It can run sufficiently long on a battery and will not burn anyone. The code is not up yet but should be posted soon.
"The code accepts an arbitrary number of LED outputs, with a minimum brightness for the general glow. A peak brightness and traversal time are generated randomly, and the timed traversal smoothly walks across the outputs. The peak falls off, so the effect is of a smooth motion of the peak across the LEDs, to an arbitrary position along the line of outputs (as a float, rather than always peaking at a specific light). When arranged in a circle, it feels like the light is moving around the group, which casts moving shadows, and gives a flickering effect that’s much more convincing that a single light variably changing brightness."
Permalink
Uh, I think the developer can do a lot better. The randomness of that isn’t very realistic. Two approaches: strange attractors or record a real candle flickering. I’ve done both and the recording works like a charm.
Also, the next generation needs to use RGB LEDs to be able to “bend” the color – flickering candles change their color slightly.
Permalink