Backup power supply

Mar 13, 2024 Last reply: 2 years ago 53 Replies

Re: Backup power supply By: Andriy D to All on Wed Mar 13 2024 01:18 pm

Any inexpensive backup power unit from a recognized brand will do. There is no need to overthinkig it if you don't want to. The cool thing of an Uninterrupted Power Supply from a recognized manufacturer is you can get one the RPi can talk to over USB (or whatever), so the RPi will be aware of the stat of the battery and shutdown if it gets dangerously low.

Production servers hooked to complex power systems are able to send you an email to your smartphone if power goes out, or if battery gets dangerously low etc. because of this reason.

Building one yourself? I have never done it but it looks quite doable. Keep in mind that starting an electrical fire or spilling the contents of your homemade battery on your carpet sucks. I'd use a self-made unit for the fun of it in a safe environment but I would not leave it running 24/7 so happily.

Hello Andriy!

Wednesday March 13 2024 13:18, you wrote to All:

There are some battery powered sub systems/ card available but you are limited by the capacity of them which is not that great. For all important computer systems I use APC smart UPS's connect to a large adaptor block that hold around

9 sockets with the APC unit being 1000Va. I did have a 2k2 VA but the batteries along with the main board failed and APC do not have spares so switch since then to 1000va units for my and my wife's requirements. The batteries last around 5 - years before replacement and I have found 3rd party sources for the batteries for around 30 pounds instead of the 100 or so for the same thing but with APC branding. It takes less than 5 minutes to swap over and you can keep the UPS running while doing it.

Note that printers are not connected the the UPS but router and primary hubs are. I did for a while also have a Pi3B+ (plus Hard drive) also connected to it when running 24/7 but switched the jobs over to my main system and discontinued the Pi despite late last year buying at great effort a Pi4B 8Gb,

240 Gb SSD all in a Argon 40 case to act as a back up but never used it - must remember to sell in on Ebay.

Vincent

Hi,



I'm considering adding some backup power supply for my RPi2 mainly to avoid filesystem issues which may be caused by a short power outage. There are some interesting schematics online as well as some quite cheap 'manufactured' options. But I'm wondering, maybe someone has some experience / feedback to share?



Cheers,



\aID


No answers - but it's something I've been wondering about off and on (albeit for a Pi4). All the commercial stuff I've seen much exceeds the base Pi in either £££ or W (or both).

Any offers out there? Even something with a stack of AA non-rechargeables would be fine.

There are tons of different '5v usb ups' options on Aliexpress :) But if you've ever dealt with them, you know the quality ...

I'm inclining towards DIY as I've found quite developed schematics online - with a charge control, signaling loop to RPi, auto-restart, etc. But wanted to check what others did, before diving into 'PCB ordering and resistors procurement' deeps :)

And what's the standby current of such a UPS?

For one Pi a 5 volt regulator connected to a battery that's held on a float charger is probably the cheapest, though I think the combo will cost more than any Pi. The efficiency of such a setup is poor, but for one Pi it's probably better than a more elaborate scheme. Also, there is no need for line detection logic, which can be tricky.

For my part I settled on a small inverter/charger connected to a 12 volt battery. It's even more expensive, but has extra capacity to run all of my computer and network equipment. Cost at the time was about $600, more than half of it the lithium iron phosphate battery. A bit cheaper now.

Rated output is 800 W 120 VAC 60 Hz. The battery can deliver about half that power for about an hour, or run my equipment overnight. Standby loss is about 10 watts.

HTH,

bob prohaska

You mean full blown AC UPS, like APC used to do? Or do you know some well-known brands producing USB UPS?

This is exactly my concern - I want this think up&running 24/7/365 and I don't want it to burn my house down :) I guess this is where you'd say 'risk' and 'price' are in a inverse relationship ;)

Hello Mike!

Wednesday March 13 2024 18:47, you wrote to me:

Standby ?

Assuming it is fully charged which would be normal (assuming no outage in the preceding 2 - 3 hours 95% or better.

Otherwise do you mean the estimated run time if so then system under power in watts per hour under the rated size - 25% so lets say :

750 w

---- = 150 = long time :)

5 w

Also e.g., my desktop / server system with an estimated consumption of 250w (and it is lower as using modular PSU, 85% eff or better ) would be around 3 hours but that assumes there is nothing else under load and there is such as:: Router Baby Hub Monitor ( but only when I am using it ) Telephone systems including VOIP adaptor Residual loading - not known as no means to test it.

Total time with a 25% battery remaining around 90 minutes allowing for 7 minutes to shut down and battery remaining of around 22-23 % approx.

If I am present when power goes I can shutdown the monitor and let it does its thing if battery drops to predetermined amount of 25%. That said during the cold months (UK wise) and I am around I will manually shutdown after 15 minutes and transfer the UPS o/p to the C.H. and turn it on in which case over 24 hours runtime, but so far has never got any where near it before power is restored. My old house in a village power outs could be longer and hence the reason for 2 x 2.2Kva UPS's. ( Also smart models ).

