Skip to content
View in the app

A better way to browse. Learn more.

Power Forum - Renewable Energy Discussion

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

JK BMS with DIY Battery and comms

Featured Replies

Anyone using any sort of comms hack from their JK BMS to their inverter?

There are a few projects out there but most of them are not free.

I found this opensource solution and am busy setting it up to test.

https://github.com/ArminJo/JK-BMSToPylontechCAN

Bought all the bits and pieces yesterday from communica.
Completed the hardware assembly/setup and loaded the software and it works great out the box in demo mode.
Will change the can board crystal today and then connect it to my JK BMS for initial test to see if it pulls the data correctly.
If that goes well then I will connect it to my Sunsynk and see what happens 🙃

 

  • Replies 57
  • Views 19k
  • Created
  • Last Reply

Top Posters In This Topic

Most Popular Posts

  • Very nice.  I see Andy is testing a neat little CAN device for the JK bms

  • WannabeSolarSparky
    WannabeSolarSparky

    Yeah, I watched that too That is a very neat project which is great for the DIY community, but unfortunately they have not open-sourced it and buying those modules from Aussie land is a bit of a s

  • WannabeSolarSparky
    WannabeSolarSparky

    Finally got around to start testing this jk bms comms project. Circled part in red is with the new comms to inverter running. It has settled down nicely now ready to run through the night an

Posted Images

  • Author
32 minutes ago, Chris_S said:

Very nice. 

I see Andy is testing a neat little CAN device for the JK bms

Yeah, I watched that too :)
That is a very neat project which is great for the DIY community, but unfortunately they have not open-sourced it :( and buying those modules from Aussie land is a bit of a schlepp.

They based it on some of the work done on this github project I am testing, so maybe I will give it a shot too and port it over to esp32 with some modbus comms to allow multiple batteries.
Baby steps though, 1st need to make sure it is working nicely on my setup using the default code and hardware.

I tested that one a month ago and moved further with that already. I have injected with new can id for providing data to the inverter (0x373): max/min cell voltage. Still struggling to find what ID shall be for the charging cycle as shown on the inverter data that battery with Mod-Bus connection can communicate. I also discovered that there is also a can Id of 0x405 captured during my sniffing of can bus between the battery and the inverter. 

[Additional data captured by the inverter - LUXpower, sill CycleCount missing)

image.png.225cc39f8ee548e552c9b2d73830a4a5.png

Relaxed charging worked from 80% of SOC with gradual reduction of charging voltage

image.png.6877688c6287bb4e02f449ecd2d0d80f.pngimage.png.5cb0cc96d0d79e906bfd78d99aaab46c.png

Also, I modified a bit on charging scheme when the SOC reach 80% the inverter will start to reduce charging voltage gradually to float voltage (Voltage at SOC 100%). However, I found out that JK BMS SOC calculation is inaccurate. As the result the inverter working incorrectly as well.

On some older JKBMS, there were not anything named as SOC at 100% and SOC at 0% in the mobile Bluetooth App so it is a real hard time for making the BMS to estimate the SOC correctly.

Anyone have hint on how to make the BMS to do this SOC calculation better?

In the mean time, I am thinking of an alternative so that:

+ SOC announced by JK will be omitted. The arduino nano will calculate the SOC using voltage using the range from 3.2-3.4 V (3.2=0% and 3.4 = 100%). This is also the safe range to prolong battery life. 

+ At 80% of the recalculated SOC (if charging), Nano will tell the inverter to stop charging shortly every 5 minutes to wait for cell voltage to stable and remap the recalculated SOC. Similar option will be applied for the 0-20% SOC at discharging. This thing will have the SOC closely linked to the actually SOC of the battery and make the Inverter work correctly.

+ Nano will inform the inverter via CAN using this SOC.

+ All non-neccessary data will be skipped such as alarm, SOH ...etc.

How do you think about this option?

Ngoc - from Vietnam

Edited by Ngoc

  • Author

Finally got around to start testing this jk bms comms project.

Circled part in red is with the new comms to inverter running.

It has settled down nicely now ready to run through the night and tomorrow daytime.
So far it is behaving as expected and controlling the inverter nicely.

image.thumb.png.414cd76ceb5e46b24fc05639c4cf57ce.png

2 hours ago, WannabeSolarSparky said:

Finally got around to start testing this jk bms comms project.

Circled part in red is with the new comms to inverter running.

It has settled down nicely now ready to run through the night and tomorrow daytime.
So far it is behaving as expected and controlling the inverter nicely.

image.thumb.png.414cd76ceb5e46b24fc05639c4cf57ce.png

Nice work i like 👌

Edited by TaliaB

  • Author
1 minute ago, TaliaB said:

Nice work i like 👆 

Thanks @TaliaB it is a nice little project, and if my testing inspires other diy folk to give it a bash then that's a bonus.

I had a small glitch when I hooked it up this afternoon.
I have been using voltage settings ever since I installed my sunsynk and totally forgot that if I change to Li comms it would change my work modes to % 🤪

I had to go reconfigure all my work mode settings, but again, everything still working perfectly 🙃

Next I will see if I can do some photos of the hardware I put together for this testing...

And if all the testing goes well I will put together a prototype of the final hardware setup to make it a more permanent setup.

  • Author

Special shout out to ArminJo for the code and and clear instructions on how to put this all together.
https://github.com/ArminJo/JK-BMSToPylontechCAN

And @Ngoc for the idea for the protoype :)

