Off actions not working

petematheson
Posts: 847
Joined: Sun Sep 14, 2014 9:51 am
Location: Southampton, UK

Off actions not working

Post by petematheson »

I realised I can use this to replace my Life360 location for when me & my wife are home / away.

I've created 3 Action groups that modify 1 variables. One sets home, one sets away, one toggles.
I've created the Virtual On/off device that sets each action group for On/Off as well as the Toggle and monitor status of the variable it's changing.

But if I go into Home and tap the device, only the 'On' action works. Off never actually switches the device off.

Have I missed something please? :)
rehafer
Posts: 285
Joined: Fri Feb 08, 2013 2:50 pm

Re: Off actions not working

Post by rehafer »

Did you create a variable to track on off state? That tripped me up once with something similar


Sent from my iPhone using Tapatalk
petematheson
Posts: 847
Joined: Sun Sep 14, 2014 9:51 am
Location: Southampton, UK

Re: Off actions not working

Post by petematheson »

I have 1 variable that is being set by 3 action groups.
On / Off and Toggle

Mind explaining how the extra variable to track the off state works?


Sent from my iPhone using Tapatalk
rehafer
Posts: 285
Joined: Fri Feb 08, 2013 2:50 pm

Off actions not working

Post by rehafer »

When you configure your Virtual On/Off Device there a check box for support status, below that a drop down menu to choose which variable the On/Off is stored in.
It’s my understanding that, in HomeKit, a switch can’t be turned “Off” unless it’s currently “On”, and that state information comes from that variable.


Sent from my iPhone using Tapatalk
petematheson
Posts: 847
Joined: Sun Sep 14, 2014 9:51 am
Location: Southampton, UK

Re: Off actions not working

Post by petematheson »

Ah yep I have that set, so I have 3 action groups but pointing at just 1 variable.

Action group to set the variable on
One for off
And one to toggle the variable


Sent from my iPhone using Tapatalk
rehafer
Posts: 285
Joined: Fri Feb 08, 2013 2:50 pm

Re: Off actions not working

Post by rehafer »

I think the status has to be Boolean, True/False; but that’s about the limit of my experience with Virtual Devices.


Sent from my iPhone using Tapatalk
petematheson
Posts: 847
Joined: Sun Sep 14, 2014 9:51 am
Location: Southampton, UK

Re: Off actions not working

Post by petematheson »

Ahhh good point.
Tried changing to True/False and that seems to be at least changing back to false now.

Will give that a test today to see how it plays - cheers!
Post Reply

Return to “HomeKit Bridge”