Cruisers Forum
 


Reply
  This discussion is proudly sponsored by:
Please support our sponsors and let them know you heard about their products on Cruisers Forums. Advertise Here
 
Thread Tools Search this Thread Rate Thread Display Modes
Old 28-09-2022, 08:15   #16
Nearly an old salt
 
goboatingnow's Avatar

Join Date: Jun 2009
Location: Lefkas Marina ,Greece
Boat: Bavaria 36
Posts: 22,801
Images: 3
Build your own BMS

Quote:
Originally Posted by s/v Jedi View Post
A BMS doesn’t require a powerful microcontroller but things like CanBus, Bluetooth and wifi are only available on the powerful units. I like the Teensy with on board CANbus. I also like the new Arduino MKR 1010 with the Arm Cortex. You simply build a website as front-end for the BMS.



But none of that is needed, all it needs to do is monitor and protect the battery. The more invisible the better


We can agree to disagree , esp32 is cheaper then Ardunio. The new ones are now RISC V based which is really powerful , on board CAN wifi and BLE. Plus full Ardunio ide support

The key to diy is decent setup tools. Also your BMS needs to integrate into ship wide monitoring systems this means CAN , wifi or Bluetooth. These days all of them.

Again your view is not an absolute truth merely an interpretation. I think a bms should be very “ visible “ ( and so does most of the industry )
__________________
Interested in smart boat technology, networking and all things tech
goboatingnow is offline   Reply With Quote
Old 28-09-2022, 08:32   #17
always in motion is the future
 
s/v Jedi's Avatar

Cruisers Forum Supporter

Join Date: Feb 2009
Location: in paradise
Boat: Sundeer 64
Posts: 19,323
Re: Build your own BMS

Quote:
Originally Posted by goboatingnow View Post
We can agree to disagree , esp32 is cheaper then Ardunio. The new ones are now RISC V based which is really powerful , on board CAN wifi and BLE. Plus full Ardunio ide support

The key to diy is decent setup tools. Also your BMS needs to integrate into ship wide monitoring systems this means CAN , wifi or Bluetooth. These days all of them.

Again your view is not an absolute truth merely an interpretation. I think a bms should be very “ visible “ ( and so does most of the industry )
Where is the disagreement? Just because I call it Arduino, doesn’t mean it’s something like a Teensy. I think Teensy had CANbus before esp did? Cheaper? We’re talking about a handful of dollars.

How visible is the BMS inside your phone, iPad, laptop etc.? Do you really need to see individual cell voltages on your breaker panel? You think the majority wants that or maybe see nothing as long as everything is okay? I like my display off until a key is pressed or an alert triggers.
Also, html based front end is okay, most apps do that anyway.
__________________
“It’s a trap!” - Admiral Ackbar.

s/v Jedi is offline   Reply With Quote
Old 28-09-2022, 08:48   #18
Nearly an old salt
 
goboatingnow's Avatar

Join Date: Jun 2009
Location: Lefkas Marina ,Greece
Boat: Bavaria 36
Posts: 22,801
Images: 3
Re: Build your own BMS

Quote:
Originally Posted by s/v Jedi View Post
Where is the disagreement? Just because I call it Arduino, doesn’t mean it’s something like a Teensy. I think Teensy had CANbus before esp did? Cheaper? We’re talking about a handful of dollars.



How visible is the BMS inside your phone, iPad, laptop etc.? Do you really need to see individual cell voltages on your breaker panel? You think the majority wants that or maybe see nothing as long as everything is okay? I like my display off until a key is pressed or an alert triggers.

Also, html based front end is okay, most apps do that anyway.


Personally the ESP series is ideal , you can choose other wise

Yes I want 1000% visibility , cell by cell , balancing progress , cell temp , warnings and Alarms , local status panel ,remote monitoring , sms or even Apple alert capability.

I want the whole thing on nmea2000 ( VE.CAN) as well.

The basic bms function is trivially simple in reality. The complexity is in remote management etc.
__________________
Interested in smart boat technology, networking and all things tech
goboatingnow is offline   Reply With Quote
Old 28-09-2022, 10:27   #19
always in motion is the future
 
s/v Jedi's Avatar

Cruisers Forum Supporter

Join Date: Feb 2009
Location: in paradise
Boat: Sundeer 64
Posts: 19,323
Re: Build your own BMS

