Sunday, March 15, 2015

Follow up: Modifications to the GEM Configuration to support the Stand Alone Dashboard and the SEG.


This is a followup to my earlier review of the GEM at: GEM - Green Eye Monitor - Review

Follow up: REMOVED SEG (Smart Energy Group) and now run with just the Dashbox.

Maintaining the Standalone software running on the server was not as stable as I would have liked, so I purchased and installed a DashBox (See Below). While I was at it, I eliminated the SEG as they were no longer free and were now looking for a subscription fee,

My comments on the DashBox. Very nice interface, and simple to connect to the GEM. Enhanced graphics over the stand alone software make it well worth the investment.


Follow up: Modifications to the GEM Configuration to support the Stand Alone Dashboard.
I have had my GEM connected to the SEG for about a year. On Feb 28th at 8:58PM I received the following message from the Smart Energy Group System:
“Your SEG device: mainpanel
just logged an event: Your device is offline, we thought you'd like to know.”
It was not just myself, but it seemed many were suffering the same outage.
By March 5th things seemed to be back, and by the 7th working as they should on the SEG (Thank you Sam!), but I had already started re-configuring my system to support a local Dashboard with forwarding to the SEG, so it took a little longer before my system was 100% back online.
Brultech offers a little device (a small fanless computer) called Dashbox, from what I understand it operates very similar to their Stand Alone Dashboard Software.

They also have available for download at no charge a Stand Alone Dashboard software program that runs on a PC or Server at the following URL:



I happen to have 2 Windows Home Servers one is a small HP EX490 running Windows Home Server with Service Pack 2. These are no longer made but a solid unit. There is also the EX495 or older EX470. The EX495 being the fastest processor. I see them on eBay from time to time for 250 – 500 depending on configuration. MY EX490 has 4 Drives, a 1TB and 3 2TB for 6.37 TB available storage. I use this server as my on 24X7 for backup of my Main PC, Family PC, Media PC, Laptop, and Garage PC. It also holds a copy of my Music collection for streaming.


My other server is a Supermicro Server with an internal SSD  for booting with 8 3TB Hot Swap drives or 21.5TB available space in a RAID 10 configuration. This is further backed up by 4 External USB-3 3TB HD’s. This one is running Windows Home Server 2011.This is my main File Server, Archive, and Media Server for the “My Movies” application and Music backup files. This one is a power hog, so I do not run it 24X7. I run this one more or less as needed.


So it was an easy decision where to put the Stand Alone Dashboard as it needs to be up 24X7. It would live on the EX490.

As per the Stand Alone Dashboard manual:
“The “Stand Alone Dashboard” (SAD) is a condensed version of the DashBox webserver. SAD needs to be installed on a webserver. The webserver may be local or remote. If it is to be installed on a local PC, This PC will require webserver software. Fortunately open source versions are free to download.”

The first thing I did was download XAMPPLITE and install it on the EX490. There are step by step instructions in the .pdf included in the download from Burltech from the link above. I needed to make one change after the installation. I had to change the httpd.conf file to a port other than 80 as 80 is used by the IIS server already installed on the homeserver. I chose 8081 as the port I would use.

Notepad was used to modify the httpd.conf file in XAMPP to be:
Listen 192.168.1.5:8081
NameVirtualHost *:8081
<VirtualHost *:8081>

After installing the  Burltech files to the server I connected to 192.168.1.5:8081 with a browser and was connected to the Stand Alone Dashboard. There is a section on security in the document included with the XAMPPLITE package. I followed the instructions to add XAMPP directory protection with a password (just to be safe).

