Monitoring the Bateries

Perhaps the most important battery measurement is its state of charge.  It can be inferred by the resting state voltage reading of the batteries, but more precise would be to track the amps as they move in and out of the bank. The most reliable way to do this is with a shunt. A shunt is a very small value, precision resistor that is capable of carrying high current loads.  Ohm’s law allows us to compute the current flowing through the circuit if we know the voltage drop across the shunt (typically less than .1 volt at 500 amps!).  Logged regular measurements can be used to calculate a very accurate approximation of the battery bank’s state of charge, assuming the measurements are close enough, say 50-100 milliseconds apart.

Risa’s inverter/charger had such a system, but unfortunately, it was a closed system and did not provide any way to read this information digitally, so it was only available by looking at a readout after pressing some buttons.  I wanted to be able to monitor this automatically and remotely!

It was my intention to add a high precision analogue to digital input to the raspberry pi and do successive readings and computing the SOC myself using the shunt that was being used by the existing display.  Unfortunately, I could not find any such add-ons that would allow me to measure the negative voltage that would exist while charging. 

I decided that the most expeditious path would be to add a battery monitor that I could read the information from.  I purchased a Victron Battery Monitor.  It provides this information on a can bus.  The protocol is published and will be easy to implement.  I was very impressed with Victron as they encourage and even assist development of open source projects around their hardware.