Porch light motion detection Automation to avoid automatic turnoff during fixed period of time

As I was migrating from the Smart Lighting app to use Automations, I ran into an annoying limitation. Previously I had it set to turn off my porch lights at 9pm every day, but then turn them on for 5 minutes if my Ring doorbell detects motion, all the way up through sunrise. This is a “period of time” automation, but in the Automations section of the new app, the only way I can select sunrise is if I bound both the start and end times to sunrise or sunset. No option to have start time be fixed and end time be sunrise/sunset, which is quite frankly a stupid oversight.

I don’t want to have the motion activity start turning off my light early in the evening, especially in the winter months. You can offset from sunset by up to 2 hours but that wouldn’t be enough in December. Nor do I want to set a fixed time to end this automation in the morning either.

Fortunately I realized a workaround. I settled on using the “Night” period of time, but also added a precondition to only activate if the light is already off. I have another automation that turns several lights on at sunset (including the porch), and one that turns just the porch off at 9. This way the motion detection automation can pass the precondition and turn itself back off again.

1 Like

I have almost the same routines setup – it does take multiple routines.

The first turns on the outdoor lights at sunset (with an offset, if you prefer).

The second turns the porch light off at a fixed time (midnight in my case).

The third has sunrise to sunset as a precondition, and that the porch light is off. If motion is detected, turn the porch light on and then off a few minutes later.

The fourth routine turns all the outdoor lights off at sunrise (with an offset, if you prefer).

This also means if someone manually turns off the porch light earlier, it will still activate on motion.

2 Likes