Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> I've also returned a few USB devices that ship with a USB-A to USB-C cable and ONLY charge in that mode...

By "that mode", do you mean "1.5A @ 5V" permitted by BC, or do you mean "3A @ 20V" permitted by non-type-C PD?

> Like, who in the hell would design a device that has a USB-C port on it where only a fraction of chargers will work on it.

Who in the hell would design a charger that can do Type-C PD but can't do either pre-Type-C PD or BC? Does the charger in question also shit the bed when a USB 1.0 device attempts to draw 100mA @ 5V? I hope not! Were it me, I'd return that crappy thing for a refund.



> By "that mode", do you mean "1.5A @ 5V" permitted by BC

Neither - OP means devices with missing CC resistors which will fail to charge with a compliant PD source. (The A-to-C cable works because it provides 5V Vbus unconditionally.)


The A-to-C cable often does not work because the resistors are supposed to be in there.

So if you are having complete charge failures, try a different cable.


That's close, but it's not quite complete. There seems to be lots of confusion here, and that's natural: It is confusing.

For just-getting-power from a USB A port into a USB C peripheral: There are supposed to be 2 resistors in the peripheral device [always], and also 1 resistor within the cable for USB-to-legacy cables[1]. That's 3 resistors, total, to get a relatively dumb USB-C equipped peripheral device to reliably charge from both USB A and USB C hosts/chargers/whatevers:

The cable itself: It gets an internal 56k pullup resistor between Vbus and USB C pin A5 -- which is the CC line [yes singular]). This resistor signifies the capabilities of the host/charger/whatever for devices that care (some do care, some do not care).

The peripheral: This minimally needs two pulldown resistors [commonly 5.1k], between each of CC1 and CC2 [yes a plurality] and ground[2]. This tells a compliant USB C host/charger/whatever "It's OK! Send the juice juice!" regardless of connector orientation.

[1]: https://www.usb.org/sites/default/files/USB%20Type-C%20Spec%... section 3.5

[bleh]: Again, it is a confusing thing. Nobody said that dealing with such flexible, ambidextrous connections would be simple. CC performs a lot of different tasks: It can be a bidirectional serial bus for active PD negotiations, and/or a resistor network for passively dealing with power, and it's the bit that performs detection of cable orientation for applications where that matters, and it probably does other stuff too.

That single little wire is clever AF. It'd be simpler to use multiple wires instead of just one, but that would take more copper. Copper is expensive, and we each save a tiny bit of money (or a large pile of money globally) by using less copper instead of more of it.


My point, which matches what you've written out in more detail, is that there's supposed to be stuff (resistors) in the cable, stuff which is often not there. There are plenty of these abhorrent cables in the wild. And when you come across one, things get weird, because some sources and sinks deviate from the standard in ways that make them work with these bad cables. Others don't do that. (I believe there were a lot more abhorrent cables in the early days, and thus began the chain of accommodation....)

So unless your cable is known-good, if you are having trouble, trying a different cable should be the first thing you do. It really does often get things working.

Contrarily, if you have identified a naughty cable, it should be immediately widlarized.


Resistors don't go in the cable. They go in the device. They indicate that the device can't negotiate voltages above 5V, so just send 5V.

USB-A has no ability to provide voltages other than 5V, so there's no need for indicating it's the max.

Not all chargers have USB-A ports. Many laptops don't have USB-A ports, so if you want to charge a noncompliant device from a laptop it won't work. Or a laptop charger, which is dedicated USB-C.


I gathered that you knew that. I'm mostly just trying to complete the picture for those following along at home, who might find some of this resistor business to be a bit weird compared to the USBs of yore.

Except the old ways were weird in unseen ways, too. Some combinations of cable, phone, and charger worked well and some barely worked at all.

We're in much better shape with USB C and PD. It's generally a good, forward-looking way of doing all kinds of things.

I just wish the cables and ports were better-marked, and that manufacturers stopped fucking around by making non-compliant stuff, and that there were a clear way with two battery-equipped USB C devices to unequivocally declare that a particular one will charge the other (and not the other way 'round).

And yes: The non-compliant widgets should ideally be named, shamed, and Widlarized -- not simply tolerated or worked around.


A-C cable assembly always works, CC signal is connected within the cable to Vbus via 56kOhm resistor, but that's only relevant to the downstream port, not to the upstream USB-A power sourcing port which does not have access to the CC signal. Upstream port provides power unconditionally within some limits depending on port type (CDP/DCP/USB3.0/2.0 data port/...).


That's how it's supposed to work, yeah.

But there is some trash out there in the world. A lot of it, actually.

Some naughty cables work with some naughty chargers work with some naughty devices. Postel's Law in action, I guess?

Usually the best place to fix it is by getting rid of the bad cables. Usually.


> Usually the best place to fix it is by getting rid of the bad cables. Usually.

No. There is no USB-C to C cable that will charge a badly implemented device with a standards compliant charger. That is the entire point.

An USB A to C cable is completely standards-compliant and safe, even if it always supplies 5V on the C end - any standards compliant USB-C device should not activate the MOSFET on its Vbus line unless it successfully negotiates via CC.


You may wish to re-read the type-c specification, especially 4.5.2.2.3.2:

"A USB 2.0 only Sink that doesn’t support accessories and is self-powered or requires only default power and does not support USB PD may transition directly to Attached.SNK when V BUS is detected."

or 4.5.2.2.5:

"A port that entered this state directly from Unattached.SNK due to detecting V BUS shall not determine orientation or availability of higher than Default USB Power and shall not use USB PD."

or 4.5.2.2.11.2:

"The port shall transition to Attached.SNK after tCCDebounce if or when V BUS is detected."

CC detection, let alone PD negotiation is not needed. You can draw up to 2.5W right away from Vbus and be standard compliant without wiring anything to CC signals.

Of course if you try this with a DRP device like a smartphone, you'll get no power. But that's not really an issue for type-c chargers or USB A-C cable assemblies.


They mean bad USB-A to C cables with no resistor on CC line. Of course this is broken junk which will work with some devices and won't with others. I've also seen cables with resistors on both CC lines, which is also broken but in a slightly subtler way.


But it’s not what anyone was talking about. Such a cable should be really quite rare because it’s unlikely to work at all in most situations, whereas devices with USB-C ports that don’t work with PD chargers (due to a cent’s worth of missing Rd resistors) are irritatingly common, because they do work with USB-C to A cables!


Huh? It seems clear to me that this is what exmadscientist was talking about, any other interpretation just doesn't make sense.

And no, such cables would still work in plenty of cases. You usually get them by having them bundled with devices they do work well with. In fact, they always work fine with the kind of devices you mention. These cables aren't as common as USB-C-shaped junk that's missing resistors on the receptacle, but I stumbled upon them anyway and I didn't really try to.


Right. That phrase "standards-compliant" in the above comments is doing a lot of heavy lifting.

A lot of devices are not actually standards-compliant. Some are close. (This may actually be worse.)

My experience has been that if the source and sink are broken, they are often hilariously badly broken and it is pretty easy to figure out that they are the problem, if not quite exactly what they've done wrong. But if things are flaky and weird and don't really make sense, it's probably the cable. Try a known-really-seriously-actually-standards-compliantly-good cable and many problems go away, even if the source and sink aren't perfect.

(Many sources and sinks aren't standards-compliant because, even though they easily could be, they're trying to work around the other end not being standards-compliant itself, because that's what you've got to do to sell a product. So they're close but not quite there. This is not always ideal.)




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: