I am designing a device which has an integrated Li-Ion battery (single cell, for simple low power portable digital device) and normally charges by way of a buck converter which goes from 12-16V Automotive supply to 5V, then into the single cell linear battery charger. If in the event the battery goes 'flat' and is not desirable to wait and rely on automotive input (inconsistent supply) or during user interaction by for example diagnostics/testing/data logging I need to also power the battery charger IC via the same power bus.
When the buck converter operates, it is intending to charge at up to 1-1.2A if possible during the short times it has energy available. In the normal use case of this device, the buck converter is the primary input to the Li-Ion charger. I will therefore make the standard case for the charge current setting of my charger IC to be 1.2A.
In the case when the USB is connected, it is assumed the device has been removed from the automotive input, but just in case I will have the USB activate the "Shutdown" Pin on my Buck converter IC. The only remaining issue (as far as I can see) is the charger IC attempting to draw 1.2A to charge the battery, from a USB port on a standard computer!
I have come up with a way to have a "normally ON" N-channel MOSFET based switch for a resistor to be in parallel to give me the required R_PROG value for ~1.2A. When USB is plugged in, the buck converter is disabled and the switch which parallels the two resistors is turned "OFF", leaving only the high value resistor and therefore the low (200mA) charge current for safe use with a PC or laptop.
I have attached a picture showing my plan below, which uses a MOSFET, NPN transistor, and 3 resistors to implement my plan. Note the blocking schottky diode D1 for the USB bus to the battery charger input node, that is there for protecting the USB power bus if the buck converter is in operation but the USB bus is not powered/floating, and to make sure the NPN transistor does not then also turn off the MOSFET.
The question is: Is there an easier way that uses less components than my intended N-MOS + NPN + 3 resistors to achieve a context sensitive resistance value for the charger IC, where the resistance is normally low, and when a certain input is connected, the resistance goes higher? This must be done in hardware, for a fast response. Slow responses may attempt to draw too much current for too long.
I am not actually sure if the charger IC can deal with an adjustable resistance like this on its PROG pin, as it may just sample the resistor initially and lock in the charge current setting until power-off. Any thoughts on that part too? The charger is MCP73113/4. Thanks for any insights guys/girls!