Bicycle iPhone and USB Charging – The Battery Pack

The number one question people ask when putting together a battery system for their bike is, “What kind of battery should I use?” There’s a torrent of information to consider here. Let’s try for a crash-course.

Battery Types

There are four common types of battery (and a bunch of uncommon subtypes), defined by the chemistry of the materials inside them. The most common battery is the Alkaline battery. The disposable batteries that you can buy in impressive rectangular packs of five hundred billion are Alkalines.

There is also a common type of battery known as "Lead Acid". The huge battery inside your car is of the Lead-Acid variety, and it’s specially designed to be very tolerant of sloppy recharging.


Big choppy surges of noisy electricity. Near-total drainage, followed by long periods of quiet. VroooOOOOM! Chugga chugga chugga! Et cetera.

Nickel-metal hydride, or NiMH, batteries are the ones you see sold in smaller quantities, often with a little recharger included in the package. These are more energy-dense than their Alkaline brethren, and are rechargeable. (Nickel-cadmium, or NiCAD batteries, are another similar type, but I’m lumping them in with the NiMH here.) NiMH batteries are what you’d usually cram into a portable CD player (if you’re old enough to remember what a portable CD player looks like).

Then there’s the Lithium-Ion, or Li-Ion battery. The laptop I’m typing this document on contains a Li-Ion battery. So does my phone. This type of battery is the most popular for small consumer electronics but is also very sensitive to mistreatment, which is why it’s usually inside a tough enclosure, or in the case of an iPod, sealed within the device, where your curious fingers can’t jab it with a screwdriver and trigger a complex chemical reaction known as a "lawsuit". They’re also quite sensitive to overcharging.

So how do I pick a battery type?

Well, it’s got to be rechargeable, so that drops Alkaline off the list. It’s also got to be small and light, and Lead-Acids have a poor energy-to-weight ratio (and are kind of hazardous), so they’re off the list. In a contest between NiMH and Li-Ion, the Li-Ion has the better energy density. But if I want to use Lithium-Ion batteries I need to deal with the slightly more complicated method for recharging them, and I also need to account for their increased fragility.

But hold on a minute here. Before I go strapping a handful of leaky batteries to a bike that’s going to bake in the hot sun, perhaps I should browse the latest technology in case there’s a better option. … Because it turns out, there is one. The Lithium-Iron Phosphate battery.

Lithium-Iron Phosphate, or LiFePO4 batteries, are like Li-Ion batteries except for a couple of very interesting differences: First, they are slightly less energy dense than Li-Ion batteries. So if I was to strap the equivalent amount of storage to a bike, the LiFePO4 batteries would make the bike weigh a bit more than the Li-Ions. That’s bad, of course. But the other difference they have is a major advantage: They are much, much safer to use.

To handle a standard Lithium-Ion battery safely, you basically need to treat it like a canned soda. Don’t freeze it, don’t get it too hot, and don’t drop it. To make a Lithium-Ion battery leak corrosive acid and heat everywhere, just give it a stout whack with the claw-end of a hammer. The explosive reaction you’ll see (hopefully from a distance) is called "thermal runaway" and is due to the guts of the battery being suddenly exposed to oxygen. Once triggered, thermal runaway is extremely hard to stop. If you puncture one cell in a multi-cell Li-Ion battery, the reaction is almost guaranteed to spread and consume the entire battery, burning for a good while.

This isn’t the sort of thing you suddenly want to have happening just below your ass while you pedal down a rough desert road. It’s not likely, but it’s possible.

A LiFePO4 battery, by comparison, is virtually inert when punctured. Go ahead and whack it with a hammer. Nothing happens. That was a waste of a perfectly good battery. To get it to explode you’d have to heat it in excess of eight hundred degrees celsius. If you’re biking in weather like that, you’ve got bigger concerns than a leaky battery. Like, how MapQuest managed to steer you into the pit of an active volcano.

LiFePO4 batteries are also more resilient in cold temperatures. They’re less prone to lose their charge, and less prone to fail when heated back up. In terms of safety, they are the best battery you could choose. And their lifespan, measured by the number of times they can be completely discharged and then recharged, averages over a thousand cycles. That is an assload of cycles. You may get old before the battery does.

Speaking of charging, how are batteries charged, anyway?

In theory it’s pretty simple: You just dump electricity back into them. From there it gets more complicated. Wikipedia has a good overview. I’ll talk more about this in the next section.

Where can you get ahold of this exotic new technology? It depends on what size battery you want, and how much you’re willing to pay… No matter what, you can expect to pay more than for regular cells. Here’s a brief list of manufacturers and sellers I investigated:

There are probably many others suppliers out there that I never found, and the market is growing fast. I encourage you to do your own search.

Anyway, I’ve chosen LiFePO4 batteries for my project. That answers the question of what battery type. Now I need to decide what capacity.

Battery Capacity

