Digital Timer for Video

Thread Starter

DC_Kid

Joined Feb 25, 2008
1,072
I don't see any ICs in the photo. But if you are relying on the internal impedance of the 4001 gate to limit the LED current, the gate will not last long. You really do need current limiting resistors (1 per segment) to prevent driver and display damage.

An LED is like a signal or rectifier diode in that it has no mechanism for limiting the power it dissipates. An LED rating of 4 V and 20 mA means that if you externaly limit the current through the LED to 20 mA, the voltage drop across it will be 4 V. If you apply a 4 V source with lotsa current available, the LED will try to pass all of it and fail.

With a 5 V source, you need to drop 1 V at 20 mA across the current limiting resistor. With Ohm's Law, this works out to 50 ohms. 47 or ohms are the closest standard values at 5% tolerance.

ak
IC's are not in yet.

But lets look at fwd V vs current. My bench PS is adj 30v and will handle 30v@10A. I put 4v on LED segment and get 20mA of current. So what exactly do you mean the LED will pass all the current? LED's have fwd and reverse bias impedance.

With just the diodes I am driving all 7 segments at just 60-70mA, around 10mA each. The LED's did not create a short from anode to cathode, if they did then I would have seen my PS go to max amps for a brief sec and then LED fizzle to its death.

So please explain for me, what am I missing?
 

MrChips

Joined Oct 2, 2009
30,712
An LED does not have fixed resistance.

At low voltages, it has a high resistance. As the voltage rises, the resistance falls. A small change in applied voltage results in a large change in current. Another way of putting it, the dynamic resistance is lower that the static resistance.

You need to control the current through the LED, not its voltage. You do that by adding resistance to the voltage source, not by lowering the supply voltage. An ideal current source would have infinite resistance.

A simple LED driver circuit would have a voltage source and a series resistor feeding the LED. If you lower the voltage source, you have to reduce the value of the resistor to maintain the same current. What you have done with the diode drop is to reduce the series resistor to zero. Hence you have no current regulation.

If you increase the voltage source, you have to increase the series resistor. This gives you improved current regulation. Thus, you want to go with a higher voltage and a higher series resistance. In other words, adding series resistance helps to mitigate changes in the LED resistance.
 

Thread Starter

DC_Kid

Joined Feb 25, 2008
1,072
LED's are sensitive to current. So even if I put a resistor in series to control current, if the LED has impedance that goes down as it heats then current will still increase even with a carbon resistor in series and the LED can burn out. The current graph will be the same profile as the LED and not linear as we see with just a simple carbon load.

The mA with 3.5v direct to segment is the same mA I see if I put two 4001's in series with segment and using 5v.

If I buy a LED that says typical fwd voltage is 1.5v and current is 10mA@1.5v, there's a danger of powering that LED directly with one AA battery?? I suspect no. I do see where using a resistor can protect the power source from a load short, like if the LED burns and shorts, but I do not see where a resistor is protecting the LED itself.

I am still failing to see where the issue is. Can you provide an example that shows the issue?
 

AnalogKid

Joined Aug 1, 2013
10,987
Can you share the LED part number, website, datasheet, etc? There is a chance that it has current limiting built-in. Most don't.

ak
 

MrChips

Joined Oct 2, 2009
30,712
This is not about protecting the LED or the power supply.
The LED brightness is highly dependent on current, voltage and ambient temperature.
The objective is to keep the current reasonably constant. The external resistor helps to keep the current from changing, not its voltage.

Your seven-segment LED displays will exhibit different brightness levels depending on temperature and the number of segments that are lit. For example, "1" will be brighter than "8".
 

Thread Starter

DC_Kid

Joined Feb 25, 2008
1,072
Can you share the LED part number, website, datasheet, etc? There is a chance that it has current limiting built-in. Most don't.

ak
Kingbright
https://www.kingbrightusa.com/images/catalog/SPEC/SA10-21SRWA.pdf

They are not current limiting. The LED's have a V vs A graph. Each segment is dual LED, the decimal is single LED. Apply 3.7v and 20mA flows. @~3.5v I am seeing ~9mA, which agrees with their graph.

Just to note: the 4v20mA was the rating on SA10-11EWA, I had then switched product (they differ in color). The 21SRWA's run a little "hotter", but I am still running the segments under 20mA, closer to 9mA, etc.

This is not about protecting the LED or the power supply.
The LED brightness is highly dependent on current, voltage and ambient temperature.
The objective is to keep the current reasonably constant. The external resistor helps to keep the current from changing, not its voltage.

Your seven-segment LED displays will exhibit different brightness levels depending on temperature and the number of segments that are lit. For example, "1" will be brighter than "8".
I am still not following. The 4001's are good for 1A, their voltage drop is fairly constant regardless of load, so where do you see this varying current you mention. In my bboard pic I lit up one segment at a time, each one had same brightness, and, the mA was about 9mA per segment, so it started at 9mA and then ended near 60mA with all segments lit. I did not see any brightness drop along the way.
 
