I have a system that uses an Arduino Uno board as a "brain". All the elements in the system are powered by a single Li-po battery (3-cell, 11.1 V, 1800 mAh).

I made a circuit so the Arduino can check the battery voltage and decide when it needs to recharge. I also have a circuit that controls the battery charge sequence and interrupts the power when the battery is charged, sending a signal to the Arduino interrupting its power saving mode. The Arduino enters the power saving mode when the charging sequence is initiated. The charging circuit uses 12 V and 450 mA which I plan to supply with a 12 V, 6 W solar panel.

My question is: can I charge the battery while the Arduino is still on, but in power saving mode?

If not, how can I make this system self-charging while keeping the Arduino on continuously?

3 Answers 3


can I charge the battery while the Arduino is still on, but in power saving mode?

You can draw power from a Li-ion battery whilst charging it, but it isn't recommended. This is because the load on the battery affects the ability to detect the different phases of charging, and determine the end-of-charge condition.

Instead you should provide a bypass facility so that if external power is applied the external power is routed to the Arduino to power it, but when the power is removed the battery provides the power to the Arduino.

The circuit I usually use is:


simulate this circuit – Schematic created using CircuitLab

When 5 V is applied the battery charges up. Q1 is held off. The 3.3 V regulator is then powered through D1. When the 5 V is removed Q1 is turned on by R1 pulling the gate low and the battery powers the 3.3 V regulator.


Application Note AN1149 by Microchip Inc:

It is NOT encouraged to attach the system load directly to Li-ion batteries when using a stand-alone Li-ion battery charge management controller with automatic termination feature.

enter image description here

Why not?

1. The charge may never end.

Most Li-ion battery chargers are based on Constant Current and Constant Voltage (CC-CV) modes. The termination is based on the ratio of charge current and preset constant current (Fast Charge). If the system draws current from the battery, the charge current will never meet the termination value. This causes the non-termination of the charge management circuit.

2. The total system current is limited by the charge current.

It is because the charger will deliver total system and battery charging current through the output pin. This solution may be feasible for some applications that run on constant current, but it is not recommended.

So what's the alternative?

A load-sharing switch with a P-MOSFET:

Plugged in

Q1 is OFF when the gate is high and no current flows from the battery cell to the system load


Q1 is ON when the gate is low and current flows from the battery cell to the system load.

The App Note contains some really good practical advice on component selection, I highly recommend reading it.


If you need to charge it and run at the same time, I would recommend getting a PowerBoost module from Adafruit. They can handle both, and they also have a low-battery indicator.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.