powering the Arduino Uno with a 12V battery

I am trying to power an Arduino Uno with a 12v battery. The problem here is that the Uno uses 5v as its operating voltage and we need to use a power source that will last longer than an hour while sending wireless signals. A 9v battery will not last a full hour (as far as I know) so we are using a smaller version of a 12v car battery and need to convert the power to 5v and to last a long time. I've thought about using a voltage regulator, but 12v to 5v will seem to give a overheating problem. Also, the thought of using resistors as a voltage divider has brought up the fact that the battery may only last as long as a 5v.

Does anyone have any suggestions or comments on how to power the Arduino for a long time on battery power at 5v with little or no cooling?

The uno has a voltage regulator on-board. 12V is fine.

Also, the thought of using resistors as a voltage divider has brought up the fact that the battery may only last as long as a 5v.

NO!!! ;) A voltage divider is OK for low-current "signals", but it's a bad idea for a power-supply "reducer". In order to work, the voltage divider itself would have to draw more current than the device being powered.

Linear regulators (like what's on the Arduino board) are sort-of like an automatically-adjusting resistor. The aren't very efficient because the power consumed by the regulator can be more than the power consumed by the device/load. (In fact, with a 12V supply, you've to 7V across the regulator,and 5V across the load and there is more power used in the regulator.)

Switching regulators are more efficient. With a switching regulator, the current from the supply/battery actually decreases if you boost the voltage. (But, a switching regulator shouldn't be necessary with a small lead-acid battery.)

If the current draw from 5v will be low, just power the Uno from the 12v battery. Otherwise, you need a switching regulator that accepts an input of around 12v and produces a 5v output. Here are some examples: http://uk.farnell.com/jsp/search/browse.jsp?N=2031+202797+110002526+110193592+110263251+110149053+110170120+110170093+110138119+110127544+110170089+110183940+110032067+110193075+731+502&Ns=P_PRICE_FARNELL_UK%7C0&Ntk=gensearch&Ntt=dc-dc+converter&Ntx=mode+matchallpartial&locale=en_UK&appliedparametrics=true&getResults=true&suppressRedirect=true&originalQueryURL=/jsp/search/browse.jsp%3FN%3D2031%2B202797%26Ntk%3Dgensearch%26Ntt%3Ddc-dc%2Bconverter%26Ntx%3Dmode%2Bmatchallpartial%26No%3D0%26getResults%3Dtrue%26appliedparametrics%3Dtrue%26locale%3Den_UK%26divisionLocale%3Den_UK%26catalogId%3D%26skipManufacturer%3Dfalse%26skipParametricAttributeId%3D%26prevNValues%3D2031%2B202797

So I can just wire a positive wire to the Vin on the arduino and a negative wire to the ground pin from a 12v battery? I was worried that the arduino would fry up or something.

CTE_T: So I can just wire a positive wire to the Vin on the arduino and a negative wire to the ground pin from a 12v battery? I was worried that the arduino would fry up or something.

The Vin pin is designed to accept the same voltage range input that the external DC connector is, approx +7-12vdc.

Lefty

I will take that as a complicated way of saying yes. Lol.

CTE_T: I will take that as a complicated way of saying yes. Lol.

LOL of course yes. Just an attempt to educate rather then just give yes and no answers for you to memorize.

Lefty

1 Like

Alright. Thank you! I've spent the last 3 days trying to figure out how to power or convert power to work at 5v on the arduino.

One more quick question, do you think the 12v battery will last more than an hour?

To answer that, we need to know the specification of the battery, and how much additional current you will be drawing from the +5v line and/or directly from +12v.

The battery we have is a NP7-12, 12v, 7.0Ah : Sealed Rechargeable Lead-Acid Battery. It says genesis on it and www.enersys.com

We need the Arduino to pull information off (separate) 12v car batteries and send that information wirelessly through Xbee for an hour.

I have not had the time to look up the battery's specifications yet, but I will later.

Any help is appreciated.

CTE_T: The battery we have is a NP7-12, 12v, 7.0Ah : Sealed Rechargeable Lead-Acid Battery. It says genesis on it and www.enersys.com

We need the Arduino to pull information off (separate) 12v car batteries and send that information wirelessly through Xbee for an hour.

I have not had the time to look up the battery's specifications yet, but I will later.

Any help is appreciated.

Well a basic arduino board draws about 50ma for it's own uses, so maybe 140 hours from that battery. But I suspect you may be powering other external devices and components that draw power from the arduino +5v pin or directly from the +12vdc battery? If so that current consumption would also have to be factored in to get a total battery run time estimate.

Lefty

I would just get one of there: DC-DC adjustable switching regulator module. http://www.ebay.ca/itm/LM2596-DC-DC-4-40V-1-5-35V-Step-Down-Adjustable-Converter-Power-Module-/270922360466?pt=LH_DefaultDomain_0&hash=item3f143b2692

Or one of these if you'd like to get it sooner rather than later. http://search.digikey.com/us/en/products/OKI-78SR-5%2F1.5-W36-C/811-2196-5-ND/2259781

CTE_T: The battery we have is a NP7-12, 12v, 7.0Ah : Sealed Rechargeable Lead-Acid Battery.

Your battery is 7 Amp hours, which means that it can more or less deliver 7 Amps of 12 Volt power for one hour. You should have plenty of power for what you want to do.

UPDATE:

Let me give you some figures.

I looked up the XBee and XBee Pro. They take 50 mA and 300 mA (respectively) of 3.3 Volts. The Arduino will take about 50 mA of 5 Volts.

Your battery will provide 84 Watt hours of power.

So if you use two relatively high efficiency switching voltage regulators (one to give 5 Volts to run your Arduino and one to give 3.3 Volts to run your XBee), in theory the XBee will take 165 milliwatt hours, the XBee Pro will take 990 milliwatt hours, and the Arduino will take 250 millwatt hours. So the XBee/Arduino combination will run for about 200 hours, and the XBee Pro/Arduino combination will run for about 65 hours.

Even if you just use linear voltage regulators instead of switching regulators, you should have plenty of power. The XBee/Arduino combination will run for about 70 hours, and the XBee Pro/Arduino combination for 20 hours.

Well a basic arduino board draws about 50ma for it's own uses, so maybe 140 hours from that battery. But I suspect you may be powering other external devices and components that draw power from the arduino +5v pin or directly from the +12vdc battery? If so that current consumption would also have to be factored in to get a total battery run time estimate.

Lefty

I had not thought of how I am going to power the other devices (specifically the Xbee) but the plan I believe was to use the battery to power the arduino, and then the arduino to power the Xbee.

It's not clear to me from this, but I assume the overheating problem is on the 5V regulator on the Arduino board, due to its dropping a full 7V when the 12V battery is used.

7V * (whatever current is being drawn) = Pd, the power-dissipated in the v.reg.

For tiny SOT223 v.regs used on Arduino boards, Pd can be only .3W or .5W before the regulator starts getting really hot. So, that means current in the range of only 50-mA or so before heat starts rising. XBees and XBee Pros draw a lot more current than that when transmitting.

As others mentioned, linear v.regs are not very efficient. As you mentioned, 9V batteries like the little 1" sized things, won't run your system for more than a few minutes.

Short of going to a switching regulator, I would try a series-R rather than a voltage divider, pre se. With a full v.divider, the resistor going to ground will suck your battery dry in no time.

Rather just try using a series-R alone, with 4-5V being dropped in the resistor. Then, the series-R will get hot instead of the v.reg, and that's a much better deal.

4V/.250Amp = 16 ohms or thereabouts. It needs to be at least 2W size.

You're still wasting a lot of battery in the series-R, as compared to using a switching supply, but at least it should work.

I would just get one of there: DC-DC adjustable switching regulator module.

Or one of these if you'd like to get it sooner rather than later.

I thought I didn't need any kind of converter now? I can just plug 12v into Vin and negative to ground right?

Your battery is 7 Amp hours, which means that it can more or less deliver 7 Amps of 12 Volt power for one hour. You should have plenty of power for what you want to do.

UPDATE:

Let me give you some figures.

I looked up the XBee and XBee Pro. They take 50 mA and 300 mA (respectively) of 3.3 Volts. The Arduino will take about 50 mA of 5 Volts.

Your battery will provide 84 Watt hours of power.

So if you use two relatively high efficiency switching voltage regulators (one to give 5 Volts to run your Arduino and one to give 3.3 Volts to run your XBee), in theory the XBee will take 165 milliwatt hours, the XBee Pro will take 990 milliwatt hours, and the Arduino will take 250 millwatt hours. So the XBee/Arduino combination will run for about 200 hours, and the XBee Pro/Arduino combination will run for about 65 hours.

Even if you just use linear voltage regulators instead of switching regulators, you should have plenty of power. The XBee/Arduino combination will run for about 70 hours, and the XBee Pro/Arduino combination for 20 hours.

We are going to use Xbee Pro and Arduino Uno. These calculations are accurate to just plugging into the Vin and ground right? Without any kind of converter? 20 hours is more than enough if this is true. Also, if your saying this will work for 20 hours, we ALSO have a camera/camcorder wired with the same battery but it is only for convenience and doesn't look like it will be a problem with 20 hours of power.

CTE_T: I had not thought of how I am going to power the other devices (specifically the Xbee) but the plan I believe was to use the battery to power the arduino, and then the arduino to power the Xbee.

That won't work. The XBee Pro uses 215 mA when transmitting. You can't get that through the Arduino 3.3 Volt output pin. That pin provides a maximum of 50 mA.

Putting this all together, the point is you have a big battery. It can provide a lot of power. Even the bigger laptop batteries don't have 84 Watt hours of power, and they can power a laptop--WiFi and all--for several hours.

But you still want to be careful how you use that power. You have a 12 Volt source that will power a 5 Volt device and a 3.3 Volt device. You want to be careful how you do that. Otherwise you will, at best, waste most of your power as heat and, at worst, burn out your devices.

It sounds like you want to get the easiest and quickest solution. At a minimum, that means getting a 3.3 Volt source for your XBee Pro.

Can I power the Arduino with the 12v battery and just find another battery source for the Xbee? Perhaps 2 D-Batteries? I still need them to last more than an hour.

Two D cells would certainly give you enough power for several hours of operation. But connecting the XBee directly to the batteries will probably not give you stable operation. The specs for the XBee modules I looked at said they take from 2.8 Volts to 3.4 Volts. I'd put a low dropout voltage regulator in there to stabilize the power. Something like: ww1.microchip.com/downloads/en/DeviceDoc/21826b.pdf

UPDATE: I did the math wrong. If you wanted to use that Microchip voltage regulator, you would need three D cells.

The Rev of the Uno will determine how much 3.3V current is available. The later revisions had a seperate 3.3V regulator which I'm pretty sure are more capable than the 50mA that the FT232 was capable of supplying. Have to check the schematic for your board and see what is used.

Two D cells would certainly give you enough power for several hours of operation. But connecting the XBee directly to the batteries will probably not give you stable operation. The specs for the XBee modules I looked at said they take from 2.8 Volts to 3.4 Volts. I'd put a low dropout voltage regulator in there to stabilize the power. Something like: ww1.microchip.com/downloads/en/DeviceDoc/21826b.pdf

UPDATE: I did the math wrong. If you wanted to use that Microchip voltage regulator, you would need three D cells.

Only 1 hour - that should a snap.

Given where you are currently at, I would still try the ~16 ohm series-R in the power line from the 12V battery, as the easiest fix.

OTOH, in pretty much all of my creations, I use rechargeable NiMH AA cells. [forget non-rechargeable]. This includes most of my robots.

Current NiMH AA cells have energy store in the 2200-2500 mA-hr range, and should run even an XBee-Pro for about 20-hours at 50% transmission duty-cycle. Also, of course, you can choose the #of cells to wire in series to fit the application. I use 5 or 6 cells in my robots that use R/C servos.

The same should be good for powering your Arduino board, and the v.reg shouldn't overheat. 6 cells might be better than 5 cells, as individual cell voltage drops to about 1 volt when the energy is depleted, and 6*1V = 6V, which is about the low end to keep the v.reg from dropping out.

I'd prefer not to have to order any extra parts or regulators or dividers or anything. We can get batteries easily, but I'm trying to make this as simple as possible.

The Rev of the Uno will determine how much 3.3V current is available. The later revisions had a seperate 3.3V regulator which I'm pretty sure are more capable than the 50mA that the FT232 was capable of supplying. Have to check the schematic for your board and see what is used.

What is the 'Rev' ? (reg. maybe?) And I do not have a Arduino Uno board or an Xbee Pro in my possession right now. We will order whatever the latest Arduino Uno is available (R3?) and the exact Pro model we are ordering I don't have the website link for on this computer, but I can post it tomorrow.

Can I use the 3.3v pin slot on the Uno to power the Xbee?