Making scene smarter... knows when door open/close?

I have a scene that will trigger both my gate and garage at the same time. This is great when I remember that I closed my gate. But it’ll be just one additional non sense item that I’d need to remind myself whenever I leave. Can I use Pleg to set something like this…

Scene - All Gates
If Gate sensor open, only activate garage
If Garage Sensor open, only activate Gate
if All sensor closed, activate gate and garage.

Can all of this be done in one scene?

PLEG does not use “scenes” per se.

You create inputs (triggers, schedules, or properties).
Inputs are used to create conditions.
Actions fire based on conditions becoming “true”.

These would probably be 3 conditions with applicable actions.

  1. Condition: Gate Open (input: device property) ==> Action: activate garage
  2. Condition: Garage Open (input:device property) ==> Action: activate gate
  3. Condition: Gate Open AND Garage OPEN (input:device properties) ==> Action: activate garage and gate

Conditions are evaluated whenever their items become true and then fire the actions. You can’t look at PLEG in a scene mentality, it’s more of an automation methodology.

I use AutohomationHD on my android phone to activate scene etc… will PLEG intergrate with AutomationHD and Imperihome as it would with a normal scene created in Vera?

Now that I’m reading your conditions again. It reminds me I would also like the same condition to close the gate and garage when I’m leaving.

So it’ll probably be like 6 conditions in 1 event -

If Gate sensor open, only activate garage
If Garage Sensor open, only activate Gate
if All sensor closed, activate gate and garage.

Using the same event everything above will be in reverse so I can close the close the appropriate door

If Gate Sensor closed, only activate garage
If Garage Sensor closed, only activate Gate
If all Sensors open, activate gate and garage

Also would eventually want to graduate this same event into an NFC trigger so I can put stickers in the vehicle

I use PLEG and have gates an garage setup with a Home/Away virtual switch. If everyone shows away then close gate and all garages. When someone arrives home open gate and entry garage door.

I use both Geofence and ping sensor for home and away.

I don’t separate out only send open/closed command is open or closed. My Gates and garages are setup with a lock and unlock button not a single push button. So open command is sent to both for opening and if one is already opened then noting happens to that door or gate. Same as if you send an unlock command to your front door lock and its already unlocked. It just polls and checks its state does nothing further.