Increasing brightness of 7 segment led display

Go To Last Post
17 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I am trying to make a digital clock with 6 - 1.5 inch 7 segment led display and 8 - 0.5 inch.

I made the whole circuit, every thing is correct only the brightness of the 1.5 inch displays are too dull, but the others are working fine.

When i am turning on single of those display it is working correctly.

I am using 74HC138 decoder and CD4511 driver, and 100 ohm resistance between the driver and displays.

Is there anything i can do with the code to improve its brightness, because I made the circuit on a printed pcb, it will be to tough to change it.

Here is my code, its a test code there are many useless lines, anyways i don't think that does matter:

/*
 * Digital_Clock.c
 *
 * Created: 7/29/2013 3:21:55 PM
 *  Author: Jem
 */ 

#define F_CPU 4000000UL

#include 
#include 

print_time(int hrs,int min,int sec)
{
	PORTB = 0x00;
	
	PORTB |= 1<<4;
	
	_delay_us(1000);
	
	
	PORTB = 0x00;
	
	PORTB |= 1<<3; 
	
	PORTB |= 1<<5;
	
	PORTB |= 1<<4;
	
	_delay_us(1000);
	
	
	PORTB = 0x00;
	
	PORTB |= 1<<2;
	
	PORTB |= 1<<6;
	
	PORTB |= 1<<4;
	
	_delay_us(1000);
	
	
	PORTB = 0x00;
	
	PORTB |= 1<<2 | 1<<3;
	
	PORTB |= 1<<6 | 1<<5;
	
	PORTB |= 1<<4;
	
	_delay_us(1000);
	
	
	PORTB = 0x00;
	
	PORTB |= 1<<1; 
	
	PORTB |= 1<<7;
	
	PORTB |= 1<<4;
	
	_delay_us(1000);
	
	
	PORTB = 0x00;
	
	PORTB |= 1<<1 | 1<<3;
	
	PORTB |= 1<<7 | 1<<5;
	
	PORTB |= 1<<4;
	
	_delay_us(1000);
}

print_date(int date, int month, int year)
{
	PORTD = 0x00;
	
	PORTD |= 1<<4;
	
	_delay_us(1000);
	
	
	PORTD = 0x00;
	
	PORTD |= 1<<3;
	
	PORTD |= 1<<5;
	
	PORTD |= 1<<4;
	
	_delay_us(1000);
	
	
	PORTD = 0x00;
	
	PORTD |= 1<<2;
	
	PORTD |= 1<<6;
	
	PORTD |= 1<<4;
	
	_delay_us(1000);
	
	
	PORTD = 0x00;
	
	PORTD |= 1<<2 | 1<<3;
	
	PORTD |= 1<<6 | 1<<5;
	
	PORTD |= 1<<4;
	
	_delay_us(1000);
	
	
	PORTD = 0x00;
	
	PORTD |= 1<<1;
	
	PORTD |= 1<<7;
	
	PORTD |= 1<<4;
	
	_delay_us(1000);
	
	
	PORTD = 0x00;
	
	PORTD |= 1<<1 | 1<<3;
	
	PORTD |= 1<<7 | 1<<5;
	
	PORTD |= 1<<4;
	
	_delay_us(1000);
	
	
	PORTD = 0x00;
	
	PORTD |= 1<<1 | 1<<2;
	
	PORTD |= 1<<7 | 1<<6;
	
	PORTD |= 1<<4;
	
	_delay_us(1000);
	
	
	PORTD = 0x00;
	
	PORTD |= 1<<1 | 1<<3 | 1<<2;
	
	PORTD |= 1<<7 | 1<<5 | 1<<6;
	
	PORTD |= 1<<4;
	
	_delay_us(1000);
}

int main(void)
{
	DDRB = 0xff;
	PORTB = 0x00;
	
	DDRD = 0xff;
	PORTD = 0x00;

    while(1)
    {
        print_time(00,00,00);
		print_date(00,00,00);
    }
}
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

There is only one way to increase segment brightness - increase the AVERAGE current. That means: (1) Increase the current value when it is on, or (2) increase the percentage of time that the segments are on.

Increasing the multiplex frequency does not help; what is important is the percentage of on-time. On-time is harder and harder to achieve as the number of multiplex states increases. And, the segments have a maximum peak current, so you can go only so far in increasing current.

It is not clear HOW you are doing the multiplexing. There may be some improvement to be found there. Can you describe: (1) How do you drive the segments (what kind of supply circuit)? (2) What is the segment interconnection scheme?

Jim

Jim Wagner Oregon Research Electronics, Consulting Div. Tangent, OR, USA http://www.orelectronics.net

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Here is the circuit.

Increasing the on time is not helping i tried it, but increasing it to 5000 micro seconds results in blinking displays.

Attachment(s): 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

JimutD wrote:
I am using 74HC138 decoder and CD4511 driver, and 100 ohm resistance between the driver and displays.

Prior connecting chips, you should read the datasheet at first :!:

For multiplexing 6 digits with 7 segments you need a digit driving current of 6 * 7 * I_LED.

If I remember right, the HC138 can only drive up to 4mA,
which result in 4mA / 6 / 7 = 95µA per LED.

By the way, nobody use delay loops for multiplexing.
The only method was a timer interrupt.
This reduce the CPU load dramtically and the CPU was able to do all the other needed jobs.

Peter

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

@danni

I can understand your logic but why are the smaller displays are working correctly??

Quote:
The only method was a timer interrupt.

how do it do it

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Quote:

I can understand your logic but why are the smaller displays are working correctly??

By "correctly", you mean "brighter"?

