Battery Derating and Chemistry Comparison

This weekend, Dave K was asking me some questions about the performance of our sweet LiFePO4 battery packs for the power wheels cars. At the time I was only able to answer his questions in generalizations, so I decided to sit down and show exactly how our lithium compares to more conventional lead-acid.

We’re running a custom 32-volt pack, but we can calculate with a more convenient size and all the observations will be proportional. Conveniently, our new teal cells are designed to create a nearly drop-in replacement for an existing form factor of gel cell. This makes direct comparisons really easy. Both options are 20 Amp-hours and both have nominal 12v output, with true output being a volt or two above that. So, straight off the bat, you’ve got the same form factor and voltage, with one option weighing 14 lbs and the other option weighing 6.6 lbs. More than double the energy density.

However, there’s quite a bit more to it than that. The two battery types are rated differently and have very different internal resistance. The lead battery gets its rating at a 20-hour rate, and the lithium is designed around a 30-minute discharge. When you use either battery outside of its intended performance envelope, you wind up with something other than the nameplate rating. There’s a formula to estimate this effect, called Peukert’s Law.

Peukert’s Law uses the following equation:

Where “It” is the effective capacity of the battery, “C” is the rated capacity, “I” is the discharge current, “H” is the rated discharge time in hours, and “k” is a constant for each different battery chemistry. For lithium, k is approximately 1.01, and for gel cells it’s around 1.15.

Do the math, and you wind up with a chart like this:


Bearing in mind we race with a 40 A fuse and occasionally burn one up, the benefit of lithium batteries in this application is pretty significant. We’re still getting more or less 20 Ah out of our packs, while the equivalent lead-acid would be derated to around 11 Ah. Suddenly we have 3.7 times the capacity per pound!

Beyond all this, there’s one other effect to bear in mind – voltage sag. When you load a battery heavily, some of the power is lost to internal resistance and you wind up with a lower output voltage than nominal. I don’t have the information to calculate this, but the effect is a lot more dramatic for lead than it is for lithium. We know from KITT that even during heavy use, we maintain close to 32 volts out of our pack until it’s almost completely flat. The “equivalent” gel-cell pack would produce at least a couple volts less in use, which means less total power is delivered to the motors.

In the end, our lithium batteries are giving us more than four times the total power of an equivalent weight in lead-acid. It’s also a lot easier to charge and maintain three battery packs than the dozen or so we would need to race two cars on gel cells. Surprisingly, even total purchase cost doesn’t look all that bad: Our total cost for the two packs on Project STEVE, including shipping, is $655. By comparison, 12 of those gel cells costs $454 and they’re so heavy that particular supplier won’t even ship them (but figure at least $100 in shipping from anyone who will). The only real disadvantage is that we’re carrying a larger portion of our $500 on-track budget in batteries and have less left for the rest of the car.

I think it’s worth it.

Power Wheels Racing Progress

Progress on the new Power Wheels racing car (Code Name STEVE) continues at a good pace! We’ve completed our innovative wood torsion box frame and are starting to lay out the other components for mounting. Here’s the recap:

The overall dimensions of the cart are 4′ in length (to make good use of our raw material) by 29″ in width (to drive through the narrowest doorway in the shop). Once we’d cut the torsion box skins to this size, we set them on the bench and started laying out the wheels and controls. Here’s James working on the seating position and handlebar layout:


Next, we started working on the internal bracing grid, using construction grade 2×4 boards ripped in half. We did this instead of just buying 2x2s because the larger boards tend to be straighter, higher-quality wood. After cutting the grid boards to length, we cut half-lap joints in them so they could cross while maintaining at least a portion of the grain all the way across the chassis.




Once everything is glued up, you can start to see the merit of this design – it’s very stiff, but incredibly lightweight. I don’t have any measurements of a steel frame to compare to, but at 21 lbs this will be hard to beat. And with the frame propped up on rollers at the axle locations and Eric sitting in the driver’s seat, there was no visible deflection.



Finally, our new batteries are in. These are BatterySpace LiFePo4 20 Ah cells, approved for us by the PRS Sanctioning Body. Right out of the box, we divided the cells into two packs and set about bottom-balancing each. Basically, we wired the cells up in parallel and did a deep discharge to 2.6 volts, putting every cell at the same minimum state of charge. Then, once they’re wired back in series we charge until the first cell hits a maximum safe voltage, setting the capacity of the pack equal to the weakest single cell. This way, we can charge and discharge without needing complicated balancing or monitoring. The minimum pack voltage is 2.6 volts per cell, and in practice we’ll set our cutoff at 28 volts or more for a 10-cell pack. The maximum voltage is whatever the pack happens to be at when one cell peaks, but we’ll generally charge to around 34 volts. As it turns out, all our cells finish charging in balance to at least 10 mV, the resolution of our multimeter. Build a sturdy box to contain and protect the cells, and we’re ready to race!



Next up, we’ll be working on the axles and steering, and then we can get to mounting motors and electronics. Stop by and give us a hand!

OMG-FTW update

Update: Button at the bottom is fixed, now

It’s about time we get started on the power wheels racers for this year. We’re starting a fund raising campaign.

We’re aiming for $1500 and we already have $610 raised, so only $890 to go! Thanks to everyone who has chipped in so far!

$1500 sounds like a lot, but includes two battery packs, motors, motor controllers, hydraulic brakes (which are amazing, btw), and tools for the pit like battery chargers. Any money that doesn’t get used this year will be ear-marked for the next. To donate money, click the “Donate” button in this post.

