Quantcast
Channel: Raspberry Pi Forums
Viewing all articles
Browse latest Browse all 8037

Other RP2040 boards • Re: Do I need a protecting diode?

$
0
0
To answer all your questions:
How do you want to power the whole thing?
TL;DR: I want to use any of my powered USB BC Hubs.

Long form:
I want to use any of my externally powered USB Hubs, following the USB BC Standard, which is limited to 1.5 A. In theory you have to follow some resistor pull-down, -up, etc., but in the real-world the implementers don't follow that and deliver as much current as you pull. The USB standard promises a protective limiting, but in reality they behave more like a wall-socket, and may only shut down at much higher currents, seemingly more for self-protection, not for protection of the device. So, I would never trust any USB hub. LinusTechTips did a whole episode around USB (https://youtu.be/hiwaxlttWow), where they discussed that and other USB stuff.
I found also a professional measurement of different standard USB hubs, where they measured when the USB hubs actually started to limit their currents. It was multiple times beyond the official specification. Sadly, the document is now gone.
It seems these hubs are designed to output the max. power on all ports at once, but you can draw much more power on one port alone (without overheating, instability or whatever), if you don't have any other high-current devices in use at the same time.

Whatever: I don't want to challenge my luck, limit my current to be around 1.5 A, and have some power left over for the RP2040-Zero. Therefore the "high" 2 Ohm resistor R1, and not the ideal 1.2 Ohm. But, yes, rounding up to 2 Ohm is too much, I think using around 1.3 Ohm is better.
Er, what is the diode for?
And you still don't really need R1 or R2.
To R2: I couldn't find any "real" datasheet on this, only the different pictures w/ instructions on AliExpress and eBay, so I want to play it safe, if you can give me a link to a real data sheet, this would be highly appreciated. But yes, I think I could lose R2.
R1: See the first answer.

The diode: If I experiment a little bit, and use a regular LED, the resulting voltage and current could be much higher, and damage my RP2040, but w/ the diode I would be on the safe side.
Or do I miss something here?
Here is the datasheet I have been using for the chip itself:
https://www.hestore.hu/prod_getfile.php?id=12002

The module is basically that chip plus a couple of support components on a handy PCB. The schematic for the module is probably the same as the examples in the datasheet, but it would be worth tracing it out and drawing your own.

A resistor such as R1 would be necessary in a conventional circuit to prevent thermal runaway in the LED, but in this case the driver chip has overcurrent protection and thermal protection. The datasheet does say that in the case of multiple LEDs "in order to make sure the current is evenly distributed among the LEDs, a robust resistor in series with each LED is recommended", but it is not clear in the case where there is only one.

R2 won't do any harm. You're probably overthinking things and it's really not needed. If you drew a schematic of the module you could see if the EN pad on the board goes directly to CE on the chip, or if something else is going on (probably not). The module comprises the chip, a potentiometer, and a resistor. It looks like the resistor is there to establish a minimum resistance which therefore sets the maximum current.

The diode. What are you talking about? I am talking about D2. It's not needed. Why is it there?

If you are only trying to control the brightness of a single LED using PWM it would be much simpler to just use a transistor or MOSFET to drive it.

Statistics: Posted by ame — Sun May 25, 2025 2:53 am



Viewing all articles
Browse latest Browse all 8037

Trending Articles