# Low cost cell voltage monitoring development



## jddcircuit (Mar 18, 2010)

Low cost parametric cell monitoring development update.

I have been developing an idea on how to make a low cost cell monitoring system. I would like to share some of my design requirements and progress to see if the product might meet the needs and desires of others. I am only at the prototyping stage of the cell circuits themselves and software control is very crude at the moment. I have only confirmed some of my design goals so far.

Design Goals and Strategy:

1. Voltage of each cell communicated to head controller for all control decisions, graphical display, and data logging. Control algorithms to include over and under cell voltage conditions at various loads and temperatures. Software development on Android tablet for cell voltage graphical display and data logging. Having the over and under voltage decisions made in software should have configurability advantages over solutions that use hardware trimming that must compromise when dealing with heavy current loads and very cold temperatures.

2. At least 2% cell voltage accuracy without software calibration, Better than 1% with software based correction files.

3. Average Less than $2.00 per cell circuit including PCBs. My current prototype is distributive in nature but groups 3 cells per circuit board. The PCB and surface mount components are less than $6.00 for 3 cells so on target with $2.00 average per cell goal. However, $1.00 per cell may be achievable in volume.

4. Less than 100micro amp quiescent current load on each cell. I don't want the distributive cell circuits to significantly discharge or imbalance the cells they are monitoring. I figure 10,000 hours to discharge the cell 1Ah is acceptable and any long term imbalance would only be a fraction of this low supply current.

5. Single wire daisy chain communication between cell circuits to reduce assembly efforts and cost. My current prototype uses two wires but I have ideas on making it a single wire.

My approach would be considered a digital solution but it is simply using a capacitor charge that sequentially propagates through the cell chain. Each cell circuit produces a digital pulse upon respective comparator voltage threshold crossings of the charging capacitor. This data pulse propagates to the end of line monitoring point which is opto isolated from the head controller board. The head board measures the time interval between data pulses to decode the voltage of each cell. My first prototype suffered from inaccuracies of resistor and capacitor values and their temperature coefficients. I since added an additional reference pulse for each cell group that allows the head board to cancel out these component value variations using the ratio of time intervals in software.

Future Cell Balancing Concept:
I also have ideas on how to make it have dissipative balancing using the same data bus to select and hold a bleed resistor for a particular cell for a period of time. For example if a single cell is always first to full SOC during charging then it may be desirable to bleed an Ah or so from it to bring it in line with the rest. This additional latching circuitry will be considered on the next version in order to keep the focus on low cost monitoring for now. This dissipative balancing concept is different from other shunting solutions that rely on shunting a portion of the charging current and thus need to use high wattage resistors. Also, having the balancing done in this case upon command might also provide a level of safety while being supervised.

Thanks
Jeff


----------



## jddcircuit (Mar 18, 2010)

I got my PCBs in yesterday. The PCB in the picture can scan 24 cells when completed. Each of the 8 sub section does 3 cells. I plan to make smaller individual boards for each section daisy chained together eventually. I laid it out this way for now because ExpressPCB offered 3 prototype boards for $51 in their standard 2.5" x 3.8" and I know this won't be my last revision.

I populated two of the sections and did some testing.

I am very pleased with the accuracy of this approach. I am seeing better than +/-0.5% even with the heat gun on it.

In the scope screen shot you can see the 10us wide data pulses separated by milliseconds. The time between each pulse is related to the cells voltage. With the heat gun on it the intervals change but their ratio and calculated cell voltage stays the same with this new design.

I am using the MAX934 quad comparator with 1.182V reference. It only draws 25uA according to the spec sheet so my total circuit should be less than 50uA parasitic load on each cell.

Regards
Jeff


----------



## DIYguy (Sep 18, 2008)

I think it's great. . . there just aren't enough monitoring options around, particularly low cost ones. 

I think ppl with new batteries are a bit crazy to see what they are doing. . I know I was. It does wear off somewhat when u see that it is . . .well, a bit boring. lol

None the less, keep going!! good stuff. 

I don't know if it is technically possible to have "no power draw" from the cells being monitored? . . but only from a separate source??? (12 volt accessory battery or DC/DC?) This would be the best, IMHO. ANY unbalanced parasitic load drives the eventual need for intervention, either manual or with circuitry and I think most ppl who would want this MAY be in the "no bms" camp ( I could be wrong. . ?) and if so, they really don't want to drive the need for balancing with the monitoring. Of course if the draw is exactly the same between all cells. . (possible??) there wouldn't be a worry.

Cheers,
Gary


----------



## jddcircuit (Mar 18, 2010)

DIYguy said:


> I think it's great. . . there just aren't enough monitoring options around, particularly low cost ones.
> 
> I think ppl with new batteries are a bit crazy to see what they are doing. . I know I was. It does wear off somewhat when u see that it is . . .well, a bit boring. lol
> 
> ...


Thank you for the feedback Gary that is why I am posting my efforts. I happen to be one of the new ones crazy to see what the batteries are doing and it might be pretty boring like you have experienced. I also do not have a vehicle on the road yet so I search posting of those that do. I have seen a couple of postings that refer to a rouge cell here and there but not much.

Kind of like in my job as a test engineer it feels that we are adding no value testing until something fails and everyone wants to know why. Then it gets exciting.

I kind of view the monitoring of cells as a way to gain test data in the field conditions. It has to be cheap, easy, and benign or few will do it. I have seen some but not a lot of data showing how cell capacity changes over the years. 

I think it might take at a minimum of a monitoring system with high and low voltage cutoff to be able run a pack with mismatch cell capacities if you are put in that position towards the end of your pack life. Perhaps monitoring will provide more value as time goes on.

