MAX7219 and 4x7-segment LED's

I’m new to electronics and would appreciate a little guidance please. I want to drive a number of 7-segment LEDs and know that a MAX7219 driver chip can control up to 8 numbers on a 7-segment LED. Is it therefore possible to drive 2 4x7-segment LEDs from 1 MAX7219 driver chip? I was wondering that if you connect pins #14, #16, #20, #23, #21, #15, #17 from the MAX7219 to pins a, b, c, d, e, f, g on BOTH the 4x7-segment LEDs, then pins #2, #11, #6, #7 to each of the 4x7-segment LEDs separately would that work? Or do you need a dedicated MAX7219 driver chip for each 7-segment LED?

I’ll be running them from an Arduino UNO.

You can drive 2x 4 digit seven segment displays from a single MAX7219 but remember the displays ideally need to be of the common cathode type.

AndyInSurrey:
I was wondering that if you connect pins ... to each of the 4x7-segment LEDs separately would that work?

TL;DR. As long as both displays are either common cathode or common anode and you parallel like elements the same over two or more display modules as you would within a single display, it will work.

Riva:
remember the displays ideally need to be of the common cathode type.

Only if you only want to display digits and thus want to avoid generating the display font in software.

But if you want flexibility, common anode or common cathode becomes entirely moot.

Before you buy anything, tell us about these displays - how big & what is the forward voltage and max current of the segments?

Paul

Thanks for the replies, I was sure it should work. So, I connect to the MAX7219 to the a, b, c, d, e, f, and g pins on both LEDs (of which I was going to get the common cathode type), and then the D0, D1, D2, and D3 on one LED and D4, D5, D6 and D7 on the other?

PaulRB:
Before you buy anything, tell us about these displays - how big & what is the forward voltage and max current of the segments?

Paul

I haven't got that far yet, I'm just starting to plan the whole board first. Once I know what I need and sizes of LEDs etc... I will ask some more questions.

I do know that I will require:

2 x 1x7-segment red LED approx 16mm tall
2 x 4x7-segment red LED approx 18mm tall
20 x 3x7-segment red LED approx 18mm tall

I know I will need an external power supply say 9V, 500W, ????

If the segments need more than 5V (which is likely for segments which are made of several LEDs connected in series, which is how the height is supported) than the MAX7219 will not work without more hardware.
On the other hand, 18mm = 1.8cm = 0.7", which is pretty small and could still be single LEDs/segment.

AndyInSurrey:
2 x 1x7-segment red LED approx 16mm tall
2 x 4x7-segment red LED approx 18mm tall
20 x 3x7-segment red LED approx 18mm tall

Those sound fine for use with max7219.

AndyInSurrey:
I know I will need an external power supply say 9V,

If nothing in your circuit needs more than 5V then get 5V. Anything else would just waste power. You can run the Arduino off 5V also (just not through its barrel connector).

AndyInSurrey:
500W, ????

500W? What else will this circuit be doing? That's 100 Amps at 5V!

Someone suggested I come back here before ordering any 7-segment LEDs. I need the following:

  • 2 x 2x7-segment red LED common cathode 14.2mm character height
  • 2 x 4x7-segment red LED common cathode 14.2mm character height
  • 20 x 3x7-sgement red LED common cathode 14.2mm character height

I have 8 MAX7219 chips already so will need another 4, to run the above LEDs.

Can anyone recommend where to source these from?

My project is going to have the following:

  • MAX7219 from which I will control 2 3x7-segment common cathode LEDs (part number: BC56-13SURKWA). There will be 20 of these i.e. 20 x MAX7219 each controlling 2 of these 3x7-segment LEDs
  • MAX7219 from which I will control 2 2x7-segment common cathode LEDs (part number: HDSP-5523-GH000). There will be 1 of these i.e. 1 x MAX7219 controlling these 2 2x7-segment LEDs
  • MAX7219 from which I will control 2 x 4x7-segment common cathode LEDs (part number:FJ5461AH). There will be 1 of these i.e. 1 x MAX7219 controlling these 2 4x7-segment LEDs

The circuit will also have a ATmega168PU and the components that are required to control the voltage to 5V i.e. an Arduino on my circuit board rather than a child board. Plus I will have a 12 button number-pad.

I have two questions:

  • How do I calculate the entire circuit power requirements?
  • How do I calculate the resister value for each MAX7219 with the LEDs each is controlling? This is the resister that goes from Vcc to pin 18 on the MAX7219.