Well, what do you expect? You apparently are using 100 ohm current-limiting resistors throughout. Thus, every driven segment is getting the same current. Let's say it is 5mA.

What do the datasheets say for the "smaller" and "larger" devices? Would you expect a pin-point LED and a very large LED to have the same brightness when driven with the same current?

Back to the datasheets: One type could be "high efficiency red", and the other not as efficient.

You can put lipstick on a pig, but it is still a pig.

I've never met a pig I didn't like, as long as you have some salt and pepper.

Last Edited: Mon. Jul 29, 2013 - 07:20 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Speaking of datasheets--Just for fun, I went to DigiKey and drilled down on 7-seg LED displays, 0.5", red, single-digit. I ended up with about 10 items. Look at the mcd (millicandela) column--it ranges from about 3 to 30. Not every LED is created equal.

You can put lipstick on a pig, but it is still a pig.

I've never met a pig I didn't like, as long as you have some salt and pepper.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Right, I missed a third method to increase brightness: use a display with a higher mcd vs ma value. mcd = milli-candela, a measure of brightness. ma is the segment current.

Compute the mcd/ma value. 5mcd/5ma is worse (less bright) than 5mcd/2.5ma.

Also, look at the spec sheet for the range of mcd values for that display type. The segments, themselves, should be pretty well matched. But, if a give part number has a mcd range from 3 to 6 at some current, then some digits could be twice the brightness of others.

Also, though related to one of the points I listed, above, your driver is not a very good choice. It does not have enough drive capability as danni pointed out. If all of one segment (say, top bar) is to be on for all of the digits (say, it is displaying 00:00:00), and you want 4ma through each on-segment, that is a total of 48ma. If the driver cannot source (or sink) that much current, the segments will be dim because not enough current is available.

Jim

Jim Wagner Oregon Research Electronics, Consulting Div. Tangent, OR, USA http://www.orelectronics.net

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

80HZ x number of displays is the best frequency for multiplexing,so the refreshing time will be 1/(80HZ x number of displays).Slower time causes flickering,higher shows ghost images or the brightness is fading.This is because every led light lights in 1/6 of a pwm time,1/6 is fixed because 6 are the leds.So 1/6 of a lower period time the lower is the visible time of every led also,exactly as in pwm.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Thanks all of you, i removed the resistors and replaced my voltage regulator with a new one, it is now a little bright, now i am running the big displays with 5 volt, later i am thinking of giving it 9v through some transistors, that will make sufficient brightness.

- Thanks

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Ouch. You can't just remove resistors.

You calculate the required current and use the correct resistor.

Yes, you can use transistors for greater current. Perhaps with resistors of 4R7 - 47R or so.

Remember to have good ceramic capacitors. You have some big currents being switched.

David.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Can you give me some idea on which transistor may i use for making a switching circuit for the big displays. I dont know its current reading the model number of the display is HB10111CSR

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Aunty Google can't find your device.

Here is a 1.0" red display: http://www.futurlec.com/LED/7SR10012BS.shtml
Luminous Intensity Typical Per Segment: 180 Mcd

You can see the max Pulse Forward Current (Ifp): 150 mA
and max: DC Forward Current (If): 25 mA

from: Forward Voltage - Typical: 3.70 V

you can calculate the necessary resistors. e.g. (5.0V - 3.70V) / 100mA = 13R0

It is generally convenient to use common-anode displays with a ULN2803 or similar to sink the segments. You then use discrete PNP transistors for the common anode.

Note that if all segments are on, you have 8x the current on the common-anode pin.

Also note that my Ohms Law calculation was for a zero-voltage switch. The ULN2803 will have a discrete saturation voltage, and your PNP will too.

So in practice, you probably connect the PNPs to 12V.

If you post your actual schematic, and links to your actual devices, someone might do the sums for you. OTOH, anyone who did Physics at school 'should' be able to do Ohms Law.

David.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

You do not need the 74HC138 and you should use a higher supply voltage for the 4511/Displays and increase the 100 Ohm resistrors. The reason is that the larger display has a series connection of LED so you have larger voltage drop than 5Volts.

have a nice day

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 1

I fear you may have arrived a little late - the rest of this thread dates from 2013, six years ago. If they don't already have a solution by now I fear they are totally banjaxed !

 

Moderator

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I hope it will help a lot of other readers who search and find this thread. I could'nt leave the thread uncommented because the TO wrote that he uses the 4511 as a driver and this device has 25mA current capability. If he use the 4511 he will not need any other decoder IC to cascade the numbers because he can use the /LE input of each 4511 separately for storaging the 4bit BCD data in the 4511 until the next update comes, kept with a short H at the /LE input.

have a nice day

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

When updating long-dead threads like this, it helps to prefix your comment with something like, "I know this is an old thread, but ..."

 

That way we know you haven't just failed to notice the date - which does, actually, happen a lot!

 

(One other manufacturer's forum actually awards a "Necromancer" badge!)

Top Tips:

  1. How to properly post source code - see: https://www.avrfreaks.net/comment... - also how to properly include images/pictures
  2. "Garbage" characters on a serial terminal are (almost?) invariably due to wrong baud rate - see: https://learn.sparkfun.com/tutorials/serial-communication
  3. Wrong baud rate is usually due to not running at the speed you thought; check by blinking a LED to see if you get the speed you expected
  4. Difference between a crystal, and a crystal oscillatorhttps://www.avrfreaks.net/comment...
  5. When your question is resolved, mark the solution: https://www.avrfreaks.net/comment...
  6. Beginner's "Getting Started" tips: https://www.avrfreaks.net/comment...