I’ve got a little question. My LiftMaster have a motion detector in it that open/close the lighting inside the garage when it detect someone. Do you think we can query it? I’m using MyQ to control it but it’s still a Wireless Garage Door Opener that I see on my wifi network. Maybe we can talk to it directly?
The JSON value after Log line “Requesting URL https://craftexternal.myqdevice.com/api/v4/userdevicedetails/get” should contain a list of all your MyQ devices. Each Device should have many parameters. The ones I’m interested in are “MyQDeviceId”, “MyQDeviceTypeName”, “MyQDeviceTypeId”. “MyQDeviceTypeId” values I know are garage doors are currently hardcoded to 2,5,7,17. If your value is different I may need to add it. If you want to PM me this info so it isn’t public, you can.
The motion detect idea has be discussed many times before and it is not supported by the API currently. The Garage Door probably talks to the Chamberlain server using encrypted connection.(just a guess I don’t work for them) You may be able to use some sort of proxy server to sniff the packets but it would not be easy. Based on recent announcements they have made about charging a monthly fee for IFTTT and Google Home support, I doubt they will every open up there API to anyone.
Is there a new binding available? 1.10.0 seems MyQ broke it again
java.io.IOException: Null response from MyQ server
at org.openhab.binding.myq.internal.MyqData.request(MyqData.java:217)[199:org.openhab.binding.myq:1.10.0]
at org.openhab.binding.myq.internal.MyqData.getMyqData(MyqData.java:128)[199:org.openhab.binding.myq:1.10.0]
at org.openhab.binding.myq.internal.MyqBinding.poll(MyqBinding.java:210)[199:org.openhab.binding.myq:1.10.0]
at org.openhab.binding.myq.internal.MyqBinding.access$0(MyqBinding.java:202)[199:org.openhab.binding.myq:1.10.0]
at org.openhab.binding.myq.internal.MyqBinding$1.run(MyqBinding.java:407)[199:org.openhab.binding.myq:1.10.0]
2017-12-04 00:10:37.383 [INFO ] [core.karaf.internal.FeatureInstaller] - Uninstalled 'openhab-binding-myq1’
2017-12-04 00:39:35.067 [INFO ] [core.karaf.internal.FeatureInstaller] - Uninstalled 'openhab-binding-myq1
As of 6 hours ago the current binding worked for me. Maybe it is your configuration. You can manually send the JSON commands as described in post #172 and see if it works outside the binding.
I did get a ReturnCode 0 manually sending the JSON commands… I’m running docker image openhab 2.1.0
I followed your instructions on installing the .jar post #150 installing the jar and restarting openhab and myq doesn’t show up in the logs like its not being run
Should I be troubleshooting the built in bindings or move forward with the addon?
I recently upgraded to OpenHab2 and have been adding bindings to it slowly. Today I tried installing and configuring the MyQ binding with my Craftsmen AssureLink working.
I installed the binding, configured the myq.cfg in services with username, password and craftmen=true.
When the binding tries to connect I get the following message.
2/2017-12-31 16:59:01.187 [ERROR] [nhab.binding.myq.internal.MyqBinding] - Could not log in, please check your credentials.
org.openhab.binding.myq.internal.InvalidLoginException: This user is locked out.
I then attempt to use the same credentials on the https://assurelink.craftsman.com site and they work correctly. The version of the binding I’m using is 1.11, and I tried installing the binding manually via PaperUI and via the addons.cfg. Both yielded the same results.
I use the MyQ binding in OH2 and it works ok. But I use it with a Liftmaster, so I can’t be of too much help with the Craftsman.
I see that craftman=true causes the binding to use the API on a different website with a different API key. Have you tried putting the binding into DEBUG or TRACE mode to see if you can get any additional information about what’s going on leading up the error?
I have one thing for you to try, add to the myq.cfg file the line below, remove the “craftman=true” line, and restart openhab (or shutdown, make change, and startup again):
To be honest, I have never tested the Craftsmen AssureLink support. I personally have a Chamberlain Opener that I developed and tested the binding for. I have never heard of any success stories of the binding working with a Craftsmen opener so it may not work. If you feel conformable with it, the easier way for me to debug the binding for you is if you could PM me your username and password (I understand if you don’t want too) and I can look into it. If not you can manully try the HTTP requests as outlined in post #172 above. You would have to use the appid above and maybe change the brandid to 3. Looking at other projects that used the MyQ API, I don’t think the current version of the binding will work with Craftsmen opener based on the updates Chamberlain made to their API last year. I see some things I need to update in the source code and see if it fixes the issue for you. I will try to update the binding this weekend and get you a new version to test. Sorry for the inconvenience.
I have been working on a openHAB 2 version of the Chamberlain MyQ Binding. It still needs lots of work but the basic functionality is present. The code is missing the invalid login checks so verify your username and password as the binding could lockout your account. I have tested it with my Chamberlain garage door and two light switches for the last day and I haven’t had any issues yet. I plan to work on it some more and post the code to my github soon. Any feedback would be greatly appreciated. I don’t think it will work with Craftsmen openers, so sorry about that. A link to the binding in my google drive is below.
Do you see any issue running this side-by-side with the OH1 version of the binding? I can’t think of a possible problem other than trying to operate the door with both bindings at the same time (which I don’t plan to do).
I could uninstall the OH1 binding, but if I run into an issue with the new binding, I’m kinda stuck…
Also, will this binding auto-discover the opener?
Edit: Answering my own question here. I don’t see a discovery service running, so I think the answer is no.
Edit2: Ah, I see, the discovery service starts once you create a gateway thing.
One other thing I noticed. It looks like you might be building the binding against an earlier version of ESH that doesn’t have this change.
As a result, running the binding on a recent 2.3 snapshot causes the discovery service to throw a bunch of exceptions, including this one below. It’s not urgent, but at some point it would be great if you could build a 2.3 version of the binding based on a recent ESH code base.
javax.servlet.ServletException: org.glassfish.jersey.server.ContainerException: java.lang.IncompatibleClassChangeError: Expected static field org.openhab.binding.chamberlainmyq.internal.discovery.ChamberlainMyQDeviceDiscoveryServic
e.scheduler
at org.glassfish.jersey.servlet.WebComponent.serviceImpl(WebComponent.java:489) [171:org.glassfish.jersey.containers.jersey-container-servlet-core:2.22.2]
at org.glassfish.jersey.servlet.WebComponent.service(WebComponent.java:427) [171:org.glassfish.jersey.containers.jersey-container-servlet-core:2.22.2]
at org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:388) [171:org.glassfish.jersey.containers.jersey-container-servlet-core:2.22.2]
at org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:341) [171:org.glassfish.jersey.containers.jersey-container-servlet-core:2.22.2]
at org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:228) [171:org.glassfish.jersey.containers.jersey-container-servlet-core:2.22.2]
at com.eclipsesource.jaxrs.publisher.internal.ServletContainerBridge.service(ServletContainerBridge.java:76) [15:com.eclipsesource.jaxrs.publisher:5.3.1.201602281253]
at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:848) [86:org.eclipse.jetty.servlet:9.3.21.v20170918]
at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:584) [86:org.eclipse.jetty.servlet:9.3.21.v20170918]
at org.ops4j.pax.web.service.jetty.internal.HttpServiceServletHandler.doHandle(HttpServiceServletHandler.java:71) [187:org.ops4j.pax.web.pax-web-jetty:6.0.9]
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:143) [85:org.eclipse.jetty.server:9.3.21.v20170918]
at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:548) [83:org.eclipse.jetty.security:9.3.21.v20170918]
at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:226) [85:org.eclipse.jetty.server:9.3.21.v20170918]
at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1180) [85:org.eclipse.jetty.server:9.3.21.v20170918]
at org.ops4j.pax.web.service.jetty.internal.HttpServiceContext.doHandle(HttpServiceContext.java:284) [187:org.ops4j.pax.web.pax-web-jetty:6.0.9]
at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:512) [86:org.eclipse.jetty.servlet:9.3.21.v20170918]
at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:185) [85:org.eclipse.jetty.server:9.3.21.v20170918]
at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1112) [85:org.eclipse.jetty.server:9.3.21.v20170918]
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141) [85:org.eclipse.jetty.server:9.3.21.v20170918]
at org.ops4j.pax.web.service.jetty.internal.JettyServerHandlerCollection.handle(JettyServerHandlerCollection.java:80) [187:org.ops4j.pax.web.pax-web-jetty:6.0.9]
at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:134) [85:org.eclipse.jetty.server:9.3.21.v20170918]
at org.eclipse.jetty.server.Server.handle(Server.java:534) [85:org.eclipse.jetty.server:9.3.21.v20170918]
at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:333) [85:org.eclipse.jetty.server:9.3.21.v20170918]
at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:251) [85:org.eclipse.jetty.server:9.3.21.v20170918]
at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:283) [78:org.eclipse.jetty.io:9.3.21.v20170918]
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:108) [78:org.eclipse.jetty.io:9.3.21.v20170918]
at org.eclipse.jetty.io.SelectChannelEndPoint$2.run(SelectChannelEndPoint.java:93) [78:org.eclipse.jetty.io:9.3.21.v20170918]
at org.eclipse.jetty.util.thread.strategy.ExecuteProduceConsume.executeProduceConsume(ExecuteProduceConsume.java:303) [89:org.eclipse.jetty.util:9.3.21.v20170918]
at org.eclipse.jetty.util.thread.strategy.ExecuteProduceConsume.produceConsume(ExecuteProduceConsume.java:148) [89:org.eclipse.jetty.util:9.3.21.v20170918]
at org.eclipse.jetty.util.thread.strategy.ExecuteProduceConsume.run(ExecuteProduceConsume.java:136) [89:org.eclipse.jetty.util:9.3.21.v20170918]
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:671) [89:org.eclipse.jetty.util:9.3.21.v20170918]
at org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:589) [89:org.eclipse.jetty.util:9.3.21.v20170918]
at java.lang.Thread.run(Thread.java:748) [?:?]
Caused by: org.glassfish.jersey.server.ContainerException: java.lang.IncompatibleClassChangeError: Expected static field org.openhab.binding.chamberlainmyq.internal.discovery.ChamberlainMyQDeviceDiscoveryService.scheduler
at org.glassfish.jersey.servlet.internal.ResponseWriter.rethrow(ResponseWriter.java:278) ~[?:?]
at org.glassfish.jersey.servlet.internal.ResponseWriter.failure(ResponseWriter.java:260) ~[?:?]
at org.glassfish.jersey.server.ServerRuntime$Responder.process(ServerRuntime.java:509) ~[174:org.glassfish.jersey.core.jersey-server:2.22.2]
at org.glassfish.jersey.server.ServerRuntime$2.run(ServerRuntime.java:334) ~[174:org.glassfish.jersey.core.jersey-server:2.22.2]
at org.glassfish.jersey.internal.Errors$1.call(Errors.java:271) ~[173:org.glassfish.jersey.core.jersey-common:2.22.2]
at org.glassfish.jersey.internal.Errors$1.call(Errors.java:267) ~[173:org.glassfish.jersey.core.jersey-common:2.22.2]
at org.glassfish.jersey.internal.Errors.process(Errors.java:315) ~[173:org.glassfish.jersey.core.jersey-common:2.22.2]
at org.glassfish.jersey.internal.Errors.process(Errors.java:297) ~[173:org.glassfish.jersey.core.jersey-common:2.22.2]
at org.glassfish.jersey.internal.Errors.process(Errors.java:267) ~[173:org.glassfish.jersey.core.jersey-common:2.22.2]
at org.glassfish.jersey.process.internal.RequestScope.runInScope(RequestScope.java:317) ~[173:org.glassfish.jersey.core.jersey-common:2.22.2]
at org.glassfish.jersey.server.ServerRuntime.process(ServerRuntime.java:305) ~[174:org.glassfish.jersey.core.jersey-server:2.22.2]
at org.glassfish.jersey.server.ApplicationHandler.handle(ApplicationHandler.java:1154) ~[174:org.glassfish.jersey.core.jersey-server:2.22.2]
at org.glassfish.jersey.servlet.WebComponent.serviceImpl(WebComponent.java:473) ~[171:org.glassfish.jersey.containers.jersey-container-servlet-core:2.22.2]
... 31 more
Caused by: java.lang.IncompatibleClassChangeError: Expected static field org.openhab.binding.chamberlainmyq.internal.discovery.ChamberlainMyQDeviceDiscoveryService.scheduler
at org.openhab.binding.chamberlainmyq.internal.discovery.ChamberlainMyQDeviceDiscoveryService.startScan(ChamberlainMyQDeviceDiscoveryService.java:57) ~[?:?]
at org.eclipse.smarthome.config.discovery.AbstractDiscoveryService.startScan(AbstractDiscoveryService.java:208) ~[?:?]
at org.eclipse.smarthome.config.discovery.internal.DiscoveryServiceRegistryImpl.startScan(DiscoveryServiceRegistryImpl.java:427) ~[?:?]
at org.eclipse.smarthome.config.discovery.internal.DiscoveryServiceRegistryImpl.startScans(DiscoveryServiceRegistryImpl.java:412) ~[?:?]
at org.eclipse.smarthome.config.discovery.internal.DiscoveryServiceRegistryImpl.startScan(DiscoveryServiceRegistryImpl.java:260) ~[?:?]
at org.eclipse.smarthome.io.rest.core.internal.discovery.DiscoveryResource.scan(DiscoveryResource.java:97) ~[?:?]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:?]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:?]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
at java.lang.reflect.Method.invoke(Method.java:498) ~[?:?]
at org.glassfish.jersey.server.model.internal.ResourceMethodInvocationHandlerFactory$1.invoke(ResourceMethodInvocationHandlerFactory.java:81) ~[174:org.glassfish.jersey.core.jersey-server:2.22.2]
at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher$1.run(AbstractJavaResourceMethodDispatcher.java:144) ~[174:org.glassfish.jersey.core.jersey-server:2.22.2]
at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher.invoke(AbstractJavaResourceMethodDispatcher.java:161) ~[174:org.glassfish.jersey.core.jersey-server:2.22.2]
at org.glassfish.jersey.server.model.internal.JavaResourceMethodDispatcherProvider$ResponseOutInvoker.doDispatch(JavaResourceMethodDispatcherProvider.java:160) ~[174:org.glassfish.jersey.core.jersey-server:2.22.2]
at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher.dispatch(AbstractJavaResourceMethodDispatcher.java:99) ~[174:org.glassfish.jersey.core.jersey-server:2.22.2]
at org.glassfish.jersey.server.model.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:389) ~[174:org.glassfish.jersey.core.jersey-server:2.22.2]
at org.glassfish.jersey.server.model.ResourceMethodInvoker.apply(ResourceMethodInvoker.java:347) ~[174:org.glassfish.jersey.core.jersey-server:2.22.2]
at org.glassfish.jersey.server.model.ResourceMethodInvoker.apply(ResourceMethodInvoker.java:102) ~[174:org.glassfish.jersey.core.jersey-server:2.22.2]
at org.glassfish.jersey.server.ServerRuntime$2.run(ServerRuntime.java:326) ~[174:org.glassfish.jersey.core.jersey-server:2.22.2]
at org.glassfish.jersey.internal.Errors$1.call(Errors.java:271) ~[173:org.glassfish.jersey.core.jersey-common:2.22.2]
at org.glassfish.jersey.internal.Errors$1.call(Errors.java:267) ~[173:org.glassfish.jersey.core.jersey-common:2.22.2]
at org.glassfish.jersey.internal.Errors.process(Errors.java:315) ~[173:org.glassfish.jersey.core.jersey-common:2.22.2]
at org.glassfish.jersey.internal.Errors.process(Errors.java:297) ~[173:org.glassfish.jersey.core.jersey-common:2.22.2]
at org.glassfish.jersey.internal.Errors.process(Errors.java:267) ~[173:org.glassfish.jersey.core.jersey-common:2.22.2]
at org.glassfish.jersey.process.internal.RequestScope.runInScope(RequestScope.java:317) ~[173:org.glassfish.jersey.core.jersey-common:2.22.2]
at org.glassfish.jersey.server.ServerRuntime.process(ServerRuntime.java:305) ~[174:org.glassfish.jersey.core.jersey-server:2.22.2]
at org.glassfish.jersey.server.ApplicationHandler.handle(ApplicationHandler.java:1154) ~[174:org.glassfish.jersey.core.jersey-server:2.22.2]
at org.glassfish.jersey.servlet.WebComponent.serviceImpl(WebComponent.java:473) ~[171:org.glassfish.jersey.containers.jersey-container-servlet-core:2.22.2]
... 31 more