I have not figured out a zero parasitic load monitoring solution yet but still trying.

Thanks
Jeff


----------



## DIYguy (Sep 18, 2008)

Giddeeeeupppp!


----------



## PTCruisin (Nov 19, 2009)

This is good stuff! As an engineer (now a professor) I can appreciate what you are trying to achieve. Keep us posted on the progress. KISS!


----------



## jddcircuit (Mar 18, 2010)

DIYguy said:


> I don't know if it is technically possible to have "no power draw" from the cells being monitored? . . but only from a separate source??? (12 volt accessory battery or DC/DC?) This would be the best, IMHO. ANY unbalanced parasitic load drives the eventual need for intervention, either manual or with circuitry and I think most ppl who would want this MAY be in the "no bms" camp ( I could be wrong. . ?) and if so, they really don't want to drive the need for balancing with the monitoring. Of course if the draw is exactly the same between all cells. . (possible??) there wouldn't be a worry.
> 
> Cheers,
> Gary


Gary,

I misread one of my data sheets and it looks like my design (depending on final version) will draw around 20 uA per cell. That is 50,000 hrs or 5.7 years to drain the cell by 1Ah. Keep in mind that any imbalance would have to be a fraction of this supply current since all cells are loaded with their own monitoring circuit. So I guesstimate over a decade to imbalance the pack by 1Ah as a result of this continuous monitoring method worst case.

I saw in the CellLog8 data sheet that it draws 8mA which is 400 times greater than what I am targeting.

Regards
Jeff


----------



## DIYguy (Sep 18, 2008)

jddcircuit said:


> Gary,
> 
> I misread one of my data sheets and it looks like my design (depending on final version) will draw around 20 uA per cell. That is 50,000 hrs or 5.7 years to drain the cell by 1Ah. Keep in mind that any imbalance would have to be a fraction of this supply current since all cells are loaded with their own monitoring circuit. So I guesstimate over a decade to imbalance the pack by 1Ah as a result of this continuous monitoring method worst case.
> 
> ...


Thats pretty damn close to zero. I think good enough to not have to worry about it. Any issues should get picked up on a bi-annual inspection for non-BMS ppl and will be easily handled by balancing circuit for BMS users.


----------



## jddcircuit (Mar 18, 2010)

I finished populating one of the prototype boards. It scans the voltage of 24 cells but is designed to be daisy chained to more boards to scan more cells.

I did a quick test and each sub circuit that represents 3 cells is alive and creating an output that appears normal. I haven't made a wiring harness to connect 24 cells and see a simultaneous scan yet.

Next step is to write some Arduino software that uses the input capture functions to time the interval between the pulses and to decode the voltages.

If that goes well then I will try my luck at getting the decoded voltage data to an Android tablet for graphical display.

Jeff


----------



## Tesseract (Sep 27, 2008)

Two potential problems:

1. 20uA implies a relatively high impedance circuit, and high impedance circuits are susceptible to electrostatic (E-field) noise. Make sure you test this BMS with a real, live controller (with as high an operating voltage as possible).

2. What will happen to your BMS if one of the jumpers between two cells comes loose? This invariably applies an inverted voltage (of n-1 cells in magnitude) across the BMS input.


----------



## jddcircuit (Mar 18, 2010)

Tesseract said:


> Two potential problems:
> 
> 1. 20uA implies a relatively high impedance circuit, and high impedance circuits are susceptible to electrostatic (E-field) noise. Make sure you test this BMS with a real, live controller (with as high an operating voltage as possible).
> 
> 2. What will happen to your BMS if one of the jumpers between two cells comes loose? This invariably applies an inverted voltage (of n-1 cells in magnitude) across the BMS input.


thanks for the heads up. The most electrostatic sensitive device would be the quad comparator IC that I am using. If it stops working then maybe it was due to static discharge. I will keep that in mind.

If one jumper comes loose question in confusing me. I thought I understood but then maybe I don't.
Connecting the data bus without having the cell potentials connected.
Plugging the daisy chain data bus in backwards may be another.
Reversing the cell connections.

I have not spent too much time trying to make it as robust as it will need to be if it were going to be marketed. I am sure there will be ways to blow it up that I will want to protect against.

Once I think I got something I will be looking to test it in as harsh an environment as possible.

Thanks


----------



## Tesseract (Sep 27, 2008)

jddcircuit said:


> thanks for the heads up. The most electrostatic sensitive device would be the quad comparator IC that I am using. If it stops working then maybe it was due to static discharge. I will keep that in mind.


