diy solar

diy solar

YamBMS JK-BMS-CAN with new Cut-Off Charging Logic (open-source)

Similarly OVERvoltage Recovery < OVERvoltage Protection.

So in essence:

Low Voltage Shutdown < UNDERvoltage Protection < UNDERvoltage Recovery < OVERvoltage Recovery < OVERvoltage Protection
 
jk-bms-ble-can-2 cell voltage undervoltage protection - 3.33
jk-bms-ble-can-2 cell voltage undervoltage recovery - 40 i think
UVPR is 4.00v?? That's incorrectly high! In your case, if a cell got as low as 3.33v, the BMS would prevent discharge until the cell recovered to 4.00v!
That is why you had no discharge yesterday, if any cell is lower than UVPR, the ESP32 will set discharge current to 0 amps.

Set UVPR to a sensible value and you will have discharge as normal.
Please ensure you're setting up your BMS correctly, values like this will prevent your system from working correctly.
 
Typo was made here not in the Software - its 4.0 on ESPHome
I'm just saying that if you are not careful you can also do it in the JK BMS app ...

I have the reverse problem as you have (OVERvoltage) but the same applies here ...
 
UVPR is 4.00v?? That's incorrectly high! In your case, if a cell got as low as 3.33v, the BMS would prevent discharge until the cell recovered to 4.00v!
That is why you had no discharge yesterday, if any cell is lower than UVPR, the ESP32 will set discharge current to 0 amps.

Set UVPR to a sensible value and you will have discharge as normal.
Please ensure you're setting up your BMS correctly, values like this will prevent your system from working correctly.
i am checking the JK side now, i dont think jk allows incorrect settings , therefore should ESP not read JK's config as is?
 
UVPR is 4.00v?? That's incorrectly high! In your case, if a cell got as low as 3.33v, the BMS would prevent discharge until the cell recovered to 4.00v!
That is why you had no discharge yesterday, if any cell is lower than UVPR, the ESP32 will set discharge current to 0 amps.

Set UVPR to a sensible value and you will have discharge as normal.
Please ensure you're setting up your BMS correctly, values like this will prevent your system from working correctly.
o.k this is what set on the JK
1710168967891.png
 
i am checking the JK side now, i dont think jk allows incorrect settings , therefore should ESP not read JK's config as is?
That value can be set in the JK BMS - UPVR of 4.00v is higher than the 3.33v you set for UVP, therefore 'valid'.
Just because it can be set in the BMS doesn't mean it is a sensible value though.

This project relies heavily on values set in the BMS settings - we can't work around situations like this. You need to set the BMS correctly in the first place.
 
That value can be set in the JK BMS - UPVR of 4.00v is higher than the 3.33v you set for UVP, therefore 'valid'.
Just because it can be set in the BMS doesn't mean it is a sensible value though.

This project relies heavily on values set in the BMS settings - we can't work around situations like this. You need to set the BMS correctly in the first place.
Well - there is an error somewhere between ESP and JK as i know i set it correctly - i have screenshots
 
o.k this is what set on the JK
View attachment 201453
Set the 'discharge_knee_v' to 3.5 in your YAML, and it will work as expected now that you have set UVPR to 3.1v.

I'm glad we're understanding what went wrong, but I'm frustrated that you were quick to blame the code - these batteries are not toys (especially the li-ion cells you have) and incorrect BMS settings could lead to a dangerous fault condition.

You should always:
- Ensure the hardware is correctly and safely set up. Connections, wiring, etc, must always be safe.
- Ensure the BMS is correctly configured for your battery chemistry.
- Only then can you utilise a project like the JK-BMS to ESP32 correctly.
 
One last point @chaosnature, I think I have mentioned this before to you. You are starting balancing at 3.0v, this means you are essentially middle-balancing your cells.

I would recommend setting the balance start voltage to 3.9v, perhaps 3.8v if you prefer. That way you will be top balancing your pack, the preferred approach for house batteries.
 
That value can be set in the JK BMS - UPVR of 4.00v is higher than the 3.33v you set for UVP, therefore 'valid'.
Just because it can be set in the BMS doesn't mean it is a sensible value though.

This project relies heavily on values set in the BMS settings - we can't work around situations like this. You need to set the BMS correctly in the first place.
That value can be set in the JK BMS - UPVR of 4.00v is higher than the 3.33v you set for UVP, therefore 'valid'
You cannot set
One last point @chaosnature, I think I have mentioned this before to you. You are starting balancing at 3.0v, this means you are essentially middle-balancing your cells.

I would recommend setting the balance start voltage to 3.9v, perhaps 3.8v if you prefer. That way you will be top balancing your pack, the preferred approach for house batteries.
Setting to 3.8 now

I didn't understand the logic of top balancing, in my situation where no comms between the both BMS when the voltage drops below 3.8 v for example and voltage is being sucked out of the Batt-2 what will keep the cells balanced at below 3.8 ot 4 v?