Last edited:

Thread Starter

DC_Kid

Joined Feb 25, 2008
1,072
When you say 4001, I thought you meant the CD4001 CMOS quad NOR gate. Are you talking about a 1N4001 diode?

ak
Yes. I mentioned the diodes in post #16. But yes, two diodes in series to knock the 5v down just enough, this feeds the power to the segments. Surely a risk if a led shorts or a diode shorts, but it's low probability, and, this is a fast put together w/o a lot of extras, a minimal approach, etc.
 

Thread Starter

DC_Kid

Joined Feb 25, 2008
1,072
I am trying to understand your comment about needing resistors.

In these two circuits what is the issue with the one on the right?

 

AnalogKid

Joined Aug 1, 2013
10,987
For the circuit at the right, at 4.5 V there is no light and at 5.5 V the display burns up, or at least fails prematurely. For the circuit on the left, things just get a little brighter or dimmer without component stress or failure.

Without a current limiting resistor, the circuit performs well only with a delicately balanced set of operating parameters and no operating margin.

ak
 

Thread Starter

DC_Kid

Joined Feb 25, 2008
1,072
For the circuit at the right, at 4.5 V there is no light and at 5.5 V the display burns up, or at least fails prematurely. For the circuit on the left, things just get a little brighter or dimmer without component stress or failure.

Without a current limiting resistor, the circuit performs well only with a delicately balanced set of operating parameters and no operating margin.

ak
The ckt's posted was as-example only to compare two electrically identical ckt's. They both do exactly the same thing. Except that I can add more LED's to the right side ckt w/o any additional parts. Adding more LED's to ckt on left you'll either suffer LED dimming or need to add more parts to keep LED brightness the same.

You lost me with "at 4.5 V and at 5.5 V"
What 4.5V or 5.5 V ??

The example LED runs at spec mcd w/ 10mA running through it. To get 10mA you need 4.3v across the LED. Thus, the LED acts like a load and not a short ckt like a 1n4001 does.

The ckt on right has no 4.5v or 5.5v anywhere. There's a 5vdc source and the voltage across the LED is exactly 4.3v because the diode steals 0.7v

So maybe I just not getting what you are trying to say, or, what you are saying doesn't make sense, not sure which.??
 

AnalogKid

Joined Aug 1, 2013
10,987
The ckt's posted was as-example only to compare two electrically identical ckt's. They both do exactly the same thing.
No, they don't. They arrive at what appears to be the same point due to two different mechanisms.
You lost me with "at 4.5 V and at 5.5 V" What 4.5V or 5.5 V ??
I was making the point that if your 5V source varies a little bit up or down, the two circuits will react very differently.
The example LED runs at spec mcd w/ 10mA running through it. To get 10mA you need 4.3v across the LED.
No. This is a fundamental misunderstanding of how an LED functions.

To get 4.3 V (or less; see below) across the LED, you need 10 mA through it. The output brightness is a function of the current through the diode, not the voltage across it.

** And according to the datasheet, the voltage across the LED at 10 mA should be 3.3 V, not 4.3 V. That is a huge difference, way outside normal part-to-part variation, and a clue to how your approach actually is functioning.

Using the numbers on the datasheet, the reference intensity happens at 20 mA and 3.7 V. But if you decrease the voltage by 11% to 3.3 V, the current decreases by *50%* to 10 mA - AND - the brightness decreases by the same 50%. This is why the important parameter for consistent LED operation is its current, not its voltage. The "right" way to drive an LED is with a constant current source, and most high brightness LED applications use them. With a decently regulated voltage source and a relatively constant ambient temperature, you can approximate a current source with a fixed resistor.

Note - I'm not trying to pick a fight or anything like that. The physics of an LED have been very well understood since the early 1960's, and it is a disservice to you not to point out that your orientation to which parameter is the cause and which is the effect is in error. The vast majority of silicon components (opamps, logic chips, processors, whatever) are constant voltage devices - you apply a regulated voltage, and they draw whatever current they need. An LED is not that.

ak
 
Last edited:

Thread Starter

DC_Kid

Joined Feb 25, 2008
1,072
The supply varies?? Not really, its pegged at 5vdc via the 7805.
The #'s I gave in post #30 have nothing to do with the datasheet, I made that clear.

It's also the case that you must apply a fwd bias voltage to get the needed current to light the LED. In post #30 I said that specific LED (a made up LED) has runs 10mA when 4.3v is applied.

Take your same description of things and make the supply 40vdc, choose your correct ohms for resistor. The resistor will burn off some power to drop the voltage down so that the current through LED is correct. Now vary your 40vdc to say 42vdc, what happens to the current? Does the LED burn up?
 

AnalogKid

Joined Aug 1, 2013
10,987
Now vary your 40vdc to say 42vdc, what happens to the current?
For the LED display in post #26, the current will increase by 5.5% for the segments and 5.2% for the decimal point. -ish.
Does the LED burn up?
I don't see why it would. Assuming you were not running the LED at its absolute maximum current rating before the increase and the new current still is within the operating limits on the datasheet, the LED should be fine.