We’ll update this post periodically with our progress. Check the omgftw mailing list for more info.

Reflow Oven Toaster Build

Surface mount soldering is the way to go for small footprint projects and multiple production runs. However, surface mount components aren’t always the most friendly for a soldering iron setup. Imagine a surgeon trying to operate with bulky leather gloves on and you kind of get the picture for what happens when you try to solder a handful of closely-spaced 0402 or 0603 chip resistors with a soldering iron. Hot air soldering is the solution for these tiny components. With hot air, you basically have two choices, a hot air rework station or a reflow oven.
Kevin wanted to take the next step for his home electronics workshop but didn’t want to go all out and buy an expensive reflow tool that wouldn’t get frequent use. After some Internet research, he decided to go the route of using an old toaster oven, a solid state relay, an Arduino, and a reflow oven shield for his build. Check out the projects wiki for all of the details of his build.

Crystal Chamber PID Tuning

Since I'm trying to use a PID controller to keep the chamber temperatures under control I need to tune the PID parameters. And since this is designed to run for hours at a time, and because I'm crap at PID tuning, getting it right it is very tedious. Also presumably I'll need to tune it differently for different chamber loads. A liter of water is going to behave differently from a 50mL of solvent, so I figure I may need to retune it several times for different uses. So I set it up to dump the parameters so I can visualize the process. Nothing fancy, just CSV out the serial port to a log file, then into Excel so I can see what's going on:
I've run half a dozen trials while I learn how to do PID tuning. That image is from part of the process where I'm looking for a good Kp that doesn't overshoot. After playing with it for a while I decided that I might as well get the rest of the hardware and software done, then play with the fine tuning later.

Crystal Chamber Controller Interface

The code I've been using to run the temperature controller for the crystal chamber so far has been pretty bare, just the core PID loop. I don't have it tuned yet, but it's generally functional, so it's time to start getting it in shape to be an appliance.
A while back I picked up some old IBM modems that were being retired from the modem pool at work. I was hoping maybe I could convince one to speak Bell 202, but that didn't pan out. Anyway, they have nice boxes and the front panel has a set of buttons and an HD44780 LCD controller, so I held on to it:
The box has a nice power cord and switch built in, so I will be able to just stuff everything inside and put a connector on the back for the heater and temp sensor wires. Then I can use different chambers depending on what size I need. I could also run set it up to run multiple chambers, it only takes a couple more pins to run additional chambers, so I suppose I could set up to run about three. Maybe for version 2.
I wired it up for the LiquidCrystal library, plugged it in and away it went. The controller is only good for 8 characters, so I've got it set up to cycle the display through each setting one at a time. Right now, that's the setpoint temp, the current temp, and the number of seconds left in the ramp.
I also noticed that at some heater PWM frequencies the power supply squeals, so I added start and end cycle beepers. When I switch power supplies I'll probably need to add an actual beeper, but this was kinda fun in the meantime.
I also mounted the heater and temp sensor for real:
It's there at the bottom of the image. I used poly tube standoffs to keep the leads from contacting the aluminum tape and to provide a relatively stable mounting to the foam. The temp sensor is in the upper right-hand corner. Previously it was just laying on the floor of the chamber. Keeping it up in the warm air rising off the heater helps the response time, but also makes it clear that there's some pretty strong stratification going on in there. I'm pretty sure I'll need to add a tiny fan to keep the air mixed. I didn't want to do that because of the possibility for vibration to affect the crystals, but if it does end up being necessary I can probably isolation mount it somehow. Or maybe I should use an ionic wind type fan. Every project needs some nice high voltages, right? The next step will be to scare up a new power supply that'll fit into the old modem box and come up with a connector for attaching the chamber.

Crystal Chamber Temperature Controller v0.1b

I cobbled together a simple temp controller to try to get a feel for what it'll take to make one that will work for my temp controlled crystal-growing chamber. For this first iteration I've just got a simple PID-controlled heater, LM75 I2C temp sensor, and a 25W heater element.
For now I'm just running on an Arduino and a crappy bench supply (with a way-too-bright power indicator). For the finished project I'm thinking I will use a Teensy 3.0 as I've got some samples of them that I'd like to do a write-up about. To house the controller I'll be repurposing an old modem that has a front panel with a small LCD and a set of buttons that I can use for menu navigation. I can mount a power supply and all the electronics inside and put a connector on the back that plugs into different chambers. This big chamber will be nice for large beakers, but I'd like to have a smaller one for test tubes. I can put a resistor on the chamber side of the connector so the control box can identify which chamber is connected and select the appropriate PID tuning. I ran this for a few hours to see how it behaves. The 0.5C resolution on the sensor is pretty bad, but overall the results were encouraging. I don't really care much about how it handles large rates of change, since the hot solution will go into a preheated chamber. The main concern will be whether it can hold a stable downward ramp with minor fluctuations outside the chamber. I haven't tested that yet. Next step is to get the heating element mounted so it is stable and out of the way and then test with a beaker of hot water so I can see how well it do temperature ramping. I'm pretty sure I'll need to upgrade to a higher resolution sensor for really long ramps, but for a day or two this 0.5C should be ok if I screw with the PID tuning enough. The PID library has some kind of auto-tune that looks interesting, but I haven't figured out how to use it yet.