Auto Load Switch TP4056

Auto Load Switch TP4056

For a big project I have a setup where I can charge a small lipo and feed other components with it at the same time. For this application is a TP4056 which can charge a lipo battery and switch off the battery if the battery has too low a voltage. In addition, I use an MT3608 used to boost the voltage of the battery to 5V, because the battery provides a voltage of 3.7V and the MT3608 indial for because it gives an output voltage between 5V-28V from an input voltage between 2V-24V.

After the setup was built, I noticed that the TP4056 always switched between charging and full with a full battery, as the red and blue light went on and off quickly. With no load on the output of the TP4056, the blue light remained on. For this a solution had to be found where the battery can be charged and at the same time the electrical circuit behind the battery and if the USB is removed that the battery starts to feed everything. In addition, when the USB is connected, the battery is disconnected from the electrical circuit.

Solution


The solution here I found on an Arduino forum. The circuit is pretty simple all it takes is a P-channel MOSFET, 10k resistor and a schottky diode. See image below for the schematic.


When the USB is unplugged, the pull-down resistor brings the gate of the MOSFET to 0V, turning on the MOSFET. The diode prevents the battery voltage from returning to the gate of the MOSFET, keeping the MOSFET on. The battery is extracted with minimal power loss.

When the USB is connected, the gate of the MOSFET is pulled above the battery voltage and turns off. The load is powered through the diode and the MOSFET prevents it from going directly into the battery. The charging module can charge the battery with the appropriate voltage from the controller as required, and the USB will supply both the charging current and the electrical circuit.

Optional

If you gonna use this setup for a Teensy there is really nice way to charge the battery and at the same time program the Teensy. The only thing you need to do is, cut the VUSB and VIN from each other and connect VUSB to IN+ on the TP4056 and IN- to ground on the Teensy. Then you connect the output of the MT3608 to the VIN of the Teensy. like this:


For more info: Click here