Eco Plugs

There should not be any open sessions… UDP is a sessionless protolcol.

Polling is already in the implementation file, with a period of 60 seconds… It was added when it was determined that the set command did not return the switch state.

please post a sceenshot of the open path table from your router and a section from the LuaUPnP.log file.

I know that UDP is sessionless :slight_smile: That is why the large data path table on my wireless controller was concerning. We mark UDP traffic as “fast path” in our controller and typically age out UDP sessions in the controller datapath table in 20-30 seconds. I should have looked at the Vera log before my last post, all the noise is shown in the log. I am posting a small section of the log, but it is the same thing over and over. It is sending multiple commands to the plug per second (somewhere around one command per .05 second). I have attached a section of the log or your review. Thanks!

I thought you wanted instant status!?!?!?! 8-}

A type in the variable used to store the poll frequency cause the poll loop to fire continuously…

Hopefully fixed… should poll once every 60 seconds now…

60 seconds is instant enough for me :slight_smile:

Everything looks great now, switch turns on/off, response is much crisper, and the polling is working. I turned on the switch in Vera, then went into the native app and shut off the outlet. I then confirmed that Vera updated the status of the switch. The logs look like they should now too…

Thank you once again!!

This is awesome. Thanks!

I had a tough time finding the IP address of my ECO plug. My router didn’t list it. In case it helps someone else… I finally installed the Packet Capture app on my Android device, started capture, turned on the ECO plug with my Android app, then went pack to the capture app, ended capture. Then looked for packets sent to an address ending with “:80” (port 80). There it was.

The only thing I just can’t seem to figure out is how to set up a scene to simply toggle the ECO plug.

I tried this:

luup.call_action("urn:micasaverde-com:serviceId:HaDevice1", "ToggleState", {}, 46)

And I tried this:

local switchOnOff = luup.variable_get("urn:upnp-org:serviceId:SwitchPower1", "Status", 46) if (switchOnOff == "1") then luup.call_action("urn:upnp-org:serviceId:SwitchPower1", "SetTarget", {newTargetValue = "0"}, 46) else luup.call_action("urn:upnp-org:serviceId:SwitchPower1", "SetTarget", {newTargetValue = "1"},46) end

Any ideas???

Not sure why your 2nd example isn’t working. I added a space I think you were missing, but otherwise mine is exactly the same except for different eco plug id. Mine turns on/off on each scene run, here is what I have:

local switchOnOff = luup.variable_get(“urn:upnp-org:serviceId:SwitchPower1”, “Status”, 116)
if (switchOnOff == “1”) then
luup.call_action(“urn:upnp-org:serviceId:SwitchPower1”, “SetTarget”, {newTargetValue = “0”}, 116)
else
luup.call_action(“urn:upnp-org:serviceId:SwitchPower1”, “SetTarget”, {newTargetValue = “1”}, 116)
end

Good day,

Where can I find the ECO plug LUUP file?

Thanks

[quote=“gwgonsalves, post:47, topic:190797”]Good day,

Where can I find the ECO plug LUUP file?

Thanks[/quote]

Look a few posts back. The developer was very good about deleting all the obsolete versions.

I tried it and couldn’t get it to work. It looks like Vera is sending it packets but it just ignores them. :cry:
Does it matter what name I give it in the ‘Internal ID’ field?

Has anyone gotten this to work for them?
I got several of these for cheap so I’d really love to get them working.

Yes.

If your switch has the ID “ECO-AABBCCDD”, and you call it “ECO-11223344” - it WILL ignore you!!

Yes.

If your switch has the ID “ECO-AABBCCDD”, and you call it “ECO-11223344” - it WILL ignore you!![/quote]
That must be my problem!! Thanks!
Only, how do I find my switches name? Is it, by chance, the last 8 digits of the MAC address?
Gonna try again tonight and see.
Thanks again,
Jim

Yep, its “ECO-” + the last 8 digits of the MAC address.
Working great! ;D

