EYEFI /getdata command (Sample Code)

The Eyedro EYEFI-x models include a built in web server that you may query with the /getdata command to retrieve the instantaneous measurement values.

While the EYEFI module is not provisioned for the internet (the out of the box configuration), you may only use the /getdata command locally by first connecting direct to the module WIFI network. Eg. EyedroWifi [00B-12345] will appear in your WIFI options list. While connected directly to the EYEFI module accessing the /dashboard, and /settings pages, and the /getdata command are the same format.

After the EYEFI module is provisioned for the internet (SSID, Security, Password are configured per Quick Start Guide), then it will connect to your local network and will be assigned a new IP address from your local network. For this blog post I am using IP address but your IP address will most likely be different, and can be found by logging into your router to see a list of connected devices and their respective IP address.

While the EYEFI module is provisioned for the internet it will communicate with the MyEyedro cloud service 24/7. The module will open a second network port at port 8080 that can be queried in parallel. The format of the /getdata command is shown below. Please note that you’ll replace the IP address ( with your own.

The output of the command is in JSON format. The example response below is from querying an EYEFI-2 (2 sensor model).

  "data": [ [988, 11665, 11800, 1360, 0], [989, 11665, 4854, 560, 0] ]

The ‘data’ array includes 2 elements, one for each sensor (A first, B second, etc). Each sub-array includes 5 values that are:

1st: Power factor in milli-units meaning ‘988’ = 0.988
2nd: Voltage in cV meaning ‘11665’ = 116.65V
3rd: Amperage in mA meaning ‘11800’ = 11.8A
4th: Wattage in W meaning ‘988’ = 988W
5th: Ignore. Used by factory only.

When viewing the /dashboard page you’ll see that it updates itself every few seconds. It is running a small piece of javascript code that calls the /getdata command as part of the update. The below html and javascript code example can be used as a starting point to create your own software. Save the file to your PC with an .html file extension, edit to replace the IP address with your own, then open the html file in a browser. The javascript should run in the background and update your simple html table with data values.

<!DOCTYPE html>
<title>Eyedro Sample Code: EYEFI-x /getdata command</title>
<style>table, th, td {
  border: 1px solid black;
  border-collapse: collapse;
<header><h2>EYEFI-x /getdata command</h2></header>
<tr><td>Sensor A</td><td id='0f'></td><td id='0v'></td><td id='0i'></td><td id='0p'></td></tr>
<tr><td>Sensor B</td><td id='1f'></td><td id='1v'></td><td id='1i'></td><td id='1p'></td></tr>
	var data=[[1,2,3,4,5],[1,2,3,4,5]];
		var WattageSum=0;
		for (var j=0;j<2;j++){
			var PowerFactor=data[j][0]/1000;
			var Voltage=data[j][1]/100;
			var Amperage=data[j][2]/1000;
			var Wattage=data[j][3];
			WattageSum += Wattage;
		var timer=setTimeout(function(){
			var xhttp=new XMLHttpRequest();
			if (xhttp==null){
				timer=setTimeout(function(){ location.reload(true); }, 3000);
				if (this.readyState==4){
					if (this.status==200){
						var json=JSON.parse(this.responseText);
						alert('Error ('+this.status+') requesting data from server.');
			xhttp.open('POST', '', true);
			xhttp.setRequestHeader('Content-type', 'application/x-www-form-urlencoded');
		}, 2000);
			if (timer!=null){
<footer>Copyright © 2009-2019 Eyedro Green Solutions Inc.</footer>

Please contact us at Eyedro Support (support@eyedro.com) if you have questions, comments, etc.

Eyedro Keeps Eye on Hydro Usage – The Waterloo Region Record

Eyedro Keeps Eye on Hydro Usage – The Waterloo Region Record

KITCHENER — Auston Gough figures he saved about $50 a month on electricity bills this past winter after he installed devices that measure his hydro usage by the second and relay the information to his tablet.

Gough lives in a two-bedroom apartment above King Street in downtown Kitchener and was spending about $400 for electricity every two months this past winter. His place is heated with electric baseboards and has a dishwasher.

Gough spent $129 for a kit from Eyedro Green Solutions Inc., a new company in the Communitech Hub. He clamped sensors on the main line feeding the electrical panel, and then hooked up a small box that sends detailed information on electricity consumption to his tablet.

Gough used to keep one baseboard heater cranked up high and the other three almost turned off. He quickly learned that doing that was hugely inefficient. He changed the settings so that all the heaters run intermittently.

Gough learned that the four light bulbs in the bathroom used as much hydro as his dishwasher. So he switched to high-efficiency bulbs. He only runs his dishwasher when electricity rates are lower.

“I just made some fairly minor changes and I was using less power, which is great,” Gough said.

The downtown bartender is an early adopter of the technology developed by Eyedro. The company already has customers — residential, institutional and industrial — in 10 countries.

Read the full article Eyedro Keeps Eye on Hydro Usage, by Terry Pender at http://www.therecord.com/news-story/4526526-eyedro-keeps-eye-on-hydro-usage/


Visit Eyedro at Schaedler yesco Expo 2014

Visit Eyedro at Schaedler yesco Expo 2014

Visit us at the Schaedler yesco Expo 2014 on March 24-25 in Hershey, Pennsylvania – Booth 531. We’ll be hosting the “Real-Time Electricity Monitoring” seminar on March 24, 1pm. If you’re unable to attend but still interested in the seminar then please contact us to schedule a 1 on 1 webinar at a time that fits your schedule (info@eyedro.com).


Schaedler yesco Expo 2014.

Schaedler yesco Expo 2014.

Schaedler yesco Expo 2014 schedule.

Schaedler yesco Expo 2014 schedule.