Why are there no "USB power supplies" with current limiting? - Page 1
Forum section: electronics / beginners

author: paulca
author_rank: Super Contributor
timestamp: July 03, 2025, 01:23:53 pm
content: We follow the suggestions from the wise and invest in a bench power supply with OCP OVP and current limiting, so we can limit the damage during a "Whoopsie"Then, when we mess with things like Arduinos and other MCU modules, we just slap the 5V USB "VBUS" straight on in without a care.A powered USB hub, some anyway, will happily supply 2A of current and melt your little circuit, burnt fingers.I went looking for the two combined and ... oddly... I don't seem to be able to find any. Everything surround it, but not a ...USB in, USB out. Current limiter in the middle.To make it super simple, a basic analogue circuit with a pot to adjust. A more advanced one with a screen and buttons which not only current limits, but provides a reading for the current and a settable "limit" setpoint as well as an optional "buzzer" set point just below it.There must be a reason why there are not 100s of modules on Ali/Amazon that do this.Any ideas why I shouldn't make this?

author: wraper
author_rank: Unknown
timestamp: July 03, 2025, 01:30:21 pm
content: Because it makes no practical sense. They are not intended for some niche development use to begin with, not to say adding such a feature would certainly make them noncompliant to the standard. Get a lab PSU if you want adjustable current limiting.

author: Seekonk
author_rank: Super Contributor
timestamp: July 03, 2025, 01:35:30 pm
content: Because you are shopping on amazon and only looking for price.

author: paulca
author_rank: Super Contributor
timestamp: July 03, 2025, 01:40:11 pm
content: Okay. So where are these power supplies that have data in, data out, but limited current supply?I mean if your product is VBUS powered, how DO you test it? Do you just make a harness to inject power from your bench PSU and leave data passthrough?

author: wraper
author_rank: Unknown
timestamp: July 03, 2025, 02:52:42 pm
content: Quote from: paulca on July 03, 2025, 01:40:11 pmDo not connect VBUS to the host side and power it from lab PSU instead. As simple as wiring two connectors together, you do not even need a PCB.

author: mariush
author_rank: Super Contributor
timestamp: July 03, 2025, 03:52:54 pm
content: There's this thing called fuses ... either plain classic fuses or resettable fuses.You can easily limit the current with any adjustable linear regulator, see for example datasheet of LM317Of course, that would cause some voltage drop on the current sense resistor, so you'd use it before a proper 5v regulator. For example 9v or higher - LM317 as current limit - 7805 or others to output 5v.If you set the current to 100mA, you'll get maybe 95-98mA (2-3mA will be used internally by 7805)

author: Rick Law
author_rank: Super Contributor
timestamp: July 04, 2025, 03:39:09 am
content: The lack of ready made USB->USB cc is probably because it is so specific (smaller market) and there are so many cheap "almost there" solutions (larger market). Not only is the market small, there is fragmentation: USB C? Micro USB? Mini USB. Fragmentation makes the market even smaller and more expensive to exploit.Worst yet, the ones who know the need and benefit of "CC" would likely be the ones who can easily close the gap from "almost there" to "there it is".Find a low cost CC+CV boost+buck convertor ($3 and up on ebay), may even be CC+CV with LCD display of V/Amp ($7 and up on ebay). All you need is to add USB socket/plugs to Vin/Vout and you got it. And a case to put it in, if desired. All could be done in an hour or two.

author: ejeffrey
author_rank: Super Contributor
timestamp: July 04, 2025, 04:00:51 am
content: Quote from: paulca on July 03, 2025, 01:40:11 pmThe normal way is to have a dedicated power input connector either with jumpers or.diodes to select the power source.Or yes, make and adapter and inject power via USB. I have some USB to screw terminal adapters. It's easy to inject power and if needed data.There are inline power meters that will give you a real time readout of voltage and current which is nice for checking that your device stays under the USB current limit.I also don't always bother testing like that for a really simple circuit (like a single USB to serial adapter or a single microcontroller) I might just test for obvious shorts with a multimeter and then plug it in. But for something more complicated I do use a bench supply.

author: JustMeHere
author_rank: Frequent Contributor
timestamp: July 04, 2025, 05:40:14 am
content: By definition, all USB power supplies have current limiting.Per even 1.0 spec, it was 100 mA unless the device could "ask" for up to 500 mA.The thing is it "should" work, but on a short circuit, it happens so fast, cheap ones don't clamp in time.There are USB isolators that mitigate this risk.(Even RS232 was suppose to have current limits to protect against damaged serial cables. A chair rolls over the wire and crushes two wires together. It was supposed to handle this.)

author: JohanH
author_rank: Frequent Contributor
timestamp: July 04, 2025, 07:28:30 am
content: This is possible with USB 3.0 and later, through PD and PPS.From Wikipedia:"The USB Power Delivery specification revision 3.0 defines an optional Programmable Power Supply (PPS) protocol that allows granular control over VBUS output, allowing a voltage range of 3.3 to 21 V in 20 mV steps, and a current specified in 50 mA steps, to facilitate constant-voltage and constant-current charging."Example:https://hackaday.com/2025/03/24/pps-is-the-hottest-usb-c-feature-you-didnt-know-about/

author: wraper
author_rank: Unknown
timestamp: July 04, 2025, 08:50:57 am
content: Quote from: JustMeHere on July 04, 2025, 05:40:14 amIt's not about limiting on the source side but about current draw. I don't know any device that would actually reduce the protection trip current if higher current was not negotiated.

