USB C + PD + BC + D+/D- current negotiation for charging? What's necessary? - Page 1
Forum section: electronics / projects

author: newto
author_rank: Regular Contributor
timestamp: July 14, 2021, 01:41:04 pm
content: I feel like I'm going cross eyed here. I want to use USB C in a new commercial product with USB 2.0. I think it would help a lot in differentiating from the competition, where mini-B is considered new technology, and half the field still uses screw in serial cables. (it's a very small industry)The problem I am running into, is the state of current negotiation/standards/etc is very confusing?I was planning to use this 2s chargerhttps://www.ti.com/lit/ds/symlink/bq25883.pdf?ts=1626196866649&ref_url=https%253A%252F%252Fwww.ti.com%252Fproduct%252FBQ25883, which has D+/D- identification for BC and "non-standard" dividers, so if I understand right, this will work with most everything with a 2.0 type A port, as well as compliant dedicated USB-C charging ports (according to this:https://medium.com/@leung.benson/how-do-usb-type-c-chargers-support-older-usb-devices-70c978eae9ec).If this is right, would the only issue I could run into is a Type-C data port (ie on a computer), since support for the BC standard is optional in that case? And in any situation where the charger IC can't identify the charger (type C that doesn't have the BC resistor, or a type A that only supports PD and not BC), then it'll run at 500mA anyways. The main issue I might run into is that there's a pump that can run up to 5V 300mA if fully restricted at full speed, so that doesn't leave much left over to charge the battery from a 500mA source. If I wanted guaranteed full power from a USB-C data port, then I'd need something that monitors the CC lines to use USB-C PD?

author: David Hess
author_rank: Super Contributor
timestamp: July 14, 2021, 07:38:44 pm
content: My observations from testing many chargers now is that they largely ignore USB 2.0 requirements and draw a minimum of 1 amp from any port without enumeration. The only exception I have found so far is the Milwaukee charger for their M12 batteries which actually limits itself to 100 milliamps like the charging specifications say it should on a non-charging USB 2.0 port without enumeration.

author: NiHaoMike
author_rank: Super Contributor
timestamp: July 15, 2021, 01:47:40 am
content: Easy circuit for detecting a standalone charger prior to USB-C is to have a 100k pullup to 3.3V on one data line and a 1M pulldown on the other, which is also what you check for a logic high level to indicate that a charger is connected. Something to keep in mind if you want to use another charger chip without built in USB support.For basic USB-C power detection, have the CC lines pulled down with 5.1k resistors and have the microcontroller check the voltages on the lines. You're basically checking if one of the lines is pulled up (from a 5V source) with a 10k (3A) or 22k (1.5A) resistor. Note that if either is detected, you can just pull the 3A or 1.5A.Unless you want to be able to pull more than 15W from the supply, USB PD adds too much complexity to be worth it. You'll also need a charger chip with a wide voltage input range.

author: sleemanj
author_rank: Super Contributor
timestamp: July 15, 2021, 02:32:01 am
content: Another thread yesterday or day before had this nice sounding chip linkedhttp://www.hynetek.com/product/pdController/HUSBPDSink/document/HUSB238_DS_EN_V1.0.pdfYou can simply use resistors to set the voltage/current you want, and the chip will do the negotioation over type C, or just look at the D+/D- for for the "old fashioned" apple/BC modes, and if the supply can do what you want it to do then it will enable the gate of a P-Fet for liven your load up.Edit to add: now I look at the datasheet, it sounds like the P-Fet is enabled all the time by default, having it enabled only after successful negotiation seems to be a hardware option that you have to specially order.