I also have 2 capacitors in parallel between Vcc and pins 4 & 9 on the MAX7219, I think these are 10uF and 100nF respectively.

I'am happy to supply any further info if required.

Many thanks.

Hi,
What is the application that requires all those displays?

Tom.... :slight_smile:

TomGeorge:
Hi,
What is the application that requires all those displays?

Tom… :slight_smile:

It’s a darts scoreboard. The 2x7-segments, 1 for Home and 1 for Away, hold the number of legs won. The 4x7-segments are for the game target score i.e. 501, and again 1 for Home and 1 for Away. The 3x7-segments are for darts score for last throw and running total counting down, 5 rows for both Home and Away.

The programming side isn’t a problem as I’m a professional C++ programmer.

AndyInSurrey:
MAX7219 from which I will control 2 3x7-segment common cathode LEDs (part number: BC56-13SURKWA). There will be 20 of these i.e. 20 x MAX7219 each controlling 2 of these 3x7-segment LEDs

So that's 120 digits, which should really only need 15 max chips. Each group of 3 max chips would control 8 3-digit displays. However, to make that saving, you will need to change to using 2-digit displays. This might make the wiring more difficult, depending how you plan to construct the whole thing. If so, easier to stick to your 20 max chips design.

AndyInSurrey:

  • How do I calculate the entire circuit power requirements?
  • How do I calculate the resister value for each MAX7219 with the LEDs each is controlling? This is the resister that goes from Vcc to pin 18 on the MAX7219.

First check the data sheet for your displays. For those 3-digit displays, the data sheet says on page 2 that the forward voltage (Vf) is typically 1.95V. It also says that the continuous current is 30mA and that the max current is 185mA with a 1/10 period with pulses of 0.1ms. Using max7219, you will be using a 1/6 or 1/8 period, and at most 40mA current, which is all the max chips can handle, so that should be fine.

Next, check the max7219 data sheet.. On page 11 there is a table which helps you choose a resistor value. Your VLED is nearest to 2.0V and you will probably want 40mA for brightness. This gives a value of 11.8K. Choose the next highest value you can find, probably 12K.

At 40mA per segment, each max7219 will draw 280mA. This is shared between the digits. More digits per max chip means slightly dimmer displays.

PaulRB:
First check the data sheet for your displays. For those 3-digit displays, the data sheet says on page 2 that the forward voltage (Vf) is typically 1.95V. It also says that the continuous current is 30mA and that the max current is 185mA with a 1/10 period with pulses of 0.1ms. Using max7219, you will be using a 1/6 or 1/8 period, and at most 40mA current, which is all the max chips can handle, so that should be fine.

Next, check the max7219 data sheet.. On page 11 there is a table which helps you choose a resistor value. Your VLED is nearest to 2.0V and you will probably want 40mA for brightness. This gives a value of 11.8K. Choose the next highest value you can find, probably 12K.

At 40mA per segment, each max7219 will draw 280mA. This is shared between the digits. More digits per max chip means slightly dimmer displays.

Thank you very much for your advice, very helpful indeed. Please pardon my ignorance, but where you say:

"Using max7219, you will be using a 1/6 or 1/8 period, and at most 40mA current...

How did you calculate the value of 40mA?

How would I then calculate the total power requirement for the whole circuit?

AndyInSurrey:
It’s a darts scoreboard.

At this rate, it would certainly be easier and just as likely cheaper, and definitely more versatile to use a Raspberry Pi and a 22 inch (or larger) display monitor (AKA: TV).

AndyInSurrey:
How did you calculate the value of 40mA?

From page 11 of the data sheet:

The
MAX7219/MAX7221’s maximum recommended segment
current is 40mA.

PaulRB:
From page 11 of the data sheet:

Thank you

Re the 4-digit 7-segment LED part number FJ5461AH, from the spec document:

Peak forward current (10% duty cycle, 0.1ms max) 80 mA
Maximum power dissipation 75 mA
Maximum continuous forward current 20 mA
Recommended continuous forward current 12 mA
Maximum reverse voltage 5 V
Operating temperature -25oC to +85oC

But it doesn't mention the "DC forward voltage". Can anyone calculate what it is from the above figures so that I can then work out what the required resistor value should be used, for the MAX7219 that will be running this 4x7-segment LED.

Thank you.

That is a rubbish data sheet!

Its probably also around 1.9-2.0V. You can measure it easily enough with a dmm and a resistor ~300R.