radeusgd
Posts: 7
Joined: Wed Apr 24, 2013 9:38 am
Location: Poland

Powering Pi with LM7805 (solved)

Wed Apr 24, 2013 9:41 am

Hello!
I'm looking for a cheap method to power RaspberryPi from batteries(accumulators or normal).
I already have lm7805 and I think I could use it.
But where should I connect the circuit? Do I have to use micro-USB cable or can I use GPIO?
I'm going to use ~9V batteries, will this be safe for the Pi?(of course I'll connect it to 5V 7805 output).
Greetings

User avatar
Burngate
Posts: 5977
Joined: Thu Sep 29, 2011 4:34 pm
Location: Berkshire UK Tralfamadore
Contact: Website

Re: Powering Pi with LM7805

Wed Apr 24, 2013 11:10 am

Yes you can. But ...

If you connect to the 5v and ground pins on the GPIO connector you will be bypassing the poly-fuse. Also there is the risk of connecting it the wrong way round. But it will work

Since the Pi uses about 3/4 A and the LM7805 is a linear regulator, the same current passes through the regulator from the 9v source
This means about 3W will be dissipated in the regulator - it will get hot without a heatsink. Also, if the 9v is coming from a battery, it will go flat that much faster.

Use a switching regulator

radeusgd
Posts: 7
Joined: Wed Apr 24, 2013 9:38 am
Location: Poland

Re: Powering Pi with LM7805

Wed Apr 24, 2013 11:23 am

Burngate wrote:Yes you can. But ...

If you connect to the 5v and ground pins on the GPIO connector you will be bypassing the poly-fuse. Also there is the risk of connecting it the wrong way round. But it will work

Since the Pi uses about 3/4 A and the LM7805 is a linear regulator, the same current passes through the regulator from the 9v source
This means about 3W will be dissipated in the regulator - it will get hot without a heatsink. Also, if the 9v is coming from a battery, it will go flat that much faster.

Use a switching regulator
Thank you for the answer.
Is something like this LT1073 going to work?
And also when I'm bypassing this fuse, would it help if I attach my own to the circuit? Or is it better to cut an USB cable and solder circuit to it?

User avatar
mahjongg
Forum Moderator
Forum Moderator
Posts: 12131
Joined: Sun Mar 11, 2012 12:19 am
Location: South Holland, The Netherlands

Re: Powering Pi with LM7805

Wed Apr 24, 2013 12:43 pm

Yes, you could build your own switcher, but why not simply buy a cigar plug to USB port adapter. Used to power your USB device (like a iPod) from the cigar lighter of a car. These often can be bought for less than $5, and already contain such a switcher, plus they have an USB output port so you can directly plug in a standard USB to micro-USB cable, no fussing around with other power entry problems which bypass the polyfuse. By the way, a normal fuse would have too much resistance to be used, or they would have such a high current rating that they would make no sense to use.
the adapter is often easy to disassemble, try unscrewing the top. After that you are left with a board, and wires running to the top contact, which is the + input, and side blades, which is GND (the - input).

PS1981
Posts: 445
Joined: Wed Dec 12, 2012 4:11 pm

Re: Powering Pi with LM7805

Wed Apr 24, 2013 12:47 pm

Or check out this currently hot discussion on the topic:

http://www.raspberrypi.org/phpBB3/viewt ... 37&t=41054

radeusgd
Posts: 7
Joined: Wed Apr 24, 2013 9:38 am
Location: Poland

Re: Powering Pi with LM7805

Wed Apr 24, 2013 12:50 pm

