How to make virtual switch track another sensor

I’m using a virtual on/off switch with Alexa Helper to allow the Amazon Echo to control a Linear Z-Wave Garage Door Opener. I named the virtual switch “Garage Door” so I can tell the Echo “Alexa, Turn On The Garage Door” to open it, and “turn off” to close it.

However, the virtual switch does not track the state of the opener, so if I manually open the garage door, the real garage sensor shows open, but the virtual switch shows “Off”. Therefore, when I tell the Echo to “turn off” the garage door, she says “OK” but does nothing since it’s already off.

It seems like there would be something built in to either make the virtual switch track the state of the garage door (preferable) or to make it always trigger the close/open action even if the switch is already in that associated state.

Can anyone point me in the right direction? Thanks.

You can use the build in smart lighting app or rule machine to sync the two switches together. I am using smart lighting to sync my smart bulbs and smart switch together.

1 Like

That worked perfectly. Thank you so much!