Hi everyone!
Firstly I am not sure if this is correct forum, but its only one related with hardware...
I has built my own emergency charger powered with solar energy.
It can provide 5V with 2A max. (about 10W) and provides two USB ports for devices.
Althought I dont have any phone/tablet with USB OTG (Host) function, I d like to prepare it to provide all this functions:
- charge two client devices
- charge two host devices
- charge one host and one client device
But, there is one problem with power - some OTG devices provides power, and some not.
Thats the thing, why I am asking - if both chargers connectors are powered and one host device is connected in it there will be a power collision - on one wire will be 5V from both sides - from e.g. phone and from charger. This will surely damage the phone because of shortcut.
I am right? Or, is a hosts power enabled, only, if there is not any external power plugged?
Hope, that anyone will understand, I can also provide a schematics later it it could help
Thanks anyone !!!
The wire is the same, so there won't be any collision, it doesn't matter where the voltage source point is when it's applied on the same wire (without any component in between the voltage sources).
I guess maybe the only thing will happen is that the phone battery won't have much or perhaps even no drain?
And speculating here on same line of thought, dunno exactly how the charging circuits work on the phone, but i guess it won't charge when in OTG mode even with an external power power source available...
My Touchpad doesn't provide OTG power but refuses to charge when in OTG mode, maybe other devices are different though. OTG will still work on it even if I disconnect the +5v Vcc (red) wire. If you wanted to force USB devices to be powered from the external supply maybe you could try disconnecting Vcc from the device.
Thanks - more people, more ideas,more knowledge
As told - there are two kinds of OTG devices - self powered (few Xperia`s and Samsung devices) and non powered (spunkler88`s Touchpad and e.g. my Xperia X10i).
In case of non powered devices, there shouldn`t be any problem, think that host just won`t accept power and nothing bad happens. But in case ot self.powered devices there is in OTG mode voltage on vcc pin - 3,3 or 5V (low power or high power mode).
I`m not so demanding to want host and slave to be charged at the same time.
We dont have to worry about non powered host devices, but afraid about powered ones... Or even if we don`t know, if our device is powered or not
Elusivo:
I know, that it is the same wire You maybe didn`t caught my point - there could be two power sources on one wire - one could be phone (in OTG mode) and one power on hub.
Will post an scheme as soon as possible.
HeliumX10 said:
I know, that it is the same wire You maybe didn`t caught my point - there could be two power sources on one wire - one could be phone (in OTG mode) and one power on hub.
Will post an scheme as soon as possible.
Click to expand...
Click to collapse
Yes, actually there shouldn't be any issues with this now that I think of it. The phone if providing powered USB OTG would simply act as a parallel voltage source with the charger meaning voltage stays the same and the available currents add.
So, there is the block diagram of device which i have built:
The red cross indicates the one wire collision when DEVICE B provides power. If device B doesn`t provide power there won`t be any problems surely.
But as I thought of it, there is no solution for it - parallel voltage will surely damage one device on one side. The power sources providing high-efficient PWM power has very very low input resistance. So if we connect any voltage to its output, very high current will flow throught and surely damage the power source. This can happen very easily, because from phycisict`s point of view the higher voltage source will damage the less voltage source (there is +/- 10% tolerance on USB power, so this could happen everytime).
So now I am thinking about some mosfet auto switching circuit, which could automatically connect or disconnect power from master device... Or maybe will simple add an switch which will disconnect the power from master device everytime and power just a slave.
< wrong posting removed >
It doesn't pay to overthink this.
These devices are usually designed to take a beating.
Just connect all the Vcc's together.
I've been using something similar on my B&N Nook Touch for months.
It's not a solar charger, but a modified $10 USB hub.
I can use USB host mode on my Nook and charge at the same time.
Of course, all the peripherals are powered off the hub power supply too.
A general schematic is attached, pull the diode and insert a jumper.
Since USB was really not designed to charge in host mode,
there are two problems related to getting the device charging circuit to play nicely.
When using host mode to directly power a peripheral you must make the device charging circuit go off.
To go into host mode the device must raise the Vcc line to 90% of 5V, i.e. >4.5V.
If the device charging circuit is still enabled it will try to charge itself using itself!
When using host mode with incoming power the device charging circuit must be convinced to charge.
Renate NST said:
It doesn't pay to overthink this.
These devices are usually designed to take a beating.
Click to expand...
Click to collapse
Yeah, mostly yes, but dont want to try if this is also for all devices. Most of them could take beatings,some not... So trying to design absolute save solution
Renate NST said:
A general schematic is attached, pull the diode and insert a jumper.
Click to expand...
Click to collapse
See that, diode is used as blocking diode, which prevents shortcut So VCCs cant be connected together without protection. It seems that is for case I spoke about power provided from OTG device....
So as I see, simpliest solution will be the best. I will add a switch at the output for one USB ports VCC wire. And if I will use my charger as host active hub, will disconnect power (with switch) to one port, second port will be powered all the time. When charging two slave devices, i could switch power back too to the second USB port.
Renate NST said:
When using host mode to directly power a peripheral you must make the device charging circuit go off.
To go into host mode the device must raise the Vcc line to 90% of 5V, i.e. >4.5V.
Click to expand...
Click to collapse
OK, mainly thankx for this lines, once it happened that my phone indicated, thats chagring, but battery ran down.... Thought that was some kind of software relaed thing....
Hi Renate,
I've read and re-read your points several times and I think I understand.
My goal is to put together a battery powered USB Hub that also charges the phone at the same time. From your points, the B&N Nook is capable of going into Host mode while still accepting a charge - do you believe this to be true of most/all devices?
Did you have to do anything to get the Nook to charge in host mode other than supplying power by putting a jumper in lieu of the diode?
What $10 powered USB hub did you use?
Sorry for all the questions.
Renate NST said:
It doesn't pay to overthink this.
These devices are usually designed to take a beating.
Just connect all the Vcc's together.
I've been using something similar on my B&N Nook Touch for months.
It's not a solar charger, but a modified $10 USB hub.
I can use USB host mode on my Nook and charge at the same time.
Of course, all the peripherals are powered off the hub power supply too.
A general schematic is attached, pull the diode and insert a jumper.
Since USB was really not designed to charge in host mode,
there are two problems related to getting the device charging circuit to play nicely.
When using host mode to directly power a peripheral you must make the device charging circuit go off.
To go into host mode the device must raise the Vcc line to 90% of 5V, i.e. >4.5V.
If the device charging circuit is still enabled it will try to charge itself using itself!
When using host mode with incoming power the device charging circuit must be convinced to charge.
Click to expand...
Click to collapse
zuberio said:
From your points, the B&N Nook is capable of going into Host mode while still accepting a charge - do you believe this to be true of most/all devices?
Click to expand...
Click to collapse
I will answer these lines
Nook can charge when in host mode. But some new devices form Sony and Samsung cant,because they are providing power to hosted device. And if you connect active hub to them in host mode, you will damage the phone - thats why I opened this topic, but I solved it with simple diode indicator and switch (manually disconnects power to the phone if it provides power itself).
zuberio said:
What $10 powered USB hub did you use?
Click to expand...
Click to collapse
I just meant any generic hub. They are all about the same.
Usually the input diode is easy to identify.
Often it's the physically largest device present.
If you want, post a good photo.
The 4 port ones have one chip, 2 for 7, 3 for 10, 4 for 13.
I've never seen/heard of a hub chip with more than four outputs.
Yes, the USB spec does say only four outputs, but that's for unpowered hubs.
The spec for all the device USB chips have a maximum recommended of 7V on the lines.
I don't lose any sleep putting my 5V in.
Thanks for warning me off just going out and applying Vcc to my phone in host mode without first testing if it supplies it's own power.
When you say diode indicator do you mean an LED? And if the LED lights up you flip a switch to disconnect the hub power to the phone?
HeliumX10 said:
I will answer these lines
Nook can charge when in host mode. But some new devices form Sony and Samsung cant,because they are providing power to hosted device. And if you connect active hub to them in host mode, you will damage the phone - thats why I opened this topic, but I solved it with simple diode indicator and switch (manually disconnects power to the phone if it provides power itself).
Click to expand...
Click to collapse
---------- Post added at 07:42 PM ---------- Previous post was at 07:31 PM ----------
Ah, I understand now.
I guess the safest option for my battery backup/powered usb hub device is to install a 'mode' switch. Either it's a battery backup, or it's a battery powered USB hub - depending on the 'mode'.
Now I just need to hunt down a cheap powered USB hub and a battery that will power it or my phone.......
Actually, would there be any issues using an inline powered USB hub and disconnecting the Vcc from the host side to instead attach to a 5V 1A power source? The power source could probably be two minty-boosts in parallel.
[EDIT] Doh, I looked again at your hub.jpg - I just need to use a powered USB hub setup like that with a switch to bypass the diode for the 'phone charge mode' mentioned above (probably with some special resistances between D+ and D- depending on the device).
Renate NST said:
I just meant any generic hub. They are all about the same.
Usually the input diode is easy to identify.
Often it's the physically largest device present.
If you want, post a good photo.
The 4 port ones have one chip, 2 for 7, 3 for 10, 4 for 14.
I've never seen/heard of a hub chip with more than four outputs.
Yes, the USB spec does say only four outputs, but that's for unpowered hubs.
The spec for all the device USB chips have a maximum recommended of 7V on the lines.
I don't lose any sleep putting my 5V in.
Click to expand...
Click to collapse
zuberio said:
(probably with some special resistances between D+ and D- depending on the device).
Click to expand...
Click to collapse
No, resistors between D+ and D- are only for charging devices that are not communicating.
If you want to charge and communicate then you have to leave those alone.
That's why I said that you may need a kernel driver mod or an app to turn on charging when communicating.
I agree and understand - I guess I wasn't very clear in my last post.
My device will have two separate modes.
Mode 1:
Battery powered USB hub that doesn't provide power upstream to the OTG host device.
Mode 2:
Battery backup power device - powered USB hub disconnected
Such a device would be compatible with all Android devices, regardless of weather they provide power in OTG Host mode or not
Renate NST said:
No, resistors between D+ and D- are only for charging devices that are not communicating.
If you want to charge and communicate then you have to leave those alone.
That's why I said that you may need a kernel driver mod or an app to turn on charging when communicating.
Click to expand...
Click to collapse
zuberio said:
I agree and understand - I guess I wasn't very clear in my last post.
My device will have two separate modes.
Mode 1:
Battery powered USB hub that doesn't provide power upstream to the OTG host device.
Mode 2:
Battery backup power device - powered USB hub disconnected
Such a device would be compatible with all Android devices, regardless of weather they provide power in OTG Host mode or not
Click to expand...
Click to collapse
I understood clearly
This is the exactly the same I made completely myself. It has only 2 ports (no active chip, simplier and more reliable solution). It has One connector only for OTG master and second one port is for host device. When switch is on, power is also delivered into OTG host port, otherwise poered are all of the slave ports. But mine is designed mainly as emergency charger (for OTG Master device or two slave only phones/devices), or as active hub (thats why I added the switch with resistor and diode as power check).
Will post a diagram if you want.
prie irgseha
My touchpad is not power OTG, but refuses to load when the OTG mode, other devices will be different. OTG still working on it, even if I disconnect Vcc +5 V (red) wire. If you force, the USB devices be powered by external power supply might try unplugging the device Vcc.
BC1.2 Usb battery charging specs
Hi All,
I see that the last post here is a month ago, but here goes anyway. I am looking to do the same thing - I want to hack a 4 port powered USB hub to also charge the host (upstream) device.
Two modes of operation shouldn't be required. The specs allow for the phone to act as the USB host, and simultaneously charge. A powered USB should be easy to hack to simultaneously charge the phone and give you a useable USB hub for keyboard/mouse/usb stick or high-powered devices you can't use directly on the phone like USB hard disks.
I've made a reasonably close study of the Battery Charging Specification rev 1.2 (dec 2010) (USB implementers forum). The relevant sections and diagrams are around section 6.3: Standard ACA (accessory charging adapter) which could be a modified 4-port powered USB hub, hacked to be an "Accessory Charger Adapter" (figure 6-1):
1. The charger port should be 5V; jump that to the 5V V+ pin on the "OTG Port" - the OTG port would be the USB upstream port on the hub.
2. An ID resistance needs to be fitted integral to the μ-A Plug connecting to the OTG device, 124kohm between the ID pin and GND. (ref table 5-3 Resistances: RID_A; table 6-2 row 6)
I won't be able to use it anywhere else, because of the short to the V+ pin I've put there, but I would then have a battery charger for my phone which simultaneously works as a 4 port hub.
I have a Galaxy Note N7000. Does anyone know if this is FULLY compliant with the above referenced BC1.2 spec? I wonder because the Note also does audio and HDMI out on that port. Presumably with non-standard Rid values at the connector end.
Different hardware supports different ID pin sensing and data pin multiplexing.
On the Nook Touch, which uses a TPS65291, ID sensing is just short/open.
There is ability to use UART through the ULPI interface, but I haven't noticed it.
Many devices have separate muxes to integrate MHL, UART, CarKit (audio) and USB.
The CarKit is the tricky one because the signal goes below ground.
scitobor said:
I have a Galaxy Note N7000. Does anyone know if this is FULLY compliant with the above referenced BC1.2 spec? I wonder because the Note also does audio and HDMI out on that port. Presumably with non-standard Rid values at the connector end.
Click to expand...
Click to collapse
I suspect that the N7000 is very similar in Specs to the I9100, and thus it is more likely that it conform to the BC1.1 as mentioned and linked in this thread/post here. Remember that HDMI (and possibly audio) is not covered by the BC specs and very manufacturer dependent.
ok here's what I want to do.
Permanently integrate a nexus 7 in my car dashboard in the double din radio opening
Remove the battery from the nexus 7 and hardwire to always on power from the car battery
Hardwire the power button to a button installed in the dash
Dashmount a usb port connected via otg for hotswapping media
Hardwire a potentiometer into the dash for volume control
all of the above is fairly simple except for power supply, otg+charging is a possible solution but a car battery wired solution is far better so what i need is information on what the battery pins supply in terms voltage/amperage so i can create a 12v to direct power converter or a device that already does this. any help is appreciated TIA
bump, if someone knows i could really use this info
b22ri22an said:
ok here's what I want to do.
Permanently integrate a nexus 7 in my car dashboard in the double din radio opening
Remove the battery from the nexus 7 and hardwire to always on power from the car battery
Hardwire the power button to a button installed in the dash
Dashmount a usb port connected via otg for hotswapping media
Hardwire a potentiometer into the dash for volume control
all of the above is fairly simple except for power supply, otg+charging is a possible solution but a car battery wired solution is far better so what i need is information on what the battery pins supply in terms voltage/amperage so i can create a 12v to direct power converter or a device that already does this. any help is appreciated TIA
Click to expand...
Click to collapse
Can't you just use the USB port to charge it? it takes 5V, and 2A. With a car battery it should have enough amps, the voltage is what you'd need to regulate.
But if you really want to take out the battery instead...can't you just use a volt meter to see what the N7 draws from the battery? I'd guess it's 3.7v lithium ion but I'm not positive. I couldn't find the specs on google either..
As far as I have read there are some major difficulties getting otg+charging to work at the same time and I need the storage space provided by external storage. Having the car power source replacing the nexus 7 battery would eliminate that problem altogether.
I was hoping that someone here had known the voltages since I don't currently own or have access to a multimeter to test for myself. Knowing the voltages in advance would give me the opportunity to see what would be entailed financially to build the project and determine if its its financially acceptable to me, if the project isn't viable the money spent on the multimeter to do the tests would be wasted as it's not something I need for anything other than this particular project. So in the interest of trying to save $20 I figured I would ask here first and that there was a good chance that someone might have the information I needed.
b22ri22an said:
As far as I have read there are some major difficulties getting otg+charging to work at the same time and I need the storage space provided by external storage. Having the car power source replacing the nexus 7 battery would eliminate that problem altogether.
I was hoping that someone here had known the voltages since I don't currently own or have access to a multimeter to test for myself. Knowing the voltages in advance would give me the opportunity to see what would be entailed financially to build the project and determine if its its financially acceptable to me, if the project isn't viable the money spent on the multimeter to do the tests would be wasted as it's not something I need for anything other than this particular project. So in the interest of trying to save $20 I figured I would ask here first and that there was a good chance that someone might have the information I needed.
Click to expand...
Click to collapse
oh ok..well have you taken a look at the battery? It should just be 3.7v, I don't think it would be too hard to find which pins it is. Maybe take a LED and test it across the pins?
Also, I have heard reports OTG + charging is working fine on CM10 with a patched kernel. you might want to check this thread: http://forum.xda-developers.com/showthread.php?t=1934722
mvmacd said:
oh ok..well have you taken a look at the battery? It should just be 3.7v, I don't think it would be too hard to find which pins it is. Maybe take a LED and test it across the pins?
Also, I have heard reports OTG + charging is working fine on CM10 with a patched kernel. you might want to check this thread: http://forum.xda-developers.com/showthread.php?t=1934722
Click to expand...
Click to collapse
I've been participating heavily in the arena of OTG + charging simultaneously, as well as using USB audio.
To answer the OP's question directly: I have demonstrated (to myself) that I can power down my Nexus 7, disconnect the battery connector, plug in my y-splitting OTG cable with power in one plug, and an unpowered USB hub in the other plug. [Plugged into the USB hub is a flash drive, USB DAC, and I'm sure a keyboard would also be an option.] Then I turn on my Nexus 7, and in the OS it shows the battery at 0%, but charging (obviously it's not actually charging without the battery present...).
I even booted up the Nexus 7 normally, with all the same stuff connected to USB, and then disconnected the battery connector... and the Nexus 7 remained on!
I've thought about integrating some sort of tactile switch that essentially disconnects the battery whenever the switch is depressed. So then part of the car mount could be a little protrusion that presses this switch whenever the tablet is inserted into the car mount. That way whenever the tablet is removed from the car mount, the battery will take over without removing power from the motherboard.
MetalMan2 said:
I've been participating heavily in the arena of OTG + charging simultaneously, as well as using USB audio.
To answer the OP's question directly: I have demonstrated (to myself) that I can power down my Nexus 7, disconnect the battery connector, plug in my y-splitting OTG cable with power in one plug, and an unpowered USB hub in the other plug. [Plugged into the USB hub is a flash drive, USB DAC, and I'm sure a keyboard would also be an option.] Then I turn on my Nexus 7, and in the OS it shows the battery at 0%, but charging (obviously it's not actually charging without the battery present...).
I even booted up the Nexus 7 normally, with all the same stuff connected to USB, and then disconnected the battery connector... and the Nexus 7 remained on!
I've thought about integrating some sort of tactile switch that essentially disconnects the battery whenever the switch is depressed. So then part of the car mount could be a little protrusion that presses this switch whenever the tablet is inserted into the car mount. That way whenever the tablet is removed from the car mount, the battery will take over without removing power from the motherboard.
Click to expand...
Click to collapse
Lol, yes, I think I had you in mind when I said that.. I'm still waiting for my Y cable. I won't get it till at least 1.5 weeks..
MetalMan2 said:
I've been participating heavily in the arena of OTG + charging simultaneously, as well as using USB audio.
To answer the OP's question directly: I have demonstrated (to myself) that I can power down my Nexus 7, disconnect the battery connector, plug in my y-splitting OTG cable with power in one plug, and an unpowered USB hub in the other plug. [Plugged into the USB hub is a flash drive, USB DAC, and I'm sure a keyboard would also be an option.] Then I turn on my Nexus 7, and in the OS it shows the battery at 0%, but charging (obviously it's not actually charging without the battery present...).
I even booted up the Nexus 7 normally, with all the same stuff connected to USB, and then disconnected the battery connector... and the Nexus 7 remained on!
I've thought about integrating some sort of tactile switch that essentially disconnects the battery whenever the switch is depressed. So then part of the car mount could be a little protrusion that presses this switch whenever the tablet is inserted into the car mount. That way whenever the tablet is removed from the car mount, the battery will take over without removing power from the motherboard.
Click to expand...
Click to collapse
Am i understanding you correctly? If i unplug the battery, and just have the OTG cable plug into the charger, it would be able to power on and off and run just fine?
ho9984 said:
Am i understanding you correctly? If i unplug the battery, and just have the OTG cable plug into the charger, it would be able to power on and off and run just fine?
Click to expand...
Click to collapse
This was how it worked while the N7 was running Jelly Bean 4.1.2. I can't guarantee it would operate the same on 4.2.2.
MetalMan2 said:
This was how it worked while the N7 was running Jelly Bean 4.1.2. I can't guarantee it would operate the same on 4.2.2.
Click to expand...
Click to collapse
Someone tried it on Reddit. Removed the battery and tried powering it on with only OEM charger. The screen just flickered. They were on 4.2.2
I am curious about removing the battery and hardwiring as well as I am gathering parts to put my Nexus 7 in my car dash. The problem w/ the OTG route - it gets pretty hot down here and I'm afraid the battery will have some long term issues (ie...could leak/explode). So, hardwiring it would be preferred.
Any ideas for hardwiring?
with the new nexus 7 coming out I am just going to mount the wireless charger behind the tablet dock, now I just hope otg is supported with the slimport on the new nexus 7
Hello all,
First thread here and hoping you guys and girls with more experience can help.
Basically I am fitting my nexus 7 2012 in my car but its got the common charging problem where my battery drains faster than I can charge it.
I have ordered a new USB port strip as I've read that can fix it and fingers crossed with that.
My problem/requirement:
1. I want to charge the tablet via the usb port using a hardwired 5V 2A device this will be plugged into a otg y splitter which is then plugged into the tablet.
2. The USB A side of the splitter I want to connect to my cars ECU (it has a USB port) so I can read the data on that (basically a very expensive memory stick)
I wanted to confirm that this would work and id be able to read data at the same time as charging it.
I also wanted to double check I'm not somehow going to send my 5v 2a power down into my ECU and set it on fire
On a side note, if my new USB port replacement doesn't solve the issue of charging the tablet i will have to remove the battery and hardwire it in, will i still be ok with using the USB port for the ecu while charging hardwired with no battery?
Kind Regards
Tim
Getting any USB 2.0 device to take current while hosting is tricky.
Usually it involves talking directly to the PMIC (power management IC).
If it's a fixed installation, why not remove the battery?
It will avoid the grief of the battery swelling up, which is not too unusual for things plugged in all the time.
I've been using a Nexus 7 (2013) for a few years, but just charging on USB.
It started falling out of its nice holder.
That's when I realized that the battery was all puffed up making the back convex.
I cut off the battery cell itself on the metal tabs and soldered in wires to a 4 V 2 A supply.
I found out that the BMS is a bit balky, it refused to turn on.
So I connected it to USB to "charge" it for about 10 seconds.
Then I could turn it on (without the USB).
Ok, I could have bypassed the BMS entirely but that can be a whole 'nother can of worms too.