mahjongg wrote:Yes, you could build your own switcher, but why not simply buy a cigar plug to USB port adapter. Used to power your USB device (like a iPod) from the cigar lighter of a car. These often can be bought for less than $5, and already contain such a switcher, plus they have an USB output port so you can directly plug in a standard USB to micro-USB cable, no fussing around with other power entry problems which bypass the polyfuse. By the way, a normal fuse would have too much resistance to be used, or they would have such a high current rating that they would make no sense to use.
the adapter is often easy to disassemble, try unscrewing the top. After that you are left with a board, and wires running to the top contact, which is the + input, and side blades, which is GND (the - input).
Oh, thank you very much.
I didn't think of that.
I have a car PSP charger which I don't use anyway so I could use it.
Is it possible to use it without disassembling though? Because I'm not too good with it and I'm afraid I could break something.
Maybe I could use some adapter.

User avatar
mahjongg
Forum Moderator
Forum Moderator
Posts: 12131
Joined: Sun Mar 11, 2012 12:19 am
Location: South Holland, The Netherlands

Re: Powering Pi with LM7805

Wed Apr 24, 2013 3:38 pm

Most often the contacts are chromed, and thus impossible to solder to. But maybe with some crocodile clips you could improvise a bit. It isn't too hard to open most of them though. Sometimes they have a kind of nut around the tip (front contact) and if you unscrew that the plug falls apart.
I have opened several (so see what IC was used inside, most often the venerable Motorola simple switcher IC, MC34063), and it was never very difficult, except when the parts were glued together and then I simply used a hammer. :lol:

User avatar
Defiant
Posts: 179
Joined: Tue Oct 30, 2012 6:17 pm
Location: Hamburg, Germany

Re: Powering Pi with LM7805

Fri Apr 26, 2013 6:48 am

I use a LM2576, it works fine.

radeusgd
Posts: 7
Joined: Wed Apr 24, 2013 9:38 am
Location: Poland

Re: Powering Pi with LM7805

Sun Apr 28, 2013 2:49 pm

I used a charger from PSP and it gave 5.5V form 9V battery.
When I plugged it to Pi there was power but ethernet couldn't start. (Probably same as USB etc. didn't check though).
And battery's voltage came down from 9.6V to 8.5V and the regulator stopped working(too little voltage).
So it consumed most of the battery pretty fast and also didn't properly boot up Pi.
What can I do for it to work better (more efficiently)?
Why Pi couldn't boot completely? (Too little current?)
And what can I do so it can work when battery has only 8V?

User avatar
rurwin
Forum Moderator
Forum Moderator
Posts: 4258
Joined: Mon Jan 09, 2012 3:16 pm
Contact: Website

Re: Powering Pi with LM7805

Sun Apr 28, 2013 3:10 pm

Batteries are more complex than we think: Datasheet. After the first little bit, most of the power is produced with the voltage well below 9V.

Even if you managed to get the maximum power out of the battery, it still wouldn't last more than a couple of hours on a PP3.

gordon77
Posts: 4123
Joined: Sun Aug 05, 2012 3:12 pm

Re: Powering Pi with LM7805

Sun Apr 28, 2013 6:05 pm

and interesting the datasheet says maxm discharge is only 120mA, not much use for a Pi.

radeusgd
Posts: 7
Joined: Wed Apr 24, 2013 9:38 am
Location: Poland

Re: Powering Pi with LM7805

Sun Apr 28, 2013 6:30 pm

gordon77 wrote:and interesting the datasheet says maxm discharge is only 120mA, not much use for a Pi.
That's probably why it couldn't use Ethernet. And could only slowly boot some initial stages from memory card.
Also I'll try this rechargeable batteries http://data.energizer.com/PDFs/nh15-2500.pdf
There are some graphs with even 5A and 500mA as typical usage so maybe they will work OK.
Also they can supply this power for some time. Currently my only problem is I don't have anything to hold them.

radeusgd
Posts: 7
Joined: Wed Apr 24, 2013 9:38 am
Location: Poland

Re: Powering Pi with LM7805

Sun Jun 02, 2013 1:37 pm

