# MAX7219 and higher voltage LED displays - how? Reply to Thread

Discussion in 'LEDs and Optoelectronics' started by yesyes, Mar 10, 2011.

1. ### yesyes

15
0
Mar 9, 2011
Hi,

I'm new here but not at all new to electronics. But here is one I just can't get my head around.

I'm looking for a solution to drive 3 inch 7-segment common cathode LED displays with a MAX7219 LED driver IC.
The displays require 9V 20mA per segment. The 20mA is well within the MAX7219's max segment current of 40mA.

However, the MAX only provides 5V to the segments. I've tried this and the only segment that comes on is the decimal point (through a zener diode) as that requires only 4V.

I've done some searches on the internet and I've found several ways to approach this problem but they all don't really apply to my situation.

I've found a MAXIM application note that describes driving displays with higher voltage but they require common anode displays. I have already bought the common cathode displays and wouldn't want to spend more money on common anode displays.
http://www.maxim-ic.com/app-notes/index.mvp/id/1196

The other thing I found is in the MAX7219 datasheet on page 12. It uses the MAX394 quad analogue switch IC to drive a MOSFET per digit. 2 problems with that solution are that a) it seems to be for higher current, not higher voltage (supply voltage still at 5V) and b) I can only find the MAX394 as SMD and I don't have SMD soldering equipment.
http://datasheets.maxim-ic.com/en/ds/MAX7219-MAX7221.pdf

I've been thinking about this for a while but just can't work it out. If this was logic outputs I'd probably find a way. But since both anode and cathode of each segment are connected to the MAX directly in a matrix kind of way I just can't get my head around this.
The best thing I could come up with is to use a matrix of 64 opto-isolators. But that would be slightly exaggerated, I hope.

Does anyone have any further ideas, please?

Chris

2. ### (*steve*)¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥdModerator

25,131
2,662
Jan 21, 2010
I imagine the normal arrangement is something like this:

Perhaps with resistors in series with the outputs from the MAXxxx chip.

To drive a higher voltage common cathode display you need to drive each segment with a level converter like this:

You can't do it with a single transistor because you'll drive current through the protection circuit of the MAXxxx chip. A similar problem exists if you decide to use a mosfet.

Basically an output low signal from the MAXxxx chip turns on the first (NPN) transistor which turns on the second (PNP) transistor. you can probably design this more efficiently so that it uses fewer resistors.

File size:
8.6 KB
Views:
3,209
File size:
12.4 KB
Views:
4,970
3. ### yesyes

15
0
Mar 9, 2011
Thanks for that Steve.
This is something I thought about as well. problem is that the cathodes of each digit do not connect to ground but to the digit driver (sink) part of the MAX. The MAX multiplexes the digits (up to 8 digits) and arranges the segments in a matrix kind of way. The digit drivers sink the current for each digit. The segment drivers are current sources controlled by a single external resistor (Rset). So none of the display pins are connected directly to ground.

That's what threw me off. I don't seem to be able to connect the emitter of the first transistor to ground.

4. ### yesyes

15
0
Mar 9, 2011
Would it help to put a TD62783 or UDN2981 (they seem to be identical) in series with the segment lines (one channel per segment) and connect the 9V or so supply for the displays on there?

If that works, I guess I would have to take care of the current limiting for the segments by adding 8 resistors between the UDN and the display.

5. ### (*steve*)¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥdModerator

25,131
2,662
Jan 21, 2010
If it's multiplexing the displays then you'll need to do something similar for the lines leading to the common pins. But you'll only need a single transistor for that.

6. ### NSklavos

8
0
Sep 5, 2010
It looks like the circuit on page 12 of the datasheet switches the cathode to -5V, thus providing 10V between anode and cathode. (+5V from the 7219 anode segment drivers & -5V thru the fets)

7. ### yesyes

15
0
Mar 9, 2011
Yes, I was wondering that. Never done anything with negative voltages, so wasn't sure.

So I'd need an extra -5V supply. Any idea what I could use instead of the MAX394? This is only available in SMD.

Would this be a better solution than putting drivers in the segment lines? I noticed that the constant current sources in the MAX are in the segment lines....

8. ### NSklavos

8
0
Sep 5, 2010
You may be able to use a couple of DG419 or ADG419. I believe a DG333A or ADG333A is the same as a MAX394 (but not sure, you will have to compare datasheets)

Last edited: Mar 11, 2011
9. ### yesyes

15
0
Mar 9, 2011
None of these ICs seem to be easy to get.

