Monitoring a battery's voltage

Ira

Active Member
This evening, I noticed that the low battery indicator light on my standby genset was on. I don't know why yet, but that's not the reason for this thread. As far as I know, the low battery light could have come on as long ago as August 25 (last time the genset exercised), or it may have just come on. That got me to thinking about maybe somehow I can monitor the battery level and trigger an alarm if it goes too low.

The genset manual says the light will come on when the voltage drops below 12.2 VDC for more than a minute, or it drops below 8 VDC while the genset is running or below 6 VDC when the genset is cranking. So it would be really cool if I could mirror those events and trigger various actions based on whichever one occurs. I have a relay that tells me when the genset is running. I was thinking of tapping off the genset starter solenoid so I could tell when the genset is trying to crank. So what I need is a way to monitor the battery's voltage. It would also be good if I could log battery voltage samples so it could be graphed if needed.

I am in the beginning stages of HA. I have CQC but not installed. I will be buying an ELK M1G very soon. There will be a remote can with a zone input expander and an output expander very near the genset.

The genset battery is a typical 12 VDC auto battery (group 26). It is on a trickle charger.

Thanks,
Ira
 
Why not just tie into the Generator battery light.? A small relay to an input would seem to do the trick. Let the Generator logic do the work.

This is how I have done it on a commercial level except that most of the commercial generators I have worked on already have relays built in that you can tie into. You would have to pop open the control to get to the indicator to add a small relay or circuit to interface between the two systems.
 
Why not just tie into the Generator battery light.? A small relay to an input would seem to do the trick. Let the Generator logic do the work.

This is how I have done it on a commercial level except that most of the commercial generators I have worked on already have relays built in that you can tie into. You would have to pop open the control to get to the indicator to add a small relay or circuit to interface between the two systems.

The light (actually an LED) is soldered to a printed circuit board. My guess is the PCB contains all the logic, so there's nothing external to it that I could tie into. It would be difficult to tie into the circuit on the board, and would probably void the warranty. I thought about using a light sensor to detect the LED on, but there are several LED's close together and the light may bleed thru from one of the others. Also, there is way to tell from the indicator light why the LED is on (<12.2 VDC for more than a minute, <8 VDC while running, or <6 volts while cranking), and I would like to be able to detect the real reason.

Thanks,
Ira
 
Sounds like you need to monitor not just the voltage, but also the state of the Gensat.

1Wire sensors can monitor the voltage at various points.

The key would be software to intepret the signals to deduce state and then voltage of that state with Min / Max thresholds for triggering events like "Battery during Engine Crank too Low".

Easier would not to code the logic, but to just graph the various voltages over time and then you would interpret the findings by viewing the graph.

For MainLobby and CQC, TChart application can be the database and the graph generating portion.

You would still need a way to get the voltage to the database. For MainLobby, there was ML1WirePro plugin. Not sure if there is a comparable plugin for CQC today or not.

You could have an ELK M1 monitor the voltage.

You would need to have fairly fast sampling rates for any kind of accurate diagnostics. Ideally, the sampling would ramp up when events like "Starter Motor Crank Event" triggers.

So, the hardware is somewhat straight forward, the software end of it would be more of the work. but definately doable and reusable for many different projects once in place.

I would start by monitoring the voltage going to the engine starter solenoid (Crank Event) and the battery voltage. The other events are likely not as important. This would help eliminate a surface charge voltage as a misleading indicator of battery quality.

Now, from my work in automotive, determining true battery condition is more difficult than just voltage values. One company that specializes in the subject is Midtronics. Now, this is probably overkill for what you are trying to really do, as the cost would be cheaper to just replace the battery every year :)

http://www.midtronics.com/home/products/st...d%20System.aspx

Some discussion on the issues with just monitoring voltage:
http://www.midtronics.com/home/support/spr...ng/autofaq.aspx
 
1Wire sensors can monitor the voltage at various points.

You could have an ELK M1 monitor the voltage.

So, the hardware is somewhat straight forward, the software end of it would be more of the work. but definately doable and reusable for many different projects once in place.

Now, from my work in automotive, determining true battery condition is more difficult than just voltage values. One company that specializes in the subject is Midtronics. Now, this is probably overkill for what you are trying to really do, as the cost would be cheaper to just replace the battery every year :)

http://www.midtronics.com/home/products/st...d%20System.aspx

Some discussion on the issues with just monitoring voltage:
http://www.midtronics.com/home/support/spr...ng/autofaq.aspx

I should have mentioned in the initial post that this is not a critical environment. It does not have to be failsafe/foolproof. I just want something that will reduce the effects of my laziness when it comes to checking on the genset status. With that said...

I found a 1-wire voltage sensor that measures DC voltage from 0 to 10 VDC. Can it be used to measure higher voltages by simply putting the appropriate resistor in the line?

You said I could have the Elk M1 monitor the voltage. Can you explain that a little further? I haven't purchased mine yet so I'm not too familiar with what it can do.

