Author Topic: USB charging current detection  (Read 5404 times)

0 Members and 1 Guest are viewing this topic.

Offline Luckymat

  • Contributor
  • Posts: 31
  • Country: de
USB charging current detection
« on: October 08, 2013, 02:48:42 am »
Hi guys
I want to make usb charger powered by battery 6x AA 1.2v rechargable Ni-MH 2500mA/h Vipow bateries
I want to power it of battery becouse its easier to buy 6x AA 1.5v batteries than charge these
(Its just more portable)
So i have already case,batteries,battery pack,lot of wires,and USB port and a step down converter
If i hook anything up i have 5v (+/- 0.1v) power supply that can supply like 2A
But if i hook my phone it charges at 499mA and it should charge at 999mA or more
I know that i need  to connect anyhow D+ and D- and shield and ground but i have no idea how to...
I already googled it...and i did'nt find mouch...
MY PHONE IS EXPENSIVE AND I DONT WANT TO BLOW IT UP  :-BROKE
 (samsung galaxy s3)
If somebody needs photos i can make some and post it
So i hope anybody anwser and help...

(Sorry for my bad englsch...im from poland)
« Last Edit: October 08, 2013, 02:50:59 am by Luckymat »
 

Offline andtfoot

  • Supporter
  • ****
  • Posts: 352
  • Country: au
Re: USB charging current detection
« Reply #1 on: October 08, 2013, 03:04:09 am »
Shorting the D+ and D- pins (the two middle ones on a normal A connector) together on the USB port from the charger is a common way of telling the phone it is connected to a charger.
There are exceptions based on phone model, such as the Apple stuff, which need a particular voltage or resistor network present.

Edit: There are some more details in the datasheet I just found for a USB charge controller chip:
http://www.ti.com/lit/ds/symlink/tps2514.pdf
Page 10 has what I was talking about (DCP Short Mode).
« Last Edit: October 08, 2013, 03:11:19 am by andtfoot »
 

Offline jakehiltz

  • Contributor
  • Posts: 7
Re: USB charging current detection
« Reply #2 on: October 08, 2013, 04:03:12 am »
you can also just use (I believe ) a 4200ohm resistor
 

Offline olsenn

  • Frequent Contributor
  • **
  • Posts: 993
Re: USB charging current detection
« Reply #3 on: October 08, 2013, 04:13:17 am »
You're wasting batteries, but that's your decision.

According to the USB specification, dumb chargers (ones that don't digitally handshake the output current capabilities) first short the supply to see if >1.5A can be sourced, and if it can, it uses 1A. If it cannot, it defaults to 0.5A (which is how much a computer's USB port can provide)
 

Offline Luckymat

  • Contributor
  • Posts: 31
  • Country: de
Re: USB charging current detection
« Reply #4 on: October 08, 2013, 06:45:27 am »
You're wasting batteries, but that's your decision.

According to the USB specification, dumb chargers (ones that don't digitally handshake the output current capabilities) first short the supply to see if >1.5A can be sourced, and if it can, it uses 1A. If it cannot, it defaults to 0.5A (which is how much a computer's USB port can provide)


So what's another ideato not waste batteries?

so i can just short D+ and D- and connect Vcc and GND and if my phone sees 1.5A it just draws so much?
and if i limit current to 1A it draws 1A?
if i just connected shield and GND to GND of phone and VCC to VCC it draws 499mA and that sucks...

it is really safe to connect D+ and D-?
becouse i blow 1 old samsung and nokia n8 xD (ovecloacking wrong polarity and some systeam change (like never turn off))
and i dont have any test phone anymore
 

Offline xstream

  • Contributor
  • Posts: 7
Re: USB charging current detection
« Reply #5 on: October 08, 2013, 09:39:43 am »
so i can just short D+ and D- and connect Vcc and GND and if my phone sees 1.5A it just draws so much?
yes
Quote
and if i limit current to 1A it draws 1A?
Well if it is limited it can't draw more and I don't see a reason why it would switch back down. In fact many chargers can only deliver 1A and it works just fine with them.
Quote
it is really safe to connect D+ and D-?
Yes, as long as there isn't anything else connected it is safe. For example if you build a cable that does this and don't use it with a charger but a PC that would not be ideal I think however most systems are protected even in this case. Modifying the power source itself in this way is never a problem.
 

