Building a Battery Board for the Raspberry Pi – Battery Board V0
Two big features of the Raspberry Pi development board are its versatility (due to open hardware/software) and its compact size. I had read a couple of different project articles on the web on how to use a USB Wi-Fi adapter to convert the Pi into a wireless access point. As an access point the Pi is creating a mini wireless network that has data passed through from the ethernet port. Taking just the wireless network part of the code and using it a portable means of communication with other devices seemed like something that could useful in a number of projects. With a bit of tinkering I could use the Pi as a wireless Samba server and a wireless web cam. Adding battery to power the Pi you would have a portable Wi-Fi network you could take with you. Googleing around showed that a number of hackers out there were already had projects doing exactly this. Some example applications include: wireless still/video camera, wireless file servers (Pirate Box), remote control and wireless data collection. I didn’t have a CSI camera at the time but I could see a number of uses just with the camera alone such as: balloon cam payload, motion activated nature cam, and time lapse photography.
Of course the easiest solution for most would be to just buy a portable cell phone charger and plug it into the mini USB port. This solution is a little bulky but takes 0 development time. Looking at the footprint of the Raspberry Pi board I thought it should be possible to build a battery attachment that would be less than 1″ thick and power it for at least two hours. With a little creative packaging it would look cool too.
Most of the powered components for the Pi were designed to be used in portable electronics. More than likely the power for these devices would be from a 3.7V li-ion battery. To power the Pi with a li-ion battery, a circuit would be needed to step the voltage up to the 5V. The battery would also need a special circuit to charge it.
Getting The Parts Together
Thanks the powers of mass production and the ever growing smart phone market most of the components necessary to build a useful battery board for the Pi are available through ebay. The three main components I needed to build my battery board were a inexpensive battery, a charging circuit, and a boost converter to convert the 3.7V to 5V. Note, whenever building something powered by a li-ion battery you have to be sure there is a circuit that has a cut-off for over voltage and under voltage limits on the battery. Since most cell phone batteries have these built into the pack I didn’t have to buy a separate one – though I do have a few in my junk box from previous projects.
It took a bit of web research to figure out what battery I wanted to use. There is a huge after-market for cell phone batteries and buying a good one can be a bit of a craps shoot. Also, though most postings for li-ion phone batteries will show a rated voltage and claimed capacity very few show the physical dimensions of what they are selling. I decided to take a chance and buy an aftermarket battery built for the Samsung Galaxy S3. The Galaxy S3 is very popular phone that has been out for a while, I figured the cost/performance for the battery should be fairly good. The no-name battery I purchased out of Hong Kong ran about $4 US. The label claim 2300mAh but I later found it to be more like 1600 mAh.
Next I needed a boost converter to take the 3.7V from the battery and step it up to provide 5V with at least 700mA of current output. Suprisingly, doing a ebay search for boost converter will yield several options for a tiny circuit board to convert from a lower voltage up to 5V. I wanted a minimum of ! A output for less than $5 delivered. I ordered two boards, one rated at 1A and one rated at 3A. The 3A unit was a bit over $5. The small 1A unit was roughly 3/4″ x 3/4″.
The charger unit was harder to find than the boost circuit. I found a couple of options on the Sparkfun and Adafruit websites but not too much on ebay short of some AC wall-plug chargers. I did notice that the simplest chargers available on Sparkfun and Adafruit used the MCP73831 IC to control the charge. I considered buying a MCP73831 and building up the circuit myself since it only required a few components but when you add in shipping costs and probably a breakout board to make the tiny IC connections it was more than I wanted to spend on a quick and dirty prototype. I went back to ebay and did a search under MCP73831 and found a little charger board for just under $8 delivered.
For more detail: Building a Battery Board for the Raspberry Pi – Battery Board V0