The charge stored in a battery is measured in Amp-Hours (AH). This is the number of amps that the battery can deliver for an hour. For example, a 12 volt, 1000mAH battery will supply 1000 milliamps (1 amp) of energy at 12 volts for an entire hour before it craps out.

However, most batteries are not designed to be depleted that rapidly. If you really do draw 1 amp of power out of a generic 1000mAH battery, it will probably die in less than 45 minutes. Batteries last longer when you drain them slower, and most commercial batteries are designed to operate at a drain rate of one-fifth their capacity, which means that a 1000mAH battery should be drained at 200 milliamps or less. At that rate it should last five hours or more.

More information and a better explanation can be found here, though the numbers are a bit suspect. (If you’re using a LiFePO4 battery like I am, you don’t need to worry about this… LiFePO4 batteries can take an extraordinarily high drain rate before their capacity suffers.)

Also (as the linked article explains), if you’re going to operate the battery in cold temperatures, such as below 50 degrees Fahrenheit, the capacity will be affected further. If you’re only outside for a short while you’ll be OK, since batteries are dense and take a long time to heat up or cool down to match the ambient temperature, but if you’re out in the hot sun or the cold rain for hours, the temperature will become a factor. (More good news: LiFePO4 batteries can handle these conditions just fine.)

To be on the safe side, I’d like to have a battery pack that can power my lights, or quick-charge an iPhone, for ten hours. Easily enough to handle two days of heavy use. Since my lighting system and the phone both draw at 1 amp, the math is easy: I want 10 amp-hours, or 10000mAh, of capacity.

Assembling a Pack

When you assemble a battery pack, you take multiple batteries and wire them in series, or in parallel, or in a grid-like arrangement. When you wire the cells in series, you add to the voltage. When you wire them in parallel, you add to the capacity without affecting the voltage. Five batteries in a string would put out 5 times the voltage. Three batteries with their ends braided together would put out the same voltage, but for 3 times as long. An array of 2×2 batteries puts out twice the voltage for twice as long.

So what sort of pack should I assemble? Should I use large batteries, or a bunch of small ones? Should I hook them in parallel, or in a long string? Questions, questions. The first question should be: What do I want to charge?

Well I know that already. I want to charge USB devices, potentially three or four. And if I can pull it off, it would be really cool if I could charge something big, like a laptop computer.

Let’s start with the USB devices. The USB standard requires 5 volts of power, so I should look for an arrangement of batteries that will supply at least 5 volts. USB devices are allowed to draw up to 1/2 amp each, so if I was going to power four of them, my worst case scenario would be supplying 2 amps. If I wanted to power those devices for an entire hour, I’d need batteries with a total capacity of 2000mAH.

Now, it’s not likely that I’ll come up with a battery arrangement that generates exactly 5 volts. Besides, the voltage output of batteries tends to sag a bit depending on how full they are, so a battery that starts out at 5 volts may end up pushing 4.5 after a few hours, which USB devices would probably refuse to accept. Instead, I’ll need to get somewhere above 5 volts, and then "regulate" the power to fix it at 5 volts with an electronic circuit.

Each type of battery chemistry (Lead-Acid, NiMH, et cetera) creates a unique voltage when the material is formed into cells.

  • A single Alkaline cell outputs around 1.5 volts
  • A single Lead-Acid cell outputs 2 volts.
  • A NiMH cell gives 1.2 volts.
  • Lithium-Ion gives 3.7 volts, and
  • Lithium-Iron-Phosphate cells give 3.3 volts.
So what about those 12-volt batteries I buy? What are those made of?

Bend one open with a pair of needle-nose pliers some day. You’ll find eight individually wrapped Alkaline cells. The packaging contains layers and stripes of foil that connect the cells in series, for a total of 12 volts.

To get as close to 5 volts as I can with Iron-Phosphate batteries, I should wire two in series, and make 6.6 volts. Another option would be to get four batteries and make a 2×2 grid, which would make 6.6 volts for twice as long. That would power USB devices quite nicely. But what about my other goal … of charging a laptop?

Charging a Laptop?

A recharging laptop can range from 12 volts up to 18 volts. For this exercise, I’ll consider the MacBook Air, ’cause that would be the coolest thing to bring along in a saddlebag.

Various internet sources inform me that the MacBook Air uses about 16.5 volts when recharging. According to the label, the maximum output power of the MacBook Air wall adapter is 65 watts. 65 watts divided by 16.5 volts equals about 4 amps. So if I can assemble a battery pack that delivers 4 amps at 16.5 volts for a couple of hours, I win.

Five 3.3 volt batteries in a series creates 16.5 volts of pressure. Let’s assume that I locate some D-size LiFePO4 cells, with a capacity of about 3300mAh each.

