> Application notes from several USB controller vendors explain that, oddly enough, the only way to perform role reversal with USB-C is to implement USB Power Delivery (PD) and use the PD negotiation protocol to change the source of power. In other words, while OTG allows reversing host and device roles independently of the bus power source, USB-C does not. The end supplying power is always the host end.
This isn't true. USB PD has both "data role swap" and "power role swap" commands, and they are independent from each other.
It even allows for things like a "fast role swap", where you can unplug the power source from a dock (so power now has to flow from laptop to dock, instead of dock to laptop) without any interruption of the data connection.
Yes, the article kind of describes the default behaviour, but after the initial source/sink selection one end or the other can then independently request power role swaps and data role swaps, which the other end can either accept or reject.
For example if you ask a USB-C power brick to let you swap to providing it power, it will reject that. Then some devices (like phones, tablets etc.) will only accept power when they're switched off, but will do either when they’re on. But some will happily let you switch to device mode and be a sink when they’re off, until the battery gets below a certain level and then they’ll only accept you providing it power. It all gets quite complex!
The company I work for makes devices that are always in device mode (called upstream facing port or UFP mode) but can provide power when they are plugged in themselves, so have to swap between source and sink. I’ve spent far too long debugging firmware issues with PD controllers because of this!
That reminds me of a while back, my phone battery was getting really low, like 1%. I grabbed a power bank and connected it, USB-C to USB-C, and for whatever reason, the two devices decided that the phone should be charging the power bank instead of vice-versa. Then the phone died a few seconds later. (Then the powerbank started charging the phone!)
My impression from the article is that what you're saying is in line with it: if you implement PD, you can do either.
It sounded like the line you quote was expressing suprise that baseline USB power supply in USB-C - without implementing PD - can't do that. But apparently could with older USB OTG.
Oh, I guess I understand now. When the article said "USB-C does not allow this", it actually meant "USB-C without PD does not allow this". And "always" in that specific paragraph also meant "without PD".
Every USB-C docking station that exposes USB ports while also supplying the attached computer with power uses this feature, letting the computer act as a host and the docking station as the power source
This isn't true. USB PD has both "data role swap" and "power role swap" commands, and they are independent from each other.
It even allows for things like a "fast role swap", where you can unplug the power source from a dock (so power now has to flow from laptop to dock, instead of dock to laptop) without any interruption of the data connection.