Quote:
Originally Posted by goboatingnow View Post
Personally the ESP series is ideal , you can choose other wise

Yes I want 1000% visibility , cell by cell , balancing progress , cell temp , warnings and Alarms , local status panel ,remote monitoring , sms or even Apple alert capability.

I want the whole thing on nmea2000 ( VE.CAN) as well.

The basic bms function is trivially simple in reality. The complexity is in remote management etc.
If I want to see that, I’ll press a button or click an icon on my phone, I don’t need a video wall with gauges showing my battery is working
__________________
“It’s a trap!” - Admiral Ackbar.

s/v Jedi is offline   Reply With Quote
Old 28-09-2022, 11:33   #20
Nearly an old salt
 
goboatingnow's Avatar

Join Date: Jun 2009
Location: Lefkas Marina ,Greece
Boat: Bavaria 36
Posts: 22,801
Images: 3
Re: Build your own BMS

Quote:
Originally Posted by s/v Jedi View Post
If I want to see that, I’ll press a button or click an icon on my phone, I don’t need a video wall with gauges showing my battery is working


Indeed that’s the beauty of the platform I mentioned as it has all that connectivity.

Anyway no point designing a run of the mill bms you can buy those for peanuts. What you do is build one to suit your own peccadilloes.
__________________
Interested in smart boat technology, networking and all things tech
goboatingnow is offline   Reply With Quote
Old 28-09-2022, 12:12   #21
always in motion is the future
 
s/v Jedi's Avatar

Cruisers Forum Supporter

Join Date: Feb 2009
Location: in paradise
Boat: Sundeer 64
Posts: 19,323
Re: Build your own BMS

About the BlueSea Systems RBS switch. We use the model 7702 which is a 24V, pulse operated version. This is by far the best option if you can program your own BMS.

How it works: it reacts to two control signals: switch ON and switch OFF. Each of those signals is a +24V voltage. The switch also provides a feedback signal, showing if the state is ON or OFF and it does so by grounding this wire when it is ON.

So how to drive and program this: first the feedback wire: we can connect this directly to a digital input pin of the microcontroller and either program a pull-up resistor when the controller supports that, or solder a physical resistor between this pin and vcc of the controller. Whenever this pin reads low, the switch is on and when it reads high, the switch is off.

That’s the easy part, now for the switching itself. Here we use two digital pins as output, one for switching ON and the other for OFF. This is where it gets difficult: the RBS wants to see a positive voltage on these conductors, meaning that we must switch on the high side, switching the +24V. Normally we want to switch the low side, i.e. the negative. While we only need to switch this momentarily, we must expect a current of unknown number, but expected to be below 100mA.

I don’t like this much, because whatever happens to this voltage we send out, may well damage our BMS. This is why I like to use a small relay for this. Now we only have to power the coil of the relay, of which we know exactly how much current we need and we can do it on the low side, which is much easier. For this I use one small transistor, a diode and a resistor.
Now you present two relay contacts which can be connected in parallel to the remote switch contacts that come with the RBS.

Which brings us to the software routines for switching. This is easy, for switching on you do:

while switch is OFF and (not timeout) {send switch-on signal}

You get the idea.

I am currently using a 2N2222 transistor which is fine, but relays I had at hand which are ridiculously large, so I’ll be selecting new components for the final design. The diode is to eliminate the flyback from the relay, so a 1N4007 is perfect.

https://www.bluesea.com/products/770..._-_24V_DC_500A
__________________
“It’s a trap!” - Admiral Ackbar.

s/v Jedi is offline   Reply With Quote
Old 28-09-2022, 14:33   #22
always in motion is the future
 
s/v Jedi's Avatar

Cruisers Forum Supporter

Join Date: Feb 2009
Location: in paradise
Boat: Sundeer 64
Posts: 19,323
Re: Build your own BMS

One thing I completely forgot and one thing I just found out:

- there is this very nice solid state relay that does exactly what we want: it has an opto-isolated input that will work on 3V and it is way strong enough to do what we want… the only problem is the price, these are $16 each…. still an option because they are really good: https://www.amazon.com/Kyoto-Electri.../dp/B00B888WVC
I tested this and it works 100%

