[RELEASE] Enhanced Z-Wave Garage Door Controller GD00Z-4/GD00Z-5/Linear/GoControl/Iris/Nortek Device Handler with Switch and Automated Garage Door Open/Close when People Arrive/Leave/Timer

OOPS, good point. Wonder why you didn’t point that out last time. Any way the logs still don’t prove that you didn’t reset the device using the tilt sensor.

I just asked if your code preserves the Alert-to-close beep required in the
US by UL 325 for unattended closure, since you only mentioned two statuses, and I didn’t see a " closing" status in the log you posted, although maybe I missed it.

Separately, if your code does reset status after a loss of power, then that would be a loss of a separate safety feature, since in the US garage door lifts are supposed to require a manual cycle after power loss before allowing an unattended close again. The lift is designed to continue to send “unknown” as the only status until the attended cycle is complete. It should not just change because of polling/refresh after the power comes back on. There has to be an attended cycle first. This is intended to force the homeowner to make sure the path is unobstructed and the door undamaged.

But I wasn’t making assumptions, just asking. You’ve used some UK/Canadian expressions like “turn off the mains,” so I didn’t know if you were in the US or not.

The features I was referring to are safety features of the lift installation.

I actually have no idea why it works - I haven’t made any changes or anything to do with “resetting” any sensors or manually tilting anything (paranoia!). It just does, even with the stock ST Z-Wave Garage door opener code it works fine. I just hit refresh a couple of times and a couple of minutes it shows up as closed (I’ve never tried a power failure on an open door, maybe I’ll try it tomorrow but on a closed door it just syncs up by itself). The only explanation I can think of as I said before if that controller knows the position of the sensor and I guess it polls it a few times and figures that if the sensor is reporting closed then the door must be down.

Note I’ve placed my sensor on the TOP edge of the garage door (which is what I believe the instruction say, NOT at the bottom), that way the moment the garage door starts to open the sensor shows it as open (or opening depending upon how the firmware interprets it).

I mean even part from that, I’ve noticed that the controller (or ST Device Class) is pretty smart. As in, say if the door is closed and you “force” a close Z-Wave command, it ignores it. Similarly if it’s Open and you “force” a Open command it too ignores it. You can actually write a custom app to use the switch interface to play and see how it reacts to conditions. The only way the controller or device class seems to operate is once the sensor is in a know position and the command being asked is the opposite of the current sensor status. I.e. the door open/close command is “ignored” if the sensor status unknown, but like I mentioned above with my GD00Z-4 device which i bought from the link below when the door is closed and the power fails, I just need to hit refresh a couple of times and wait for a few minutes to “resync” itself. No magic.

If anyone’s interested the device I bought was from here http://www.amazon.com/gp/product/B00M75TEIU/ref=oh_aui_search_detailpage?ie=UTF8&psc=1

From what I’m reading, it sounds like @RBoy just implemented the on()/off() and push() commands of the switch and momentary capabilities. I don’t think he worked around any limitations - just added new commands to existing functionality. (Meaning he hasn’t done anything that would mess with UL requirements.)

(Perhaps not, as push() would have had to be implemented previously in order to work with the ST “doors and locks” built in smartapp.)

In my own device type, I’ve specifically chosen NOT to implement on()/off(), as they don’t make clear sense to me in the context of a door. However, if anyone asks, they are trivial to implement.

Here are basic implementations of all three (code licensed under ApacheV2 from which it came):

