Battery Isolation with P Mosfet

I am designing a remote sensor that I want to use either battery power or switch to wall power when plugged in. I decided to use a Mosfet to isolate the battery when the device is on wall power as to limit losses from going through a diode.

It works properly with battery power only, however when I plug in wall power I am seeing 3.7VDC Between B1(+) and GND(with battery disconnected. I decided to measure the amperage with the battery connected and the battery is drawing over 780uA. Being a non rechargeable battery this obviously is no good. Please see the below schematic and maybe someone can tell me where I screwed the pooch.

Thank you in advance!!
Paul

I tried adding an image of the schematic but it does not seem to be working so I am adding the link to Imgur below.

pguerra75:
I am seeing 3.7VDC Between B1(+) and Q1(2).

Sure about that? That's a massive voltage drop for a direct connection

Sure about that? That's a massive voltage drop for a direct connection

My apologies, between B1(+) and GND. Thanks for catching that.

Alright.

About that "charging" current: There is a parasitic body diode inside every MosFET (it's visible in your schematic). I'm guessing that's the path your unwanted 780µA take.

What kind of battery are you using?

The good thing about MOSFETs is they can flow current in either direction. You can just flip it around to point the body diode the other way.

So long as the battery voltage is not more than the diode's forward voltage (0.6-1.2V) greater than the wall power, this will do what you want. If it is greater, then some current will flow from the battery while the wall power is connected.

About that “charging” current: There is a parasitic body diode inside every MosFET (it’s visible in your schematic). I’m guessing that’s the path your unwanted 780µA take.

Thank you, I am going to try MorganS’s idea, hopefully this will do the trick.

What kind of battery are you using?

Lithium Primary, 3.6VDC/19aH.

So long as the battery voltage is not more than the diode’s forward voltage (0.6-1.2V) greater than the wall power, this will do what you want. If it is greater, then some current will flow from the battery while the wall power is connected.

The battery is 3.6 VDC nominal and the wall power is 5VDC so this should work, I will try and let you know, that you.

Why not use socket with a switch in it to isolate the batter when the PSU is plugged in....

Or use two schottky diodes between the battery and the PSU to the load - the higher voltage from the psu will turn the battery current off.

Allan

Why not use socket with a switch in it to isolate the batter when the PSU is plugged in....

Normally I would, however space and weatherproofing requirements make that unfeasible.

Or use two schottky diodes between the battery and the PSU to the load - the higher voltage from the psu will turn the battery current off.

I am trying to avoid the voltage drop and power loss cause by the use of a diode on the battery power circuit.

All valid ideas though.

Hi,

Your Mosfet is a P-Channel device. This type of device turns "ON" when the gate is negative "with respect to" (wrt) the source. I can't see how reversing the Mosfet is going to work. With a positive voltage wrt the source will only turn the Mosfet off more (actually do nothing).

I believe your 780µA is the current draw from the 5V supply through 2 diode drops (the Mosfet and D1) to the battery. If you removed the battery and put your ammeter from the B1+ to ground you would measure the current limit of the 5V regulator.

Put another way, if your battery was low (say 3.5 V) you would draw much more than the 780µa you are seeing now.

Looking at your circuit I don't see an obvious solution that would not draw any current from the battery when the wall power is on. I guess you could use a small relay powered by the wall supply.

Looking at your circuit I don't see an obvious solution that would not draw any current from the battery when the wall power is on. I guess you could use a small relay powered by the wall supply.

I see exactly what your talking about, thank you for taking the time to answer. Looks like I may just need to start barking up a different tree.

If the MOSFET is a common TO-220 case, then it's probably got the gate on the middle pin. You can just turn it around and solder it the other way. Check the datasheet first.

The way you've got it is the usual direction used for reverse-voltage protection. If the battery is hooked up backwards, then the gate is positive with respect to the source and the MOSFET is OFF. Additionally, the body diode doesn't conduct.

In that mode, the normal battery connection is "backwards" to the textbook description that John quoted. Before the battery is connected, source, gate and drain are all at the same potential and it's OFF. The Source is actually the pin connected to the circuit. When you plug in the battery, the Drain immediately goes up to the battery voltage but the MOSFET is still OFF because the gate is not more negative than the source. However the body diode always conducts, which brings the source up and allows the MOSFET to actually turn ON. This shorts out the diode so you don't have the diode drop wasting power in normal operation.

I doubt supply>battery takeover will work smoothly with that circuit.
The mosfet is not turned on until VCC drops below (Vbatt - Vgs(th) - BAV70 drop).
That could be 1.5volt.
Are you sure the Arduino is fine with that.

Maybe better to detect if voltage across the regulator drops below the dropout voltage of the regulator (~0.5volt) with e.g. an opto coupler.
That should give you an early warning.

Just brainstorming here. have not tried or drawn anything.
Opto LED (with CL resistor) across the regulator, anode to Vin, cathode to Vout.
(assuming Vin is at least 2volt above Vout of the regulator).

Opto transistor between source and gate of a p-channel fet.
High value (>=1Megohm?) pull down resistor from gate to ground
Fet source to +batt and drain to 5volt rail. No diodes.
The regulator should be ok with ~4volt on it's output all the time.

Only problem could be that the pull down resistor on the gate draws some battery current (~4uA).
That could be compensated with a resistor across source/drain of the mosfet.

Leaving it to OP to draw, so it can be checked.
Leo..

Lithium Primary, 3.6VDC/19aH.

Since your battery is so large it would take ~3 years at 780uA to flatten it.

I bet it's self-discharge rate is higher than that.

And schottkys only drop about 0.3V - can't you handle that?

Why worry?

Allan

You could alternatively just add a second diode in series with D1 to bring the voltages in line with
each other.

allanhurst:
Since your battery is so large it would take ~3 years at 780uA to flatten it.

I bet it's self-discharge rate is higher than that.

And schottkys only drop about 0.3V - can't you handle that?

Why worry?

Allan

You have mis-interpreted the direction of the current flow. The circuit is "charging" a non-rechargeable battery.

I'm beginning to think the Shottkey might be the easiest solution. I had not considered the "unplug the power" event as being important for this design.

allanhurst:
Since your battery is so large it would take ~3 years at 780uA to flatten it.

I bet it's self-discharge rate is higher than that.

And schottkys only drop about 0.3V - can't you handle that?

Why worry?

Allan

Its being charged, not discharged, and its a primary cell so that's bad news.