author: tooki
author_rank: Super Contributor
timestamp: July 04, 2025, 09:11:47 am
content: Quote from: JustMeHere on July 04, 2025, 05:40:14 amNo, that’s not how it works. The USB host is responsible for managing the current budget, but relies on the devices themselves to be honest about their current draw. While most computers have simple overcurrent protection (i.e. the bus shuts down if there’s a short or gross overload on the USB bus), there are no known implementations where dynamic, per-port current limiting is used.In other words, a device asks “hey, is it OK if I pull 500mA?” and the host looks at the situation and says “go ahead” and enumerates the device, or says “nope, no can do, sorry” and refuses to enumerate it. The device is expected to respect the 100mA limit if not granted permission to draw more. But there’s nothing to physically prevent the device from trying to do so anyway.

author: berke
author_rank: Frequent Contributor
timestamp: July 04, 2025, 10:00:10 am
content: Quote from: tooki on July 04, 2025, 09:11:47 amYes and more specifically, there is no guarantee that the host will enforce those limits, but there isn't any guarantee that the host won't either.There are rumours of some USB hosts (Apple?) monitoring the current draw and enforcing such limits.As a result, because lots of USB devices give false information about how much current they draw, "compatiblity" issues might arise.I have some commercial USB devices (some with fantasy VID:PIDs) that even claim to be self-powered when they clearly are not. Not to mention excessive inrush currents and lack of tolerance to low voltages (per spec USB devices are expected to work even with the "5V" rail at 4.4V).Also, as the 5V rail is typically shared between multiple ports, plugging in or operating one crappy USB device can cause resets on the whole bus.

author: paulca
author_rank: Super Contributor
timestamp: July 04, 2025, 10:36:28 am
content: But the convenience to "tinkerer"/"maker" who just plugs their arduino into his/her PC and goes at it on the breadboard.We have USB cables with power meters in there. Why not a "USB Nanny" cable that looks much the same but beeps at you when you exceed a certain current. No UI, no buttons. Just sell 20mA, 50mA, 100mA cablesPersonally I expect to make mistakes. If you have to triple check everything, everytime, you get nothing done. On my current breadboard setup I do a few things.1. Power it from a bench PSU, not USB, except for finished tools/boards.2. Add power LEDs on 10kRs to all breadboard power rails.3. Set the current limit on the PSU to "expected" + headroom.4. Measure the furthest end of the power rails with a meter independant to the PSUs supply voltage.For "headroom", I use the max clamp current on the most expensive IC. If I expect 70mA I might set the limiter to 100mA.The moment a pin goes in the wrong hole I get a whole range of notifications of a short or hard pull down - my case more likely a drive conflict and driving an open drain output.1. The BB leds dim or go out.2. The PSU fan audibly kicks up a notch.3. The current limit light comes on.4. Logic resets.No smoke. No damage.There are limitations to this I understand and I am lucky, right now to be working on a DC circuit with few macro transients so I only need to accomodate a +-5mA range, ie < headroom.It is having this lovely soft safety net that encourages me to try things and test them immediately with limited consequences. It is also why I had this thought when I then plugged my next test circuit into the USB hub via it's USB micro and decided that there was no way I could trust that hub the same.

author: tooki
author_rank: Super Contributor
timestamp: July 04, 2025, 11:00:12 am
content: Quote from: berke on July 04, 2025, 10:00:10 amSince the USB standard doesn’t call for host-side enforcement, I don’t see any reason why anyone would implement it.Quote from: berke on July 04, 2025, 10:00:10 amI’ve been a Mac user since 1992, including selling and servicing them at various times, and I’ve never heard of any that endorse the limit. They have the usual situation: warnings if enumeration fails due to power requests, and turning off if the bus gets overloaded.Now, I haven’t owned any of the Apple Silicon-based Macs, so I can’t rule out that they have different behavior. But I doubt it.Quote from: berke on July 04, 2025, 10:00:10 amWell, in standard USB (i.e. not PD*), a device can’t give information about its current draw. It can only request specific, predefined current levels. E.g. the default 100mA, or the increased 500mA, for USB 1 and 2. A device can’t request, for example, just 350mA, even if that would actually free up power budget for other devices.*I don’t know whether PD allows it, either, but since I don’t know with certainty, I’m adding that qualifier.

author: NE666
author_rank: Frequent Contributor
timestamp: July 04, 2025, 11:35:28 am
content: Quote from: paulca on July 04, 2025, 10:36:28 amSomething like this?https://www.aliexpress.com/item/1005009165794346.html

author: paulca
author_rank: Super Contributor
timestamp: July 04, 2025, 12:32:12 pm
content: Quote from: NE666 on July 04, 2025, 11:35:28 amSomething like it yes. However in my experience, USB2.0 claiming isolators is ... well. Don't bother.However, nice device and nice AliExpress search foo.

author: CaptDon
author_rank: Super Contributor
timestamp: July 05, 2025, 01:11:52 pm
content: There was on some older laptops and towers a 100ma. current limit unless a driver for the enumerated device specifically allowed up to 500ma. Case in point, the older 'black' Xilinx platform cable drew 90ma. and would work 99% of the time without hassle. The later 'Red' platform cable drew current above the 100ma. limit and needed the proper drivers to tell the host computer to up the current capacity. Sometimes on some machines you had to have the Xilinx software running with the drivers active PRIOR to plugging in the red platform cable. This was evident by the yellow LED indicator never shifting to green. Xilinx in the meantime has come up with about 10 other reasons why their platform cable doesn't work with their own software products.