And for the clever electronics folk here on the forum, let me know if I am on the right track 🙃

 

jkbms-can-coms-rev101-circuit-view.jpg

  • Author

3 days now with out any issues.
It feels like I have more solar available in the mornings now as the charge algorithm sent to the inverter throttles down the amps the closer the battery gets to full.
I will have to do some capacity tests to check that.

image.thumb.png.6de576a12f9fbe2c08c9bf1f1db007d8.png

1 hour ago, WannabeSolarSparky said:

charge algorithm sent to the inverter throttles down the amps

Probably not, since the cells themselves would allow less current to flow the closer they're getting to being full...

Anyway, dude, I need some info from you, I'll be needing to setup something similar, I now have a JK B1A20S15P with 16 cells connected and would need to make up a translation interface to get data from the JK and give dope to the Sunsynk 5k...

The serial comms cable from the BMS plugs into the GPS port, I guess, is this connector with some wires attached available locally? (probably not locally to me, but maybe around the Cape Town area)

 

  • Author
14 minutes ago, Kalahari Meerkat said:

Probably not, since the cells themselves would allow less current to flow the closer they're getting to being full...

Anyway, dude, I need some info from you, I'll be needing to setup something similar, I now have a JK B1A20S15P with 16 cells connected and would need to make up a translation interface to get data from the JK and give dope to the Sunsynk 5k...

The serial comms cable from the BMS plugs into the GPS port, I guess, is this connector with some wires attached available locally? (probably not locally to me, but maybe around the Cape Town area)

 

https://www.communica.co.za/products/hkd-micro-jst-1-25mm-4pfem-15cm?variant=44762822902060

I have not gone to communica yet to see if that is the correct one...

Edited by WannabeSolarSparky

  • Author
15 minutes ago, Kalahari Meerkat said:

Probably not, since the cells themselves would allow less current to flow the closer they're getting to being full...

Anyway, dude, I need some info from you, I'll be needing to setup something similar, I now have a JK B1A20S15P with 16 cells connected and would need to make up a translation interface to get data from the JK and give dope to the Sunsynk 5k...

The serial comms cable from the BMS plugs into the GPS port, I guess, is this connector with some wires attached available locally? (probably not locally to me, but maybe around the Cape Town area)

 

Give this project a try it works perfectly and you can set it to your battery's number of cells.
 

/*
 * Software serial for JK-BMS stuff
 */
#if !defined(MAXIMUM_NUMBER_OF_CELLS)
#define MAXIMUM_NUMBER_OF_CELLS     24 // Maximum number of cell info which can be converted. Must be before #include "JK-BMS.hpp".
#endif
#include "JK-BMS.hpp"

 

  • Author
25 minutes ago, Kalahari Meerkat said:

Probably not, since the cells themselves would allow less current to flow the closer they're getting to being full...

Yeah, I checked and the same amount of amps went into the batteries as before. Just my graphs now look slightly different. I am so used to what my graphs looked like before when I used voltage settings 🙃

2 minutes ago, WannabeSolarSparky said:

Final prototype ready to send to jlcpcb to fabricate.

How about using the Vbatt from the JK connection and a switch mode module to not require an external power source? One of these may be a good option... then I may ask you to have a few more boards made... I'd probably want 3 or 4 of them...

 

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.