Scene with conditions

Hello guys,

I am looking for some advice.

I would like to create a scene to arm the alarm system but the scene doesn’t arm the alarm system if the alarm system is not in an arming state. Due to this I would like to run some checks and see all the sensors from my alarm system e.g. door sensors, window sensors, etc are closed allowing me to arm the alarm system.

My ultimate goal is to use my Sonos speakers to provide the feedback like this:

A) Check if all windows and doors are closed

B1) if no, verbal output “Lockdown stopped. Sensor XYZ is not closed”. Don’t execute any other scene or command and just stop.
B2) if yes, verbal output through Sonos “Arming initiated”

C) If yes, verbal output through Sonos “Alarm system armed in 123 mode”.

The issue I have is how do I run the checks via e.g. LUUP code and only if the yes, run the other scene which arms the alarm system. I assume I have to use 2 scenes to accomplish this unless I can use a single scene with the checks.

Looking for ideas. Thanks.

[quote=“Pseudomizer, post:1, topic:190493”]Hello guys,

I am looking for some advice.

I would like to create a scene to arm the alarm system but the scene doesn’t arm the alarm system if the alarm system is not in an arming state. Due to this I would like to run some checks and see all the sensors from my alarm system e.g. door sensors, window sensors, etc are closed allowing me to arm the alarm system.

My ultimate goal is to use my Sonos speakers to provide the feedback like this:

A) Check if all windows and doors are closed

B1) if no, verbal output “Lockdown stopped. Sensor XYZ is not closed”. Don’t execute any other scene or command and just stop.
B2) if yes, verbal output through Sonos “Arming initiated”

C) If yes, verbal output through Sonos “Alarm system armed in 123 mode”.

The issue I have is how do I run the checks via e.g. LUUP code and only if the yes, run the other scene which arms the alarm system. I assume I have to use 2 scenes to accomplish this unless I can use a single scene with the checks.

Looking for ideas. Thanks.[/quote]

Time to move from the stock scenes and use the PLEG plugin. All this can be done with PLEG but it’s to much for the stock scenes.

I have PLEG installed and I am using some rudimentary items with the day and night plugin. This is much more complex and I wouldn’t know where to start with PLEG for this. On top of this the licensing schema for PLEG is complicated. I purchased one license and I don’t know how many devices, rules, etc. i could use hence my initial ask but that doesn’t mean I would give it a shot with some help. :wink:

Once license will allow you to create 4 PLEG plugins.

EACH plugin can have an unlimited number of inputs, conditions, and actions. Only limited by the processing power of your Vera and your imagination!

This wasn’t posted in the PLEG section so I didn’t assume you already had PLEG. But Stock scenes are to limited to handle your complex ideas.

PLEG gives you a max of 4 different plugins or PLEG devices per each license (which is like 6.00). Each one of these devices you can have basically (VERA RAM/CPU is your limit) no limit to amount of devices (triggers or inputs), condition’s, or actions. Your limit is when it gets to cluttered then you should start a 2nd PLEG plugin. I use 4 myself and have them spread out by tasks to organize myself. ALL light controls in one, HOME/AWAY in another, notfications in another and so on. I probley have an average of 30-50 triggers and 30ish conditions per each one.

It would be safe to say you’ll probley never need a 2nd license unless you choose to for your own organizational sake. So 6.00 is the normal anyone should spend on pleg. That is per vera and it is tied to your vera ID, which means if you change VERA’s (upgrade, swap out what ever) you will have to pay 6.00 again for the next vera u purchase.

Once you get that setup PLEG basics PDF (search the forums) is a good place to start. Get all your inputs/triggers your going to use in this case entered into PLEG. for PLEG help we always ask you print your “STATUS” report in PDF forum and post it with your question. It will show us everything we need to help or trouble shoot.