Now time to connect the GEM to the Stand Alone Dashboard. I contacted Ben at Burltech and he suggested, “While you’re making changes, you may as well install the latest COM/ENG firmware.  I’ve attached them.” So I proceeded to update the firmware, and as usual all went fine. I noticed another email from Ben suggesting “Apply the attached firmware to your WiFi/Ethernet module.” This was going to be the fix that would allow me to leave the GEM in Server Mode and connect to the Stand Alone Dashboard using Network Settings in the GEM. This would be great as you could pop in and out of the GEM without having to keep changing it from Client to Server mode every time. I proceeded to run the firmware upgrade on the WiFi/Ethernet module and somehow managed to brick it solid! Ben was very helpful in trying to help get it talking again, but we ended up replacing the module. A small set back. Once the new chip arrived (3-Days) I popped it in and the GEM came up, and I was good to go. (Big thanks to Ben and Burltech).

Over the next few days I attempted to connect the GEM to the Stand Alone Dashboard application running on the server. The problem was, other than the “Raw Data” tab in the application I had no way to tell if the packets were getting to the server or if the GEM was sending them. I downloaded CommView 6.5 packet sniffer (trial Version) and installed it on the server. By setting it to look for packets from 192.168.1.5 (the server) or 192.168.1.50 (the GEM) I could now see what was going on.

Using the GEM Network Utility I found the GEM at 192.168.1.34. I opened the Network :80 to a browser.
The first thing I did was to hardcode the IP address in the GEM WiFI/Ethernet module to 192.168.1.50, and also blocked this IP from being assigned by the routers DHCP.


Next, as I have the GEM connected via Ethernet and was not using the WiFi I made it hidden and added WPA security to the access point. I found that it must stay in AP mode, any attempt to change to STA mode and I lost connectivity and had to reset the module to get back in.

I applied a password to the module in the Device Management settings then applied and reset the device.

Now on to the GEM Setup page at port 8000. I opened this to a browser and made the following changes.


From the Packet Send TAB I set the GEM to Packet Format 3 – HTTP GET and set the interval to 30 sec. Then turned on Include Current in Packet on.


Moving to the Data Post TAB the URL address I entered was http://192.168.1.5:8081 to direct the packets to port 8081 on the server as it was asking for a URL.

I then set the Network Host IP address to 192.168.1.5 and port 8081. When I exited the setup page I did see the GEM attempting to send packets to the server on the packet sniffer, but the server was responding to the GEM with an error message. (This is not something you would know without the sniffer as the application did not show any activity)

I then went into the GEM and changed the URL address to simply the IP, and exited the set up page. Keep in mind when you enter the setup page it stops communicating until you exit the page.

It was at this point I noticed it was sending packets and getting an OK back from the application.




   
The Raw data flowing into the server (from the RAW Data TAB) now looked like this:
-------------
2015-03-15 12:56:06: Serial Number is 01000230 and seconds is 12598062
01000230 Debug
Pulse: 11508667,11140125,6499299,11810680
Wattseconds: 11508667,11140125,6499299,11810680
Temps: 0,,,,,,,
-------------
In a few minutes I started seeing data in the Stand Alone Dashboard. Below are some examples of what the Dashboard looks like. You will not see anything in the top panel until you select your Main from the Manage Monitor Device Information.



 I need to finish adding pictures to the loads main page. You can drill down by clicking on a load and compare to another load or date side by side.


Or view the graph add and remove channels you wish to review by clicking them.

  
Once the GEM was talking to the Stand Alone Monitor it was very simple to have it resend the data to the SEG, you simply enter your SEG key and that is it! Although I did have to recreate my stream as it was discovered as a new feed, this took me about an hour. The result is now I have my data visible in two places, the Stand Alone Dashboard running on my Homeserver, and the SEG. Both are visible from my iPad or iPhone and function very well.

The only flaw I have found in the Stand Alone Dashboard that I have not yet discussed with Brultech is that the only thing that seems to be impacted by selecting hide a channel in the Device Information is the main loads page. All others, including what it is re-sending to the SEG do not appear to take advantage of this setting.

You will see below I now have an archived Main Panel TAB on the SEG (Prior to the change) and a new TAB “My Home on the SEG” housing the data being resent from the Stand Alone Dashboard.

I still have 8 free channels on the GEM so I can support future enhancements such as a Solar Panel System.