Switching between battery charger and the circuit - Page 1
Forum section: electronics / beginners

author: fenclu
author_rank: Regular Contributor
timestamp: October 13, 2013, 01:52:48 pm
content: Well, this is embarrassing...I have a circuit that's powered from a Li-Po battery. It's going to be charged from USB using MCP73831. The thing is I need some circuitry to switch the battery between the charger and the rest of the circuit (when the USB is plugged in it's supposed to disconnect the battery from my widget, connect it to the battery charger and also power my widget from the USB). I've been thinking about it fot three days straight and I just cannot seem to come up with a solution.Please help!

author: madires
author_rank: Super Contributor
timestamp: October 13, 2013, 03:03:54 pm
content: A SPDT relay :-) But i'd guess that there are some battery management ICs for that. Two PNP BJTs with some clever driver might also work, i.e. one PNP between the battery and the circuit and the second one between USB and circuit. Or two Schottky diodes instead of the BJTs (slightly higher voltage drop but very simple, i.e. higher voltage wins).

author: JohnnyGringo
author_rank: Regular Contributor
timestamp: October 13, 2013, 03:13:29 pm
content: Use some OR-ing diodes. Basically a OR function with 2 diodes.Check out:http://www.codemsys.com/SMPS/Parallel.htm

author: dr_p
author_rank: Frequent Contributor
timestamp: October 13, 2013, 03:20:00 pm
content: why disconnect the battery in the first place?the datasheet for the MCP73831 states less than 2uA discharge in shutdown mode (VDD not present)

author: M. András
author_rank: Super Contributor
timestamp: October 13, 2013, 04:40:21 pm
content: why not chose a charge controller which has this function? disconnects the battery from the load when external power applied

author: fenclu
author_rank: Regular Contributor
timestamp: October 13, 2013, 08:05:52 pm
content: The circuit is in the attachment. A relay is far too big for this application. It's a small 5x5cm board so only SMD semiconductors are possible. I dunno. It's sounds simple but I completely can't get my head arround that. My widget is powered from VCC (the Li-Po battery) and is supposed to be powered from 5V USB when connected.

author: M. András
author_rank: Super Contributor
timestamp: October 13, 2013, 08:28:10 pm
content: look at what these dedicated TI charge controllers provide simple elegant but requires "few" components :http://www.ti.com/lit/ds/symlink/bq24610.pdfthe rest are herehttp://www.ti.com/lsds/ti/power-management/battery-charger-solutions-products.page#p1152=Single%20Cell&p2192=Power%20Path&p338=Li-Polymerhave a look and decide few fets passives etc provides charging while powering the system from the external supply some of them as i recall have fatures that supplies excess power from the battery on demand while running from external power source. but i was looking at 6+cell chargers

author: sleemanj
author_rank: Super Contributor
timestamp: October 13, 2013, 10:04:55 pm
content: See this thread I started a couple weeks back:https://www.eevblog.com/forum/projects/primary-(eg-usb)-and-auxillary-(eg-battery)-power-steering-ic/Note, the circuit I proposed there doesn't work brilliantly, the mosfets sometimes seem to stay on or only partially shut down.I've tried solving that unsuccessfully with some resistance to influcence the order of the mosfets shutting down etc, but it didn't work well either and I think it would have been fiddly.My latest idea (not yet tested) is to use some 4000 series NOR gates, 2 P Channels (S to S config) and one N per power source, the G of the P channels pulled up to a diode OR'd low current supply and the 4000 series gates driving the N channel gate high, pulling the P channel gates low when appropriate.But this is getting ridiculously complicated and only serves as a "dammit I'm sure I can make this work" thing, when one of the IC's in that thread can do the job for a buck.

author: Maxlor
author_rank: Frequent Contributor
timestamp: October 13, 2013, 10:46:12 pm
content: For a USB/battery-powered project at work we're using the TIbq24072. It does exactly what you seem to need: when a charger is connected, it charges the battery and powers the rest of the system from the charger, and if you disconnect the charger, it switches to the battery. This happens without interruption (or at least fast enough that the system doesn't seem to notice.)A similar chip is theMCP73871. The keyword with both isautonomous power source selection.They're both bigger devices than the one you mentioned, but they're not as complex as they seem at first glance; you probably don't need all their pins and can simply tie some to VDD or GND, and you'll save the hardware you'd otherwise need for switching between sources.