EEVblog Electronics Community Forum

Electronics => Projects, Designs, and Technical Stuff => Topic started by: 741 on November 23, 2021, 09:56:55 am

Title: Dedicated USB C power deivery to charge Li-Ion
Post by: 741 on November 23, 2021, 09:56:55 am
I'm looking for an inexpensive chip that will handle both smart (eg Apple) "USB-C power Delivery" or dumb (5V only) chargers at the input.
3A out would be fine.

The target Li-Ion/Li-Poly (4.2V) would be 7 to 12AH.

I'm interested to know about

This is all new to me, I've only used '4-wire' USB to date.

Looked at TI and their solutions all appear to require an I2C bus to control things, wheras I'm looking for an all-in-one solution.
Title: Re: Dedicated USB C power deivery to charge Li-Ion
Post by: jwm_ on December 01, 2021, 01:24:24 am
you can buy little boards for a couple bucks that do nothing but ask for the most power they can from a USB-C port then pass it on. they are pretty useful. I have usb-pd-ized a lot of projects with them.
Title: Re: Dedicated USB C power deivery to charge Li-Ion
Post by: NiHaoMike on December 01, 2021, 03:31:56 am
4V at 3A would be 12W, well within the capabilities of 5V USB-C. No need to do USB-PD unless you want more power or want to use some advanced features like telling the other end to go into OTG mode. Easiest solution would be a buck charger with adjustable current limit and a microcontroller to read the pullup resistor value. The device side pulls down the two CC lines with 5.1k resistors (which tells the other end to start supplying power), then check the voltage to figure out the resistor value.
https://community.infineon.com/t5/Knowledge-Base-Articles/Termination-Resistors-Required-for-the-USB-Type-C-Connector/ta-p/253544
One thing USB-C missed is when using a USB-A (regular USB) to USB-C cable, how to easily tell the difference between USB 2.0 and 3.0. With micro USB 3.0 or USB-A 3.0, it's a simple matter of checking if the USB 3.0 ground is in fact connected to ground. Perhaps it might work to check voltage or impedance on the USB 3.0 data lines?

If you want to detect a dedicated USB-A charger, an easy way is to pull up one data line with a 100k resistor, then have a 1M pulldown on the other data line along with a connection to the microcontroller to check the level. The most basic of dedicated chargers simply bridge the data lines which is easily detected by that circuit.