It’s that time of year at which the Christmas lights are coming out of storage, isn’t it. Some modern seasonal rituals: untangling half a mile of fairy lights, and replacing a pile of CR2032 cells in LED candles.
[RobBest] had a solution to the latter, owning a set of nifty rechargeable LED candles that came with their own wireless charger. Sadly the charger wasn’t working quite as intended, as the indicator light to show when it had finished its cycle was always on. How could he indicate that the induction system was in operation?
His answer was to take a non-functioning candle and strip it down to expose its induction pick-up coil. He could have simply hooked it up to an LED for a quick result, but since the device in question was a candle it made sense to give it a candle effect. A PIC microcontroller was therefore pressed into service to drive the LED with its PWM output, giving a pleasing flickering effect.
You don’t have to own a set of electronic candles to have a go at wireless charging. Instead you could try a trip to IKEA.
There was a Had article on musical greeting card noise maker being the source of the flickering in some of these things.
Many candle simulators use random numbers or even melody chips as featured on HaD. When I tried to make PIC candle simulator I tried example from GitHub (EternityForest/CandleFlickerSimulator) and it works great. It even emulates periodical wind gusts that make candle flicker bit faster, then it gets steady again. Pretty convincing. I used it with ws2812 but I guess you can use any orange LED with similar success.
Baaaah its not even December…… grumble mutter mutter