Friday 18 May 2012

Battery Power

One thing my son and I were interested in was powering a Raspberry Pi from batteries. At present we have no specific application for this, but obviously if it can be done it opens up a world of opportunities for a portable Pi!

To this end I popped into my local Maplin store on my way home and picked up a 4xAA Battery Box (Code HF29 - £1.29) and a PP3 Clip (Code HF28 - £1.19) to go with a micro USB cable I picked up at Poundland earlier in the week.

I snipped the USB plug (the big one, not the micro one!) from the end of the cable and stripped back some insulation. I then snipped the yellow and white wires off and connected the red and black wires to the same colours on the PP3 cable. This then clipped onto the battery box which by now was filled with batteries, ready to rock.

We connected up the Pi and it came to life! Booted OpenELEC and started a video playing, all without problems. Very pleased.

We might make a further trip back to Maplin this weekend to pick up a switch and some rechargeable batteries, I'll keep you posted!

EDIT: Tweeted about the above, and the Raspberry Pi people dropped me a tweet back to say "awesome - but be aware that if you push more than 5v through you may shorten the lifetime if the chip. 5v linear regulator FTW!" Hmmm... obviously this isn't quite as simple as I thought and a bit more work is required! In short, don't follow my instructions above for now, will update when I come up with a better solution.

11 comments:

poiuyterry said...

How long do the batteries last?

Anonymous said...

Post some photos of it :D
Solar charging of the batteries would be really awesome, with a portable screen and stuff

Player Dad said...

poiuyterry, I have no idea as we only had it on for a couple of minutes to test that it actually worked. Once I sort out the 5v linear regulator (see the edit above) I will do some more testing and report back.

Anonymous, I have an old PSOne LCD screen that I am very interested in getting hooked up to my Pi as a portable solution, so that's in the pipeline too!

Conrad Braam said...

A boost-buck regulator like a mintyboost should do the trick. hard to acquire if you are in the UK though. I do intend to copy you - ma having a helluva time finding a portable screen that will suite, I have all the other bits though.

Garry said...

Just drop in a 7805 with two capacitors, maybe a diode to ensure you don't reverse polarity and you should be good to go...

maroelawerner said...

A 7805 requires a minimum of 7V input to work properly and a diode in series would add another 0.7 to that. 4 cells in series will not get you there. A carefully worked out Zener diode and resistor combination would work.

Anonymous said...

I wonder if a low dropout regulator would be better than a 7805

Conrad Braam said...

Do not muck about, a boost-buck regulator is the trick.

Conrad Braam said...

Do not muck about, a boost-buck regulator is the trick.

Anonymous said...

If you use rechargeable (NiMH) batteries, you should be OK. NiMH AA batteries have a nominal voltage of 1.25V (see http://en.wikipedia.org/wiki/AA_battery), giving you 4*1.25=5V. With alkeline batteries, you have 4*1.5=6V.

Anonymous said...

Solution is to use monoprice part 9282. Output is 5v 1amp. 3000mAh. At least 7 hours of use on charge using USB keyboard and mouse.
@gainestr