Oops - wrong electrostatic... though your interpretation of the word is technically correct while I somewhat abused it; the correct phrasing would be "electric field", but I try to avoid that mainly because it sounds hokey... At any rate, in the near field (q.v. - Maxwell's equations), the battery cables primarily radiate magnetic ("H") fields as the current flowing through them is rapidly changing; the motor cables, in contrast, mainly radiate electric ("E") fields as they experience rapidly changing voltage levels (ie - from PWM).

E-field noise is relatively easy to block with metal shielding and circuit susceptibility is improved by reducing loop impedance as much as possible. H-field noise is more difficult to block, as it requires metal shielding with a high-permeability (e.g. - "mu metal"), so one usually attempts to reduce circuit susceptibility by minimizing loop area and increasing loop impedance (note conflicting requirement with above!). This implies the use of multilayer boards (ie - two or more) with one layer devoted to circuit "ground".



jddcircuit said:


> If one jumper comes loose question in confusing me. I thought I understood but then maybe I don't....


Nope, this hash-up is all your own! 

Whether you intend to sell it or not, you probably don't want to start a fire in the vicinity of your battery pack because of a loose/high resistance cell-to-cell jumper. And by the latter I mean the short piece of braid/strap/cable that connects the positive terminal of one cell to the negative of the next (and which your BMS will connect to as well).

Draw a series connection of cells and then use a resistor across the whole "pack" to simulate the motor controller. Now, put a meter across any of the cells and see what happens when you disconnect a jumper from one cell to the next such that pack current must then flow through the BMS wiring to complete the external circuit (which, of course, it can't do... not for long, anyway).

Note that serious problems can occur just from the cell connection becoming somewhat high resistance (from, e.g., incipient corrosion at the time the terminals were fastened becoming worse over time) - this will result in a much higher voltage being presented to the BMS when high current is flowing than it would otherwise see from the cell potential alone.

Good engineering is not just making a product work right, it is making a product gracefully handle as many foreseen, and even unforeseen, failures as possible.


----------



## jddcircuit (Mar 18, 2010)

Tesseract said:


> Oops - wrong electrostatic... though your interpretation of the word is technically correct while I somewhat abused it; the correct phrasing would be "electric field", but I try to avoid that mainly because it sounds hokey... At any rate, in the near field (q.v. - Maxwell's equations), the battery cables primarily radiate magnetic ("H") fields as the current flowing through them is rapidly changing; the motor cables, in contrast, mainly radiate electric ("E") fields as they experience rapidly changing voltage levels (ie - from PWM).
> 
> E-field noise is relatively easy to block with metal shielding and circuit susceptibility is improved by reducing loop impedance as much as possible. H-field noise is more difficult to block, as it requires metal shielding with a high-permeability (e.g. - "mu metal"), so one usually attempts to reduce circuit susceptibility by minimizing loop area and increasing loop impedance (note conflicting requirement with above!). This implies the use of multilayer boards (ie - two or more) with one layer devoted to circuit "ground".
> 
> ...


Ok I will keep the E-field in mind.
I assume ( but don't know) the change in voltage related to the PWM in proximity to a single cell is much lower than at the motor which is seeing full battery voltage on off really fast.

As far as being able to tolerate full -pack voltage with a cell strap opening up, I am pretty sure something is going fry. Perhaps I could consider some type of fusing in this case to avoid a fire. I guess that I would have to have some reliance on being able to see increased cell connection resistance reflected in a low cell voltage under load and then react to it before it became catastrophic.

Internal resistance is one of the calculations that I would want to be able to track by combining cell voltage with pack current measurement.

This is good input. Thanks for making me think.


----------



## green caveman (Oct 2, 2009)

You might want to check out the Digital BMS thread. I'd especially appreciate feedback on why it won't work/what we're doing wrong.

The plan for balancing is a standard single cell charger ($37) and two MOSFETs per cell.

Once you have the Arduino collecting data and the Android tablet storing it, you can start to get some fun instrumentation. We have an accelerometer, so should be able to get power vs. incline. The Android tablet has GPS and therefore speed, so power vs. speed.

Since we're hand soldering the circuits on prototype boards (board fab, indeed most of electronics, is out of my league) it's taking a while. I'm intrigued to know what accuracy we'll be able to get. The OpAmp difference circuit is inherently noise tolerant and the Arduino should be able to take data fast enough for a digital filter, but I don't suppose we'll really know until it's on the car.

I'd really like to be able to pick up aerodynamic differences, the effect of synthetic transmission oil, etc. Since the Android can store years of data these may show up more a long term trends.


----------



## Tesseract (Sep 27, 2008)

jddcircuit said:


> ..As far as being able to tolerate full -pack voltage with a cell strap opening up, I am pretty sure something is going fry. ...


If the strap breaks in the middle between two cells that's a benign failure; it's if a bolt attaching a strap to a cell terminal comes loose that real havoc ensues. Fortunately, the voltage impressed across the BMS is effectively inverted, so easy to block with a series diode, back-to-back MOSFETs, etc... The best approach to take will depend on whether the BMS will also do shunting, and, of course, how much you want to spend per cell, both in dollars and in quiescent current drain.



jddcircuit said:


> Internal resistance is one of the calculations that I would want to be able to track by combining cell voltage with pack current measurement.....


Possibly one of the most valuable measurements to make... just remember that you need to compare cell voltage at two non-zero currents; if one voltage is taken at 0A then the calculated internal resistance* will be way too high.



* - internal resistance is technically a misnomer here... some of the resistance in an electrochemical cell is true resistance - ie, it is Ohmic in nature - but the bulk of it comes from transporting ions and the intercalation of lithium into and out of the graphite anode, for LFP cells in particular.


----------



## jddcircuit (Mar 18, 2010)

Tesseract said:


> If the strap breaks in the middle between two cells that's a benign failure; it's if a bolt attaching a strap to a cell terminal comes loose that real havoc ensues. Fortunately, the voltage impressed across the BMS is effectively inverted, so easy to block with a series diode, back-to-back MOSFETs, etc... The best approach to take will depend on whether the BMS will also do shunting, and, of course, how much you want to spend per cell, both in dollars and in quiescent current drain.
> 
> 
> 
> ...


Just by you telling me to consider the full reversal of pack voltage being seen by my circuit and how it is a plausible occurrence helps me. I will search for the best way for me to add this protection. Dollars and quiescent current are precision to this endeavor so I may need to get creative on how to block the voltage reversal.

The voltage to current relationship (internal resistance) is really why I am attempting to get the cell voltage. I think it will give me a lot of insight into the health of my cells and connections. It seems to be the name of the game as far as I can tell. Balancing is not so important to me right now. Knowing that I need to balance, repair a connection, or replace a bad cell is important to me.

I am enjoying the challenge of trying to come up with a low cost and hopefully benign way of doing it.

Regards
Jeff


----------



## m38mike (Dec 27, 2008)

Jeff,
As a bottom balancer, I am very interested in what you are doing, and for the same reasons. I don't have your technical skills, but I am interested in your application. I would like to be able to evaluate each of my cells easily and inexpensively. I'm happy to fix the problem manually. I'd just like to know if and when I have that problem. 

So keep on it! You're building what I want!
Mike


----------



## jddcircuit (Mar 18, 2010)

I got the Arduino measuring the intervals that my ramp and compare circuit is generating. I put the values in excel for decoding the voltages and created a chart. I plugged the 3 cells into each of the 8 sub circuits one at a time.

The cyan line is the average voltage of the 3 cell group. This shows me the amount of absolute error that each circuit has. This error is expected since I only have a 2% voltage reference.

The other 3 lines show me the relative combination of each cell within its group. The axis is normalized to 1/3. The relative comparison looks pretty reproducible even if the absolute value is not as much. Calibrating for the absolute reference voltage offset should be pretty simple.

I intentionally picked a lower than the other cells for cell2 (pink line).
Cell 1 and 3 are at about 3.29volts and Cell 2 is at 3.17volts

Even though it is working I think there is some room for improvement with the accuracy and repeatability. However these changes may increase the parasitic current draw.

I am not going to optimize anything quite yet.

Next step is to try and get the information from the Arduino to an Android Application that can continuously display a bar graph of a whole string of cells.

Thanks
Jeff


----------



## jddcircuit (Mar 18, 2010)

m38mike said:


> Jeff,
> As a bottom balancer, I am very interested in what you are doing, and for the same reasons. I don't have your technical skills, but I am interested in your application. I would like to be able to evaluate each of my cells easily and inexpensively. I'm happy to fix the problem manually. I'd just like to know if and when I have that problem.
> 
> So keep on it! You're building what I want!
> Mike


Very good. If you have any specific requirements feel free to share.
Thanks
Jeff


----------



## green caveman (Oct 2, 2009)

Jeff,

Are you using a voltage divider on each circuit to avoid the problem of high (120V+) common mode?



jddcircuit said:


> Next step is to try and get the information from the Arduino to an Android Application that can continuously display a bar graph of a whole string of cells.


I've just sent you a PM offering an Android App-builder. It's beta and so I don't want to just publish the link, but if anyone else is interested, feel free to PM me. It should do more than you need, including "real-time", historical data and charting. You can use bars, meters, etc. etc. 

The bluetooth app in the digital BMS thread represents a couple of hours work (the displays could be bars, instead of text boxes). 

Let me know if I can help.


----------



## jddcircuit (Mar 18, 2010)

green caveman said:


> Jeff,
> 
> Are you using a voltage divider on each circuit to avoid the problem of high (120V+) common mode?
> 
> ...


Not really using voltage dividers to handle voltage difference. The way I am handling the high common mode voltage of the stack is by using locally referenced analog to digital conversion by dedicated circuits and then pass the digital information between each circuit to the next. In this way each cell only sees its neighbor which is a much smaller voltage level shift between them to deal with.

I can then capture and decode the digital information at the end of the daisy chain bus. There are other circuits I have seen like ones that use a micro per cell and special purpose ICs that can handle 12 cells at a time and then use a daisy chain serial bus to propagate the digital information.

Thanks for the Android stuff. I will check it out. I am not an experienced programmer. I don't plan on using blue tooth. The Ardunio board that I have can act as a USB host so I will need to put my Android tablet in what is called accessory mode. I don't have the tablet yet and not real familiar with the programming so this is going to take me a little while.

Thanks
Jeff


----------



## green caveman (Oct 2, 2009)

Jeff,



jddcircuit said:


> I can then capture and decode the digital information at the end of the daisy chain bus. There are other circuits I have seen like ones that use a micro per cell and special purpose ICs that can handle 12 cells at a time and then use a daisy chain serial bus to propagate the digital information.


That sounds to be a very slick design. Where do you feel you are on the hardware side? Ready to put out a board layout and a BOM? I'd be very happy to build it up, test it and build out the software.

I would really like to be able to balance the cells with a charger rather than by discharging. I think that it can be done using the Arduino outputs, two MOSFETs and a single cell charger. With two MOSFETs you can "switch" in any cell. With the Arduino, you can create a custom balancing strategy, whether that's a top balance, bottom balance or anywhere in between.

I suspect this may need to be completely separate because there's the possibility to put some amps.



jddcircuit said:


> Thanks for the Android stuff. I will check it out. I am not an experienced programmer. I don't plan on using blue tooth. The Ardunio board that I have can act as a USB host so I will need to put my Android tablet in what is called accessory mode. I don't have the tablet yet and not real familiar with the programming so this is going to take me a little while.


You can buy a $2 BlueTooth USB dongle (dealextreme) for the Arduino/USB host. This adds a couple of neat features. The tablet is now isolated. No matter how badly you mess up your Arduino, the tablet will survive.

You can also move the tablet to a mount on the dash and be able to carry it away from the vehicle without unplugging anything.

Downside is that you need a tablet with BlueTooth.

How interested are you in learning the programming and doing it all yourself? If you're willing to keep working on the hardware and let us help on this end with the software, we might get a better product faster.

From a feature perspective I think we have the same goals. I want year-over-year data and to be able to correlate it to any outside factors 
anyone can think of a way to measure. I really want aerodynamics - a way to get Cv and see if you can change it with simple aeromods. I also want realistic estimate of power vs hills - mainly because that's not really included at all in range estimates because no one really has any data.

Strain gauges would give you a measure of the weight of the car, but I'm not sure that you could find a stable enough spot or a spot that would give you good estimate regardless of the position of the load. I'm probably willing to try if I have some way to measure power.

Others have already pointed out that you can add OBDII, if you have a new enough car and a tablet with BlueTooth. The data manipulation capabilities are endless, once you can gather the data.


----------



## jddcircuit (Mar 18, 2010)

green caveman said:


> Jeff,
> 
> 
> 
> That sounds to be a very slick design. Where do you feel you are on the hardware side? Ready to put out a board layout and a BOM? I'd be very happy to build it up, test it and build out the software.


My hardware is not ready for prime-time. However it is looking promising and unique to other solutions in a couple ways. I am not prepared to post the full schematic and layout yet. Possibly soon.

I am looking forward to doing the software but I will be reaching out for assistance when I hit a wall.

My cell monitoring method is only a piece of my project. It will be integrated with my own battery charger and motor controller that interfaces with a junkyard Prius inverter.

I have several balancing ideas. Plan A is to not have any on board but know when it is time to balance using the cell voltage monitoring.

With the voltage monitoring I should know which cells are at a higher state of charge than the rest because they reach the high voltage cutoff first each time during charging.

A simple circuit to remove a specified amount of amp hours from those high cells should be enough to improve the balance. I plan to use the same wiring harness that my monitoring circuit uses to tap the cells for this periodic balance.

Jeff


----------



## green caveman (Oct 2, 2009)

jddcircuit said:


> My hardware is not ready for prime-time. However it is looking promising and unique to other solutions in a couple ways. I am not prepared to post the full schematic and layout yet. Possibly soon.
> 
> I am looking forward to doing the software but I will be reaching out for assistance when I hit a wall.


OK, let me know. I just wouldn't want a slick hardware design to be buried for months because you get lost in the Android world. I created the BlueTooth stack for Arduino (it's a port of BTStack), so let me know if you want to go that way - it may give me some incentive to work on an upgrade that I haven't, yet, made time for.

Android is actually a pretty easy platform to program. 

As I say, I'd be happy to build up the circuit and test it so that you have at least one other installation before you send it out to the world. On the other hand, there may be better candidates watching this list since my expertise is definitely on the software side rather than hardware debugging.



jddcircuit said:


> My cell monitoring method is only a piece of my project. It will be integrated with my own battery charger and motor controller that interfaces with a junkyard Prius inverter.


Yep, a little local intelligence opens up a whole world of possibilities.

One of the problems with conversions is that they need TLC. For the most part, you couldn't give your grandmother your conversion and have her just drive it.

The system you're building brings us closer to a system that automates what can be automated and will provide a notification so that your grandmother can call and tell you what the system says needs attention.



jddcircuit said:


> I have several balancing ideas. Plan A is to not have any on board but know when it is time to balance using the cell voltage monitoring.
> 
> With the voltage monitoring I should know which cells are at a higher state of charge than the rest because they reach the high voltage cutoff first each time during charging.


Surely, and for the bottom balancers the same hardware applies, it's just a minor software change to balance before charging rather than after (if I understand bottom balancing correctly).



jddcircuit said:


> A simple circuit to remove a specified amount of amp hours from those high cells should be enough to improve the balance. I plan to use the same wiring harness that my monitoring circuit uses to tap the cells for this periodic balance.


I wonder about mixing "high" power, I suspect to balance you'd be looking at 10W+, in with the low power monitoring circuit.

I would expect to use, say 1A, fuses for the monitoring circuit - connected directly to the terminals or the straps of the cells. Inline glass fuses seem to be the lowest cost if you're not anticipating replacing them. I think that you can embed them in a battery lug in the style of the zeners in the Lee Hart Balancer. 

My other problem with dissipative is that, well, it's dissipative. You go to the trouble of charging the cells and then start discharging them. I know it's infrequent and the charge loss is minimal, but it still bothers me.


----------



## green caveman (Oct 2, 2009)

A little offtopic and a future development rather than an immediate idea. One other thing that you might consider as an Arduino substitute is the RaspberryPI with the GertBoard

There's an availability problem on these. The $35RPi is delayed (again) waiting compliance testing. I suspect the GertBoard won't become a reality until the RPi exists. I also haven't seen final specs on the GertBoard (Analog In?).

It's a much more powerful solutions and easier to program for a given value of "easy". (I think that simple programs on Arduino are easy but it doesn't scale well and complex programs are non-linearly more difficult - mainly a lack of threads).


----------



## fb_bf (Jul 6, 2011)

green caveman said:


> From a feature perspective I think we have the same goals. I want year-over-year data and to be able to correlate it to any outside factors
> anyone can think of a way to measure. I really want aerodynamics - a way to get Cv and see if you can change it with simple aeromods. I also want realistic estimate of power vs hills - mainly because that's not really included at all in range estimates because no one really has any data.
> 
> .


I'm not sure what your looking for, but it sounds a little like what I've tried. I used a GPS running watch to log how my car slows down after I push in the clutch. From this I calculate Cd and rolling resistance. I also developed a spreadsheet to calculate energy use for any route you can document with the GPS. The data is recorded once a second. Form my Cd estimates I can then calculate energy required to overcome drag. From the change in velocity, I can calculate energy to accelerate, and from the altitude change I can calculate energy gained or lost on hills. I've posted my spreadsheets for download on my site. They are crude in that they'll need to be modified for your own data, but I'd love to hear your opinions on the ideas. I also use my logging feature in my Soliton Jr. controller to measure energy use. This is good because all of your drive train losses are being measured as well. My latest measurement was to see what the luggage rack on my car was costing me. From the data It looks like it was around a 5% increase in drag force at 50 to 60 mph. I hope I'm not interrupting this thread. We can discuss this elsewhere if you’re interested.


----------



## jddcircuit (Mar 18, 2010)

I have made some progress on my development. I made a video.
http://www.youtube.com/watch?v=XpjJNani1Hk&feature=youtu.be




I am getting about a .1% repeatability which is good but I want to improve the accuracy a little. Another engineer pointed me to a likely source of current leakage that may be creating an imbalance in my RC time constant. The circuit is designed to draw very low currents from the cells (20uA approx) which makes small leakage currents that much more significant.

Quick test will be to change from 1meg to 500k resistor for my charging time constant and see what happens. I also have a redesign on paper but I am shooting for good enough at the moment with this design.

The Android tablet I am using has version 4.0.3 operating system and cost me $107 including shipping (Novo 7 Paladin). I wanted this latest version of Android to hopefully take advantage of the Android Open Accessory Development (ADK) library for USB devices but I spent days without being able to get it to work as advertised.

I am currently using a work around for my USB protocol using the Android Debug Bridge (ADB). This USB method might have some hidden advantages. It should work with earlier Android versions and may give me the ability to shut down or reset my tablet if needed.

Thanks
Jeff


----------



## green caveman (Oct 2, 2009)

Very cool! Are you planning to publish the circuit before or after the redesign? At the minute it appears from random hand-measurements that the odd pack in the little van is staying pretty well in balance, so I'm not quite as worried about individual cell measurement as I was. 

The downside of ADB is that you have to enable "USB Debugging" under "Applications Setting-> Development" on the tablet - not a big deal for a project like this.


----------



## jddcircuit (Mar 18, 2010)

green caveman said:


> Very cool! Are you planning to publish the circuit before or after the redesign? At the minute it appears from random hand-measurements that the odd pack in the little van is staying pretty well in balance, so I'm not quite as worried about individual cell measurement as I was.
> 
> The downside of ADB is that you have to enable "USB Debugging" under "Applications Setting-> Development" on the tablet - not a big deal for a project like this.


Thanks

I need to hold back a while before publishing the schematic of the monitoring circuit. There is quite a bit of testing to be done still. Even though it is not directly related to my work I went ahead and submitted the concept for an innovation award. I guess I need to wait until they decide whether to pursue a patent or not.

In the meantime I will post my progress with integrating it into my battery management system, data logging with Android GUI, and homemade battery charger and controller.

Jeff


----------



## jddcircuit (Mar 18, 2010)

It has been a while but I am back to working out my battery pack monitoring and control strategy and I wanted to give an update.

Here is a picture of the setup so far.








The company I work for did end up pursuing patent on the concept but I am thinking publishing a schematic for DIYers might not be out of the question. I think I just have to wait until the patent application is made public information. This prototype circuit is not my preferred design but will work for now as I get the rest of the pieces in place.

You can see some inaccuracies for the cell voltages in the bar graph but I think this can be improved. The Y axis range in the display is 2.5V to 4.0V so you can get an idea of the voltage measurement variation. It is about +/- .1 volt at this time. I have some ideas on how to improve it to +/- .01 volts. My pack voltage sum is showing about a 2% inaccuracy at this time. Since the measurements seem very repeatable and stable for now I can handle the inaccuracies in software.

My main goal is to have an intelligent controller that can detect changes in the cell characteristics over time. In addition to detecting the high and low voltage extremes I want to be able to analyze the relative cell to cell to behavior under the same current draw.

I am getting a little better at my Android programming. This week I want to get some data logging working in preparation for running some charge and discharge cycles. 

The precharge, main contactor, and battery charger control will get added into the system through the Arduino IO. This way my BMS software in the Android can activate and deactivate them based on the pack condition.

My strategy is to use the Android as the master controller for making decisions about the health of the batter pack and each cell at all times. The Arduino will be its slave and the interface to the outside world. The Arduino will default to safe state if USB communication to master is lost.


----------



## jddcircuit (Mar 18, 2010)

I have made some changes to my cell voltage monitoring design. Minimum parasitic load is one of my main design goals in order to not induce SOC imbalance during monitoring.

The new distributed cell circuits measure two cells per board. There is a two wire connection between each cell board. One of the wires is for the positive node connection of the adjacent cell the other wire is for data. 









One of the advantages of connecting in this fashion as opposed to a single board per cell is that it includes the contact resistance of the straps in the voltage measurements which will help indicate a bad connection fault. I have seen other posts that view this as a disadvantage but to me additional fault coverage is a good thing. However misleading fault coverage is not a good thing so perhaps some software to help indicate resistance given voltage and pack current will help the user remedy the problem.

The data protocol is a series of pulses separated by time. The time interval is proportional to cell voltage. It is this time based sample and signaling that is patent pending but we will see if it holds water. The time interval is measured by the Arduino at the end of chain with a single opto isolation point and then sent to the Android via usb to decode and display.









The end of interval data pulses are transmitted between cells as a 200uA x 40us pulse via P channel mosfet chain. I tried to minimize the data bus contribution to cell imbalance. With 100 cells in series at a 2 second sample rate the data transmission will create a 0.4uA load difference between cell 1 and cell 100. This could be reduced but seems good to me for now.

It takes approx 5msec per cell sample so 100 cells takes half a second to update.

The three cell boards that I assembled so far are drawing 9.5uA +/- .1uA based on the voltage drop across the 100ohm input resistor on each cell board.

I am still doing some testing but I am pleased with the initial performance.

I am not hitting my low cost targets (dirt cheap) but haven't given up yet.

Regards
Jeff


----------



## GizmoEV (Nov 28, 2009)

Looks good. Some questions which come to mind. To use an odd numbered pack would the last (first?) cell tap just be left off? What happens if a wire in the middle breaks? What would happen in a situation where there are separate battery boxes? What about shorts? Is there a fuse or something for safety?


----------



## green caveman (Oct 2, 2009)

jddcircuit said:


> The time interval is proportional to cell voltage. It is this time based sample and signaling that is patent pending but we will see if it holds water. The time interval is measured by the Arduino at the end of chain with a single opto isolation point and then sent to the Android via usb to decode and display.


Isn't that technique fairly well understood?

A board from Metrabyte (acquired by Keithley Instruments) back in the mid-80's used a technique that sound similar to this for A/D conversions. IIRC, the longer it took to get a reading, the lower the voltage (or vice-versa). High accuracy at low cost, but slow.
If you go through the descriptions of the boards listed here:_

http://www.mccdaq.com/isa-data-acquisition/CIO-DAS08-AOM.aspx

_you'll probably find it.I don't know whether you have something that's truly novel or not, but the USPO rarely looks for prior-art so it's unlikely that you'll have the patent rejected. Unfortunately, I think you'll have a hard time getting hobbyist involved in a project that's encumbered by a patent unless they can get a clear grant of rights from the holder first.


----------



## jddcircuit (Mar 18, 2010)

GizmoEV said:


> Looks good. Some questions which come to mind. To use an odd numbered pack would the last (first?) cell tap just be left off? What happens if a wire in the middle breaks? What would happen in a situation where there are separate battery boxes? What about shorts? Is there a fuse or something for safety?


Even number of cells only for now

Multiple chains, each their respective Start of Chain opto isolation works fine for multiple packs. At the first cell board opto interface the sample trigger and data pulse signals are separate so each chain would have its own Start of Sample trigger signal but can share a common data return back to the Arduino for processing which then only requires a single Input Capture pin on the Arduino.

No fuses yet. No high voltage signals leave the pack which is good. If one of the cell boards has a short or is malfunctioning I will hope it to be reflected in some out of range cell measurement by the controller that will not engage the main contactor for pack use.


----------



## jddcircuit (Mar 18, 2010)

green caveman said:


> Isn't that technique fairly well understood?
> 
> A board from Metrabyte (acquired by Keithley Instruments) back in the mid-80's used a technique that sound similar to this for A/D conversions. IIRC, the longer it took to get a reading, the lower the voltage (or vice-versa). High accuracy at low cost, but slow.
> If you go through the descriptions of the boards listed here:_
> ...


I am not sure if it is novel but it seems to be working and appears to be different from what is available on the market.

You are correct about being able to increase measurement resolution of the ADC by increasing the integration time which works well for this application I think since I am only sampling every couple of seconds.

DIYers like myself love to copy designs. Patents do not restrict DIYers in any way. I think patents are only for commercialization of ideas.

My motivation for patent pursuit was really to get time to work on my hobby while on the clock during my day job.

Regards
Jeff


----------



## PStechPaul (May 1, 2012)

The time proportional to voltage method is interesting, but I think it might be difficult to get good accuracy over an optoisolated interface. For instance, to get 8 bit resolution, the pulse width would need to be something like 1 mSec to 256 mSec. Thus 50 measurements may take as long as 50*0.256 = 25.6 seconds. OTOH, you could send a 10 bit RS232 signal (8 bit data) with 1 mSec bit width (about 1200 baud) in 10 mSec.

There are other threads where BMS designs are discussed and I think I proposed a similar system of pulse width communication. But my method was to send perhaps 4 pulses each having a width of 1 to 10 mSec corresponding to a decimal digit of 0-9. Thus a 4 digit reading could be sent in less than 50 mSec, and it would have a resolution of 1/10000 or 100 PPM. But just two 8 bit data words could be sent via RS232 1200 baud in about 20 mSec and have 16 bit resolution or 15 PPM. 

Since most newer processors have USARTs as well as SPI and IIC modules, more standard forms of communication can be done with little overhead and much more efficiently. But it's always interesting to conceive of new ideas.


----------



## jddcircuit (Mar 18, 2010)

PStechPaul said:


> The time proportional to voltage method is interesting, but I think it might be difficult to get good accuracy over an optoisolated interface. For instance, to get 8 bit resolution, the pulse width would need to be something like 1 mSec to 256 mSec. Thus 50 measurements may take as long as 50*0.256 = 25.6 seconds. OTOH, you could send a 10 bit RS232 signal (8 bit data) with 1 mSec bit width (about 1200 baud) in 10 mSec.
> 
> There are other threads where BMS designs are discussed and I think I proposed a similar system of pulse width communication. But my method was to send perhaps 4 pulses each having a width of 1 to 10 mSec corresponding to a decimal digit of 0-9. Thus a 4 digit reading could be sent in less than 50 mSec, and it would have a resolution of 1/10000 or 100 PPM. But just two 8 bit data words could be sent via RS232 1200 baud in about 20 mSec and have 16 bit resolution or 15 PPM.
> 
> Since most newer processors have USARTs as well as SPI and IIC modules, more standard forms of communication can be done with little overhead and much more efficiently. But it's always interesting to conceive of new ideas.



The only IC on the cell boards is a very low power quad comparator. I am using a simple RC charge circuit to create a time constant. It takes approximately 10msec per cell board so 5msec per cell since each board does 2 cells. Each cell board generates 3 pulse events. One of the pulse events is for reference to cancel out RC time constant variation. Each pulse is 40usec in width but separated by 3 to 4msec depending on the cell voltages. It is the time between the leading edge of the pulses that matters for the decoding.

I am not so sure what resolution I am getting but keep in mind the project goal is to minimize parasitic current draw on the cells. I am not so concerned about sample rate.

However, Like you suspected I am getting some measurement variation with my opto interface at the end of chain that I don't get with my non isolated transistor interface. Perhaps there is some difference in the sharpness of the signal edge with the opto. The variation is manageable but I wish it wasn't there. I hope to track this source of error down and find an alternative.

Thanks
Jeff


----------



## jddcircuit (Mar 18, 2010)

I just got notification that my patent application is now public information. I am not sure if it will mature into a patent but at least now I can share more with what I am thinking for us DIYers.

http://www.google.com/patents/US20130265058

My latest version is working pretty good. I am using it to monitor some cells that I am doing some cycle life testing research for my company.

There are some schematics in the patent application. They resemble my latest version but not exactly the same.

Ultimately I would like to have a way to monitor at the cell level in the most benign way possible. Perhaps a standard will emerge and be incorporated into the cell construction.

Regards
Jeff


----------



## jddcircuit (Mar 18, 2010)

Here is my latest working schematic. Not optimal but does work.








It monitors two cells at a time by sending 3 pulses after receiving a trigger signal from the south connected circuit.

One of the pulses is for the 1.182V on board reference. One pulse for the first cell voltage and the third pulse for 2/3 of the sum of the two cells.

I am using the Arduino Due input capture to time the interval between pulses and pass it to an Android tablet for logarithmic decoding, display, and logging.

Regards
Jeff


----------



## PStechPaul (May 1, 2012)

After scanning through the patent and the drawings I think I have a good idea how this works. It seems to be similar to the dual slope ADC conversion that is performed by many digital voltmeters. Basically, a capacitor is charged for a fixed period of time with a current proportional to the voltage, so it reaches a voltage which is proportional to the sample voltage. Then the capacitor is discharged through a constant current and the time of discharge is proportional to the ratio of the sample voltage and the current, which is determined by a fixed voltage reference.

In your case, the charge and discharge are based on a resistance, so the voltage is a logarithmic function. This requires more computational power in the processor, but that is not a major issue now, and may be cheaper than the voltage-to-current circuitry. There is, however, the question of the precision of the measurement as the curve flattens out, and the ability of the comparator to switch at a precise and repeatable point.

As I understand it, this device triggers a conversion which first performs a calibration which generates a return pulse at a time interval determined by the reference voltage and the capacitor charging through a resistor. Then it uses the sample voltage to do the same thing, so that the return pulse position will be proportional to the ratio of the sample to the reference.

I just don't know how accurate and sensitive this mechanism will be. I have not really studied the mathematics in the patent, and I'm not sure if an analysis was made on the effects of component tolerance and temperature coefficients. As you say, this "works", but may not be optimal. I'd like to see actual test data under a variety of conditions to verify if it is "good enough", and also a comparison of parts cost (including PCB) to compare with a simple PIC circuit. 

The idea of pulse position and timing for voltage measurement seems good, and this could be implemented with other means such as a PIC with ADC, and each element could trigger the next on a "daisy chain" with a wired-OR configuration which could send back a pulse train with widths proportional to cell voltage. It could also be offset to give a pulse width of perhaps 1 to 100 uSec for voltage of 2.5 to 4.0 volts, for an effective resolution of 15 mV/uSec.


----------



## jddcircuit (Mar 18, 2010)

PStechPaul said:


> After scanning through the patent and the drawings I think I have a good idea how this works. It seems to be similar to the dual slope ADC conversion that is performed by many digital voltmeters. Basically, a capacitor is charged for a fixed period of time with a current proportional to the voltage, so it reaches a voltage which is proportional to the sample voltage. Then the capacitor is discharged through a constant current and the time of discharge is proportional to the ratio of the sample voltage and the current, which is determined by a fixed voltage reference.
> 
> In your case, the charge and discharge are based on a resistance, so the voltage is a logarithmic function. This requires more computational power in the processor, but that is not a major issue now, and may be cheaper than the voltage-to-current circuitry. There is, however, the question of the precision of the measurement as the curve flattens out, and the ability of the comparator to switch at a precise and repeatable point.
> 
> ...



You are correct. It is like a dual slope ADC without the digitizing part. The idea is that removing the digitizing and serial communication will help to reduce the supply power and parasistic draw on the cells and increasing the integration time may help improve precision.

One of the examples in the patent describes a dual slope implementation that uses the neighboring cell as the integration reference source as opposed to having an on board reference voltage.

The schematic that I posted is what I call a single slope dual compare.

Using a PIC with an ADC is a legitimate consideration for implementation based currently availability and cost of components.

My hope is that this idea may mature into a special purpose IC that could miniaturized and perhaps embedded into the cell construction with the access to the data terminals for daisy chain.

I view the idea as creating a heart beat for a battery pack.

The final design may draw zero current from the cell for extended shelf life perhaps until the data chain was connected in a pack and then would draw very small yet equal amounts of power.


----------



## polodiy (Oct 25, 2015)

Just saw your progress video https://www.youtube.com/watch?v=R46kxQqWmb4
Looks promising.
Good luck!


----------

