diy solar

diy solar

Taves BMS

A relay has 2 sides to it. The control side, where the 2 leads do have power on them, and the controlled side, where the 2 leads have nothing on them unless you put the relay to good use. The green/orange connector shown in the photo has the 6 pairs for the 6 relays that are used to control the various loads and chargers. The connect has the controlled side, thus a female type of connector is poor. What is going to be plugged into that connector is the controlling side of another relay that is in the inverter, or the DC/DC converter, or the charger, or your whole battery disconnect relay. The controlling side of those relays are indeed powered, and thus a naked wire (male) is a poor choice to stuff into the female socket on the BMS.

So it's not relays, it's logic inputs on other devices. Usually such inputs are protected but to be safe, yes, it would be a good idea to use another type of connector ;)


I thought you were saying that you were measuring individual cell SoC. I am concluding that I misinterpreted you.

I am. Current is the same in every cell as they are in series. So as I have the current and each cell voltage I can calculate each cell SoC in addition to the whole pack SoC.


What does a "SoC based balancer" mean?

You use SoC instead of voltage as your data input for the balancing logic. It allows you to be able to balance the cells all the time instead of only in the knee.


Ummmm, didn't I say I will charge to say N%? Isn't that exactly leaving (100-N)% unused? Yes, I have no intention of attempting to regularly get 280Ah from my 280Ah battery. Why would anyone size their pack so perfectly that they are routinely using 100% of the rated capacity? And if so, why in hell not get another 20% bigger battery and stop at 10% and 90% so you don't waste it as fast as your laptop and phone batteries are wasted (2-3 yrs)?

Yes, of course, but you talked about avoiding the knees. If you want to stay in the flat part only it'll reduce the usable capacity a lot for not much more cycles, so I was advising to not do that to that extreme and just reduce it by 5-10 % on each end, as more than that leads to very poor ROI.

And, as @snoobler said, they are NMC cells who have a higher degradation per cycle than LFP cells.


If we stop charging at, say, 90%, are we avoiding the pressure all together? Wouldn't that be even better?

My guess is that the expansion/SoC relationship is somewhat linear so stopping the charge at a lower SoC will not be super useful. But it's just an educated guess so an experiment will answer the question for sure ;)


It’s not ideal, the lower charge rate you can average- the better. It’s better to charge at 1amp for an hour than it is to charge at 60amps for a minute.
If at that point your charge controller is pumping 60amps into your pack it won’t be possible to bleed current from the errant cell.

I agree ;)


They try to balance at this point and overheat bypass resistors

Then I'd say the dump resistors are undersized. A proper design would ensure the resistors can handle the balancing indefinitely.
 
It would be great to be able to dump 100amps from a single cell during charging.

Wiring would be an expensive nightmare to make safe though. Much more practical to lower the charge current.

I’m not seeing any BMS that is more simple than lowering charge current when the first cell hits target voltage, and resistive bleed that lower current until all cells reach target voltage.

I think BMS designers get too obsessed with the batteries, and miss the big picture of overall system operation.
 
Last edited:
Well, if you need a balancing current that high then you have bigger problems to worry about (or x0000 Ah cells... ^^)
 
I agree. I'm thinking about a product range, not just one solution for me.

I am working towards having many people using my solution. So I am working on minimal installation, maximum utility, minimal part counts, etc.

Add one more part to the architecture I suggested and the battery can be expanded to 32 cells (96V battery).

TCA9548A is a 1 to 8 I2C multiplexer. Add that part to the main controller. Each of the I2C multiplexed outputs can go to 4 cell measuring adc's. It couldn't be any simpler and use fewer parts.
 
You won’t know if you are charging to 80% of your battery capacity
Mine counts Amps over time. It knows the SoC.
The cell voltages often won’t differ until the weak cell is in its knee, this is where active balancers and most passive balancers miss the point. They try to balance at this point and overheat bypass resistors, or fail to control voltage rise in the weak cell.

The Batrium for example will bypass current until the bypass gets hot - then will turn off the charger. In practice it works a lot better to turn the current to a level that won’t overheat the bypass, and keep charging the rest of the cells.
Correct, and the whole point of this thread is to show and tell about a BMS that does not do that nonsense. I suggest you read at least the initial posts from me at the start of this thread so you know what I am doing. Once you get caught up, I can point you to other clarifying comments if this is not making sense.

