A week ago I decided to make an uninterruptible power supply for RPI3. In case when the external power supply fails, Raspberry UPS must provide proper shutdown of RPI3.
As a power source I use two types of batteries - a lithium LSH20 and a lithium polymer battery for which a charge circuit is provided. They can be used together or separately (to choose from). The advantage of the lithium battery is a wide temperature range.
I chose a Atmega328p microcontroller as a control unit and as a result - device is completely Arduino compatible.
Raspberry and Raspberry UPS will be communication through the USB B socket (VCP) and I will try to implement a NUT protocol
Picture below expalins how this UPS have to connect to RPI3: