Authors: Michel and Gernot
The following DIY manual describes an easy-to-implement battery backup module for the BeagleBone Black. This can be useful in certain applications, such as out-door usage where constant power is not present and it is not desirable to just drop power on the BBB board. It was built for a RasPBX setup with the motivation to have a safely powered BBB in all situations. The BBB is unfortunately suceptible to slowly rising supply voltage when powered on. Therefore it didn’t sometimes boot at all, which can be a serious problem after a power glitch. On top, voltage irregularities can cause the device to crash as well.
The battery backup can be applied to any BBB installation, running RasPBX, the original Anstrom Linux or any other distribution. However, USB devices cannot be used while running on battery, as the UPS does not power the USB host port. Take care that some distributions will automatically shutdown a battery connected BeagleBone Black within 60 seconds when power outage occurs. It might be the case with both Angström and Debian distributions available here. When running a standalone system 24/24, use instead the console version of the distribution. Debian console version works fine and is available here
The 1950 mAh Li-Ion battery used in this example keeps the board powered for more then 6 hours when running idle most of the time. It is currently in stock for around 36 Euros at Farnell.
The instructions are based on Shabaz’ work documented on Element 14, and have been slightly modified with a different circuitry and used battery type.
WARNING: The modifications presented here can destroy your BBB when not done carefully! The authors of this article are not responsible for any hardware defects that might occur when implementing these modifications. BeagleBone Black power supply MUST be removed before working on it
Another BeagleBone UPS with more simple components is described further down in this topic. In this other small projet 2 leads battery is used instead of 3 leads battery. A Bill of Material is also available. After checking this main tutorial, it is perhaps interesting to have a look at this other small tutorial
- Solder wire
- Side cutter
- Soldering iron
- Wire stripper
- Metal file
- Nail file
Bill of Material
1200 mAh (Panasonic CGA-633450)—-> not anymore sold by Farnell
- 1950 mAh (Panasonic CGA-103450)
The small prototyping board has been built with a saw and a metal file. All components are generally available in local electronic stores (not the Li-ion battery). The multi-stranded wires were taken from an old defective PC power supply.
This is a part of the Texas Instruments TPS65217C block diagram. A bridge between BAT and BAT_SENSE must be soldered on the BBB board.
The used Adafruit enclosure needs to be modified as shown. Cut off acrylic sheets of
this particular enclosure at the sides. To protect the acrylic sheets during the job, leave the brown adhesive paper on. The red hatched parts need to be removed.
If the enclosure and the BBB are already mounted, it is safe to disassemble them and prepare the enclosure sides as described (see red marks).
This shows the modified enclosure and the BBB reassembled without top cover.
Throughout this DIY tutorial, a crimp housing is shown on most pictures. It connects the small electronic board to the BeagleBone Black. Nevertheless crimp sockets need a good crimp tool to be correctly fastened on each wire. A good crimp tool is expensive. To build a suitable connector, a cheaper solution exists.
Small “2×2 way” connectors are rarely sold in electronic shops (I mean tiny connectors matching the small place available on the BeagleBone Black). But expansion connectors similar to those on the BeagleBone can often be found in these shops. That kind of connector may be cut, with a small saw, to build a “2×2 way” connector. Stranded wires can than be soldered on connector pins. The above picture shows different steps to achieve this task. A wood toothpick or better a bamboo knot pick with some glue at one end is a convenient polarising key. A metal file can help getting the right bamboo pick size if it is too large to fit in the connector.
ADVICE: Socket pins easily fit in BBB TP5, TP7, TP8 holes and header pins not.
Unhappily header pins will need to be slightly modified to fit in these holes…with a nail file. I discourage soldering the small black socket onto BBB board and mating header onto stranded wires. If this method is used, the header, powered by battery voltage, could inadvertently touch components on the BBB board and destroy them. The small black socket is at least isolated. It is safer to connect it to the coloured stranded wires.
Tinkerers, who anyway want to use Harwin crimp housing shown in the following picture and preferably already own the right crimp tool, have to purchase Harwin M20-003 polarising key and Harwin crimp socket M20-1180042. In this case use 22AWG wire. 20AWG wire won’t fit in crimp socket. By the way, Harwin crimp tool M20 series Z20-320 costs 312,85 EUR. The whole black connector seen on the upper left corner of the previous picture costs less than 1,00 EUR !
Before soldering components, verify that no tiny copper parts may fall from the small board onto the BBB when installed (possible damage!!). If necessary, use the metal file to carefully remove copper parts that the saw didn’t correctly cut. Clean the board when done.
The components (connector, capacitor, resistor and coloured leads) must be placed along the copper strips parallel to the coloured lines as shown. Also have a look at the solder side further down.
CAUTION: Set the shrouded header in the same position as the picture displays it. When battery connector is plugged into the JST shrouded header, the coloured leads must match the coloured strips as shown. Incorrect header positioning will damage your BBB! The electrolytic capacitor is polarised. Its negative pole needs to be connected to the “GND” copper strip. The shortest lead connected to the capacitor body is the negative pole. Take a look at one of the previous pictures to avoid wrong insertion. Watch the small minus sign on the capacitor side to clearly identify it’s negative pole. Magnify the picture if necessary.
When the small board is built, its leads have to be connected to BeagleBone Black board with a header and matching connector. This latest was built in one of the previous steps.
Unhappily, headers from electronic stores have too large pin size to fit in BeagleBone TP5, TP7 and TP8 holes. Therefore a nail file is used to carefully file away pin edges before inserting the header. It’s easier to keep the four pins on the black header housing when doing this job. In this case two pin edges may be filed away at the same time with correct filing angle. All other edges need to be filed away one by one. From time to time during this job, it can be proceeded to insertion test in BBB holes. When done, remove one header pin, bend it and resize it to suit distance between two holes. It will build the bridge between BAT and BAT_SENSE described on the block diagram. These parts are then inserted in Beaglebone holes as shown on above picture (Header pins in TP5,TP7, TP8 holes and bended pin inserted in TP6 building the bridge with TP5 !) .
IMPORTANT: DO NOT TRY TO DRILL LARGER HOLES. This will damage the BBB because it is built with a multi layer PCB. Existing metal coating, within the holes, builds electrical conductive connections between different layers and may not be removed by drilling larger holes.
Connect the battery to the shrouded header and place the small board between the enclosure sides and available notches. Place the battery cables into the cable notch.
Place the battery along the enclosure side, where temperature is lower than on top. The Lithium-ion battery fastened on that side will probably last longer.
Don’t place it inside the enclosure! Eventual battery leaks may damage the BBB.
DIN rail enclosure for BeagleBone Black UPS
DIN rail enclosures are frequently used in home and industrial cabinets. The BBB + DIY UPS + battery can be very easily integrated in this 4 modules enclosure. Following pictures are self explanatory. Nevertheless it is recommended to read the DIY tutorial prior to build BBB UPS board.
Warning: if a µSD card is used on the BBB, shutdown the BeagleBone, switch off its power supply and remove the µSD card before assembling the equipment. It can be mechanically damaged when opening or closing the enclosure.
A wall mounting hole is provided on the enclosure backplane.
This picture in picture is a reference to the main DIY tutorial. Building the UPS board is straightforward, though it is necessary to use a crimp tool for the “2+2 way” crimp housing. A cheaper solution will be used in the following steps because a good crimp tool is generally expensive.
The two small boards may not move in the sliding guides . Placing removable stickers gives good results (see picture). Removable acid-free “montage” glue may be used. Placing one small glue dot, between the top of the board and the sliding guide, is sufficient . The drawback is that removable “montage” glue have long drying time. Not to forget is the rubber band. It enables use of different battery thicknesses.
As mentioned above, crimp tools are expensive and correct “2×2 way” connectors are rarely sold in electronic shops (connectors matching the small place available on the BeagleBone Black). But expansion connectors similar to those on the BeagleBone can often be found in these shops. Using a small saw, a “2×2 way” connector can be easily built. Stranded wires can than be soldered on connector pins. Check the numerous pictures in this DIY to solder these wires at the correct connector position.
A wood toothpick or better a bamboo knot pick with some glue at one end is a convenient polarising key. A metal file can help getting the right bamboo pick size if it is too large to fit in the connector. Magnify the picture to precisely know where to stick it. Check also the following pictures to avoid any mistaken. Instant glue doesn’t allow wrong positioning.
Before plugging the connector on the BBB board, a 3 pins header needs to be soldered on the board. The bridge to solder on the BBB solder side is not to forget. The main DIY tutorial gives some tips to place this header. A nail file is used to achieve this task.
Suggestion: as dust may fall on enclosure top, protecting all three connector (µSD, HDMI, USB) from dust is highly recommended.
“Kaedra” modular mini-enclosure from Schneider Electric is IP65.