# Dual power sources (PV cell and battery)

I have a small IoT project with a 280 mAh Li-ion battery. My intention is to plug in the device and charge the battery when it dies, but I wanted to extend the battery life and have been thinking about adding a small PV cell since the device will be exposed to sunlight frequently.

In most circumstances, the battery will be able to output more mA at the system bus voltage (4V) than the PV cell, but I want to increase total system runtime. Is it possible to use the PV cell and the battery at the same time to power the system bus? If the battery is doing less, that's still a win (even if it's not charging).

• It could work, but there are a lot of details involved. You have to make sure to avoid any conditions (including simple fault conditions) which might cause the battery to be charged uncontrollably. But it could definitely work with some attention to detail. Commented Feb 18, 2020 at 2:41

There should be no problem doing this provided that the battery is never charged above Vmax - typically 4.2V/cell.

Assuming that battery is a single LiIon cell then a safe method is to provide the PV input via a diode and to clamp the PV voltage (not the battery voltage) such that Vbattery can never be charged above say 4.0V.

Clamping the battery at 4.0V is unsafe if the external charge ever takes it above that voltage. Clamping the PV voltage with diode separation means that if the battery is above 4.0V it will not be PV charged initially.

To clamp the PV such that Vbattery can never exceed 4.2V - and so that it typically stops charging at 4.0V, then you either need to properly allow for diode drop at low current or provide a simple opamp based circuit that allows sharp detection of voltage.

One method would be to use a TL431 voltage reference with the ref voltage detect pin driven from the battery, but the TL431 used to clamp the PV panel. At low enough currents the TL431 can sink current directly,. With a higher current PV you may need to add a pass transistor.

TL431 datasheet

R1 R2 set PV clamp voltage
Clamp charging when Vbat reaches say 4.0V for single LiIon cell.

A disadvantage is that R2 + R1 provide a constant drain on the battery. They can be sized such that the current is insignificant or, if desired, a high side transistor on the divider can be turned on only when the PV panel is producing significant voltage.

simulate this circuit – Schematic created using CircuitLab