I would need to supply 4 amps, which is a lot, but LiFePO4 cells could handle it. They might get a bit warm, but no warmer than a regular Lithium-Ion battery under a lesser load. They would also experience less of a capacity degradation from "high drain rate". Even so, the most charging and operation time I could get out of those five batteries would be about 50 minutes. (3300mAH divided by 4 amps is 0.825, and 60 minutes times 0.825 is 49.5 minutes.)

50 minutes of charging and operation of a MacBook Air until these batteries are completely dead, and then the MacBook would last another 40 minutes or so off the charge placed in its battery. So I’d get about an hour and a half, with heavy use of the MacBook Air. (Running Google Earth, for example, constitutes heavy use.) Light use might be a different story entirely … I may get twice this value. (3 hours of time.)

So it’s possible, but is it a good idea? Is it worth it?

One thing I need to consider here is the potential difficulty of charging five individual batteries.

Each battery we buy is chemically unique inside, and while they may all perform identically for their entire usable life, it is likely that one will start to degrade before the others do. A "bad" battery will have high internal resistance, which limits its charging speed. It is also possible that the higher "voltage drop" across the higher resistance of the battery will put an artificial limit on the completeness of the charge for the whole set. So when one battery in a series begins to die, it tends to take the rest of the series along for the ride.

Either way, when the charge doesn’t last as long as you’d expect it to, you need to separate all the batteries out of the pack, and test them individually to find the bad one. (Or just chuck them all out, which is what most people do.)

If I’m going to be buying expensive batteries and wiring them up inside a fancy custom enclosure, I want those damn things to last as long as possible.

Another thing to consider is power loss from converting the voltage. A 16.5 volt battery pack is great for charging a 16.5 volt laptop, but to power USB devices I’d need to regulate that down to less than a third of that voltage. In general, the bigger the step you need to make, the more power you’re going to waste during conversion. Would it be worth it if I had to lose another 15% of all the electricity I make and store for USB devices?

It just doesn’t make sense to change my whole design around to power a laptop. Especially for such a short amount of time. Fully charged, the laptop lasts around three hours anyway all by itself. On the other hand, if I can design the battery pack and charging circuit to be recharged off the same adapter that a MacBook Air uses, I can carry one less power adapter while I’m on the road. (Well, if I ever get ahold of a MacBook Air, anyway.) That is definitely worth pursuing.

The Order

To keep the voltage close to my 5v target, to avoid dealing with charging many cells, and to have enough capacity to handle anything, I ordered two half-pound 10,000mAh LiFePO4 cells from BatterySpace.

Scary story: When I was testing these with my cheap amp-meter to see how much power they were running through my charger, I accidentally short-circuited them across the meter for a split second. The meter is rated to measure up to 20 amps of power. The meter flashed: 20 AMPS. Who knows how much actually went out. Probably twice that.

If you were to connect the wires to needles and puncture a finger on each hand, the current passing through your heart could actually kill you. (Do not attempt to verify this claim!)

This claim initially fostered some debate amongst my electrical engineer friends, Matt and Tavys. Was it true?

Me: "Is 6.6 volts at 40 amps enough to kill this way?"

Matt: "The voltage on those batteries is too low to really worry about. The amperage is… I can’t say irrelevant, but at a low enough voltage, it’s just usually a moot point. Pacemakers have to put out a very particular waveform to make up for the fact that they are using very little power. Your heart is a lot harder to stop than it gets credit for, honestly… It’s just that there ARE certain waveforms that will do the job."

"For example… There’s a reason electric chairs are AC. Edison actually tried to make a DC electric chair — to show that DC was safer than Tesla’s AC — and had to crank it up to some hellacious amount of power to electrocute the cow or whatever it was. The animal actually caught fire."

"Incidentally, you might enjoy reading ‘Empires of Light‘. It’s about Edison, Tesla, and Westinghouse, and the early technology and the politics of it."

Tavys: "Oh sure, you could lick your fingers and touch the tabs on the batteries and be fine. But Ohm’s law is absolute. A given voltage potential across a given resistance will deliver a specific current. High enough current through your skin burns it, high enough current through your heart kills you."

"Our skin naturally has a fairly high resistance. Measure yourself with an ohm meter; like, measure the resistance between your fingers, then lick them and do it again. The resistance decreases."

Me: "So the key here is puncturing the skin?"

Tavys: "Blood conducts rather well. Muscle contraction is controlled by electrical impulses in the body, and enough current DC would make the muscles contract in one direction and prevent them from contracting the other way."

"While I can’t guarantee that these batteries’ voltage would be high enough to do this, with low enough resistance you’d be delivering enough current to essentially put your heart in a vise."

Also, don’t stick knives in your spleen, kids. That’s a bad idea too.

To The Charging Circuit

One Response to Bicycle iPhone and USB Charging – The Battery Pack

  1. Pingback: How do I charge two 12V batteries using two solar panels that are 15V each and 5 AMP each? | Uses of Solar Power

Leave a Reply

Your email address will not be published. Required fields are marked *