The final candle code(?)
Those who have been with this channel for awhile would know that this fake candle obsession of mine dates back at least to 2017!
Over the years this one project has driven my understanding of code, both C and ASM, as well as some deep dives into microprocessors such as the PFS154 and the ATTiny13A. I've learned about "randomness" and even written a book on Assembler.
Now I feel like it's time to release all the code into the wild (well as wild as github gets) and also pose a question for you - if you could download working candle code for an ATTiny13, or ATTiny85, or a CH32V003 - would you be interested?
The code is pretty mature now and the latest version (just 1.8kB compiled) contains such elements as:
- 32 bit PRNG Xorshift code
- Noise seeding the random generator using the timer and the comparator
- Dusk/Dawn Hysteresis
- Code efficiencies including array dimension
- Super capacitor over discharge protection
Enjoy the video, and the repository, and please comment if you'd like to see the project extend to other micro-controllers, and name your favourite!
Links:
- PFS154 Code Repository
- ATTiny13 Candle (C)
- ATTiny13 Candle (ASM)
- AVR code by example book
- Hysteresis
- FreePDK Repo
- Dieharder

No comments:
Post a Comment