Then I also found you can now buy relay modules for 3V. When I was prototyping, only 5V versions were available, so this is great as these also have opto isolation and the only difference is that they use more power, but still okay for direct drive from a microcontroller I think: https://www.amazon.com/Channel-Optoc...dp/B07XGZSYJV/
__________________
“It’s a trap!” - Admiral Ackbar.

s/v Jedi is offline   Reply With Quote
Old 28-09-2022, 16:33   #23
Registered User

Join Date: Mar 2016
Location: San Francisco
Boat: Morgan 382
Posts: 3,191
Re: Build your own BMS

Quote:
Originally Posted by goboatingnow View Post
Microcontroller is a much better job.
No doubt. The concern is that microprocessors sometimes crash. The $5 worth of other parts was only as a failsafe incase that happened, not as primary protection.

Maybe it's not needed, idk.
__________________
-Warren
wholybee is online now   Reply With Quote
Old 28-09-2022, 17:34   #24
always in motion is the future
 
s/v Jedi's Avatar

Cruisers Forum Supporter

Join Date: Feb 2009
Location: in paradise
Boat: Sundeer 64
Posts: 19,323
Re: Build your own BMS

Quote:
Originally Posted by wholybee View Post
No doubt. The concern is that microprocessors sometimes crash. The $5 worth of other parts was only as a failsafe incase that happened, not as primary protection.

Maybe it's not needed, idk.
These are not microprocessors, they don’t run an OS: they are microcontrollers, which are in everything, even your car keys.
__________________
“It’s a trap!” - Admiral Ackbar.

s/v Jedi is offline   Reply With Quote
Old 28-09-2022, 18:55   #25
Registered User

Join Date: Mar 2016
Location: New England. USA.
Boat: McCurdy & Rhodes Custom 46
Posts: 1,481
Build your own BMS

Microcontrollers ARE everywhere. Some are tiny, as in your digital watch or your car key. Some are bigger and more complex.

Microcontrollers run code. Code has bugs. Code crashes.

Microcontrollers sometimes run operating systems too.

When I was programming microcontrollers most of them had little memory. No operating system as there was no room for that.
Now it’s not hard to find microcontrollers with 512 meg of flash and 256meg of ram. They are more powerful than a pc-xt, an early IBM pc.

So microcontroller can crash. If you use a small code base that is well validated and verified you can have a fairly reliable system. See your watch and your car key. And the compass and other displays in your 2000s era car. But it takes effort.

Circuitry can have issues too. What happens when inputs exceed design parameters? What happens when you hit transmit on your SSB or VHF? When you hook up the system in reverse? That takes effort too.

I’m NOT poo pooing this project. Just saying protect all your inputs and outputs and spend quality time with your code.
dfelsent is offline   Reply With Quote
Old 28-09-2022, 19:08   #26
always in motion is the future
 
s/v Jedi's Avatar

Cruisers Forum Supporter

Join Date: Feb 2009
Location: in paradise
Boat: Sundeer 64
Posts: 19,323
Re: Build your own BMS

Quote:
Originally Posted by dfelsent View Post
Microcontrollers ARE everywhere. Some are tiny, as in your digital watch or your car key. Some are bigger and more complex.

Microcontrollers run code. Code has bugs. Code crashes.

Microcontrollers sometimes run operating systems too.

When I was programming microcontrollers most of them had little memory. No operating system as there was no room for that.
Now it’s not hard to find microcontrollers with 512 meg of flash and 256meg of ram. They are more powerful than a pc-xt, an early IBM pc.

So microcontroller can crash. If you use a small code base that is well validated and verified you can have a fairly reliable system. See your watch and your car key. And the compass and other displays in your 2000s era car. But it takes effort.

Circuitry can have issues too. What happens when inputs exceed design parameters? What happens when you hit transmit on your SSB or VHF? When you hook up the system in reverse? That takes effort too.

I’m NOT poo pooing this project. Just saying protect all your inputs and outputs and spend quality time with your code.
Okay, please name me the BMS’s that don’t have a microcontroller. Let’s start there.
__________________
“It’s a trap!” - Admiral Ackbar.

s/v Jedi is offline   Reply With Quote
Old 28-09-2022, 19:12   #27
always in motion is the future
 
s/v Jedi's Avatar

Cruisers Forum Supporter

Join Date: Feb 2009
Location: in paradise
Boat: Sundeer 64
Posts: 19,323
Re: Build your own BMS

