Chamberlain MyQ Binding

Thats probably a better strategy then, I’ll look to add that when i have lights working, thanks!

Hello. Has anyone determined how to add a Garage Door thing in a .things file? I was able to add a Gateway thing as follows:

Bridge chamberlainmyq:MyQGateway:myqacct "MyQ Account" [username="email@address.com", password="mYpAsSwoRd"] {
}

I can then add a Garage Door thing through PaperUI, but literally everything else in my OH installation is done through text config files, which is great for when I need to upgrade or do a clean install. I’ve tried a few combinations (both inside and outside the curly brackets) for a Garage Door thing, but so far I haven’t had any luck. Any guidance would be great.

Hi all, if anyone could test the Jar on their OH3 system, and let me know how it goes, that would be great. I have not tested out lights yet, but at this point testing is the only thing stopping me from submitting this for review and inclusion into our distribution.

This is a new implementation, so configuration may be different than the other bindings in the thread. There is an updated readme with example items. I have not tested manual Thing configuration, but adding the account and letting the system discover devices works as expected. See the PR README for more examples:

Thanks.

2 Likes

Awesome! Dropping the new binary in now.

EDIT:
I’m not able to establish connection to the API service

2020-12-13 13:49:51.725 [TRACE] [q.internal.handler.MyQAccountHandler] - Account Response - status: 200 content: {"SecurityToken":"REDACTED"}
2020-12-13 13:49:51.775 [TRACE] [q.internal.handler.MyQAccountHandler] - Account Response - status: 200 content: {"Users":{REDACTED}
2020-12-13 13:49:51.826 [TRACE] [q.internal.handler.MyQAccountHandler] - Account Response - status: 404 content: {"code":"404.401","message":"Not Found","description":"Account not found."}

Is there a updated 2.5.x binary or just the 3.0.x one?

Best, Jay

All new bindings are against 3.0 , so there will not be a 2.5 binding unfortunately.

The latest version was updated as of 2pm PST yesterday and i hope is working smoothly. If anyone has a light they can test with as well that would be great.

Jar (download to addons folder)
https://github.com/digitaldan/openhab-addons/releases/download/myq-wip-1/org.openhab.binding.myq-3.0.0-SNAPSHOT.jar

1 Like

Is this the same from when we were looking at the user ID or is this newer?

Just tried out the 3.0.0 version with openhab 3.0.0 rc1. Discovery and operation worked great, no issues at all. Thanks again!

This contains the userId fix we discussed on the PR

Awesome, thanks for testing !

so that means if I have 2.5 openhab, I can’t use the new one right? Cause right now, my log is spammed with error and and I can’t control my garagedoor in the last 24h or so

2020-12-19 11:53:01.551 [ERROR] [handler.ChamberlainMyQGatewayHandler] - Requesting URL Failed
java.io.IOException: java.util.concurrent.ExecutionException: org.eclipse.jetty.client.HttpResponseException: HTTP protocol violation: Authentication challenge without WWW-Authenticate header
        at org.openhab.binding.chamberlainmyq.internal.HttpUtil.executeUrl(HttpUtil.java:148) ~[?:?]
        at org.openhab.binding.chamberlainmyq.handler.ChamberlainMyQGatewayHandler.request(ChamberlainMyQGatewayHandler.java:415) ~[?:?]
        at org.openhab.binding.chamberlainmyq.handler.ChamberlainMyQGatewayHandler.getMyqData(ChamberlainMyQGatewayHandler.java:251) ~[?:?]
        at org.openhab.binding.chamberlainmyq.handler.ChamberlainMyQGatewayHandler.refreshDeviceState(ChamberlainMyQGatewayHandler.java:331) ~[?:?]
        at org.openhab.binding.chamberlainmyq.handler.ChamberlainMyQGatewayHandler.lambda$0(ChamberlainMyQGatewayHandler.java:321) ~[?:?]
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_265]
        at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308) [?:1.8.0_265]
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180) [?:1.8.0_265]
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294) [?:1.8.0_265]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_265]
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_265]
        at java.lang.Thread.run(Thread.java:748) [?:1.8.0_265]
Caused by: java.util.concurrent.ExecutionException: org.eclipse.jetty.client.HttpResponseException: HTTP protocol violation: Authentication challenge without WWW-Authenticate header
        at org.eclipse.jetty.client.util.FutureResponseListener.getResult(FutureResponseListener.java:118) ~[?:?]
        at org.eclipse.jetty.client.util.FutureResponseListener.get(FutureResponseListener.java:101) ~[?:?]
        at org.eclipse.jetty.client.HttpRequest.send(HttpRequest.java:685) ~[?:?]
        at org.openhab.binding.chamberlainmyq.internal.HttpUtil.executeUrl(HttpUtil.java:128) ~[?:?]
        ... 11 more
