LED Circuit Design with C type USB connector.

Thread Starter

pr4veen

Joined Oct 21, 2024
12
Hello,

I'm building a wooden lamp with 5mm Warm-white LED's. This is how my current design looks and it works. However, since, I'm planning on selling these lamps, I have a few queries about my design.

1. Do i need to change anything in my current design - like say the resistor value to improve the LEDs longevity?

Screenshot 2025-02-25 at 12.59.13 PM.png
2. Currently I'm using a DC power adapter connected to a female DC jack - mounted on my wooden lamp. I would like to replace the DC jack, with a C-type USB connector. I found a 2-pin C-type USB connector-SMD and I replaced the DC power jack with this connector and the LED's work. However, I'm not sure how efficient it would be to use these C-type USB connectors and whether using such USB connectors would negatively affect the LEDs in the long term.

These are the specs for the 2-pin C type USB:

  • Connector Type: USB Type-C
  • Pin Count: 2 pins (power only).
  • Mounting Type: Surface Mount Device (SMD)
  • Rated Voltage: 5V
  • Current Rating: Up to 3A
  • Operating Temperature: -40°C to 85°C

ctype usb.png
 
Last edited by a moderator:

meth

Joined May 21, 2016
298
Bro how much light do you intend to illuminate, 1 photon per second? :D
That resistor is ridiculously high for LEDs, share the datasheet of the LED you intend to use and we will show you how to calculate your resistor (since obviously you werent able to google this out).
 

WBahn

Joined Mar 31, 2012
32,702
I believe that USB-C connectors have to negotiate with what they are plugged into in order to establish the voltage and current that they will get. Maybe there is a default if no negotiation is performed. It's something you should look into.

There's no way for anyone to tell you what current you should limit your LEDs to for longevity unless you provide the LED specs.

Having said that, if you use 150 kΩ resistors, your LEDs should last pretty much forever. Of course, they might also be indistinguishable from dead LEDs.

Are you sure that your warm white LEDs only have a 2.1 V forward voltage drop? I just checked Digikey and the lowest Vf they have for warm white LEDs is 2.65 V. Even if your LEDs are actually 2.1 V, putting two in series doesn't leave you much overhead for current regulation.

Assuming both LEDs are actually 2.1 V, you only have, nominally, 800 mV of overhead. But USB is not guaranteed to be 5 V. I believe the spec allows it to be between 4.75 V and 5.25 V, which means that whatever current you get when it is 4.75 V, you could get more than twice that if it happens to be 5.25 V. The situation gets a LOT worse if you take into account the variability of LED Vf, even for chips from the same wafer. Unless you pay more to get binned parts, you can probably expect a tolerance of ±100 mV or even more. Using that figure, the combined Vf of your two LEDs could be anywhere between 4.0 V and 4.4 V, resulting in a worst case variability of the max current being more than 3.5:1.
 

Thread Starter

pr4veen

Joined Oct 21, 2024
12
Bro how much light do you intend to illuminate, 1 photon per second? :D
That resistor is ridiculously high for LEDs, share the datasheet of the LED you intend to use and we will show you how to calculate your resistor (since obviously you werent able to google this out).
Sorry that was a typo.. I'm using the 150 Ohm .25W resistors
 

meth

Joined May 21, 2016
298
Okay then that makes sense.
I back everything Bach says, but we need the LED datasheet not only for the voltage drop, also for the current draw of the diodes. That is how you calculate your resistor.. you do not just choose 150 Ohm as reasonable value.
I have had USB connections supplied by crappy phone chargers only to find out that the signal is not DC constant voltage, but pulsed, which can ruin your application. So make sure whatever you connect the other end of the USB cable is reliable power source.
 

Thread Starter

pr4veen

Joined Oct 21, 2024
12
Screenshot 2025-02-25 at 3.21.07 PM.png

Being a newb, I made some ignorant errors and I'm sorry for that. I had initially used Yellow LED's and assumed, all LED's had the same forward Voltage. But I rechecked and the forward voltage for the Warm white LED is indicated as 3.0 to 3.6 VF. So, from my very very limited knowledge and some research online, I would assume, if I'm using 5V power supply then, I would probably need a 150ohm resistor per LED.

The main reason I want to use a USB-C over the DC jack is because the DC jack is too big for the lamp and i need something more compact. So. is there anyway I can use the USB-C with the LED's? Thanks
 

Jon Chandler

