Page 1 of 1

Virtual Device "not working" when one of them is already ON

PostPosted: Thu Jun 27, 2019 1:18 pm
by MarcoGT
Hi all,

I have a "Alarm Night" Virtual Device which should go ON when one of the composing device becomes ON and if variable "alarm_night" is true.
Let's suppose that I set this variable to true but at this moment one of the composing device is ON --> Virtual Device is therefore ON.
Of course if then another composing device becomes ON, virtual device does not go ON because it was already ON.

What can I do? Of course I do not want to set all the devices to OFF (window sensors, mainly) to OFF before setting the variable to TRUE.

What is the "Update All" checkbox?

Thanks
Marco

Re: Virtual Device "not working" when one of them is already

PostPosted: Thu Jun 27, 2019 2:39 pm
by jay (support)
Device Groups don't use variables. Can you describe more clearly what your setup is?

Re: Virtual Device "not working" when one of them is already

PostPosted: Thu Jun 27, 2019 4:09 pm
by howartp
There’s all sorts of ways to interpret what you’ve put here, so as Jay says, please try explain further.

What might help is my Variable Device plugin, which mimics your alarm_night variable as a device, which you could then add into the virtual device you already have.


Sent from my iPhone using Tapatalk Pro

Re: Virtual Device "not working" when one of them is already

PostPosted: Thu Jun 27, 2019 11:34 pm
by MarcoGT
I will try to explan my use case better:

I have a Virtual Device called VD1 which includes only window sensors.
At evening, I set the home in "night" mode and the alarm is armed; if the virtual device becomes ON (that means, one of the window get opened), the alarm fires. So far, so good.
In this part on the year we sleep maybe with a couple of windows open, that mean when a set the home in "night mode", that virtual devices is already ON, and if another windowd (which is part of the virtual device but is closed) is opened, the alarm is not fired :)

Re: Virtual Device "not working" when one of them is already

PostPosted: Fri Jun 28, 2019 12:19 am
by howartp
Ok, I’ve got you.

If someone breaks in through a window during night_mode, you have a trigger to sound an alarm when VD1 becomes on.

However because VD1 is already on, due to windows being open when you go to bed, someone breaking in through another window doesn’t trigger the alarm because VD1 doesn’t “become on”.

The virtual devices builtin plugin won’t work for this scenario.

You need to look at one of these three plugins; personally I use the third but only because I already use it elsewhere and is more powerful.

1) Group Change Listener
2) Group Trigger
3) Timed Devices

Peter


Sent from my iPhone using Tapatalk Pro

Re: Virtual Device "not working" when one of them is already

PostPosted: Fri Jun 28, 2019 8:40 am
by jay (support)
howartp wrote:
If someone breaks in through a window during night_mode, you have a trigger to sound an alarm when VD1 becomes on.

However because VD1 is already on, due to windows being open when you go to bed, someone breaking in through another window doesn’t trigger the alarm because VD1 doesn’t “become on”.

The virtual devices builtin plugin won’t work for this scenario.


Well, a single Device Group device won't work in this scenario. You could have multiple device groups (one for windows that are never left open for instance) and use those together in various ways. It could be done without any other plugins, but @howartp is right that there are plugins that make it easier to implement.

Re: Virtual Device "not working" when one of them is already

PostPosted: Fri Jun 28, 2019 10:26 am
by Dual
I have created a Z-Wave and Indigo based custom alarm system using door sensors and motion sensors. I use a variable to count sensor activations. When the alarm is first turned on I set the variable to 0. When a motion is triggered I add 1 to the variable. When a door is triggered I add 2 to the variable. If the variable becomes greater than or equal to 2 I trigger the alarm. Therefore a single motion does not trigger the alarm. You could use the same principle of a variable.

Or, simply create triggers for each window that if they are opened they set off the alarm conditional upon the alarm being enabled. Those that were opened before the alarm was enabled won’t trigger it.


Sent from my iPhone using Tapatalk