ak
 

Thread Starter

DC_Kid

Joined Feb 25, 2008
1,072
For the LED display in post #26, the current will increase by 5.5% for the segments and 5.2% for the decimal point. -ish.

I don't see why it would. Assuming you were not running the LED at its absolute maximum current rating before the increase and the new current still is within the operating limits on the datasheet, the LED should be fine.

ak
Not sure how you calculated the current for the decimal point because the DP is a single LED, not two like the segments are.
My testing using just 5vdc w/ 1n4001 diodes for the segments agrees with the math.
I think we'll just leave it here as I cannot follow your posts.
 

AnalogKid

Joined Aug 1, 2013
10,987
Per the datasheet, each display segment is two LEDs in series with a total forward voltage drop of 3.7 V at 20 mA. The decimal point is a single LED with a Vf of 1.85 V at 20 mA.

Therefore

The voltage across properly sized current limiting resistors will be (40 - 3.7) V for the segments, or 36.3 V.

Increasing the source voltage increases the current through both the resistor and the LED. Because the slope of the V-I curve for the LED is greater than 45 degrees, increasing the current through the string a small amount has a much smaller effect on Vf. This means that the majority of the 2 V increase appears across the resistor, not the LED. Increasing the source from 40 to 42 V increases the voltage across the resistor by (2 / 36.3) = 5.5%. With Ohm's Law, an increase in resistor voltage causes a directly proportional increase in resistor current. Thus, the current through the resistor (and LED) increases by 5.5%.

Similar math applies to the decimal point.

ak
 
Last edited:

Thread Starter

DC_Kid

Joined Feb 25, 2008
1,072
Per the datasheet, each display segment is two LEDs in series with a total forward voltage drop of 3.7 V at 20 mA. The decimal point is a single LED with a Vf of 1.85 V at 20 mA.

Therefore

The voltage across properly sized current limiting resistors will be (40 - 3.7) V for the segments, or 36.3 V.

Increasing the source voltage increases the current through both the resistor and the LED. Because the slope of the V-I curve for the LED is greater than 45 degrees, increasing the current through the string a small amount has a much smaller effect on Vf. This means that the majority of the 2 V increase appears across the resistor, not the LED. Increasing the source from 40 to 42 V increases the voltage across the resistor by (2 / 36.3) = 5.5%. With Ohm's Law, an increase in resistor voltage causes a directly proportional increase in resistor current. Thus, the current through the resistor (and LED) increases by 5.5%.

Similar math applies to the decimal point.

ak
Because the electrical characteristics VA of the LED is not linear, the graph of ΔV vs ΔA will not be linear no matter where/how you look, w/ or w/o putting a constant ohms in front of the LED.

Unless you can point out where the LED will fail using 7805 to peg the Vdc to 5v, and putting two 1n4001's in series to knock down the voltage, w/o resistors, then I am not sure there's an issue for the LED segments.

What does LTspice show you if you make the ckt using 5vdc supply and two 1n4001's in series ??
 
Last edited:

Thread Starter

DC_Kid

Joined Feb 25, 2008
1,072
I got the 1st digit all wired into perf board. Interestingly enough at 1kHz on the counter the display simply looks like number 8, perhaps just too fast for human eye. I put the cathode side of segment LED on my scope and I see square wave which indicates on/off current.

I did also test the counting using just a manual switch, and the counter & display counts 0-9 then back to 0.

1) the SN74LS47N has 100ns on/off time, so it takes 200ns to turn a segment LED on and off. This is way faster than 1ms.
2) I do not know the on/off times of the Kingbright LED displays, but using 120fps on my cell phone and looking at it in slo-mo (1s vid = 2sec, etc) I can see a little flicker of the segments but just the number 8.

So, thus far I do not have a msec display that I can see in video :(
 

AnalogKid

Joined Aug 1, 2013
10,987
I went out to Kingbright's site and looked up other LEDs with the same technology, and they don't give rise and fall times for anything I found. memory from way back, red LEds have typical rise and fall times in the 50 ns range, like 10-50 ns rise and 25-75 ns fall. ish.

What is the frame rate of your camera; this might be a problem. For example, if the counter is advancing the display at a 1 kHz rate and the camera is capturing images at a 100 Hz frame rate, then the camera will integrate 10 separate numbers during one frame's exposure. The last digit will look like an 8 with unequal brightnesses of the segments.
1) the SN74LS47N has 100ns on/off time, so it takes 200ns to turn a segment LED on and off. This is way faster than 1ms.
The 7447 output rise and fall times don't matter. Assuming you are not doing anything with the blanking inputs, the outputs from a 7447 to a display are constant throughout an input state. In your case, the outputs of the LSD counter are a constant throughout the 1 ms clock period. The 7447 turns on the correct segments, and those are illuminated constantly throughout the 1 ms period. Compared to that, the outputs 100 ns rise and fall times are essentially instantaneous.

ak
 
Last edited:
Top