I know how to build a big digit but how the heck did you control that much current with such few ICs and such few control lines? Ahh, I’m glad you asked. Here are some fun pointers about how to control large numbers of seven segments LEDs.

Now if you’re not a hardware person, get ready for some technical jargon.

A PIC 16F877A has quite a few I/O pins (around 32). But if you start doing the math, you see just how limited we are.

6 digits * 7 segments = 42 channels

Sure, we could find a microcontroller that has 42 available I/O pins, but there’s got to be a better way! This is actually an age-old problem. Turns out there are chips out there! The 74HC4511 is the magical chip that takes a Binary-Coded-Decimal (BCD) input and outputs the correct pins to create that binary number on a seven-segment display.

Okay, so we go from seven lines down to four, big deal? There is a latch on the 74HC4511. This latch allows us to share the 4-bit bus with all the channels, and then just toggle the latch pin on the digit we need to talk to. Maybe a schematic will help:

You can see four Control lines. This is the BCD bus. There is also six Driver lines. These Driver lines activate the latch on each ‘channel’.

U6 is the 74HC4511. U7 is a ULN2003A. JP1 is the RJ45 jack. Just stick with me a bit longer!

The ULN2003A is a high-current Darlington array. Darling what? This IC has seven channels. Each channel can control up to 500mA. When 1B goes high, current is allowed from the ‘1C’ input to ground.

So when the Num1_f pin goes high, current flows from RAW, through the LED Light Bars in the big digit, into 1C, and then out through GND. This may seem a little bit odd at first. Maybe this will help:

Okay so now for the chain of events.

The PIC parses out the GPS time from NMEA sentences coming out of the Lassen iQ receiver at 4800bps.
The PIC decides that the time is 6:45:33, so a ‘3’ needs to be displayed on channel 1.
A binary three (0b.0011) is put onto the bus.
Driver1 is pulled low, then driven high. Because all other driver lines are kept high, the other drivers ignore this bus data.
The 74HC4511 for channel 1 sees this binary number, notices that it’s been latched, and then outputs the correct segments to light up a three. Segments A, B, C, D, and G go high.
The ULN2003A detects these lines (Num1_a, b, c, d and g), goes high and allows current to sink through 3C, 4C, 5C, 6C, and 2C.
The LED Light Bars inside the digit (located farthest to the right) light up the correct bars to display a three.

It’s really pretty slick. The system is completely scalable. To add another seven-segment display requires only one additional I/O pin for another DriverX line. The PIC 16F877A could control as many as 28 digits. Have you ever seen 28 digits next to each other? How about 18″ wide and on a wall? That’s really huge.

That’s it! Sorry the tutorial ended up being so long. This project took about two weeks of cutting and figuring out how to best create the digits. The firmware took about an hour and hardware layout took about three (we’ve used most of the basic components before). Let us know what you think.