Two doors, one light...

I giggled at my own title… and I’m ashamed of myself.

I know this exists elsewhere. I don’t think it’s necessarily a unique issue, but I haven’t found an adequate expression yet. I have two sets of doors… the two garage doors, and two entry doors. The two garage doors’ statuses are combined in a single condition. The two entry doors are on the same alarm loop so that I can’t differentiate between the front door to the house (which I don’t care about in this case) and the door between the garage and the house (which is the only one that matters here). I’ve given up on any expression that attempts to differentiate between the two. I don’t (yet) have a functional motion sensor in the garage which would give me the ability to narrow down which door is opened or closed. I have a garage camera which has been a little flighty in providing a garage motion signal to Vera.

Currently, I have a condition that turns on the garage light if one of the garage doors is opened or if one of the entry doors is opened. That works just fine, or, as fine as I can expect without a way to differentiate between the two entry doors:

c14_Garage_Doors_Open t16_Garage_Door_1_Opened OR t17_Garage_Door_2_Opened
c38_Garage_Doors_Closed !t16_Garage_Door_1_Opened AND !t17_Garage_Door_2_Opened
c44_Enter_Garage (t23_Front_Entry_Door_Opened AND (c38_Garage_Doors_Closed;t23_Front_Entry_Door_Opened;>5:00)) OR
(c14_Garage_Doors_Open AND (!t23_Front_Entry_Door_Opened;c38_Garage_Doors_Closed;c14_Garage_Doors_Open;>10:00))

What I don’t have is a good expression to turn off the light when I want to. This condition works just fine if I just leave the house… I open the entry door, then get in the car, open the garage door, then leave and close the garage door within five minutes… the condition is satisfied, and the action shuts off the garage light:

c45_Leave_Garage c38_Garage_Doors_Closed AND c28_All_Entry_Doors_Closed AND
(t23_Front_Entry_Door_Opened;c14_Garage_Doors_Open;c38_Garage_Doors_Closed;<5:00)

However… if someone walks through the front door–the one that has nothing to do with this scenario–c44_Enter_Garage is satisfied, which turns on the garage light. And then there’s no subsequent condition to shut off the light. I’ve tried adding an expression onto c45_Leave_Garage, but nothing works as I expect it to. I think 15 minutes after both entry and garage doors closed is a reasonable time.

Can anyone advise me on how to modify c45_Leave_Garage?

The two following two conditions are complementary:
c14_Garage_Doors_Open t16_Garage_Door_1_Opened OR t17_Garage_Door_2_Opened
c38_Garage_Doors_Closed !t16_Garage_Door_1_Opened AND !t17_Garage_Door_2_Opened

So you can eliminate one and just use the !OfTheOneYouKeep

I would probably keep the first and remame to c14_Any_Garage_Door_Open

As far as your problem … I would:

  1. Create a 10 Minute self retriggerable timer. Triggered on your c44_Enter_Garage condition.
  2. Then:
    c45_Leave_Garage c38_Garage_Doors_Closed AND c28_All_Entry_Doors_Closed AND (c45_Enter_Garage; !YourTimerName)
    [hr]
    Demorgan’s Theorem states:
    !(A and B) is equal to !A or !B
    And
    !(A or B) is equal to !A and !B

[quote=“RichardTSchaefer, post:2, topic:188571”]The two following two conditions are complementary:
c14_Garage_Doors_Open t16_Garage_Door_1_Opened OR t17_Garage_Door_2_Opened
c38_Garage_Doors_Closed !t16_Garage_Door_1_Opened AND !t17_Garage_Door_2_Opened
So you can eliminate one and just use the !OfTheOneYouKeep

I would probably keep the first and remame to c14_Any_Garage_Door_Open[/quote]
Yes, they absolutely are complementary… does it save anything other than keystrokes, though? I figured since I wasn’t creating a new trigger, and the result would be the same number of conditions, it wouldn’t matter either way. Let me know! I’m all for efficiency improvements.

[quote=“RichardTSchaefer, post:2, topic:188571”]As far as your problem … I would:

  1. Create a 10 Minute self retriggerable timer. Triggered on your c44_Enter_Garage condition.
  2. Then:
    c45_Leave_Garage c38_Garage_Doors_Closed AND c28_All_Entry_Doors_Closed AND (c45_Enter_Garage; !YourTimerName)[/quote]
    I haven’t played with timers. In fact, I don’t even have PLTS installed. I suppose I need to do that.

You do not need PLTS !!!

Reread the PLEG basics …

You can create a timer in PLEG.
Using the Schedule Tab!
Create a timer, Give it a name, Set the ON Type to SelfRetrigger … the Off Type to Interval with the appropriate timer value (seconds, minutes, hours, …)

Use the Advanced Tab in an Action to start the timer, select the current PLEG device, action is StartTimer, specify the timer name you created.

To use it in a condition you typically use:
AND (ConditionThatTriggeredTimer; !TimerName)

Which is true when the timer timeouts after being started.

Ah hah! Thank you. +1 no-longer-existing karma point.

P.S. - you have one more post to 7,000.

Here’s what I did, based on RTS’s instructions… I haven’t tested it yet, but it makes sense:

New schedule:
s3_Garage_Light_Timer

New condition expression:
c45_Leave_Garage c38_Garage_Doors_Closed AND c28_All_Entry_Doors_Closed AND ((t23_Front_Entry_Door_Opened;c14_Garage_Doors_Open;c38_Garage_Doors_Closed;<5:00) OR (c44_Enter_Garage;!s3_Garage_Light_Timer))

This worked, incidentally. Thanks!