I've been recommended to use ULN2803 sink drivers for the common cathodes. I changed the schematic to include the ULN2803. Actually 2 of them. Since the ULN2803 is inverting I had to invert the inputs again. I prefer to use another ULN2803, mostly because I prefer its pin-out to, say, a couple of 7404s.

Do you think this will work this way?

I ordered a few ULN2803 and UDN2981 from China (a lot cheaper!) but will have to wait a month or so for them to arrive before I can test this out.

File size:
41.5 KB
Views:
1,046

8
0
Sep 5, 2010
11. ### yesyes

15
0
Mar 9, 2011
OK, I'm happy to report that this works. :lol:

I only had to change the limiting resistors for the LEDs. I hadn't taken into account the voltage drop through the 2803s and 2981. So these are now 22R and 560R for the decimal point. But you would want to recalculate these for your displays anyway.

Also, the load resistors between the MAX and the 2981 were not required but it worked just as well with them.

I have amended the schematics. This is how it actually works.

I took a few pictures of my testing. First few show the circuit on breadboard. Then half the display in action. Then I soldered everything on strip board. The first board is the one with the MAX that I had already made. The second one I made today is the "driver board". On this board you can see why it was a lot easier to use another 2803 as inverter. Only one wire on the whole board. )

File size:
41.1 KB
Views:
1,422
12. ### [email protected]

3
0
Aug 16, 2011
Help

I have the same problem but i need 7.7 volts at the LED 25 mA max vs the 10 or 12 you needed. Must I get the lower voltage by lowering the 2981 Vs from 15 to some test select value or do I adjust the 2k2's?

13. ### yesyes

15
0
Mar 9, 2011
Either way would work. It depends on your power supply. If you need 7.7V, I would go for a 12V supply and put that on the Vs pin of the 2981. The 2981 and the 2803 together drop about 1.5V. Calculate the current limiting resistors for the LEDs to drop the remaining voltage.
But you could also use a 15V or so supply and use higher resistors dropping the excess voltage.

14. ### yesyes

15
0
Mar 9, 2011
Two more things...
- The resistors in my circuit are 22R, not 2k2.
- Don't forget that the decimal point usually requires much less voltage (it has less LEDs inside) and therefore needs a much higher current limiting resistor (22R vs 560R in my case)

15. ### [email protected]

3
0
Aug 16, 2011
Thanks!

I'll start with the 12, get ~10.5 out and then drop ~2.8 with resistors at the target current of 25 ma. And thanks for the tip on the decimal, I saw the higher resistor value. I need to recheck the LED data sheet for the decimal voltage requirement.

On the output side you have a bank of resistors between the 2803's and the 5 V supply. What are they for?

16. ### yesyes

15
0
Mar 9, 2011
They are pull-up resistors. The output of the first 2803 is open collector, so either connected to GND or open. So you need to pull up the level for the input of the next 2803.

17. ### [email protected]

3
0
Aug 16, 2011
Great, thanks

You have been a great help. Time to order some more parts

15
0
Mar 9, 2011
19. ### mangustasz

5
0
Nov 30, 2011
Hi, I made everything like you, but we have ghosting in our digits, Maybe you know how to remove ghosting?? this is video : , watch from 0,34S.

20. ### yesyes

15
0
Mar 9, 2011
Hi,
I have not had this problem. I assume by "ghosting" you mean that some of the segments are on very dim when they should be off? (as seen in the youtube video)

The video is a bit shaky but it looks like each segment is copied to the left very dimly. So if segment A of the right-most digits is on, then segment A of the next digit to the left is also on but very dim.

This looks to me like a timing problem, i.e. the left digit gets a little bit of the impulse that is meant for the next digit to the right. In other words, it looks like the cathode side switching lags behind the anode side.

Since it works fine when you connect a small 7 segment display, I'm sure that is not your code that is causing this. I assume you are using the LEDcontrol library. There really is nothing you can do wrong in your code that would cause this problem.

One thing comes to mind... I see you are only using 5 digits whereas I am using all 8 digits. Have you set the number of digits in your code?

Also, what is the value of your Iset resistor? This should be a rather high value to keep the current low. The MAX7219 outputs are a constant current source. Maybe your UDN or ULN need too long to recover from on state to off and mess up the timing?

Do you have very long wires between the MAX and the ULN/UDN?

But this is only just guessing. I did not have this problem and don't know how to fix it with the information I have.

Chris

PS: I've also seen your message that you sent via the contact form on my website. I better reply here as it might help someone else later on... ;-)