Offline Jon Chandler

  • Frequent Contributor
  • **
  • Posts: 540
    • Throw Away PIC
Re: USB charging current detection
« Reply #6 on: October 08, 2013, 11:03:10 am »
I've collected some info about iPhone/iPad charging here.

The resistor values selected tell the device how much current it may draw.
 

Offline PokemonCookies

  • Contributor
  • Posts: 9
Re: USB charging current detection
« Reply #7 on: October 08, 2013, 04:06:06 pm »
I recently did the same thing, I used a resistor on  D+ and on D- I think it was 2 100 ohm resitors and connected them to +  and a 5v voltage regulator but for some rason my iPhone says that the device is not compatible.
Does anybody know the correct resistor to use?
 

Offline BravoV

  • Super Contributor
  • ***
  • Posts: 5857
  • Country: 00
Re: USB charging current detection
« Reply #8 on: October 08, 2013, 04:17:02 pm »
I've collected some info about iPhone/iPad charging here.

The resistor values selected tell the device how much current it may draw.

Hey Jon, thanks for pointing that out and also appreciate your works there :-+, since I'm going to build 4 or 5 USB ports charging deck in my car serving various gadgets. 

Btw, does that resistors configuration works at android device for high current draw ?

Offline Jon Chandler

  • Frequent Contributor
  • **
  • Posts: 540
    • Throw Away PIC
Re: USB charging current detection
« Reply #9 on: October 08, 2013, 06:06:39 pm »
The iPhone method isn't compatible with the smart phone method.  I don't have a smart phone so I haven't tried this but it might be possible to do both with the two voltage dividers for the iPhone arrangement plus a resistor connected D+ and D–.
 

Offline BravoV

  • Super Contributor
  • ***
  • Posts: 5857
  • Country: 00
Re: USB charging current detection
« Reply #10 on: October 08, 2013, 06:17:49 pm »
The iPhone method isn't compatible with the smart phone method.  I don't have a smart phone so I haven't tried this but it might be possible to do both with the two voltage dividers for the iPhone arrangement plus a resistor connected D+ and D–.

It will be nice if it works for both camps, cause me & wifey own android phone & tablet vs ipad & iphone, and all hell breaks loose in the car when it times for charging those gadgets.  :palm:

Offline Luckymat

  • Contributor
  • Posts: 31
  • Country: de
Re: USB charging current detection
« Reply #11 on: October 08, 2013, 06:41:29 pm »
I gonna try it just connecting d+ and d-

And i'm not talking about 'I' stuff like IPad or Iphonebut i have
2nd question
If i plug my phone to ac charger with a good quality cable it chargest fast
But uf i connect orginal samsung cable it charges normal
So can i just solder USB port ( Vcc to Vcc ...gnd to gdn and shield ...d+ to d-)
And use any cable i want? Like micro usb? Mini usb? Or anything i want?
Or need i to cut the high quality cable off and solder it direct?
Has anybody any nice ideas? Maybe can somebody send me some photos of their USB charger?
 

Offline zapta

  • Super Contributor
  • ***
  • Posts: 6004
  • Country: us
Re: USB charging current detection
« Reply #12 on: October 10, 2013, 04:26:17 pm »
Have you considered buying an off the shelf product? For example this one Link: http://amzn.com/B000N7HT0E
 (I am sure there are others).

(I am using a Galaxy Nexus which allows to change batteries, and carry a spare battery in my wallet. Very small, high energy density and zero conversion losses).
Drain the swamp.
 

Offline Luckymat

  • Contributor
  • Posts: 31
  • Country: de
Re: USB charging current detection
« Reply #13 on: October 10, 2013, 07:30:53 pm »
Does it supply at least 1A ? And can 1 power it from 1.2v battery?
Becouse my phone needs MUCH power to charge and play HD games in train or on bus station :D
(May be hard to get it if you live in europa (germany))
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf