MyQ - Chamberlain / Liftmaster / Assurelink combined plugin - updated version

Attached is an updated version of Macrho’s MyQ plugin that now out of the box also supports the Craftsman Assurelink system.

Note: At this time the app has only been tested under UI5.

I have updated Macrho’s original installation instructions and updated them to reflect the new Brand variable I added to the Advanced tab to be able to determine the brand. Valid entries for this field are Liftmaster, Chamberlain and Craftsman.

The rest of the plug-in has been left intact with the exception of setting the Authorization check time to 4 hours instead of 8 and the door status check to 5 minutes instead of 1 and a half minutes. The latter due to reports that Chamberlain may be blocking IP addresses of people banging their servers to often.

INSTALLATION INSTRUCTIONS:
The first step is to copy the files in the zip archive found below to your Vera

Navigate to the APPS tab in the Vera UI and then click on ‘Develop Apps’
Click on ‘Luup files’ and then upload the 6 lua, xml and json files:
-D_MyQGateway.json
-D_MyQGateway.xml
-I_MyQGateway.xml
-L_MyQGateway.lua
-L_MyQGateway_json.lua
-S_MyQGateway.xml

Scroll down a bit and check ‘Restart Luup after upload’ and then click the ‘Go’ button

If you want to use the icon with the device, use WinSCP or another app to ssh to your Vera box.
Copy the “MyQ_Gateway.png” file to /www/cmh/skins/default/icons/

]Now we have to create the device:

Navigate to the APPS tab in the Vera UI and then click on ‘Develop Apps’
Click ‘Create device’ and:

  1. In the Description field type “MyQ Gateway”
  2. In the Upnp Device Filename type “D_MyQGateway.xml”

Finally, click the “Create device” button. A pop-up should occur with “Device created: Dev #”

Click “Reload” on the top right of the Vera UI

If all went right, you should see a warning at the top of the page:
MyQGateway: Username not configured. Password not configured. Brand not configured

Click on the wrench of the MyQ Gateway device and then click on the “Advanced” tab

If you don’t see a “Username”, “Password” or Brand entry under Variables, you’ll need to click on ‘Reload’ again.

Check the Advanced tab of the “MyQ Gateway” device and enter your username and password for MyQ/Assurelink.
Depending on the brand of your opener gateway enter one of the following values in the Brand field:
Liftmaster/Chamberlain MyQ opener - enter Liftmaster
Craftsman Assurelink opener - enter Craftsman
and then click on Save

Your Vera should startup again and create your children device, which are as many garage doors as you have associated to the gateway.

Suggestions/thoughts…

Would be useful to expose the time settings in the Advanced tab.

Check status and restart the device if has not updated/authenticated in a specific time frame.

Something like the following code used to do this with the ISY App…

[code]local runningStatus = luup.variable_get(“urn:garrettwp-com:serviceId:ISYController1”, “DaemonRunning”, 190)
local connectedStatus = luup.variable_get(“urn:garrettwp-com:serviceId:ISYController1”, “DaemonConnected”, 190)

luup.log("ISYCheck: runningStatus = " … runningStatus)
luup.log("ISYCheck: connectedStatus = " … connectedStatus)

if (runningStatus ~= “Running”) then
luup.log(“ISYCheck: Daemon is NOT running - restarting”)
return true
end

if (connectedStatus ~= “Connected”) then
luup.log(“ISYCheck: Daemon is NOT connected - restarting”)
return true
end

luup.log(“ISYCheck: Daemon is connected & running - not restarting”)
return false[/code]

I’ve tried to do that and allow users to set the values on the advanced tab but the app would crash on startup. So for now that is on the back burner. :slight_smile:

I’ve been running the updated version (4 hour authorization interval / 5 minutes status check interval) for the last 10 days and have noticed an improvement in reliability from about 80% to over >90% of the time the door will respond correctly. Leading me to wonder if the original 90 second interval between status checks was causing the MyQ server to start ignoring requests due to ‘resource over use’. Which would explain why the myQ/Craftsman app I tried using after the plugin did not open/close the door, also would not provide results a lot of times.

I really don’t need the status check as I have a garage door sensor installed that tells me the door status already.

BOFH
Things have been working great for me, even with 90 second checks.

One question (feature request - if possible)…
Is there a way we can identify method (remote, door pad, etc) the garage door is being opened?

thanks

I have been wondering that but the unofficial API that Macrho created the plugin from and the info I dug up for Craftsman don’t seem to offer an option for to extract that information. As the renotes and keypads connect directly to the opener and not go through the gateway or the wall controller, there really is no way for MyQ to know if it was a remote or a keypad. All it knows is that the door opened or closed.

I keep get message “Starting Lua engine” followed by message “MyQ gateway"Authorization failed” any idea where I’m going wrong?

You may have neglected to read the first post in this thread that discussed that particular message. However, this version is no longer supported as it has been superseded by the MyQGateway plugin that can be found in the app store and is compatible with both Ui5 and Ui7.

Please uninstall your existing version and install the new one from the app store. Following the installation instructions on that one will most likely solve your problems.

[quote=“BOFH”]You may have neglected to read the first post in this thread that discussed that particular message. However, this version is no longer supported as it has been superseded by the MyQGateway plugin that can be found in the app store and is compatible with both Ui5 and Ui7.

Please uninstall your existing version and install the new one from the app store. Following the installation instructions on that one will most likely solve your problems.[/quote]

Thanks for the response, I did figure that out after the fact. One day I will figure this all out …little by little. …

This clarification helped me a lot!. It wasn’t clear to me that the available MyQ plugin had merged in BOFH’s Craftsman AssureLink modifications. Nothing in the MyQ plugin description alludes to the support of AssureLink (just ‘some rewrites by BOFH’ which isn’t descriptive at all). I’ve been searching around and avoiding the MyQ plugin thinking the code was still forked or incompatible with my device, all this time not knowing it would work just fine.

It made more sense for JoeyD to incorporate my Craftsman mods than for me to adapt his code (and keep adapting) for Craftsman and have 2 seperate plugins. The new MyQGateway plugin supports Liftmaster and Chamberlain MyQ devices as well as Craftsman Assurelink ones. Not only garage door openers but also gate openers and lights. JoeyD also incorporated support for the new WiFi Chamberlain MyQ device that works with most other garage door openers.

Unfortunately, due to the way MyQ operates, the plug-in still has to contact the MyQ servers. Which then contact the gateway and relay your command. This means if you lose internet connection, the plug-in will be unable to operate your garage door, gate or light.