This blog is about all my projects together. Look through them and find whatever you want!
|Posted by steen.nick on March 14, 2013 at 4:05 PM||comments (12)|
From now on, I'll post my projects on this blog, which might be easier to read, and a lot more simple to update for me. Starting with this clock project I've been working on:
This projects started out as a simple 8x8 matrix, which is fairly simple. Using an Arduino and 2 74HC595 shift registers, I was able to acheive a very high framerate without any flicker on the LED matrix. Usually, to drive an LED matrix like this, each LED is driven one by one, resulting in 64 loops for one screen refreshment. I drive one colum at a time, resulting in 8 loops for one screen refreshment, thus the time needed for this refreshment is 8 times smaller. Also, using the regular shiftout and digitalWrite was banned from my code, since I only use low(er) level C commands, such as PORTB |= _BV(PB0) to set pin 8 at HIGH, and PORTB &= ~_BV(PB0) to set pin 8 low. This instruction needs 1/8th of the time of digitalWrite.
The result of all this experimenting led me to the idea of making a clock out of it, since 8x8 is enough pixels to display text. I also realised I was only using 5 pins of the arduino; 3 for the daisy chained shift registers, and 2 for two buttons (one to set the mode of the clock, one to switch to settings), the code only took up 7kB and the speed was only 16MHz. This mad me think of porting it to a ATtiny85, which I did. After some troubles to link the compiler correctly to the Arduino IDE, I managed to realise this idea. The alfa-stage prototype is now running on a breadboard, with this ATtiny85 and 2 74HC595's.
I couldn't resist to make a 3D render of what it should become when finished, and this step isn't far away anymore.
A friend of mine made the aluminum base, and I created a small but working protoboard, ported the source to ATtiny85, the LED's arrived yesterday, and everything is set up to be finished.