Pages: [1]   Go Down
Author Topic: Multiplexing a big 7-seg display with MAX7219  (Read 1888 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 1
Posts: 28
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I've a problem with this circuit, it should drive 2 (or more) big 7-segment display using a MAX7219 and the relative Arduino's library. It uses ULN2003 and UDN2981 to use +12V and a series of 5 led per segment (in the image I simplify with only one led for segment).

The CD40106 is used as logic NOT adapting the inpupts for the ULN2003.

The problem is during the MAX7219 test example code, loaded into the arduino uno. The leds slightly turn on when they should stay off. A video will show better the problem.

More info about MAX7219 library and test code here



* aaa.jpg (206.37 KB, 1878x1266 - viewed 116 times.)
Logged

Global Moderator
Boston area, metrowest
Offline Offline
Brattain Member
*****
Karma: 525
Posts: 26554
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Look at the output drive specs of the CD40106 vs the input drive current requirement of the ULN2003.
http://www.ti.com/lit/ds/symlink/cd40106b.pdf
http://www.ti.com/lit/ds/symlink/uln2003a.pdf
The CD40106 is really marginal to drive the ULN2003.
Find a better part.
Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

Offline Offline
Newbie
*
Karma: 1
Posts: 28
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Look at the output drive specs of the CD40106 vs the input drive current requirement of the ULN2003.
http://www.ti.com/lit/ds/symlink/cd40106b.pdf
http://www.ti.com/lit/ds/symlink/uln2003a.pdf
The CD40106 is really marginal to drive the ULN2003.
Find a better part.

I'm not very skilled, where I do exactly look for?
I've tested the circuit without the MAX7219, setting manually the input pins of CD40106 and UDN2981, and all works fine. I tried another MAX7219 but same problem.
Logged

Global Moderator
Boston area, metrowest
Offline Offline
Brattain Member
*****
Karma: 525
Posts: 26554
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Yes, manually it might. MAX7219 multiplexes at 800 Hz tho, and marginal signals will show up at higher speeds.

Look at the output drive capability - something like 0.4mA at 4.5V power supply.
Look at what's needed to be recognized as 0/1 - something like 0.5mA.
Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

Global Moderator
Boston area, metrowest
Offline Offline
Brattain Member
*****
Karma: 525
Posts: 26554
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Page 3-389 - output low(sink) current IOL min, Vdd = 5V.
+25, 0.51min mA
output high (source) current in same area of the chart.

Page 5,  Input current, couple of places.
Vin = 3.85V, Iin = 0.93mA to 1.35mA
Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

Offline Offline
Newbie
*
Karma: 1
Posts: 28
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thank you, I'm going to buy a SN74HC04 the next week, It should had the right parameters for the ULN2003. Hoping to solve the problem.

Datasheet

Quote
±4-mA Output Drive at 5 V
Logged

West Yorkshire, UK
Offline Offline
Edison Member
*
Karma: 41
Posts: 1236
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi,

If you only need 4 digits and you can get common cathode displays, saa1064 may be easier to work with. It can deal with 12V without extra driver ics.

Paul
Logged

Offline Offline
Newbie
*
Karma: 1
Posts: 28
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thank you, I'm going to buy a SN74HC04 the next week, It should had the right parameters for the ULN2003. Hoping to solve the problem.

Datasheet

Quote
±4-mA Output Drive at 5 V

Same problem with 74HC04  smiley-cry
Logged

Global Moderator
Boston area, metrowest
Offline Offline
Brattain Member
*****
Karma: 525
Posts: 26554
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Try putting a 10K pullup to 12V on the ULN2803 outputs to help bring the cathodes high.
Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

Offline Offline
Newbie
*
Karma: 1
Posts: 28
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Try putting a 10K pullup to 12V on the ULN2803 outputs to help bring the cathodes high.

I put 10K pullup resistors to 12V on the two outputs of the ULN2003, the result is visible in this video, when I connect and disconnect them to show the difference.

Logged

Offline Offline
Newbie
*
Karma: 1
Posts: 28
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

A user from another forum told me to try with a diode after the UDN2981, or a 1K pulldown resistor after the MAX7219 digits output, but they can't solve the problem.  smiley-cry
Logged

Offline Offline
Newbie
*
Karma: 1
Posts: 28
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I simplify the code on Arduino so now is easy to identify the problem.

Any suggestions?

Logged

Pages: [1]   Go Up
Jump to: