LED on Parallax Propeller Proto Board
Humanoido
Posts: 5,770
The SMD LED on the board, when isolated to just the LED and resistor, draws 20mA. I tried adding another resistor and it goes down to 19mA and then becomes too dim.
Why, when I add my own larger LED, it draws 1mA at full brightness? Are all SMD LEDs hungry power consumers or is it just based on the specs of this one SMD LED?
I did try other PPPBs and all the SMD LEDs draw the same power.
Why, when I add my own larger LED, it draws 1mA at full brightness? Are all SMD LEDs hungry power consumers or is it just based on the specs of this one SMD LED?
I did try other PPPBs and all the SMD LEDs draw the same power.
Comments
Q: How did you isolate the LED? Did you remove it from the board?
V = I * R
or
0.019A * 240R = 4.56V
So at 19ma, that 240Ohm resistor would be dropping 4.5V!
But it sounds like you were running the LED from a prop pin for the test? in which case the absolute max current should be 3.3v / 240R = 13.75mA (that's with 240R straight to ground, no diode).
Even if we assume the worst case of a 20% tolerance resistor (240 * 0.8 = 192) the absolute max current is still only 3.3/192 = ~17.2mA (again, that's with no diode to drop the voltage).
I wonder if there is something else at work here? Perhaps you should measure the voltage on each side of the resistor (obviously one side should be 3.3v) then use that to determine the current going through the LED?
Side note: googling leads me to believe that an SMD resistor marked '241' is 240 ohms (last digit is the number of zeros: '240' = 24 ohms, '241' = 240 ohms, '242' = 2400 ohms, etc).
2.78V - 1.94V = 0.84V
Meaning that the current (I = V/R) is 0.84 / 240 = 3.5mA.
And the diode has a forward voltage of around 1.9V-2.0V.
Giving some wiggle-room on the resistor (say, 20% as before - also allows for some inaccuracy of the multimeter), gives us a max current of around 4.38mA.
That sounds more reasonable to me
I guess the 0.5V drop between the prop and the resistor must be in the wire being used (0.5/4.5 = ~110mOhms, which is too small for cheaper multimeters to measure).
One option could be to flash it on/off (say 1Hz, 500ms on, 500ms off). That way the LED is still bright (and drawing 4mA) but it is not drawing it continuously - so your average draw goes down to 2mA.
You could also change the ratio to increase the power savings (e.g. 250ms on, 750ms off).
Many of the products at my work have a 1Hz flash pattern as the standard 'on' signal as it also has the advantage of showing you that the microcontroller is still running (though obviously this does not really apply to the propeller as the other cogs can stop/start independently of the LED flash).
I wish the surface mount LED was 4mA current draw after adding the resistor to the prop pin and going dim. I could use it that way. But I'm not seeing 4ma draw. It drops by only 1mA so it draws current around 19 or 18mA. I can try measuring this again and confirm the results on a different board but I expect results will be about the same.
I'm a little confused though, based on the voltage readings above there is only ~4mA going through the LED and resistor when they are fed from 3.3v - how are you measuring the current to get 19mA?
The ammeter should be in series with the circuit, something like this:
Prop pin -> ammeter + lead -> ammeter -> ammeter - lead -> resistor -> LED -> gnd
Or, if you care about total current (say, for battery life) you could measure the current going into the board as a whole:
+ supply -> ammeter + lead -> ammeter -> ammeter - lead -> prop pcb Vin
Method #2 will give you a better idea of what it 'costs' to have the LED on, as it includes all the power lost along the way (such as losses in the regulators, current drawn by the prop if running another cog to do the LED, etc).
If you are measuring using #1 above and still seeing 19mA it might indicate a partial short to ground somewhere - a strong possibility if you are hacking up boards I've occassionally found pieces of lint/dust/etc can cause this kind of thing. It's not as obvious as a dead short (which generally results in something burning) but rather lowers the resistance of a circuit causing more current through parts of it.
My main suspect would be the around wire from the prop pin to the resistor, as the voltage drop across it is higher than I would've thought - though without seeing it it's hard to say.
This uses Phil's pwm object.
Yes, if you get the same result on multiple boards then a random short is unlikely.
My first step in that case would be to run the same test you have been doing, but alter the prop code so that the LED pin stays low (or is an input).
Then you can compare it with the result when the pin is set high to power the LED.
If the difference is more than the expected LED current (around 4mA from our calculations) then the current is going through the pin but does not appear to be going to the LED. If not, then the current draw has nothing to do with the LED but is from something else (for example, the prop itself may be drawing the extra current to run the test program - remembering of course that the prop's current draw can vary a lot depending on clock speed, how many cogs are running, whether waits are used, etc).
When the pin is low, there is 0 volts at points A, B, C and D.
I've had trouble in the past conductive flux leaking current. Have you washed the areas you soldered with an appropiate solvent?
Duane
http://www.parallax.com/go/pekit
http://forums.parallax.com/showthread.php?124495-Fill-the-Big-Brain&p=969476#post969476
On one of my proto boards the LED (near the power switch) was drawing 12.7mA. Its series resistor was 237 ohms.
Here's how I measured:
With proto board off, measure the series resistance with a dmm
Power it up. Measure the voltage drop across the same series resistance.
Ohms law gives you the current (3.01 volts / 237 ohms = 12.7mA).
Measuring the voltage drop across the resistor is more accurate than inserting the meter in series. My Fluke 77 was dropping 208mV while measuring a current of only 27mA (proto board supply idle current).
If I tried to measure the LED current using a DMM in series, I would have seen 12.3mA instead (about a 3~4% error).
However the error would have been much worse if the LED was operating from a 3v3 rail (something like an 8% error at the same led current of 12.7mA). The voltage drop method is only better because of the high impedance input of the multimeter (typically well over 1 Megohm)
Some high efficiency LEDs are quite visible well down below 1mA.