The code you posted worked for me. Only thing that could make it better is if the sensor could be polled every min or so. Seems that if I use my normal garage door opener smartthings is not refreshing the door status to tell me the state has changed. I have to hit the refresh button within smartthings to read the correct state. Thanks again codahq! It’s definitely closer to working perfectly for me.