After some experimenting I finally succeed to power Pi from batteries.
I used 8 serially connected Energizer AA 2500mA batteries and PSP car charger.
I was able to use WiFi, Ethernet and play FM radio (Raspberry Pi FM transmitter).
Unfortunately after about 0.5h of use batteries went from 10.6V to 7.2V. It still worked but I worried about batteries, I'll see but I hope they aren't broken(they shouldn't be discharged so much).
But it stayed so short probably because I used WiFi, Ethernet and FM at the same time and I have some daemons always running (Facebook bot, apache and GroundControl).
I'll try to solder the circuit (now it was connected with aluminum foil xD) and turn off daemons and Ehternet and I'll see how much can it last and how much current does it use.
Thank you everyone for help.

User avatar
[email protected]
Posts: 2020
Joined: Tue Feb 07, 2012 2:14 pm
Location: Devon, UK
Contact: Website

Re: Powering Pi with LM7805 (solved)

Sun Jun 02, 2013 1:58 pm

Old thread resurecting :)

I've been looking at some "car charger" units as of late for another project - ie. take 12v turn it into 5v (or 19v for laptops!) and I'm not convinced some of the off-the-shelf ones are quite as efficient as they could be - and they probably don't have to be either - afterall, the car will be running most of the time, thus charging the main car battery, and even when its not running, the car battery is big enough to run most 5v USB power stuff for some time anyway. The one I currently have in my car to charge my phone runs very hot - my bet is that there is nothing more than a simple 7805 in it ...

So if you're a dab-hand with electronics then using one of the SMPS regulator chips and building up a circuit around it isn't too hard.... Alternatively I've used this in the past:

http://uk.farnell.com/xp-power/sr10s05/ ... tt=sr10s05

it's a drop-in 7805 equivalent, but uses SMPS technology.

There are others just like it - a bit more expensive than a bog-standard 7805, but personally I think they're worth the extra just because you don't have to make your own from components and it really is a drop-in replacement.

There seems to be a few alternatives out there - e.g.

http://www.rapidonline.com/Electrical-P ... ries-78072

as well as the multitude of ready built ones on ebay with adjustable outputs too, but they're typically not a drop-in for the 7805.

-Gordon
--
Gordons projects: https://projects.drogon.net/

radeusgd
Posts: 7
Joined: Wed Apr 24, 2013 9:38 am
Location: Poland

Re: Powering Pi with LM7805 (solved)

Sun Jun 02, 2013 2:04 pm

[email protected] wrote:Old thread resurecting :)

I've been looking at some "car charger" units as of late for another project - ie. take 12v turn it into 5v (or 19v for laptops!) and I'm not convinced some of the off-the-shelf ones are quite as efficient as they could be - and they probably don't have to be either - afterall, the car will be running most of the time, thus charging the main car battery, and even when its not running, the car battery is big enough to run most 5v USB power stuff for some time anyway. The one I currently have in my car to charge my phone runs very hot - my bet is that there is nothing more than a simple 7805 in it ...

So if you're a dab-hand with electronics then using one of the SMPS regulator chips and building up a circuit around it isn't too hard.... Alternatively I've used this in the past:

http://uk.farnell.com/xp-power/sr10s05/ ... tt=sr10s05

it's a drop-in 7805 equivalent, but uses SMPS technology.

There are others just like it - a bit more expensive than a bog-standard 7805, but personally I think they're worth the extra just because you don't have to make your own from components and it really is a drop-in replacement.

There seems to be a few alternatives out there - e.g.

http://www.rapidonline.com/Electrical-P ... ries-78072

as well as the multitude of ready built ones on ebay with adjustable outputs too, but they're typically not a drop-in for the 7805.

-Gordon
Thank you. I'll look into it. But also I'm going to make some more measurements with my current circuit.
I took off the case of the charger (so it is smaller) and after a quick look I don't see typical 7805, there are some ICs and a coil but I can't read the parts names because I lost my magnifier lens somewhere xD

micedwards
Posts: 4
Joined: Thu Jun 07, 2012 2:51 am

Re: Powering Pi with LM7805 (solved)

Sun Jun 02, 2013 3:07 pm

These step-down converters look like a much better choice than traditional 7805s ...

http://www.adafruit.com/products/1385

