Dangerous Things
Custom gadgetry for the discerning hacker

The Store is now open! Check out the gadgetry »
Like what you're reading?
Share It.

Use MRTG to graph OutBack Power system data from the MATE3

I’ve been using an OutBack Power Systems FW500 inverter system in my funky datacenter for a couple years now. So far I’ve been impressed, but one of the issues I’ve run into has to do with simply pulling power system data from the MATE via RS232 serial connection. I’ve connected the MATE to a USB to RS232 adapter to get data, but I found the connection to be unstable. It would work for a while and then just stop, and I’d have to pull the USB adapter out and reconnect it to get it working again (basically a USB reboot). To be clear, this was a USB issue, not a MATE issue.

Even so, I decided to virtualize my power monitoring server, which meant even more difficulty with USB/serial connectivity. So, I went ahead and swapped out my MATE for a MATE3, which has an Ethernet port on it which allows power system data to be pulled down via HTTP call.

Since I use a Windows installation of MRTG to monitor and graph various environmental conditions (temperature, humidity, etc.) within the datacenter, I wrote a simple piece of software called MRTG_MATE3 to pull in and graph power data as well. Now you too can use MRTG to graph various power data points from your MATE3.

Download MRTG_MATE3.ZIP v1.0.1

MRTG_MATE3 was written in Visual Basic 6.0 and relies on a few other components (including VB6 runtime files) to operate. Many Windows systems already have these components installed by default, but just in case you get an error message when trying to run MRTG_MATE3, here are various download links for these required package:

Download VB6 Runtime Package: vbrun60sp6.exe (Broken link? Search on Google)

Download Windows Scripting Host 5.6 (Broken link? Search on Google)

Download Microsoft Core XML Services (MSXML) 6.0 (Broken link? Search on Google)


5 Responses to “Use MRTG to graph OutBack Power system data from the MATE3”

  1. at says:

    Hey, I love the mate3 app you wrote it was just what I was looking for.

    I copied your entry and made a host file to match d1_pwr for my mate3 but when I run the script I turn into an error, I’m still a noob when it comes to custom MRTG, stock smnp is working okay for me. In the below error I only have your sample entry in the script.

    Target[d1_pwr]: `C:\mrtg-2.17.2\bin\mrtg_mate3.exe Sell_I Buy_I` perl mrtg mrtg.cfg
    WARNING: “Title[d1_pwr]” not specified
    WARNING: “MaxBytes[d1_pwr]” not specified
    ERROR: Please fix the error(s) in your config file

  2. Amal says:

    Hmm, from the look of the error, it seems you either don’t have the title and maxbytes fields in your d1_pwr config section, or the values are invalid. Can you post your complete d1_pwr section from the cfg file? Also, why do you have “perl mrtg mrtg.cfg” suffixed to the target line? The target should simply be;

    Target[d1_pwr]: `C:\mrtg-2.17.2\bin\mrtg_mate3.exe Sell_I Buy_I`

  3. at says:

    I found the issue, it was a blank white space[tab] in front of the configuration lines of the cfg file for nesting/formatting, your app is great for MRTG, too bad MRTG decimal values are rounded to a whole integer, I hope to build my own app storing all the results from the dev_status output into sql for a replacement web interface for the Mate3.

    Btw have you experimented with changing the XML config file remotely on the mate3? it’s a huge missing feature of the current version of firmware.

    I added 3kWh solar array to my whole house UPS, and never lost power while an 18 hr power outage occurred.

  4. Amal says:

    Actually, I believe MRTG does support decimals… I use decimals in my temperature monitoring all the time. For example, it’s 39.5F outside right now. The problem is the MATE3 cannot output fractions of certain values. For example, I’m tracking Buy_I and Sell_I on my graphs, but those data values are provided by the MATE3 in whole round numbers. This is a limitation of the power meters built into the inverter.

    However, if you want serious control over the MRTG output, the solution is to use RRDtool; http://oss.oetiker.ch/mrtg/doc/mrtg-rrd.en.html

  5. Swiderski says:

    oh wow! i see! Most excellent offering!
    I think this will satisfy, but first i will have to get a mate3.. Thanks, may ping you in some months.
    Peter Swiderski

Leave a Reply

Get Adobe Flash player