I'm a software developer, so for me the software side is the easiest (at least for me to understand). If I can get the data to a file on a PC, I can figure out what to do with it if CQC doesn't make it easy. Where I'm lacking is the hardware side of the various components, e.g., 1-wire, the Elk M1G, etc. I have a general understanding of what they do, but that's about it right now.

Thanks,
Ira
 
Lots of options.

You could try using the Elk's expansion input as an analog zone, though this comes with a set of 'baggage' that may or may not let this work the way you want. More details HERE.

I believe there is a one-wire analog to digital converter, but then you would have to incorporate one-wire hardware and interfaces.

If it were me, I would probably use a PH-Anderson analog to digital converter, but see if you can do a serial port interface to it with CQC. I know you can do this with HomeSeer and even wrote a How-To on the process (on using it with the Ultimate Garage Door Monitor) so I'm sure someone here could create a CQC interface as well. If you do go with the PH-Anderson A-D board, make sure you notify Professor Anderson that you would like the values in one line and not two (i.e. all the values are in one line and not split up into two lines). That way the code is a lot easier to write.

You could then just graph the values in Excel as you write them to a text file (again with some code via CQC).

EDIT: FYI, I was writing this reply before I saw your above post

You may also want to browse my Analog to Digital Converter Guide as well.

You will need to establish a voltage ratio using two resistors to measure say 13-14 volts with the PH-Anderson A-D board as it only accepts five volts max, but this is a very simple task.

I'm sure you could then do some comparison scripting in CQC for triggering actions based on a devices value (in this case battery voltage).

Just throwing out some more options to consider. :)

EDIT: FYI, I wrote this reply before reading your above post.
 
BSR,

Thanks for the info. I had actually read your ultimate garage door opener how-to a few months ago put that on my to-do list since I have the same type of door hardware.

I think I will see what a vendor I've used in the past has to offer. Turns out they have a data logger that can monitor and log 0-2.5VDC with 12 bit accuracy at up to one second intervals. Since I'm already using their state loggers and software to monitor state (relay) changes, I think I can make their voltage logger work for me. The logger can be connected to a LAN, and their software has the ability to write log data to a PC file (or files), as well as some decent alert capabilities.

Thanks,
Ira
 
I assume this is an expensive device? If it isn't, would you mind sharing more info please.
 
I assume this is an expensive device? If it isn't, would you mind sharing more info please.

It's $105 for the data logger, plus $9 for the cable, plus $145 for the "USB server" to connect it to the LAN, plus $89 for the main software package, plus $55 for the Alarm Tool addon software.

In my case, I'm already using their state/event logger to monitor various things, so I already have the main software package. I ordered the USB server (from Amazon for $100 instead of $145) yesterday, so that cost is already "sunk". I was also already planning on buying the Alarm Tool addon software because it also provides for automated/scheduled readout of the logger data to a PC file, so that cost, too, is already "sunk". Bottom line cost for me because I already have or planned to purchase other required items is about $115 (logger and cable) for the additional hardware/functionality.

Unfortunately, I found out from the manufacturer this morning that the Alarm Tool is not as good as I thought from reading the manual. It does have the option of driving a user-supplied program when an alarm triggers, but you can only specify one program that will be driven for all alarms, even those from different loggers/sensors. That in itself isn't the bad part. The bad part is that no data is passed to the program when it is called by the Alarm Tool so that the program can determine what alarm triggered. You can specify a file to be passed to the program as an argument, but you can only specify one file that will be passed for all arguments, and there is no way to dynamically alter the contents of the file to show what alarm has tripped before your program is called. Since I'm getting the software anyway, I'm hoping that the tech support guy just doesn't know what he's talking about, and that data describing the alarm really is passed to the program. If the tech support guy is right, it shows that there was very little thought in the design phase for the "program option". I will be playing around with it next week probably to find out.

The Alarm Tool software does have the ability to send out emails and/or text messages, and it has the ability to provide enough info in the message to determine exactly what alarm was triggered. That's why I'm hoping the tech support guy was wrong and that this same "message" is passed to the supplied program. If not, I will look into either reading and parsing the email message with CQC and driving a CQC event, or trapping the outgoing email message with some sort of email spyware and parsing it then driving something in CQC to trigger a CQC event. I started a thread at the CQC forum on the latter option.

The data logger I'm considering using is the U12-006. Note that it has four channels for logging four sensors, and they don't all have to be DC voltage sensors. So it's really about $35 "per sensor" if you can have stuff for all four channels. The USB server can support up to four loggers, so that adds about $25 per logger (amount per sensor depends on how many sensors in the logger) to the cost. You can have multiple USB servers on the same LAN if you have more than four loggers. I'm not sure how many loggers the software supports, but I think I saw somewhere that it supported up to 32 loggers. I'm already using the U11-001 state data logger which can log up to three state sensors and one event sensor. The main software package is their "HOBOware Pro" software. The addon is the "Alarm and Readout Tool". Right now, the loggers are "standalone" because I'm just now starting with HA and CQC. Even without being automated, they have provided useful info, like when my genset exercised (or most recently, when it didn't), when my water well pump was quick cycling due to a bad check valve, when my water softener regenerates, etc. The HOBOware Pro software includes some pretty good graphing capabilities.
 
Back
Top