Quote:
Originally Posted by rgleason View Post
I am interested in this project and will be following it. Thanks for sharing.
I believe I read somewhere that you were interested in building a BMS that supports CANbus for integration. This isn’t too difficult: the hardware is mainstream and I find protocol descriptions online:
Attached Files
File Type: pdf 6411-Canbus-v4.pdf (207.8 KB, 53 views)
__________________
“It’s a trap!” - Admiral Ackbar.

s/v Jedi is offline   Reply With Quote
Old 28-09-2022, 19:42   #28
Registered User

Join Date: Mar 2016
Location: San Francisco
Boat: Morgan 382
Posts: 3,191
Re: Build your own BMS

Quote:
Originally Posted by s/v Jedi View Post
Okay, please name me the BMS’s that don’t have a microcontroller. Let’s start there.
https://www.amazon.com/diymore-Prote...1_11_sspa?th=1

It's a cheap one, but illustrates a BMS without a microcontroller. They are quite common for smaller batteries. I would guess the cheapest of the drop in batteries use something similar.

I'm not advocating building a BMS without a microcontroller though, just to add a failsafe in the design that doesn't rely on the microcontroller. If the consensus is that a failsafe isn't needed, I'll probably skip it.
__________________
-Warren
wholybee is online now   Reply With Quote
Old 28-09-2022, 19:49   #29
always in motion is the future
 
s/v Jedi's Avatar

Cruisers Forum Supporter

Join Date: Feb 2009
Location: in paradise
Boat: Sundeer 64
Posts: 19,323
Re: Build your own BMS

Quote:
Originally Posted by wholybee View Post
https://www.amazon.com/diymore-Prote...1_11_sspa?th=1

It's a cheap one, but illustrates a BMS without a microcontroller. They are quite common for smaller batteries. I would guess the cheapest of the drop in batteries use something similar.

I'm not advocating building a BMS without a microcontroller though, just to add a failsafe in the design that doesn't rely on the microcontroller. If the consensus is that a failsafe isn't needed, I'll probably skip it.
That is not for lfp… it is a lipo charger/balancer for an electric drill.

This thread is for lfp house batteries on a boat.
__________________
“It’s a trap!” - Admiral Ackbar.

s/v Jedi is offline   Reply With Quote
Old 28-09-2022, 19:57   #30
always in motion is the future
 
s/v Jedi's Avatar

Cruisers Forum Supporter

Join Date: Feb 2009
Location: in paradise
Boat: Sundeer 64
Posts: 19,323
Re: Build your own BMS

INA226 addressing for I2C bus.

The INA226 modules have the A0 and A1 address pins connected to solder pads and pull down resistors. A vcc solder pad is at hand for easy connections with a drop of solder, but it seems this only allows 4 addresses: 00, 01, 10 and 11. But we need 8 modules!

You can actually connect 16 modules to one I2C bus. They use a trick where you can also use the SDA and SCL pins of the I2C bus to connect to the A0 and A1 pins! No neat solder pads for these so little wire jumpers are required.

The attachment shows exactly how to use this
Attached Thumbnails
Click image for larger version

Name:	46F2084A-7470-458A-9265-BAF9603FE434.jpg
Views:	83
Size:	410.3 KB
ID:	265106  
__________________
“It’s a trap!” - Admiral Ackbar.

s/v Jedi is offline   Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Replacing a drop in batteries BMS with your own alctel Lithium Power Systems 23 29-06-2022 07:50
Do you have to be up for your own maintenance and repairs to sensibly own a sailboat Rblakenyc General Sailing Forum 68 31-01-2021 16:42
Yet another LFP and BMS build tanglewood Lithium Power Systems 0 19-11-2018 07:40
LiFe(Y)PO4 BMS Dessign - good reading for DIY BMS developers CatNewBee Lithium Power Systems 10 20-09-2018 00:15
Did you build your own compost toilet? Are you using it successfully on your boat? magentawave Liveaboard's Forum 9 28-06-2013 12:36

Advertise Here


All times are GMT -7. The time now is 16:26.


Google+
Powered by vBulletin® Version 3.8.8 Beta 1
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Social Knowledge Networks
Powered by vBulletin® Version 3.8.8 Beta 1
Copyright ©2000 - 2024, vBulletin Solutions, Inc.

ShowCase vBulletin Plugins by Drive Thru Online, Inc.