EEVblog Electronics Community Forum

Electronics => Projects, Designs, and Technical Stuff => Topic started by: Pack34 on November 16, 2017, 04:26:33 pm

Title: Detecting current capacity of a USB cable?
Post by: Pack34 on November 16, 2017, 04:26:33 pm
Here's the idea.

On a project I want to use a USB-C connector to take advantage of the added current. The power budget of the device is going to be tight for the 500mA USB standard, which is why I'm looking at USB-C.

Now, you can buy a USB-A to USB-C cable and charge at the 500mA. In this state I don't want to be able to charge while the device in ON. However I would like the ability to use a portable USB-C charger and use the device at the same time.

How would you be able tell if the connected USB cable is cable of the 5V 1.5A of a USBC-USBC cable or the 5V 500mA of a USBA-USBC cable?
Title: Re: Detecting current capacity of a USB cable?
Post by: tszaboo on November 16, 2017, 04:31:16 pm
USB can supply more current than .5A. Because they dont place fuses or current limit switches on them, because they cost money, and generally, nobody really cares about the standard. Also, your phone will charge with like 2A on a regular USB cable if it can.
What they do is simple: Measure the voltage. If it drops below 4.4-4.5V it's bad, reduce the current. Simple as this.
Title: Re: Detecting current capacity of a USB cable?
Post by: Pack34 on November 16, 2017, 04:38:52 pm
So, just let the battery charge and the device operate at the same time but disable the charging circuit if VBUS dips? Sounds simple enough.

Something like this would probably want to be under firmware control so I don't have the battery charging state oscillate...
Title: Re: Detecting current capacity of a USB cable?
Post by: tszaboo on November 16, 2017, 04:47:49 pm
You dont disable the charging, you reduce the current.
A chip like BQ25895M    does everything for you, it is worth reading the datasheet, just to see what features it has, and what you might need.