Caused by: org.eclipse.jetty.client.HttpResponseException: HTTP protocol violation: Authentication challenge without WWW-Authenticate header
        at org.eclipse.jetty.client.AuthenticationProtocolHandler$AuthenticationListener.onComplete(AuthenticationProtocolHandler.java:163) ~[?:?]
        at org.eclipse.jetty.client.ResponseNotifier.notifyComplete(ResponseNotifier.java:198) ~[?:?]
        at org.eclipse.jetty.client.ResponseNotifier.notifyComplete(ResponseNotifier.java:190) ~[?:?]
        at org.eclipse.jetty.client.HttpReceiver.terminateResponse(HttpReceiver.java:444) ~[?:?]
        at org.eclipse.jetty.client.HttpReceiver.responseSuccess(HttpReceiver.java:390) ~[?:?]
        at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.messageComplete(HttpReceiverOverHTTP.java:316) ~[?:?]
        at org.eclipse.jetty.http.HttpParser.handleContentMessage(HttpParser.java:574) ~[?:?]
        at org.eclipse.jetty.http.HttpParser.parseContent(HttpParser.java:1644) ~[?:?]
        at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:1490) ~[?:?]
        at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.parse(HttpReceiverOverHTTP.java:172) ~[?:?]
        at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.process(HttpReceiverOverHTTP.java:135) ~[?:?]
        at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.receive(HttpReceiverOverHTTP.java:73) ~[?:?]
        at org.eclipse.jetty.client.http.HttpChannelOverHTTP.receive(HttpChannelOverHTTP.java:133) ~[?:?]
        at org.eclipse.jetty.client.http.HttpConnectionOverHTTP.onFillable(HttpConnectionOverHTTP.java:154) ~[?:?]
        at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:311) ~[?:?]
        at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:103) ~[?:?]
        at org.eclipse.jetty.io.ssl.SslConnection$DecryptedEndPoint.onFillable(SslConnection.java:426) ~[?:?]
        at org.eclipse.jetty.io.ssl.SslConnection.onFillable(SslConnection.java:320) ~[?:?]
        at org.eclipse.jetty.io.ssl.SslConnection$2.succeeded(SslConnection.java:158) ~[?:?]
        at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:103) ~[?:?]
        at org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:117) ~[?:?]
        at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:336) ~[?:?]
        at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:313) ~[?:?]
        at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:171) ~[?:?]
        at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:129) ~[?:?]
        at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:367) ~[?:?]
        at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:782) ~[?:?]
        at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:918) ~[?:?]
        ... 1 more
2020-12-19 11:53:01.559 [ERROR] [handler.ChamberlainMyQGatewayHandler] - An exception occurred while executing a request to the Gateway: 'null'

it is only built for OH3 for which RC1 is available now, and RC2 will be out very shortly.

java.io.IOException: java.util.concurrent.ExecutionException: org.eclipse.jetty.client.HttpResponseException: HTTP protocol violation: Authentication challenge without WWW-Authenticate header
at org.openhab.binding.chamberlainmyq.internal.HttpUtil.executeUrl(HttpUtil.java:148) ~[?:?]
at org.openhab.binding.chamberlainmyq.handler.ChamberlainMyQGatewayHandler.request(ChamberlainMyQGatewayHandler.java:415) ~[?:?]

This is referencing another binding (chamberlainmyq), not the one i posted, but that Jetty exception is familiar to me, it is thrown if the credentials are not right, or if the token being used is no longer valid .

It is the 2.5.0 snapshot I downloaded from here. I just updated my docker to 2.5.11 from 2.5.10, using now the version that came with 2.5.11 which is 2.5.0.20xxxx and now it’s working. Is there a different myq binding? It is the one from Scott Hanson and posted by scooter_seh on this thread on may 6. Do we have more then one bindings now cause I’ll I see are 1.x bindings in paperui addons browser

I have downloaded the 3.0 version. This is working great on my single door. Sorry I do not have any lights to test.

Hello,
I am a bit confused as to where to put the 3.0 binding. The only add-on file I have is located under /tmp/kar/openhab-addons-3.1.0-snapshot.
Is this where I place the Chamberlin 3.0 binding?
I put it there but I do not find it in the discovery and don’t see any reference to it in the fronttail log.
Thank you in advance for any help you can provide.

/usr/share/openhab/addons

I can’t seem to find a link to the new jar file above… is there a new link?

It looks like it’s now:
https://github.com/digitaldan/openhab-addons/releases/download/myq-wip-1/org.openhab.binding.myq-3.1.0-SNAPSHOT.jar

2 Likes

Cool, thanks. I rooted around the GitHub but couldn’t locate it…

Thanks for the work on this binding. Unfortunately, I’m having difficulty establishing a connection with the myq servers. When I setup the bridge thing, it remains offline. Here is the only message that I’m seeing in the openHAB logs:

2021-01-02 20:21:52.500 [TRACE] [q.internal.handler.MyQAccountHandler] - Sending POST to https://api.myqdevice.com/api/v5/Login

2021-01-02 20:21:53.017 [TRACE] [q.internal.handler.MyQAccountHandler] - Account Response - status: 0 content: null

I did a packet capture on the traffic. It negotiates with the myq server, processes a key exchange, then fails with a “Certificate Unknown” error:

57 4.689685 192.168.1.2 40.71.237.40 TLSv1.2 73 Alert (Level: Fatal, Description: Certificate Unknown)

This behavior is the same in both the 3.0.0 and 3.1.0 snapshots. I have confirmed my credentials in the binding, and I can login via the iOS myq app. Any guidance would be appreciated. Thanks in advance.