My resistor is 50Ohms and will dissipate the heat just fine.
It’s not ideal, the lower charge rate you can average- the better. It’s better to charge at 1amp for an hour than it is to charge at 60amps for a minute.
I suspect you are discussing the diminishing current at the top of the charge. My dumb solar controller will be shut off by the BMS when it is capable of delivering more Amps than the batteries will accept without going above 3.5V. This means I cannot trickle in the Amps necessary to bring the pack to the rated 100%. But, again, I have no intention of running my cells up there regularly. I intend to stop at N% SoC.

I am totally interested to hear a use case where it is necessary to eek out the max rated capacity of the pack every day. I suspect most people that are concerned about this, have lost themselves in a bout of anality that is pointless for their use case.

However, you might be pointing out a use case where the charger is capable of delivering more than say .4C. For example, a large PV array that will grab enough sun during the winter and clouds to charge at say .3C and keep your off grid setup running. In full sun, that array will deliver a huge, and pointless, 1C. You want to avoid stressing out the batteries with that higher charge rate. In other words, you'd rather charge over 5 hours, than 1. I can accomplish the goal of turning off portions of the array with a cool upgrade to my software.

I will spend nothing on my setup to do this. I have 4 DSSR20's. Each is just a diode and a relay that turns on/off the PV array. I have no MPPT. Each can handle 30A, but the PVs attached to each won't deliver more than say 22A. Right now all 4 are controlled via 1 relay on my BMS. It is trivial to separate 2, or all 4, so that the BMS can control the 2 halves of the array separately.

After I update my software to handle this, the user will specify the maximum Amps allowed for the total. The BMS will turn off charge sources in your ranked ordering until Amps going into the battery is below that maximum.

In summary, your concern is really about eeking out the full rated capacity of a battery pack, which is rather pointless and stresses Lithium batteries. With lead-acid, you do want your battery regularly at full charge, but with lithium you really don't want to do that. Or your concern is about balancing where again, the benefit is to eek out the max rated capacity, or the BMS cannot stop at a %SoC.

And if your concern was the interesting situation where you have more charge capacity for rainy days and want to not use them on sunny days, then my BMS provides an excellent solution (when I update the software, after someone states they want this feature).
 
Current is the same in every cell as they are in series. So as I have the current and each cell voltage I can calculate each cell SoC in addition to the whole pack SoC.
You use SoC instead of voltage as your data input for the balancing logic.
Ugh. This was a long round about way of saying that when I get to the knee, and thus the voltages are showing a meaningful difference, I can then look at the amps to help judge how much time I want to drain power from the high cell. Yes, good point. I will do that.
but you talked about avoiding the knees. If you want to stay in the flat part only it'll reduce the usable capacity a lot for not much more cycles
The user can set the settings however they like to define "knee" and "flat part", "much more", and "a lot" however they like. I am not concerned with the specifics values of "knee", "flat part", "much more", and "a lot".
 
Have you checked ATtiny841 spec? It has 10-bit resolution, *but* absolute accuracy is +/- 2 LSB. That means the adc has 8 bits of accuracy. Is that still plenty?

Actually that means 2 * 1 LSB so 2 * Vref / 2^10.

Edit: wait, you're right, Vref * 2 / 2^10 is equal to Vref / 2^9 and with the +/- you get down to 2^8. I shouldn't do maths after a day of work... bad outcome... ^^
 
Last edited:
That means the adc has 8 bits of accuracy. Is that still plenty?
I will review. But since the bulk of the time the BMS will be stopping at N% SoC based on Amp counting, the number of times the cells get into the interesting part of the knee where accuracy gets increasingly necessary, is low.
 
I think BMS designers get too obsessed with the batteries, and miss the big picture of overall system operation.

Problem is lack of standard on the comm side (and lack of comm too actually), the SCC could easily query the BMS and adapt its charge current as a result.
 
Add one more part to the architecture I suggested and the battery can be expanded to 32 cells (96V battery).
You'll have to explain more about how you are doing this. My understanding is that you will be hard pressed to find an ADC that can tolerate 96V. I am not talking about measuring the 96V, I mean the ADC that is attached to the last cell has its ground reference 96V below the 2 inputs it is measuring. So, I assume you've got to have multiple separate isolated units. Maybe each unit handles 4 or 8 cells. You've got isolated i2c communication, which seems no cheaper to implement than a $1 chip that has a USART.

Plus the load dumping, and it's kind of cool (pun intended) to measure individual cell temperature. Have I missed that you've got some isolated, scalable, solution for load dumping and temp measuring?

