Wemo switch and insight smart plug

@jason0x43

I installed the code yesterday for a Wemo Switch and I am seeing the following when manually toggling the device

I have control over it, but I can't seem to get away from this error. That is the correct IP, both in decimal and hex. Anything I should look at to try to remedy this? I've tried subscribe/unsubscribe/resubscribe with no results.

Hmmm... That would seem to indicate that the device, as it was added to Hubitat, doesn't have the correct device network ID, so Hubitat is unable to properly assign incoming messages to it.

Try removing and re-adding the device in question.

I did, but no luck. What is the DNI supposed to be, the IP, Mac, or other? I noticed my DNI is blank when added,

It should be the MAC. When you add a device, the WeMo Connect app should log a message like:

initDevices: Created My Device with id: 1234, MAC: ABCDEF123456

If the MAC field in that message is blank, or if you didn't see that message, then something isn't working right.

This might be on my end. I have the Wemo joined to an IOT network on a dedicated subnet and I use an ssdp router to advertise the broadcasts. I see the device but the MAC doesn’t come through.

I have found that if you have wifi mesh networking (like google wifi), you can have a lot of fun with Wemo and HE.

Example

  • the wemo's I have near my primary google wifi device, will appear to not respond to ssdp
  • They can also have a hard time if you reset them them and want to reconnect to your wifi network

What appears to be going on: (first on the setting up the wemo devices near the primary router)

  • google wifi advertises both 2.4gh and 5ghz wifi with the same name
    • your mobile device used in setting up is likely on the 5ghz network, and during the handoff from the wemo private network to the wifi network, wemo app tells you could not connect.
    • google in their don't be evil, are evil in that you cannot disable the 5ghz network.

So to setup the factory reset wemo devices, you need to move yourself, your mobile device and the wemos to be configured far enough away from the primary router that your mobile device switches to 2.4ghz, then with the devices near by to you, you can set them up.

So the next problem is the devices don't discover in the wemo connect app (and sometimes the wemo app). It was strange that a device near the other mesh router would be visible via ssdp, but not the wemo devices near / connected to the primary router.

  • in my case I have the 2ndary mesh routers wired back to the primary router in other locations.
  • if I move (temporarily) the switches that won't discover, by the 2ndary router, then the discovery works in HE and I can add the devices to HE

So all this gets down to wemo wants 2.4Ghz, and it appears to me google is has issues with 2.4ghz devices broadcasting and that being forward properly from the primary router.

I have seen strangeness in the wemo app thru this, but it seemed to see the device much sooner than Wemo Connect/HE did.

The question I have is if the ssdp returns to not seeing the device, but HE has already configured the device, will wemo connect correctly keep the device working and subscribed?

Yep, why I have my WEMO's on a single "guest" 2.4 network that's allowed to see my other network devices. I dont like the WEMO wifi implementation at all. But what to do?

@jason0x43, I have successfully installed the drivers and app for my Wemo switches and they are working well so far (thank you!). I can't seem to install the driver for my Wemo Maker. I keep getting the following error:

No signature of method: Script1.input() is applicable for argument types: (java.util.LinkedHashMap, java.lang.String) values: [[type:bool, title:Invert Sensor, description:Inverts the sensor input, ...], ...] Possible solutions: inspect(), wait(), run(), on(), push(), run()

Am I doing something wrong?

Oops, that was a bug in the source. I pushed an update; give that a try.

Thanks Jason. I'll try it in a couple of days when I return home and report back.

Hi Jason. Confirming the driver works great now! Thanks for your work on this. Much appreciated.

@jason0x43 thanks for this driver, I have 1 insight switch and I’m seeing the following error in logs each time it refreshes

2019-12-20 10:45:00.159 pm errorgroovy.lang.MissingMethodException: No signature of method: user_app_jason0x43_WeMo_Connect_193.childRefresh() is applicable for argument types: (com.hubitat.app.DeviceWrapper) values: [Basement Washer] on line 116 (childRefresh)

Thanks Jason. This is working great for my Wemo switches.

Is there a version of Wemo Connect that allows for turning off description text logging? The version I'm using is from 2019-07-23. Thanks

Assuming you mean the basic info logs, there isn't currently an option for that, just for the debug logs.

Regarding the childRefresh error, it looks like you may be using older WeMo drivers with a more current Connect app (the childRefresh method, and all uses of it, were removed from the Connect app and drivers a few months ago).

yes, I did find a newer version. Thanks again for the driver.

Hi Jason. I've installed your Wemo Maker driver and the Wemo Connect app and I'm getting the following message in the logs.

dev:492020-01-21 05:51:17.169 pm errorjava.lang.NullPointerException: Cannot invoke method leftShift() on null object on line 214 (parse)

I have a contact connected to it and it's not reporting state. The Wemo app shows that it is working, so suggests it's something with HE. Any suggestions? Do you have a Wemo Maker successfully working with this driver?

Driver version is 2019-10-01, 09:03:13-0400.

FYI, although I've had it installed for a while, I never actually tested the contact, which is why I'm only letting you know now.

I don't have a Wemo Maker device, so I've never actually tested it myself. From looking at the code, though, I can see where the problem might be. I'll push out an update a bit later today.

1 Like

Thanks Jason. I'll test it out and report when you publish it.