DIY Lithium Battery Balancer and monitoring (BMS)

Hi dirk

Take a look at Colins coding that may help you GitHub - chickey/diyBMS: Do it yourself battery management system for Lithium ion battery packs/cells

I havent put all 11 modules under full run and charge belance yet as im building the 6p packs for my LIPO Poly packs.

Im running colins coding due to the auto balancing on packs which i like

But i dont have an EPever charge controller has the same charge controller as you do.

Which file exactly.
Just did not find the part for the balance.

or is this in the module itself (Arduino-BMS-Cell-Module.ino)

**
Already have an EMONCMS on a Pi 3 for data acquisition / tacking. Need therefore the extensions for external data acquisition.
**
I Have a
EASUN POWER 5000W Solar Inverter 80A MPPT Off Grid Inverter 48V 220V Hybrid Inverter Pure Sine Wave Inverter 60A Battery Charger
and a PCM 60X only Charger
The MPT-7210A is only for testing

You can see My Project at secondlifestorage . com [New German Powerwall - by Walde … at forest]


Update: 01.12.2018

EMONCMS on a Pi 3B with DIY BMS on test run
With Temp, Balance Display on WiFI Pic 0/1 Identication = If Wifi On / 1 than Working Balance and Volt Meter



Update: 01.12.2018

Some of my problems are apparently due to EMC Electromagnetic Field.
I have the inverter now times in the next room with 10 meters power line to the battery pack.
And my problems with the I2C are almost gone.
1-2 errors in 2 hours with 60W load.

:checkered_flag: Recommendation:
Watch everyone and in case of emergency try to set up the charger and the transformer further away.

1 Like

“Already have an EMONCMS on a Pi 3 for data acquisition / tacking”

Is your Pi3 a model B+ or just a standard Pi 3?
as i have a pi 3 model B+ been looking at emoncms

Colin has written the coding it influxdb part for voltage and auto balancing a to a set value im looking at his coding now.

Most of the scripting is located in SoftAP.cpp but would have to go through and see what you can us and make out of it and where the references are pulled from and directed to so that can be read on screen

Hi dirk

finally got the pi3 B+ to work with emoncms can view device setup now and about to start creating a dashboard
are the widgets apart of the dashboard or they your own images you have uploaded to the dashboard

All parts default by Emon inkl.

image emonSD-30Oct18.zip

Probably worth creating a new thread about emoncms (or search the existing answers) as its a bit off topic for this thread about the BMS!

HELP HELP HELP !!!

Still need help with the Diy BMS for the code in terms of balance!

It will someone know the code better and can help me with the problem.

Making progress, go easy on me. This project inspired me to learn how to solder. :yum:

4 Likes

Hi,

I changed also the balancing routine in the controller, so I am still a bit in the code with my brain.
But my cells are a bit powerfull to be balanced only by the cell modules.

What do you need?
What kind of cells do you plan to use?

As I found out you need to break in the cells with some cycling (as long as they are not compleatly out of line??) after that you may need to bottom balance. I just finshed a bottom balancing project. I use some power resistors controlled by a MOSFET switch and an ACS712 30A current sensor and additional I convert the Voltage with an STM32F103 12 bit ADC and controll also the MOSFET swtich with it.

So tell me where are you now with your progress? how far away from each other are your cell´s? mV??

kind regards Oliver

The solar system is currently not mounted.
But the technology that should run with the DiY BMS
is as follows:
two chargers with total power of 6000W.
Removal 1. Rechargeable batteries S14P100 (1400x18650 cells) = 58v
Expansion 2. 2800x18650
That’s about 90-100A charge current. And then I just need longer balance times than 12 seconds and then 20-30 seconds nothing until the balance turns back on,
I have equipped the DiyBMS systems with R1 (2ohm) = 2A balance discharge yes also the fuse is adapted to 2A.

Only I just can not find the timing settings for the balance in the code.
To set the balance time to 20,30, or 60 seconds.

→ I had already written about the problems in previous news.

**
Your bottom balancing project sounds interesting, I would also be interested in
**

Hi,

I do not remember any timings for balancing, what is done by the cell modules.

The controller calculates the average voltage of the batterie and sends this to the modules. They start to balance the cells that are above this average until its down to average voltage.
thats how I did understand the code.

My cells behave according to this.
I build 24V and 600Ah in 6P8S
My charger is 120A
My inverter is 5000W plus 24 service loads with peak currents of 500A.

even with a 2 Ohms resistor you will not effectivly balance a high capacity batterie if the cells are heavy out of balance. Thats what I experianced the last weeks.

what voltage and how many Ah does your batterie get in the end?

Did you bottom balance your cells with some kind of equipment?

regards Oliver