Maybe you are saying that 1 attiny and 1 ADC for a 4x cell board would be cheaper and more accurate than 4 attiny. Hmmm. I'm listening. If the cost is similar, this combo thing might be cool. I am totally happy to reduce the number of attiny that need to be programmed by 1/4.

We can cooperate where you supply the ADC part, and I supply the microprocessor logic and software, if this has a chance of being better.
 
Last edited:
Problem is lack of standard on the comm side (and lack of comm too actually), the SCC could easily query the BMS and adapt its charge current as a result.
I don't see the utility of this. In my setup, as an example, I have at most 60A of solar. So, yes, my solar will snap off when the batteries (280Ah) cannot accept more than 60A without exceeding the 3.5V setting, at noon on a perfectly sunny day. This might snap off charging before my goal of N% SoC.

However, the sun will descend. The amps from the solar will inexorably drop off. The BMS will turn the solar on over and over to keep trying to get to N% SoC. Why do we care that this on/off is a lower frequency of cycling than some MPPT can do?

In addition, the BMS supports turning on other loads based on SoC, or Amps or both, so in fact my fridge and water heater will click on and divert a lot of Amps away from the battery.

And again, you can divide your panels into 2 or more separate chunks and I'll implement that snazzy "max Amps" feature if you really want it.
 
Last edited:
Ugh. This was a long round about way of saying that when I get to the knee, and thus the voltages are showing a meaningful difference, I can then look at the amps to help judge how much time I want to drain power from the high cell. Yes, good point. I will do that.

Not sure we're on the same page; I was saying something like "as long as this cell SoC is over the average SoC I dump power from it to bring it back to the same SoC than the other cells; do the same for all the cells above the average".


I don't see the utility of this.

I was answering @toms , it's not related directly to your BMS, but it's related to all BMS in general I guess ;)


Why do we care that this on/off is a lower frequency of cycling than some MPPT can do?

You should compare it to PWM SCCs then, not MPPT SCCs ones. Their goal isn't to do PWM at all (whatever the frequency might be) but to control a DC/DC converter to be able to use higher voltages on the PV side (so less wires and thinner ones too) and to maintain the power drawn to the maximum the PV can deliver.


In addition, the BMS supports turning on other loads based on SoC, or Amps or both, so in fact my fridge and water heater will click on and divert a lot of Amps away from the battery.

Perfect, that's a mandatory feature in any BMS IMHO ;)
 
So, I assume you've got to have multiple separate isolated units. Maybe each unit handles 4 or 8 cells. You've got isolated i2c communication, which seems no cheaper to implement than a $1 chip that has a USART.

Plus the load dumping, and it's kind of cool (pun intended) to measure individual cell temperature. Have I missed that you've got some isolated, scalable, solution for load dumping and temp measuring?

Maybe you are saying that 1 attiny and 1 ADC for a 4x cell board would be cheaper and more accurate than 4 attiny. Hmmm. I'm listening. If the cost is similar, this combo thing might be cool. I am totally happy to reduce the number of attiny that need to be programmed by 1/4.
That's correct, isolation via I2C. Each cell measurement unit contains a ADUM1250 (I2C isolation), couple of capacitors, resistor divider and the adc. Your solution requires ~ 16 parts and the cost of programming the ATtiny841. Your measurement has 8-bit accuracy, while mine has 13 bits.

Each multiplexed I2C can service 4 cell measurement units (limited due to 4 distinct adc addresses per device). Using a 1:8 I2C multiplexer (TCA9548A), max 32 cells can be used.

I'm really not sure why you are counting pennies. Performance trumps cost.

Are you intending to sell your software? Seems like it's exactly like Pittaway's with the addition of individual control of multiple solar panels.
 
If you think that by counting amps over time that you will know an accurate SOC, then you are wrong. It will be an approximation that will drift out of accuracy over time.
 
If you think that by counting amps over time that you will know an accurate SOC, then you are wrong. It will be an approximation that will drift out of accuracy over time.

Resetting when at 100 % SoC (or 0 % SoC) is mandatory to avoid too much drift, that's how all coulomb counters work ;)
 