will that not damage the cells as we have to wait for it to get to 3.8 /4v before balancing?
the cells closest to the exit logically will drain faster and therefore can be very low while the others are higher until charged to that 3.8/4v again

makes sense?
 
Have to say that version 1.17.3 is working perfectly for my EG4 6000xp (LFP Battery Type 2). Charging slowly at the moment for additional testing/calibration readings. Forgot the charge limit can only be updated by reflashing so will need to edit the config and update again.
Well scratch that update. Seems the ESP is rebooting or something about every 22 minutes. Ran for hours without issue. Get comms failure with battery, no data to HA, and the website on the ESP itself is not available for about 7 minutes.

All charging and discharging stops when this occurs.
 
Last edited:
Set the 'discharge_knee_v' to 3.5 in your YAML, and it will work as expected now that you have set UVPR to 3.1v.

I'm glad we're understanding what went wrong, but I'm frustrated that you were quick to blame the code - these batteries are not toys (especially the li-ion cells you have) and incorrect BMS settings could lead to a dangerous fault condition.

You should always:
- Ensure the hardware is correctly and safely set up. Connections, wiring, etc, must always be safe.
- Ensure the BMS is correctly configured for your battery chemistry.
- Only then can you utilise a project like the JK-BMS to ESP32 correctly.
I'm glad we're understanding what went wrong, but I'm frustrated that you were quick to blame the code - these batteries are not toys (especially the li-ion cells you have) and incorrect BMS settings could lead to a dangerous fault condition.

Also - I was not quick to blame the code and I don't do blame (as I know you guys did an intelligent hard work coming up with this solution) i initially stated it might have been something i touched at the start of logging my issues refer back to the beginning.

why would i blame the code when i have not a clue how to write simple arguments like you guys do.

i understand your frustration, but these things happen and yes i am very safe - i do think through my decisions both on paper and in my head multple times before i move to implementation.
 
One last point @chaosnature, I think I have mentioned this before to you. You are starting balancing at 3.0v, this means you are essentially middle-balancing your cells.

I would recommend setting the balance start voltage to 3.9v, perhaps 3.8v if you prefer. That way you will be top balancing your pack, the preferred approach for house batteries.
Furthermore - Based on my above concept if the cells are uneven below 3.8 v according to the little I understand about how the system works it will use the lowest cells as the source of truth during the UVP and the UVPR operations...
 
Can someone do a recommend settings for both main battery technology types - I think it should be part of the release as there will be many who are not well learnant on this topic and it might help them - that is if the objective of this project is to get ppl to use the DIY solution without too much technical background.

just a thought - dont bite my head off!!
 
Can someone do a recommend settings for both main battery technology types - I think it should be part of the release as there will be many who are not well learnant on this topic and it might help them - that is if the objective of this project is to get ppl to use the DIY solution without too much technical background.

just a thought - dont bite my head off!!
hey there, i´m personally an LFP Guy and could provide screenshots of my settings.
But could not give any advice for Li-Ion chemistry at all.

On a second thought, i don't want to recommend any settings to anybody who has a DIY Build battery - cause that person should know what he is doing before setting up the battery and connecting any BMS, Inverter or ESP Project.
That is my personal opinion and i must agree to MrPablos comment - especially with Li-Ion Cells you really have to be very careful not ending up in a total mess or worst...

there are dozens of very good and detailed informations on how to safely build a DIY Battery (youtube, here in the forum, blogs and so on). I don't see it as part of our project to give advice how to use lithium DIY Batteries.
If someone is not willing to learn the basics on the chemistry and how to build and use a DYI battery, i would highly recommend a prebuild battery pack instead

hope for your understanding
 
Last edited:
Well scratch that update. Seems the ESP is rebooting or something about every 22 minutes. Ran for hours without issue. Get comms failure with battery, no data to HA, and the website on the ESP itself is not available for about 7 minutes.

All charging and discharging stops when this occurs.
Ok, 1.17.3 definitely is not working. ESP M5Stack keeps rebooting. Pulled it off the system for now.
 
Along side, human readable time is now only getting up to about 42 seconds in HA.
 
It's definitely feasible, do you have any good reference for C-rate vs temp?
I use EVE LF304 cells, with rates as below:
View attachment 201484View attachment 201483
I didn't realize *that* much derating is required :oops: ...

Based on @upnorthandpersonal analysis I thought that no derating (at very low temperatures !) was even necessary, since you'd just need an extreme voltage to be able to push that current.

In my case batteries were sitting at around 10-20 °C this winter and charging up to 100A (280Ah). So *barely* within limits :oops: ...

Each battery in my system is sized (breakers, cables, ...) for 100A RMS only. So you could say that the margin is "built in" in my case (unless I try to charge below 0°C, but BMS won't let me do that).
 

diy solar

diy solar
Back
Top