Gave me enough time to power up my ex-mil generator if needed but it was a petrol model so did go through it - petrol I mean so had to keep a few jerry cans filled with fresh fuel as a JIC.

Vincent

It is entirely possible to trickle charge a lithium cell at uber low risk, Essentially you want to current limit the supply at at one tenth of the hourly capacity so e,g a 2200mAh celll would need to be charged at no more than 220mA, and voltage limit the charge at 4.2V.

That will give you a cell which, off charge in UPS mode will slowly decay to an end point of around 3.5V. You will need a step up converter to deliver a sane 5V to the pi and some way to power it all down in case of battery going too low.

That's probably a case for a Pi Pico. Or buy a unit that's already done it all :-)

Majority of the schemes I've found so far suggest use of NiMH cells as they are less 'combustive'. However cheap AliExpress devices do use Li-ion cells. Confusing :)

I'm using a cheap APC, I believe 650 or 750, with USB monitoring hookup. Also have my router connected (with VOIP) to keep communication possible for a little while (runtime abt 30 minutes). Battery replaced once, I believe it was some 7 years old.

Somehow that makes no sense to me..... current 650 is £227 (maybe plus VAT) on the APC website. 5 times the cost of the Pi. I'm sure it's a very nice UPS, but.... ???

Sense or not, it seems to be a fact of life. The inverter/charger/transfer units I used have vanished from Amazon, replace by units with four times the power and double the price. Battery prices seem to have dropped very slightly, but are still a whisker over $200/kWH.

A 12 volt to 5 volt stepdown converter appears to be less than $10, small 12 volt batteries range from $20-100 in the few AH range, a 12 volt 5 amp charger ranges from $11 to $50. The charger would be the iffy part, since a smart charger on a loaded battery is apt to get confused by what looks like high self-discharge..

Something reliable for less than $100 will take both luck and ingenuity. One possibility is finding a used UPS unit in e-waste and replacing the battery.

bob prohaska

Indeed, but if the power requirements are low (a Pi Zero without any power-hungry USB/HDMI connections) then supercaps might be an easier option. Since then you don't need to worry about over-charging, which will still wear out NiMH, even if it doesn't then burn your house down.

Here's one project that came up in a quick search:

formatting link

Confusing? Not at all, those Chinese sellers know you're not going to be able to sue them if their junk burns your house down. If you buy a mains powered device from them I think you're lucky if the secondary doesn't short right through to the mains and kill you when you touch it - it's happened before with phone chargers. It was recently in the news here in Aus that Li-Ion batteries had caused over 1,000 fires in the past year. I'm highly suspicious even of cheap locally-distributed Li-Ion products and wouldn't consider buying one from an unaccountable AliExpress seller unless I was prepared to sit near it the whole time it charges on a fire-proof surface.

Perhaps what's confusing are the words "trickle charge." You don't "trickle charge" LiIon cells in the sense that most people think of trickle charging. A charger limited to 220 ma at 4.2 volts max is a constant voltage current limited charger, more commonly called a "float charger."

Forget "trickle charger" and just pay attention to the description NP gave of its electrical characteristics.

Hello Ahem!

Friday March 15 2024 10:51, you wrote to me:

The time specified in my post was based on ACTUAL power on time using battery only.

No I will admit it is also based on some other kit being turned off / shutdown if needed such as the monitor (keyboard / mouse are battery powered). Hub is very low, router low with no secondary kit being connected to the UPS such as printers as not required for normal operation. The primary system uses a modular PSU and secondary DASD are stopped if not use after 2 minutes - they are rarely used other than back ups and secondary systems / O/S, etc.

Likewise on receipt of a power cut and after a predefined number of minutes not needed applications are shut down although there is no many.

Average time before the system will shutdown is 75 - 90 minutes on a 1000Kva UPS and with a newish battery. The UPS is connected directly to supply so is always being under charge or at least being topped up if needed.

Real live cycle of the UPS battery depends totally on the number of times the UPS is used when the mains power goes down and since moving from a village to town property, power cuts are rare and normally short.

I do not have a way of working out exactly the power requirements are of the main system although I can look at the loading of the UPS via a direct web location going by memory as it has been years since I tried it and that assumes it was the APC model I currently use as I down sized our UPS's after down sizing our home when the mobo's failed on the 2200Kva units. The cost of the current kit, new, was around 300 each and they have had a least one change of batteries each.

Not all computer around the house has them such as the media recording system (using MythTV under Ubuntu) does not.

One powered kit in the village was the C.H. (Gas boiler and controls) but now just use an extension lead to connect it if needed and only in the cold winter period, I seem to recall, maybe once.

Vincent

I had this thought as well, as all I need is to have enough power to cover for a few seconds of a power outage or gracefully shutdown RPi if it's longer than that. Thanks for that link!

I think he means what's the vampire load of just keeping a UPS warm :-)

Join the Discussion

Have something to add? Share your thoughts — no account required.

Didn't find your answer?

Ask the community — no account required