"as long as this cell SoC is over the average SoC I dump power from it to bring it back to the same SoC than the other cells; do the same for all the cells above the average"
If you cannot measure the amps between the cells, the cell SoC is nothing more than an individual cell voltage times some constant. I don't mean the Amps are constant over time, but it is over the set of cells. There's nothing to be gained, except confusion, by switching from one unit of measure V to another SoC. I am pretty sure I double checked that you are not intending to measure cell differences while the SoC is in the flat part of the curve, maybe I am mistaken there. Again, I see no benefit to measuring imbalance when the cells are not in the knee and they are not disconnected
You should compare it to PWM SCCs then, not MPPT SCCs ones. Their goal isn't to do PWM at all (whatever the frequency might be) but to control a DC/DC converter to be able to use higher voltages on the PV side (so less wires and thinner ones too) and to maintain the power drawn to the maximum the PV can deliver.
Yes, I know what an MPPT does. And I still don't see the point.

This thread of discussion with @toms was begun with his statement that:

It is desirable for the BMS to control the charge controller, not just “switch it off”
There is no utility to this, unless you are going to argue that 1) getting the rated amps out of the pack is really important for your application and the sun will not descend, or 2) you have a brain dead BMS that will only drain when the V is at the knee, and your cells are not balanced within some tolerance, or 3) you state that lithium batteries degrade faster with cycling charge/discharge while in the flat spot of the curve (not near 100% or 0% SoC).

I have heard nothing on any of those 3 points.
 
Last edited:
If you think that by counting amps over time that you will know an accurate SOC, then you are wrong. It will be an approximation that will drift out of accuracy over time.
I know. You should read this thread and find where I state that I will periodically run the cells to the knee to reset the accumulated error.
 
Each multiplexed I2C can service 4 cell measurement units (limited due to 4 distinct adc addresses per device). Using a 1:8 I2C multiplexer (TCA9548A), max 32 cells can be used.
I still have not heard anything regarding dumping the cells or measuring cell temps. These are nice to have features. I see no point to switching to a different design and lose that.
I'm really not sure why you are counting pennies. Performance trumps cost.
What performance? You mean the accuracy? You have not made a case that more than 8 bits is useful. I've stated multiple times why I don't think it matters. I will agree that if someone wants to keep their batteries near 100%, then yes, maybe the attiny is not going to provide the accuracy. But this is lithium. Why would someone do that?
Are you intending to sell your software? Seems like it's exactly like Pittaway's with the addition of individual control of multiple solar panels.
I think you are comparing the cell board design only and not paying attention to the controller.
DIYBMS (Pittaway's):
1) does not have current measurement yet.
2) does not allow draining a cell over time. It only does the drain for the brief moment when the charger is about to be shut off.
3) does not have optoisolators/relays built in
4) has numerous physical (buying, assembling, mounting, wiring) disadvantages

I am not sure what I am going to do. I am attempting to gauge interest. So far have found nothing but people not understanding. This leads me to conclude that I need to dramatically simplify my description and get the feedback I want a different way. A discussion forum produces lots of text that people skim over, and this results in comments where it's clear they missed a concept, and now have added more stuff others have to skim over.

I wrote that the SoC will get an accumulated error and I will run the pack up to the knee to clear that to cut off anyone from telling me that the SoC will have an accumulated error, but still someone has to write that the SoC will have an accumulated error. Ugh. (Of course these last sentences were nothing but even more clutter on the thread).
 
If you cannot measure the amps between the cells, the cell SoC is nothing more than an individual cell voltage times some constant. I don't mean the Amps are constant over time, but it is over the set of cells. There's nothing to be gained, except confusion, by switching from one unit of measure V to another SoC. I am pretty sure I double checked that you are not intending to measure cell differences while the SoC is in the flat part of the curve, maybe I am mistaken there. Again, I see no benefit to measuring imbalance when the cells are not in the knee and they are not disconnected

It's not a constant because the current varies with time (and time is also a factor here BTW). Using the SoC allows you to do exactly what you can't do with just voltage: know the imbalance while not in the knee, that's the whole point of using it instead of the voltage.


There is no utility to this, unless you are going to argue that 1) getting the rated amps out of the pack is really important for your application and the sun will not descend, or 2) you have a brain dead BMS that will only drain when the V is at the knee, and your cells are not balanced within some tolerance, or 3) you state that lithium batteries degrade faster with cycling charge/discharge while in the flat spot of the curve (not near 100% or 0% SoC).

The point is to be able to do this:

When the target voltage is reached on the first cell, ideally the BMS will instruct the charger to hold the input current at a suitable current for balancing (typically less than 2A.

When all the cells have reached the target voltage the charger needs to match it’s output to the battery load.
 
Back
Top