I have no experience with them, but their efficiency is very high (~95%) and they look like exactly what you need.

User avatar
[email protected]
Posts: 2020
Joined: Tue Feb 07, 2012 2:14 pm
Location: Devon, UK
Contact: Website

Re: Powering Pi with LM7805 (solved)

Sun Jun 02, 2013 6:37 pm

micedwards wrote:These step-down converters look like a much better choice than traditional 7805s ...

http://www.adafruit.com/products/1385

I have no experience with them, but their efficiency is very high (~95%) and they look like exactly what you need.
The "UBEC" devices have been used in the (electric powered) Radio Control world for a long time - they're just another SMPS device - UBEC meaning Universal Battery Eliminator Circuit - designed so you can power the electronics off the main power drive battery - usually 11-14 volts (ish) when you need 5 for the electronics, rather than having a separate battery for the electronics - hence the term battery eliminator...

Good little devices - but I do like the drop-in 7805 units - simply because they're "drop in". Pin & size compatible. The technology is more or less the same - SMPS - switched mode power supply, just packaged differently.

-Gordon
--
Gordons projects: https://projects.drogon.net/

Sonny_Jim
Posts: 45
Joined: Tue Oct 23, 2012 4:15 pm

Re: Powering Pi with LM7805 (solved)

Wed Jun 05, 2013 5:59 pm

I've used a cheap UBEC along with an 18V battery from a cordless drill, worked for about 12-14hrs as an wireless AP.

User avatar
liudr
Posts: 685
Joined: Sat Jun 01, 2013 12:11 am
Location: Central MN, USA
Contact: Website

Re: Powering Pi with LM7805 (solved)

Fri Jun 07, 2013 4:42 am

Sonny_Jim wrote:I've used a cheap UBEC along with an 18V battery from a cordless drill, worked for about 12-14hrs as an wireless AP.
Now that beats my ipad :)

Thanks everyone for this thread. I bookmarked the drop-in replacement for 7805 (kind of expensive). I'm only starting to use pi but will certainly appreciate the information regarding battery. I am used to Arduino. You can power it with a 9V battery for around 2 days :) I once had a simple temp/humidity display with it.
Arduino data loggers, user interface, printed circuit board designer since 2009, RPI 3B 2B 2B Zero Jessie, assembly/C/C++/java/python programmer since the 80's

Alek
Posts: 1
Joined: Fri Jul 26, 2013 11:45 pm

Re: Powering Pi with LM7805 (solved)

Fri Jul 26, 2013 11:57 pm

I am using a 7805 with a lithium batterie that I found in my house and it seems to be working just fine for me, but the 7805 chip does get a little hot when powering the raspberry pi. I will probably have to add a heat sink onto to the 7805 to keep it from getting to hot!

User avatar
rpdom
Posts: 15056
Joined: Sun May 06, 2012 5:17 am
Location: Chelmsford, Essex, UK

Re: Powering Pi with LM7805 (solved)

Sat Jul 27, 2013 6:46 am

Alek wrote:I am using a 7805 with a lithium batterie that I found in my house and it seems to be working just fine for me, but the 7805 chip does get a little hot when powering the raspberry pi. I will probably have to add a heat sink onto to the 7805 to keep it from getting to hot!
Change that clunky old 7805 for a cheap UBEC circuit. It won't get hot and your battery will last longer :)

Hot regulator = wasted power :(

User avatar
Lob0426
Posts: 2198
Joined: Fri Aug 05, 2011 4:30 pm
Location: Susanville CA.
Contact: Website

Re: Powering Pi with LM7805 (solved)

Sat Jul 27, 2013 3:18 pm

You can get 3A UBEC at hobbyking for less than 4$ USD.
512MB version 2.0 as WordPress Server
Motorola Lapdock with Pi2B
Modded Rev 1.0 with pin headers at USB

http://rich1.dyndns.tv/
(RS)Allied ships old stock to reward its Customers for long wait!

Return to “Other projects”