Joined Jun 12, 2008
1,560
You need 5.1k pulldown resistors (i.e., connected to ground) for the two CC pins on the USB-C connector to get voltage from a supply with a USB-C connector. Those 2-wire "power only" connectors often overlook that detail.

Without the resistors, using a USB-C – USB-A cable to a supply with a USB-A connector will work.
 

Thread Starter

pr4veen

Joined Oct 21, 2024
12
You need 5.1k pulldown resistors (i.e., connected to ground) for the two CC pins on the USB-C connector to get voltage from a supply with a USB-C connector. Those 2-wire "power only" connectors often overlook that detail.

Without the resistors, using a USB-C – USB-A cable to a supply with a USB-A connector will work.
Thanks Jon. So I would need to connect each LED to a 150ohm resistor and then connect the entire circuit to the USB C connector. I could then include a USB C to USB A power adapter and cable with my lamp. I'm guessing that should do it?
 

meth

Joined May 21, 2016
298
OK, I understand you might be new in this, but first of all you keep avoiding to share the exact diode that you intend to use. Thats why you will not get any help from me for the resistors. That is on you.
I have another question, With 5V voltage source, how you gonna supply two components in series that have 3V voltage drop?
 

Thread Starter

pr4veen

Joined Oct 21, 2024
12
OK, I understand you might be new in this, but first of all you keep avoiding to share the exact diode that you intend to use. Thats why you will not get any help from me for the resistors. That is on you.
I have another question, With 5V voltage source, how you gonna supply two components in series that have 3V voltage drop?
Since I was playing with these diodes to see how to get them to work, I got the chinese ones and they have no data sheet. The only information given in english is :: "Input- 3-3.6 Volts DC. Working voltage 50MA Max current. "

I understand its not possible to connect two LED's to a 5V supply, so I could connect each LED to a 150Ω resistor. Unless theres a better way to do it.
 

ericgibbs

Joined Jan 29, 2010
21,390
hi,
Assume 3.3v drop for the LED.
So 5v-3.3v = 1.7v to drop across the resistor
If you have 25mA through each LED, that requires a 1.7v/0.025A = 68 ohm resistor.
Total current for 16 LED = 0.4Amp

E
 

Jon Chandler

Joined Jun 12, 2008
1,560
A USB-C connector to a USB-C –;USB-A cable to a USB-A supply will work great.

EDIT EDIT EDIT

I forgot to specify the resistance value. That's what happens when I write something during a massive blackout at 4am with 60 mph winds in a house surrounded by 100' fir trees!


For LEDs with Vf between 3.0 – 3.6 volts, the current will be between about 10 – 13 mA with 150 ohm resistors. This is perfect with modern LEDs.
 
Last edited:

meth

Joined May 21, 2016
298
The resistor's job is to limit the current. Here is how you calculate your resistor:
1740491954790.png

You read Vforward from the LED's datasheet, you calculate Vr,led, and then, knowing Vr,led and reading Iled (also from the datasheet) you calculate your Rled.
 

Thread Starter

pr4veen

Joined Oct 21, 2024
12
hi,
Assume 3.3v drop for the LED.
So 5v-3.3v = 1.7v to drop across the resistor
If you have 25mA through each LED, that requires a 1.7v/0.025A = 68 ohm resistor.
Total current for 16 LED = 0.4Amp

E
Hi Eric, So I was told to limit the current to 10mA-15mA per LED since pushing the LEDs to their upper limits could reduce the life of the LED. Moreover, more current means more brightness and more heat, which can lower the forward voltage. As the forward voltage decreases current increases and that could be a problem as well, si what I've been told. So i limited the current to 10mA and I got 150Ω, considering 3.6v drop :). I hope limiting the current is the right way to do it.

After some research, I also found out I could probably use a Boost step-up converter, but I'm still figuring it out though :)
 

Thread Starter

pr4veen

Joined Oct 21, 2024
12
The resistor's job is to limit the current. Here is how you calculate your resistor:
View attachment 343218

You read Vforward from the LED's datasheet, you calculate Vr,led, and then, knowing Vr,led and reading Iled (also from the datasheet) you calculate your Rled.
So, I basically used https://www.allaboutcircuits.com/tools/led-resistor-calculator/
The Vsupply is 5v, forward V is 3.6V, the forward current I set to 10mA and I got 140Ω. However, 150Ω is easier to get.
 
Top