Powerbank/UPS for power dips

Hi, been using VF2 alot and left it once at night compiling stuff. Woke up at morning and it was at boot password prompt (my system is encrypted on it). Lost alot of work (I compiled into tmpfs that night). Last log entries suggested it was just reset, or power was gone.

I immediately thought that a conventional powerbank can serve as a battery backup for possibility of such event. But here lies the trouble: most powerbanks you buy today do NOT provide constant power when you start or stop charging them, they RESET their output to 0v for a short period of time once you connect them to wall socket. I’ve got three, one is xiaomi, another is of shady chinese origin, and third is very ancient with replaceable 18650 cells. All behave the same way.

I post this as a new topic because my attempts to find powerbanks with UPS/passthrough features on sale all failed - they’re a typical deficit item targeted by RPi customers. Maybe amongst us here people who faced same problem and know the right brand and model?

P.S. I need a safe solution hence why I think about powerbank. Li-ion batteries are known for their reactivity, so I dont want to set fire with diy UPS.

Thank you.


I have TOMO powerbank which charges each of 18650 battery separately, so it can charge and provide power at the same time. One drawback - it is louder that normal powerbanks.


The easy way is to choose a “NAS UPS”.

How about adding a super capacitor to the 5v and ground pins on GPIO? I mean with your powerbank.


If this HAT wasn’t so expensive …

UPS output : 5.1V ±5% Max 6A = 36W should do


I’ll think about this but I dont want to do this because I power board through USB-C with USB-PD charger which might go to 12 volts.

The 5v gpio pin was regulated whether input was 12v or 5v, and the gpio pin also one of the VF2 power sources as documented, so I think putting a super capacitor there should help power the board during that 1 sec power down.

1 Like

Thank you! I found some interesting items, I’ll update topic once I will make progress.

I’m late but I wanted to mention https://lifepo4wered.com/lifepo4wered-pi+.html which I need to try on the VF2. LiFePO4 is a much better choice for a UPS than Li-Ion.


You’re not late! Well, it’s even in my reachability, so I’ll consider this as an option. Nice one.

crazy idea
if you have another device that’s always on with a battery maybe you can power it off that
for instance, I have a celeron tablet that idles at around 3-4 watts, it has a type-c port …


Crowdsupply’s page is actually readable.

1 Like

DISCLAIMER if you’re going to repeat my steps, you’re going to put your boards in fire, UNLESS you KNOW what are you doing! Author is NOT responsible for any of YOUR actions. This is just an advice or, more like, report of field adventures with devices holding enough power to set your home in fire. BE WARNED!

So here is my current temporary plan (so, dudes, don’t put this into production! This can kill your boards! meh, usual DISCLAIMER) of using only single powerbank:

  1. Connecting cheap powerbank (cheap ones never reach specs like “usb-c port for quick charging your equipment” to GPIO (how you would like to do this is up to you. I have USB-A to lots of P/N 2.54 connectors connected, for each domain: parallel each, to relatively thick wire tip)
  2. Connect GPIO power headers, prepare to connect powerbank to USB-A
  3. Connect your USB-C power as usual (btw does anyone know if USB-C here is only a “sink” type port?)
  4. Connect main power source. Boot your board.
  5. Connect USB-A end of GPIO to powerbank.

What I’ve got:

  1. During normal operation, without powerbank, the main power source (say, 15W USB-C charger) supplies voltage, say, 4.93V
  2. Connecting powerbank and measuring it with USB tester I see PB bumps voltage to 4.99V and starts to give partial energy (0.1A) but not so sufficient to actually make battery drain very quick and well above threshold if you worried that powerbank will self turnoff.
  3. Now, interesting part. Cutting power from main supply (the charger) goes almost unnoticed: load is dumped on still active PB and it goes straight into GPIO. PB just hooks up additional power. System keeps running without any dips, although it is observable that fan drops cycles abit. But stuff inside OS still working. SSD working. Good.
  4. Bringing main power back again causes two sources to “fight” for percentage to be served, main one wins and leaves secondary PB only these 100mA which are well enough to shut up his guts about even an idea of turning auto off.

No running rust build processes was harmed during testing (4 tests were carried, one within less than a second).

I know, sounds sketchy, dangerous (why shall you dual-power it?) and will not work for everyone. But it works for me right now with materials I’ve got at hand.

Now, limitations.
Device will NOT survive cuts of mains power if powerbank starts charging - these crafty things inside usually prefer to reset their output completely if such event raises. So that’s why I went with “low drain auxiliary battery”. Draining just half a watt out of it might not be efficient for internal circuitry of PB, but might save hours or days of compiling time (Imagine these big UPS and how they get disposed off after them idling 99.8% of their lifetime and only .2% surges draw from their Lead-Acid boxes, leading to their degradation). Once all lights off - go recharge it and run the second power input from your laptop for example.

I tried to solve this by stacking mains charged master powerbank charging slave powerbank LOL it worked (kinda). I still did not figured out what order and which one shall be on the second rail and which becomes a source of power and what timings of these process.

Some powerbanks even trashy - they crowbar the line in the event of reset and nobody cannot recover from this.

Hopefully this will be resolved by USB-C compilant powerbanks which will never disconnect their load as long as load commands them not to. But these are still high class items now.

1 Like

UPS have a switcher to stop the 0.1A output.
Your powerbank reset output is the switcher working.
But UPS’s switcher is fast, powerbank’s is slow.

I know, yeah, but perhaps for this application a full featured UPS is total energy disaster, as it will eat more idling and converting rather than a powerbank. And there are powerbanks which are capable of being as UPS, I just want to know exact models.

I think there shuld be “PoE UPS”. VF2 use this is needed a PoE Module.
UPS is not energy eater when it is on standby. Your solution is need keep the battery voltage higher than the changer.

I know. It’s not over, yet, and this is not a permanent solution. When I’ll build one working reliably, I’ll report back.