stuartpittaway / diyBMSv4ESP32

diyBMS v4 code for the ESP32 and new controller hardware
Other
166 stars 78 forks source link

Cell Voltage reading freaks out when Active Balancer kicks in - STM32All-In-One #273

Closed Ipirk88 closed 5 months ago

Ipirk88 commented 5 months ago

Hardware/Software Versions Controller version (from PCB): Controller V4.6 & AllInOne V4.90 Version: Release-2023-12-27-12-02

Hello, i charged today my Powerwall full the first time with diyBMS.

The Cell Voltage reading is stunning accurate. But i discovered an error.

When the Active Balancer (NEEY 4A Active Balancer) kicks in, the Cell voltage reading freaks out (see in the picture - hard to catch, because it changes so fast).

You can see sometimes it measures verry low Voltage and sometimes it measures realy high Voltages - and than it measures the right Voltage.

I think the Switching Converter inside the NEEY makes some noice on the Cable - and the BMS detects it.

I head a "amateur" look into your Code and i discovered that you only takes one Cell Voltage reading per round. Is it not better when you take several readings and filter them a bit - so that we are not so influenced by any noise on the line?

grafik

stuartpittaway commented 5 months ago

The V4.90 performs 256x oversampling on each cell reading, so the sample averaging is already there - but it does do this very quickly/over a short time period.

https://github.com/stuartpittaway/diyBMSv4ESP32/blob/9a0a3ed26f2dc973d3faf3e2799a6688da3ab13e/STM32All-In-One/src/main.cpp#L575

Whilst balancing is going on, I suspect there are capacitors in the balancer which affects the cell voltage readings.

Can you confirm you are NOT sharing the balancer wires with the DIYBMS cell voltage monitor? Both should be connected DIRECTLY to the cell terminals

Ipirk88 commented 5 months ago

Yes i think thats also the problem - i am sharing the Balancer wires!

there is around 1m 2,5m² Kable to a Terminal Block with 4 connectors (phoenix contact pt 4-quattro) and from that Terminal Block i go one time to the NEEY Active balancer and one time to the BMS board.

I will try today adding 1000µF 10V LowESR capacitors to the Terminal Block (one Cap per Cell) and tomorrow i will se if it helps or not - my thinking is that the Caps will filter out the noice a bit.

But i also think that oversampling will make sense or i am wrong?

stuartpittaway commented 5 months ago

Don't share the balance cables, when the balancer is pulling a large current it will ALWAYS affect the DIYBMS cell reading

Ipirk88 commented 5 months ago

OK - tested yesterday with the Cap´s (1000µF) parallel to the Battery Cell (mounted on the Therminal Block) and the results are the same. I ordered yesterday cables an Crimp Connectors for connecting the BMS directly on the Battery Cell - i let you guy´s know the result (Material shoud be her on Friday). But thanks so far for your support - and of corse for the great project!! BR Ingo

Ipirk88 commented 5 months ago

OK - Tested it today with new Balancer Cables - Active Balancer and AllInOne diyBMS have now theyer own Cables to the battery terminals. And it works now - now more interferance!

I also measured with the oszilloscope - the Current is in range (4A max - so no Current peaks). But the Active Balancer makes some noice on the Cables - and that is what the BMS detects.

Thanks for your help!!!

stuartpittaway commented 5 months ago

Can this issue be closed now?

Ipirk88 commented 5 months ago

Thanks - yes can be closed!

To wire the Active Balancer and the diyBMS seperat to the battery terminals is the solution!