Open source battery monitoring system (BMS) with a difference
karrak
Solar Expert Posts: 326 ✭✭✭✭
I have made available the design information and software I have used to make a low cost ($100-150) flexible battery monitoring system using the Beaglebone Linux single board computer. The project can be found here https://github.com/simat/BatteryMonitor.git
Rather than design a purpose built board I have gone for the very capable Beaglebone and added a simple battery interface comprising a resistor divider network and a few multichannel 16 bit A/D chips to convert the battery cell voltages to a digital signal, this gives a resolution of around 1mV for a 24 volt battery bank. Battery current can also be monitored with the addition of a shunt and two small resistors.
The project does not require special soldering skills and could be bread-boarded except for soldering a connector on to a A/D PCB that is available if you don't want to solder the A/D chip with its 0.5mm pin spacing.
The only word of WARNING I have is that anyone who is not aware of the dangers of connecting up wiring to high power battery banks should not do it!
Currently the program just logs to files, but it would be easy to extend this to generating web-pages for display over the internet. It is also a fairly trivial exercise to have the Beagleboard produce alarms to drive safety relays or maybe even send texts to your mobile phone.
My primary use of this device is to monitor my LiFePO4 battery bank and provide me with information via the internet on the battery state when I am away from home, and also log the battery data over a long period of time so I can see how good or bad these batteries really are over time. It is more than likely that this project will develop into a full power management system.
I have had this up and running for a little while and found it to be very useful, hopefully it will be useful to others.
Here is the running summary file Attachment not found. and daily summary file Attachment not found. produced from the program, the circuit diagram of what I built Attachment not found. and some photos
Attachment not found.Attachment not found.
Rather than design a purpose built board I have gone for the very capable Beaglebone and added a simple battery interface comprising a resistor divider network and a few multichannel 16 bit A/D chips to convert the battery cell voltages to a digital signal, this gives a resolution of around 1mV for a 24 volt battery bank. Battery current can also be monitored with the addition of a shunt and two small resistors.
The project does not require special soldering skills and could be bread-boarded except for soldering a connector on to a A/D PCB that is available if you don't want to solder the A/D chip with its 0.5mm pin spacing.
The only word of WARNING I have is that anyone who is not aware of the dangers of connecting up wiring to high power battery banks should not do it!
Currently the program just logs to files, but it would be easy to extend this to generating web-pages for display over the internet. It is also a fairly trivial exercise to have the Beagleboard produce alarms to drive safety relays or maybe even send texts to your mobile phone.
My primary use of this device is to monitor my LiFePO4 battery bank and provide me with information via the internet on the battery state when I am away from home, and also log the battery data over a long period of time so I can see how good or bad these batteries really are over time. It is more than likely that this project will develop into a full power management system.
I have had this up and running for a little while and found it to be very useful, hopefully it will be useful to others.
Here is the running summary file Attachment not found. and daily summary file Attachment not found. produced from the program, the circuit diagram of what I built Attachment not found. and some photos
Attachment not found.Attachment not found.
Off-Grid with LFP (LiFePO4) battery, battery Installed April 2013
32x90Ah Winston cells 2p16s (48V), MPP Solar PIP5048MS 5kW Inverter/80A MPPT controller/60A charger, 1900W of Solar Panels
modified BMS based on TI bq769x0 cell monitors.
Homemade overall system monitoring and power management https://github.com/simat/BatteryMonitor
32x90Ah Winston cells 2p16s (48V), MPP Solar PIP5048MS 5kW Inverter/80A MPPT controller/60A charger, 1900W of Solar Panels
modified BMS based on TI bq769x0 cell monitors.
Homemade overall system monitoring and power management https://github.com/simat/BatteryMonitor
Comments
-
Re: Open source battery monitoring system (BMS) with a difference
Wow! Thanks for sharing. And writing it in Python!
... Linux 3.2.0-4-686-pae #1 SMP Debian 3.2.60-1+deb7u3 i686 GNU/Linux -
Re: Open source battery monitoring system (BMS) with a differencePNjunction wrote: »Wow! Thanks for sharing. And writing it in Python!
Thanks for the thumbs up. Hopefully my first attempt at writing in Python is decipherable! Your feedback would be appreciated.
My design days date from the time where every machine cycle and byte of memory was sacred. Getting used to the new regime of processors running at speeds in the GHz and having megabytes of memory takes a bit of getting used to. I am still amazed that a single board computer running a complex operating system can work well running a real time application. I must say that I am suffering from withdrawal writing in machine code and Forth.Off-Grid with LFP (LiFePO4) battery, battery Installed April 2013
32x90Ah Winston cells 2p16s (48V), MPP Solar PIP5048MS 5kW Inverter/80A MPPT controller/60A charger, 1900W of Solar Panels
modified BMS based on TI bq769x0 cell monitors.
Homemade overall system monitoring and power management https://github.com/simat/BatteryMonitor
-
Re: Open source battery monitoring system (BMS) with a difference
Youll no doubt know ive been working on something similar here:
http://code.google.com/p/theblackboxproject/
Ill take a look over yours when i get a moment and see if theres useful collaboration to be had.
Thanks!1.8kWp CSUN, 10kWh AGM, Midnite Classic 150, Outback VFX3024E,
http://zoneblue.org/cms/page.php?view=off-grid-solar -
Re: Open source battery monitoring system (BMS) with a differenceThanks for the thumbs up. Hopefully my first attempt at writing in Python is decipherable! Your feedback would be appreciated.
I won't be much help as my high-level language programming consisted mostly of shell script grep/sed/awk. I never did graduate to perl, or other high level languages. What is amazing is that what used to be run on a massive machine or really costly workstation I can now run on a thumbdrive. Knoppix typically. Still blows my mind. -
Re: Open source battery monitoring system (BMS) with a differenceYoull no doubt know ive been working on something similar here:
I was not aware that you were working on this. I have looked at your very good web page on your solar set-up but didn't look at any of the side links.
Looks like you have been working on the web integration side of things which is one area that I am interested in. I suppose the main difference between our approaches is that I am getting the data directly from the battery where you are integrating it from the other equipment.
Thanks for letting me know about your project, I will investigate further.Off-Grid with LFP (LiFePO4) battery, battery Installed April 2013
32x90Ah Winston cells 2p16s (48V), MPP Solar PIP5048MS 5kW Inverter/80A MPPT controller/60A charger, 1900W of Solar Panels
modified BMS based on TI bq769x0 cell monitors.
Homemade overall system monitoring and power management https://github.com/simat/BatteryMonitor
-
Re: Open source battery monitoring system (BMS) with a difference
Very cool! I've got a 'Roll Your Own' BMS but it uses embedded PIC controllers and C instead of a full blown Linux OS but can use data collected from Linux TCP/IP DAQ clients. -
Re: Open source battery monitoring system (BMS) with a differenceI was not aware that you were working on this. I have looked at your very good web page on your solar set-up but didn't look at any of the side links.
Theres a few people on the midnite forum who periodically throw some energy at blackbox, but its moving slowly.Looks like you have been working on the web integration side of things which is one area that I am interested in. I suppose the main difference between our approaches is that I am getting the data directly from the battery where you are integrating it from the other equipment.
Thanks for letting me know about your project, I will investigate further.
So far the focus has been on talking to RE gear, but the plan is to make something modular that could eventually talk to anything. The current thinking (for further prototype development) is to pair the ARM board with a atmel/arduino class device to manage sensors and radio links.
Various of us have put together our own systems, out of necessity, but i was hoping that we might some of us anyway work together to try to advance this project. In total theres quite a bit to it. My own priority is focused on tuning the linux os to better manage its flash storage life/ long term system stability. Theres another guy who is currently doing some work on the UI. And a pair of guys with an interest in the ADC/wireless sensors. But we all of us have time constraints.
I hope we can stay in touch and i also am studying your stuff. Looks nice with that precision ADC. A special interest of mine is to monitor insolation independently of controller throughout, so as to get a realtime measure of power available for oppurtunity loads.1.8kWp CSUN, 10kWh AGM, Midnite Classic 150, Outback VFX3024E,
http://zoneblue.org/cms/page.php?view=off-grid-solar -
Re: Open source battery monitoring system (BMS) with a difference
Hey Karrak
Thanks for doing this,
This is the same reason why I really started learning the whole bunch of Arduiono/RPI/ Beagle bone/Cubie truck.
Happy to see your opensourced system, I will take a look and see how hard it is for me to try yours and further help. -
Re: Open source battery monitoring system (BMS) with a differenceHey Karrak
Thanks for doing this,
This is the same reason why I really started learning the whole bunch of Arduiono/RPI/ Beagle bone/Cubie truck.
Happy to see your opensourced system, I will take a look and see how hard it is for me to try yours and further help.
Yes this is very interesting, thanks! we have an open source energy management platform focused on renewable energy called SolarNetwork:
https://github.com/SolarNetwork/solarnetwork/wiki/Developer-Guide
and we capture data from a number of different solar charge controllers, grid-connect inverters, industrial switches and can run on a Raspberry Pi, and other ARM based computers that run Debian or BSD and Java. We look forward to using the BeagleBone Black!
clearly there is a lot of potential in storing solar energy in LiFePO4 and releasing it judiciously.John Gorman / SolarNetwork Foundation
e:john@solarnetwork.net -
Re: Open source battery monitoring system (BMS) with a difference
Do you have a website or some higher level docs, quick start like? The docs appear extensive, but assume you know what the thing does.
Edit : its here: http://solarnetwork.net/
Ambitous!1.8kWp CSUN, 10kWh AGM, Midnite Classic 150, Outback VFX3024E,
http://zoneblue.org/cms/page.php?view=off-grid-solar -
Re: Open source battery monitoring system (BMS) with a differenceI hope we can stay in touch and i also am studying your stuff. Looks nice with that precision ADC. A special interest of mine is to monitor insolation independently of controller throughout, so as to get a realtime measure of power available for oppurtunity loads.
The ADC is working well, for the current monitoring I have two channels in differential mode hooked up to a 50mV, 200A shunt which if my calculations are correct gives a resolution of around 30mA, also works well for current in both directions.Off-Grid with LFP (LiFePO4) battery, battery Installed April 2013
32x90Ah Winston cells 2p16s (48V), MPP Solar PIP5048MS 5kW Inverter/80A MPPT controller/60A charger, 1900W of Solar Panels
modified BMS based on TI bq769x0 cell monitors.
Homemade overall system monitoring and power management https://github.com/simat/BatteryMonitor
-
Re: Open source battery monitoring system (BMS) with a difference
I have added some new features to the battery monitoring system- Configurable alarm outputs
- Extra information on battery current throughput and SOC
The following information is now logged- Minimum and maximum cell voltages and overall battery voltage with and without load
- Minimum and maximum difference in cell voltages with and without load
- Maximum charge and discharge current
- Maximum, minimum and average battery SOC
- Total charge and discharge current
SimonOff-Grid with LFP (LiFePO4) battery, battery Installed April 2013
32x90Ah Winston cells 2p16s (48V), MPP Solar PIP5048MS 5kW Inverter/80A MPPT controller/60A charger, 1900W of Solar Panels
modified BMS based on TI bq769x0 cell monitors.
Homemade overall system monitoring and power management https://github.com/simat/BatteryMonitor
-
Re: Open source battery monitoring system (BMS) with a differenceI have added some new features to the battery monitoring system
Cool. Looks like progress! keep going, there's a lot of great stuff to do with that data I'd say.John Gorman / SolarNetwork Foundation
e:john@solarnetwork.net -
Re: Open source battery monitoring system (BMS) with a difference
We'll have some updates and additions to this site soon...For a user, it's really easy to add new components to a SolarNode. You just boot up with the standard SD media, and navigate to the GUI interface just like a DSL router or modem with a browser - point and click. You need to associate the node with our cloud server application (SolarNet) but then you add a plugin repository, and you can add components like inverters, switches, charge controllers, etc. Do you have a Midnite Classic by the way? we'd love to support those with Modbus connectivity.John Gorman / SolarNetwork Foundation
e:john@solarnetwork.net -
Re: Open source battery monitoring system (BMS) with a difference
I do modus over ethernet with our classic, but you can also do it over serial, using the internal rj11s . There were some early teething pains with the controller firmware but thats settled down and works ok. You can read as fast as 100ms intervals if you want.1.8kWp CSUN, 10kWh AGM, Midnite Classic 150, Outback VFX3024E,
http://zoneblue.org/cms/page.php?view=off-grid-solar
Categories
- All Categories
- 222 Forum & Website
- 130 Solar Forum News and Announcements
- 1.3K Solar News, Reviews, & Product Announcements
- 190 Solar Information links & sources, event announcements
- 886 Solar Product Reviews & Opinions
- 254 Solar Skeptics, Hype, & Scams Corner
- 22.3K Solar Electric Power, Wind Power & Balance of System
- 3.5K General Solar Power Topics
- 6.7K Solar Beginners Corner
- 1K PV Installers Forum - NEC, Wiring, Installation
- 2K Advanced Solar Electric Technical Forum
- 5.5K Off Grid Solar & Battery Systems
- 424 Caravan, Recreational Vehicle, and Marine Power Systems
- 1.1K Grid Tie and Grid Interactive Systems
- 651 Solar Water Pumping
- 815 Wind Power Generation
- 621 Energy Use & Conservation
- 608 Discussion Forums/Café
- 302 In the Weeds--Member's Choice
- 74 Construction
- 124 New Battery Technologies
- 108 Old Battery Tech Discussions
- 3.8K Solar News - Automatic Feed
- 3.8K Solar Energy News RSS Feed