LED Current limiting resistor calculation - help needed urgently ?

peterdeco

Joined Oct 8, 2019
484
The datasheets you attached are for a 3 pin RGB led. I have white led's that require 3V @ 10mA. So I would calculate R308 as 15/.01 = 1500 ohms. I would not use R300. R308 will dissipate .15A so a 1/4 watt resistor should be OK but I would use 1/2 watt to keep it cool.
 

pmd34

Joined Feb 22, 2014
527
I would agree with Peter you dont really need R300...
To calculate:
The Red LED needs 2.4V @ 15mA
Assuming the transistor is fully switched on: The voltage you need to drop across your resistor R308 is then (18-2.4)V @15mA
=15.6V ...
using R=V/I
R=15.6/0.015 =1040 Ohms
The power dissipated by this resistor is given = I^2 x R = 0.234W

For R312 you need to put enough current into the transistor to fully switch it on.. without R300 the base will be at about 0.7V about ground.
So R312 will have 3.3v-0.7v across it = 2.6V
As you are not doing anything fancy, just switching the LED we just need to drive the transistor into saturation.. ie. make sure we put plenty of current into the base.. from the data sheet the current gain should be > 100... so we to allow 15mA to flow through the transistor we need a base current of > 0.015/100 = 15uA (this is tiny, so really there is no worry about taking too much power from your microcontroller output).
So R312 < 2.6V/15uA = 17,333 Ohms... actually anything from 1k to 15k will no doubt be fine.
 

dl324

Joined Mar 30, 2015
16,846
Not only do you not need R300, it's presence affects the ability to drive the transistor into saturation. That requires more base current (smaller R312).
 

ronsimpson

Joined Oct 7, 2019
2,989
you dont really need R300...
That depends on what you are trying to do.
1) One option is R300=0, R308 limits the current.
2)Option 2; Keep the Base resistor small. Input signal (5V) substract 0.7V for the B-E and that 4.3V across R300 sets the current. In this case R308 could be 0 or often is set to eat up part of the 18V so the transistor runs cooler.
Example 18V supply 3V across the LED, Emitter at 4.3V so there is about 10V across the C-E of the transistor and R308. You could plan on R308 eating up 5V of that.
 
Top