
Flickering Tealight LED Candle Remix
thingiverse
Changelog: Added new 3D-models of my latest testbed creation. Added photos showcasing the completed build. The pcb was assembled by carefully pinching small cylinders with a soldering iron. A simple yet effective method that gets the job done. Next up is creating a pcb-design and then refining the final 3D-models. I chose to use black PLA as filament because it was already loaded in my printer. I plan to print the diffuser in white for a sleeker look. --- I found Bobthechemist's original solution fascinating, but it lacked certain features that I wanted to incorporate. So, I took his code and added a timer and voltage control to protect batteries from undervoltage. The design will also feature a modified version of the printed candle, which is still in development stages. Credit goes to Bobthechemist for the flicker-code; it's truly impressive-looking. You can adjust three individual variables at the beginning of the code: Vwarn: When the battery reaches this voltage, the brightness will be reduced by half, serving as a clear warning to recharge the battery. Vsleep: When reaching this voltage, the system will enter "deep" sleep mode to protect the battery. Runtime_hrs: This variable determines how many hours from connection the LED remains active. The rest of the day, the system will be in sleep mode. You can also modify intensity and flicker settings, but I found them suitable as is. Pre-entered values are for a single-cell LiPo-battery (3.7 V, 150 mAh) with a runtime of six hours. I'm still testing the code, but it appears to be working effectively. Please note that this code is specifically designed for an Attiny85 microcontroller running at 1 MHz clock frequency. Other Attiny versions may require different register programming and flicker settings due to varying frequencies. The code is currently in alpha version as there are some lines left for serial communication. It's also not polished, as it was my first coding attempt after a long break from the keyboard. With the current circuit and an adafruit sequin LED, the system draws approximately 3 mAh when active and around 0.3 mAh when inactive. This translates to roughly 1 mAh per hour of runtime, leaving room for my 150 mAh LiPo-cell to potentially last four to six days. Still testing... The txt-file should work seamlessly with PlatformIO as .cpp or .ino in ArduinoIDE. I've included two pictures of my breadboard testbed with a multimeter measuring current for your reference.
With this file you will be able to print Flickering Tealight LED Candle Remix with your 3D printer. Click on the button and save the file on your computer to work, edit or customize your design. You can also find more 3D designs for printers on Flickering Tealight LED Candle Remix.