1307 data to 7 Seg Display
Cenlasoft
Posts: 265
in Propeller 1
Hello,
Thanks to this forum, I have created a digital clock using the 1307 RTC with spin. My results (Time) is going to the serial terminal. I would like the time to be displayed to 4 seven segment displays (common anode). Any ideas would be appreciated. Thanks, Curtis
Thanks to this forum, I have created a digital clock using the 1307 RTC with spin. My results (Time) is going to the serial terminal. I would like the time to be displayed to 4 seven segment displays (common anode). Any ideas would be appreciated. Thanks, Curtis
Comments
Then you will need to convert the binary (BCD, actually) time to segments. I would use LOOKUP if I was doing it in Spin. But long before you do that, you need to get your display working.
The DS1307 registers are BCD, so you can use this to extract the 1s and 10s digit from each register. That can be as an index into a table of segments that correspond to the value.
Curtis
I would be inclined to tie the anodes direct to +12V and control the cathodes with a constant current driver like Texas Instruments TLC5916 (four pieces, one for each digit). One nice thing about the 5916 is you can program the current (and thus the intensity).