def push() {
    // get the current "door" attribute value
    def lastValue = device.latestValue("door");
    // if its open, then close the door
    if (lastValue == "open") {
        return close()
    // if its closed, then open the door
    } else if (lastValue == "closed") {
        return open()
    } else {
    	// this happens if the door is "unknown", in the process of opening or in the process of closing
    	log.debug "push() called when door state is $lastValue - there's nothing push() can do"
def on() {
    close() // or open() depending on how you want to interpret "on" in the sensor of a door
def off() {
    open() // or close() depending on how you want to interpret "ooff" in the sensor of a door

That’s correct @garyd9.

For those who would like to customize it themselves don’t forget to register the switch status in the z-wave event handler also to update the switch status otherwise it won’t function properly. The code be something like (again like gary said depending upon your logic of implementing door handling):

createEvent(name: "switch", value: "on")

I just installed the Linear GD00Z-4. I also created a new device type and re-used your code. (code is well written and I very much appreciate it) I was able to get the Linear to Open and Close the door a couple of times and then it went to “unknown” state again. I did the Live debugging and it showed me the

506fb651-7a56-4804-99bb-3b69adbfb0ad 3:03:43 PM: debug "zw device: 3B, command: 9881, payload: 00 71 05 00 00 00 FF 06 45 00 " parsed to [‘displayed’:true, ‘descriptionText’:North Garage Door remote operation disabled (UL requirement), ‘isStateChange’:false, ‘linkText’:‘North Garage Door’]

I also got this debug message too

506fb651-7a56-4804-99bb-3b69adbfb0ad 3:02:50 PM: debug "zw device: 3B, command: 9881, payload: 00 71 05 00 00 00 FF 06 46 00 " parsed to [‘displayed’:true, ‘descriptionText’:North Garage Door failed to perform operation due to device malfunction, ‘isStateChange’:false, ‘linkText’:‘North Garage Door’]

My question is what can I do about those error codes. Is there a manual or something you can point me to to figure this out?

Would really appreciate any help!

There was no power outage though. I was just in my garage using ST to open and close the garage door a few times to make sure I had everything installed properly and it was working. I opened it the garage door up and closed it a couple of times and then it went to “unknown”. I must have done something wrong or have another problem,

You replied to one of posts, but it doesn’t sound like your using my device type… It does sound like you might have a power issue, a poor connection, or a faulty gd00z unit.

Someone responded to my last post that I had a power outage. But I was standing right in the garage. I know that was not the case and then they withdrew the post.

In any case, I used the device type you posted here.

I followed the directions and installed it. It is called “My Z-Wave Garage Door Opener”.

It shows up in Doors and Locks too now. That shows the door as closed. (I assume that is the sensor part)
I can also import into lights and switches. Right now it shows “unknown”.

When I do live logging and I press open/close I got this again.

506fb651-7a56-4804-99bb-3b69adbfb0ad 5:52:08 PM: debug "zw device: 3B, command: 9881, payload: 00 66 03 FD " parsed to [[‘name’:‘door’, ‘descriptionText’:North Garage Door door state is unknown, ‘value’:‘unknown’, ‘isStateChange’:false, ‘displayed’:false, ‘linkText’:‘North Garage Door’]]
506fb651-7a56-4804-99bb-3b69adbfb0ad 5:52:08 PM: debug encapsulated: BarrierOperatorReport(barrierState: 253)
506fb651-7a56-4804-99bb-3b69adbfb0ad 5:52:08 PM: debug "zw device: 3B, command: 9881, payload: 00 71 05 00 00 00 FF 06 45 00 " parsed to [‘displayed’:true, ‘descriptionText’:North Garage Door remote operation disabled (UL requirement), ‘isStateChange’:false, ‘linkText’:‘North Garage Door’]
506fb651-7a56-4804-99bb-3b69adbfb0ad 5:52:08 PM: debug encapsulated: NotificationReport(event: 69, eventParameter: [], eventParametersLength: 0, notificationStatus: 255, notificationType: 6, reserved61: 0, sequence: false, v1AlarmLevel: 0, v1AlarmType: 0, zensorNetSourceNodeId: 0)
506fb651-7a56-4804-99bb-3b69adbfb0ad 5:51:56 PM: debug "zw device: 3B, command: 9881, payload: 00 66 03 FD " parsed to [[‘name’:‘door’, ‘descriptionText’:North Garage Door door state is unknown, ‘value’:‘unknown’, ‘isStateChange’:false, ‘displayed’:false, ‘linkText’:‘North Garage Door’]]
506fb651-7a56-4804-99bb-3b69adbfb0ad 5:51:56 PM: debug encapsulated: BarrierOperatorReport(barrierState: 253)

These error messages … I could find right in your code. I don’t think I have a power issue. Standard outlet and I secured the gd00z with the bracket. The connection seems tight to the unit. I can check again though.

I reset everything. Double checked the connections. Reverified the power was good. Opened the door and closed it with the normal remote (no ST). I Got ST to open the door and then close the door but then went back into this “unknown state” again. More logs but they look the same…

[quote=“TobinKrueger, post:30, topic:10578”]
In any case, I used the device type you posted here. //github.com/garyd9/smartthings/blob/master/my_z-wave_garage_door_opener.groovy
[/quote]Can I suggest moving this conversation to the other thread, then?

(It’s less confusing for device type folks if the issues concerning their devices types are in the threads for that type…)

I’ll go ahead and reply to this stuff over there…

Take care

Just added support for native garage door capabilities for the Z-Wave Garage Door Opener with Switch Capability device type. Now you can control the garage door using the Good Morning, Good Night actions.

Just bought this device. Trying to load your app so that “close it when people leave” or ability to use with IFTTT works. Clicked on link to your app and it requires a password. How can I get your app?

Rboy charges for his code. Most of the community members share theirs freely or have a donate button for after you’ve tried it and liked it.

If you have the Linear GD00Z, I recommend the free device type from
GaryD9 . It’s very popular.


Yes, for a small one time contribution you can have access to all my premium apps and device types on a single server with instructions. If you have ideas for new apps or features feel to drop me a line.

@WTLimitless I agree with JDRoberts. I used GaryD9’s version and it works great. I made a few small tweaks and have my own copy but his should work for you.

If you want the on/off features so it can act like a switch I would be happy to add that to my version of this device and share with you. No need to pay anything for this device code.

1 Like

Don’t forget to register the events if you’re using the free versions:

Hi @Ron, I’d love it if you’d share your device code. My goal is to just be able to use the linear device as a relay switch as well. That way, I can use it with IFTTT and use the “close it when people leave” function. Will your device code do that? How is it different from GaryD9 and will I have to do that thing where I copy code to IDE?


I also posted a block of on/off code enabling stuff in the thread a while back. It’s been working fine for me as well, allowing control via minimotes and hello home phrases and whatnot.

@WTLimitless Sure you can get it here

I just added a few features I have been wanting.

  1. Added a DisplayOnly Open/Close Tile
    I added this because I hate that when I try to open the device I sometimes miss the little gear in the upper right corner and hit the tile instead. This opens or closes the door when I did not intend. So I added this static (no action) display only tile that can be selected as your preferred main display tile of you too have this issue.
  2. Added On/Off button. Since we added switch I also added the button to display the state. Helps someone understand what On maps to and what Off maps to since you will always see the state of both buttons. I have considered adding a preference which selects if ON=Open or Closed. For an electrician On = closed as in closed circuit, and Off = Open as in open circuit. For the rest of us On=Open Off=Closed is likely more intuitive. But I have not done this yet. I opted for On=Open Off=Closed
  3. I also cleaned out a few confusing comments

I didn’t need to add the events Rboy mentions, I am pretty sure they are already there. Not sure why he says they were not. He might have been referring to GaryD’s version but then he didn’t implement on/off so it makes sense he didn’t have the events.

Anyway enjoy and let me know if you need any help or have any suggestions.
Keep in mind when testing the linear has a delay between commands which will ignore additional commands. So don’t try to open and then immediately close it will seem like the app is failing since things will not work. Wait a minute or two between presses and it works fine.

My version looks like this.