I have resisted every Diy BMS with 2 ohms at the moment which is after calculation 4,2v / 2 ohm = 2,1A resistance to balances.
The batteries are 1400 cells (18650 4.2V / 2300ma) divided into 14 serial to 100 cells in parallel With a total output of 58.8V max and 202 A which corresponds to 58.8x 202 = 11910 W / 11.91 kwh.

My cell drift is currently not so high but in the summer when loading it could cause a problem and I would like to change that with longer balance times in the code. The loaders are set to 57.4 V max which are 4.1v max per pack.

Hi Dirk,

I had an other look at the cell module code and it looks to me as I told you before. The controller calculates the average cellvoltage and sends a bypass command to these cellmodules that are higher than the average above all.
The bypass time in the cellmodules is not limited by a timeframe. It bypasses for about 30sec and then pauses to get a cell voltage reading. Now a decision is made, if the cell voltage under the bypassvoltage when the balancing was enabled bypass process it finished and the balancing is switched off. Is the cellvoltage still above the bypassvoltage the balancing goes on and next check is in 30sec.

If I am wrong with that Stuart might help me out?

My cell modules behave according to this pattern. I use the original cell firmware from Stuart.
I do not use the original Stuart firmware for the diyBMS controller as I work with an ESP32.
At this time my firmware will probably not work with your setup bcs I adapted it for LiFePo and 8 cells. I need to go through my software and check if I can relaese it to your system.

What exactly is going on with your cellvoltage when you activate balancing?
Considder your chargers or loads my influence the balancing process while they change the voltage measured at the cells.

I would suggest you turn of chargers and loads, write down all cellvoltages and activate balancing. Now have a close look how the cell voltages change and when the cell modules stop balancing what is indicated with the blue LED´s.

I did similar to your setup, I placed 1.8 Ohms as load resistor for the bypass. As I work with LiFePo cells my nominal cell voltage is a bit lower than yours with max 3.65 V.
The resulting bypass current is very similar to yours with 2.027 A and my 10W resistors get quite hot, about 80 to 100 degree C. But it works.

Oliver

Hi,

Do you have an aliexpress wishlist for V3.0?

Thats correct.

Even for VERY LARGE battery banks - you won’t need massive amounts of current bypass (low resistor values) if the packs are constructed correctly, they will only need balancing infrequently (monthly or less) - and even then the cells should be no more than a few 0.1V out of balance.

Thats the reason why the thermistor was on the board - to monitor the resistor temperature and shut off in case of over temp - although most people seem to want to use this to monitor the cell pack temp instead!

Hi,

I came about PCA9601D Dual bidirectional bus buffer for the guys who run into i2c noise.

I will try that driver and increase the distance from controller to slaves.

How about that? Does anybody mind about adding it? :sunglasses:

Oliver

what would be coursing esp8266 to drop and not reset which the moduls still think there is wireless communication?

This is probably the wrong solution - if you are suffering from i2c interference, the DIYBMS is probably not for you. This is why the commercial solutions use CAN BUS or similar to avoid such problems.

DIYBMS could be changed to use CAN BUS however this then drives the price per unit up to that similar to commercial units so there is little point!

Hi everyone, i have some little issues ordering the last piece of electronics, they all have this -ND at the end, and thus i’m not quite sure if these are the one i should buy. Because opening the file on kidcad, i don’t see those -ND at the end, could anyone confirm me please?

SE30AFG-M3/6A Diode https://www.digikey.pl/product-detail/en/SE30AFG-M3%2F6A/SE30AFG-M3%2F6AGICT-ND/3983597/?itemSeq=279085378

SI2312BDS-T1-E3 https://www.digikey.pl/product-detail/en/SI2312BDS-T1-E3/SI2312BDS-T1-E3CT-ND/1656844/?itemSeq=279086149

REG710NA-3.3/250 https://www.digikey.pl/product-detail/en/REG710NA-3.3%2F250/296-12135-1-ND/404728/?itemSeq=279086222

ADUM1250ARZ-ND https://www.digikey.pl/product-detail/en/ADUM1250ARZ/ADUM1250ARZ-ND/1242409/?itemSeq=279086395

Thermistor 10K https://www.digikey.pl/product-detail/en/B57891M0103J000/495-2157-ND/739907/?itemSeq=279086620

Also, im unable to see anywhere MC36228 1.5A 8V PPTC 154C, it’s like this component doesn’t exist :confused:

I was trying to guess that may be this would work instead

PTC RESET FUSE 8V 1.5A 1206 https://www.digikey.pl/product-detail/en/littelfuse-inc/1206L150THWR/F3372CT-ND/2090991 ???

Thanks a lot for your precious help :wink: