144 7-Segment Displays Combine To Form A Mighty Clock

What do you do with 144 7-segment displays? If you’re [Frugha] you put them all together to create an epic clock. Each display has 8 individual LEDs — 7 segments, and a decimal point. Put that all together, and you’ve got 1152 individual LEDs to control. This presented a problem, as [Frugha] wanted to control the clock with a single Arduino Nano. Even charlieplexing won’t get you that many I/O lines.

The solution was a nifty little chip called the MAX7219. The ‘7219 speaks SPI and can control 64 individual LEDs. [Frugha] used 18 of them in the clock, giving him full control over all his LEDs. That’s pretty impressive, considering the last matrix 7-segment display we saw required 48 Arduinos!

Another problem is memory – 1152 “pixels” would quickly overrun the 2KB RAM in the ATmega328. This is a clock though — which means only digits 0-9 and a colon. [Frugha] picked a nice font and hand-coded lookup tables for each digit. The lookup tables are stored in ROM, saving precious RAM on the Arduino.

A clock wouldn’t be any good if it wasn’t accurate. A Tiny RTC supplies battery-backed time data. [Frugha] wrapped everything up with a neat layout on a custom PCB. Sure, you could put it in a case, but we think a clock this crazy deserves to be left open – so you can see it in all its glory.

23 thoughts on “144 7-Segment Displays Combine To Form A Mighty Clock

  1. I would serious question this general HaD statement: “A clock wouldn’t be any good if it wasn’t accurate. A Tiny RTC supplies battery-backed time data.” This is not the first time that this has be said without any actual accuracy figures.

    A RTC module does not imply accuracy. It is only as good as the crystal used. In fact the particular RTC module has an *external* crystal means that whoever *slap* this together might not have used the cheapest crystal and not gone through the trouble of calibrating it. The newer better RTC chip would at least have a factory calibrated RTC with some levels of accuracy.

    FYI: I made a firmware only RTC with a 24-bit NCO for calibrating against tolerances. It has been tested and measured to +/- 1 sec/month in real life. https://hackaday.io/project/169509-a-very-accurate-led-clock

    1. What are you doing about temperature compensation? The most accurate crystals use a heating element to keep it at a stable and known temperature. Check out crystal ovens

  2. I like it until you realize the MAX7219 is a $9 chip and they used 18 of them.
    I recently got a bulk of alphanumeric 16 segment displays and have been looking for an economical way to control them all in a similar fashion as this. I’m expecting to throw a bunch of cheap AVR ATTINY chips at it.

  3. There is a whole range of LED und key controller chips by Titan electronics. Available at lcsc.com for 20..40 cent each:
    TM1638: 10×8 LEDs, 3×8 keys, SPI-like interface
    TM1640: 16×8 LEDs, no keys, I2C-like interface
    and many more, these two would be best suited for this project.

    They are meant for the user interface part of DVD players and similar devices. The popular china boards with 8 7-segment displays, 8 LEDs and 8 keys are based on the TM1638.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.