Naturally, each of my Raspberry Pi computers is also protected in
the same manner. However, that
doesn’t really solve my problem
because my ultimate goal for at least
one of them is to install it in my
backyard shed (which also serves as
an outdoor kitchen and
smokehouse), so that I can monitor
and control the temperature of my
smoker from my cell phone. I don’t
want to buy yet another commercial
UPS because replacing all those 12V
gel cells every few years has become
an expensive proposition.
The UPS that we’re going to
construct this month should be able
to protect my Pi as well as a
commercial UPS at a fraction of the
cost. Of course, only time will tell for
sure, but my “smoker” Pi will also
monitor its backup batteries and
hopefully warn me of any impending
problem. I do realize that not many
Primer readers will also have a
backyard smoker that needs
controlling, but I’m sure you can find
your own idiosyncratic uses for a
simple battery-backed UPS for one of
your PICAXE-Pi projects, so let’s get
started!
Designing the
UPS Circuit
When I first began thinking
about a UPS for the Pi, I had two
major requirements in mind:
• It should provide 1A at 5V —
the same as a typical USB
power supply.
• It should be inexpensive and
simple to construct.
With those two requirements in
mind, I chose to use ordinary non-rechargeable alkaline batteries rather
than a rechargeable gel cell. The
resulting schematic is presented in
Figure 1, and several of its features
require a brief explanation.
Main Power Source
I used a switching 12V wall wart
power supply because I happened to
Construct a Battery-Backed UPS
for Your Pi
This month's installment
was prompted by a
recurring problem I have.
I happen to live in an area
that, for some reason, is
plagued by very brief but
frequent power outages.
Almost every day, the
power provided by the
local electrical utility drops
out for a fraction of a
second at least once, and
sometimes more often. As
a result, my computers,
monitors, and printers are
protected by several
commercial
uninterruptable power
supplies.
■ BY RON HACKETT PICAXE PRIMER
www.jrhackett.net
8 June 2014
■ FIGURE 1. UPS schematic.