Now if I can figure out how to get my Almond+ router to block 210.65.89.22 so it will quit sending my ssid/password to somewhere in China every time I use it. >:( >:( >:(

Any chance of adding that tip to the first page?

Thanks all.

I have this working fine now but I am afraid to use id. :o
Every time it is used it sends my ssid and PassPhrase in the clear to a server in Tiwan: 210.65.89.22. :frowning: :frowning:
I can, of course, put all the switches on their own wifi network so they couldn’t phone home, but then my Vera Plus couldn’t talk to them.
I could move my VeraPlus over to that network but then it couldn’t talk to the internet so I couldn’t control it remotely.
I thought of blocking access to 210.65.89.22 but Securifi says my Almond+ can’t be made to do that and I should talk to my ISP but my ISP says they can’t do that and I should talk to Securifi!!!

I have found sites that show how to load new firmware onto the device but the process appears daunting plus I doubt the device will work with the new Vera driver anymore.

I’d really really like to find a way to use the switches because I scored a dozen of them. ;D
Any ideas? Did I miss something obvious? Is there a better place to post this question?
TIA, Jim

Hi cybrmage. I am a newbee and your solution looks interesting. Would like to try my self. I could see the latest implementation file here. Where is D_BinaryLight1.xml ? I assume Device file as well a implementation file is required for this to work. Thanks

I think I should, already have this on my system . Am I right ? Tkis

I thought you wanted instant status!?!?!?! 8-}

A type in the variable used to store the poll frequency cause the poll loop to fire continuously…

Hopefully fixed… should poll once every 60 seconds now…[/quote]

This implementation is now obsolete, as I have converted it into a plugin…

Until the plugin is approved, you can install it semi-automatically, by entering the following url in a browser… (make sure to replace “vera_ip” with the actual IP Address of your Vera)

http://vera_ip:3480/data_request?id=action&serviceId=urn:micasaverde-com:serviceId:HomeAutomationGateway1&action=CreatePlugin&PluginNum=8901&Version=33186

What is the status of plug in ? I am getting an error if I run the said link in a browser.

Hi cybrmage,
I installed version 1.0 from the app store and really like it. I especially like the way it scans my network and lists all the switches it finds and allows them to be added by simply clicking the ‘Add’ button.
A very professional and easy to use interface! Thanks.
My only problem is that the switches work fine when I click them in the interface, but when I use them in a scene, nothing happens.
Vera allows me to add the switch to a scene, it just doesn’t do anything when It attempts to turn the switch on or off. Vera also ignores the lua command line:

luup.call_action(“urn:upnp-org:serviceId:SwitchPower1”, “SetTarget”, {newTargetValue = “1”}, 519)

Alexa is able to turn the switches created by your plugin on and off just fine…
Am I doing something wrong? Is this an undocumented feature?

Thanks again for the way cool plugin,
Jim

Hi @cybrmage,

I too have difficulties with this plug in. I have two systems and it behaves diferently. The help link is going no where. Can you please look into this whenever you are free.

@cybrmage, appears to be busy. Any one cnhelp ?

Where can I get some eco help ? Any one knows ?

Here’s what I’m doing and it’s working great. I take no credit for any of this, it is not my code and try it at your own risk.

I have installed the new plugin but it is not working correctly for me so I am just using it to discover and enumerate my ECO devices. In other words, I do NOT add any of the devices it finds. Instead I create the devices manually using the data the plugin gives me.
Here is the process I use. This is mostly taken from the first post.

  1. On your Vera, go to Apps/Develop Apps/Luup Files, and upload the implementation file in Reply #42 of this thread.
  2. On your Vera, go to Apps/Develop Apps/Create Device.
  3. Fill in the parameters as follows:
    Device Type: urn:schemas-upnp-org:device:BinaryLight:1
    Internal ID: (enter the name of your switch ie: ECO-12345678) last 8 digits of mac address, taken from the plugin.
    Description: (enter the name you want for the plug - if left blank, it will be names “_Binary Light”)
    Upnp Device Filename: D_BinaryLight1.xml
    Upnp Implementation Filename: I_ECO_Switch.xml
    IP address: (enter the IP Address of your ECO plug, taken from the plugin)
  4. Click on “Create Device”
  5. Allow the LuaUPnP engine to reload and refresh your browser. You may have to start a reload manually.

You should then be able to control the switch directly from your Vera.

Hope this helps and also hope cybrmage doesn’t mind me horning in on his project.
Again, I take no credit for this effort, it was all written by cybrmage