# Sensing current into a battery while charging

I want to sense the current into a 84 V battery while charging and disconnect it when fully charged using a MOSFET. Is it advisable to use lowside current sensing? I used a noninverting opamp configuration shown below but the MOSFET started smoking so I quickly turned it off.

Am I right in assuming that the power losses while the MOSFET is conducting is the voltage difference between the drain and source multiplied by the current flowing through it? The charging current is 5 A. Please help me out. The part of the circuit on the left of the MOSFET is for ensuring that the gate voltage is 12 V and the 16.8 ohm resistor represents the battery being charged. It is a lithium ion battery with its own BMS I just want to use a single charger to charge multiple batteries one at a time and disconnect each once full so I am using this circuit externally. Please assist me debug my circuit. Thanks.

• The IRFR120Z has a RDSon of 190 milliohms. At IDS of 5A, you will be dissipating 4.75W. With a Rth J-A of 110 C/W, your temperature rise is 523C so yes, you will need a bigger MOSFET. What is the battery chemistry? There are charging ICs for every type out there that will manage every part of the charge and throw in some fault protection too. Their datasheets will also help you select a suitable MOSFET.
– vir
Mar 7, 2022 at 18:46
• @vir pls help me understand why then the mosfet is rated at 150W and if it dissipates 150w will that not mean 150*110degrees ? Mar 8, 2022 at 8:36
• @vir it is a lithium ion battery with its own bms i just want to use a single charger to charge multiple batteries one at a time and disconnect each once full. Its just an external solution Mar 8, 2022 at 8:39
• With infinite water cooling at 25 degrees C, it may be able to dissipate 150 W for a short while. Do you have it water cooled to 25 degrees C? Mar 8, 2022 at 10:07
• ”16.8 ohm resistor represents the battery being charged” This makes no sense. Please draw a schematic of what you actually have. Mar 8, 2022 at 10:11

The switch must be rated for at least 5x your charge rate for reasonable cooling design. The case of your FET is Rja jcn to ambient rise of 110'C/W unless a heatsink is designed, so it would fry instantly.

I suggest you research thermal switch design.

You can sense battery current on high or low side by choosing a shunt R that drops no more than 50 mV at the maximum expected current using an amplifier designed for hi or lo side using P or N type inputs that determines the Vcm common mode range.

You must choose to measure charge and load current separately if you are charging during load. Otherwise a single sensor is only needed.

The switch transistor must have a RdsOn much smaller (<<10% ) than your current sense R which already is chosen to limit power dissipation ~ 1/4 W more or less.

There are many topologies used that also provide reverse voltage protection.

• Start with a block diagram with a range of V, A and design rules with functions.
• then look for pre-existing solutions and refine your design requirements before leaping to a solution that does not work.
• it is a lithium ion battery with its own bms i just want to use a single charger to charge multiple batteries one at a time and disconnect each once full. its an external solution Mar 8, 2022 at 8:40