# Ubiquiti UniFi Protect - Motion Sensor state/status

**URL:** <https://community.homey.app/t/ubiquiti-unifi-protect-motion-sensor-state-status/114854>\
**Category:** Apps\
**Tags:** advancedflow\
**Created:** [August 23, 2024, 3:17am UTC](https://community.homey.app/t/ubiquiti-unifi-protect-motion-sensor-state-status/114854 "2024-08-23T03:17:02Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![Lane\_Canada](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/lane_canada/32/92195_2.png) [@Lane\_Canada](https://community.homey.app/u/Lane_Canada)\
**Post date:** [August 23, 2024, 3:17am UTC](https://community.homey.app/t/ubiquiti-unifi-protect-motion-sensor-state-status/114854/1 "2024-08-23T03:17:02Z")

</div>

Hello,  
I am brand new to Homey… My first Advanced flow challenge is to create a flow that turns on the entry lights when motion detected there and then off after x minutes. I am using a UniFi Protect Sensor, motion and LUX enabled. The motion alarm has gone off on the sensor, 4 hours ago when I first installed it and it is still flashing “YES Motion Alarm”. There seems to be TWO motion icons, one reports motion with a date and when I hover the mouse over, indicates 4 hrs ago. The other reports Last motion but time. THIS one is realtime and reports immediately when there is motion.

Despite all this, if there IS motion, the lights do not turn on. I tried a flow where “If motion, dim to 100%” Trying in zone active…" as well but no luck. Anyone have experience working with the motion sensor? Any help appreciated.

 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/1/a/1a3b8691c6449295dbf00ecc2acea969e426ab10.png)

 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/6/9/69c9736b50210675fb296897608de32713e47283.png)

---

<div class="post-metadata">

**Author:** ![Rmb](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/rmb/32/79135_2.png) [@Rmb](https://community.homey.app/u/Rmb)\
**Post date:** [August 23, 2024, 7:04am UTC](https://community.homey.app/t/ubiquiti-unifi-protect-motion-sensor-state-status/114854/2 "2024-08-23T07:04:23Z")

</div>

Start by making the simplest flow and excluding all possible errors:  
WHEN motion detected THEN make a timeline notification.  
If that works, extend the flow step by step.

---

<div class="post-metadata">

**Author:** ![DirkG](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/dirkg/32/118897_2.png) [@DirkG](https://community.homey.app/u/DirkG)\
**Post date:** [August 23, 2024, 10:18am UTC](https://community.homey.app/t/ubiquiti-unifi-protect-motion-sensor-state-status/114854/3 "2024-08-23T10:18:26Z")

</div>

If the Motion Sensor didn’t cancel the motion detection 4 hours after last motion detection, then there seems to be a hardware problem, a problem with the Ubiquiti UniFi Protect App or some configurations of the MS are not correct. But because I don’t use this MS nor the UUP App, I don’t have any experiences with this and can’t give you some suggestions.  
But in my opinion, these are the first things you should check.  
If there are issues with the UUP App or you need some help regarding the UUP App, please continue in the corresponding topic: → [[APP][Pro] Ubiquiti UniFi Protect](https://community.homey.app/t/app-pro-ubiquiti-unifi-protect/42966)

The second issue is, that your Advanced Flow is created incorrectly.  
The used flow card _ **The zone IS active** _ is an _ **And…** _ flow card or also called _ **Condition** _ flow card.  
Every flow **must** begin with a _ **When…** _ flow card, also called _ **Trigger** _ flow card. So something must happen or change to start a flow.  
In your case the first flow card must be one of these here: _ **The motion alarm turned on** _ or _ **The zone BECAME active** _.  
To ensure that the light will be switched off again when no movement is longer detected, you need at least a second flow with an other _ **When…** _ resp. _ **Trigger** _ flow card: _ **The motion alarm turned off** _, _ **The zone became inactive** _ or _ **The zone became inactive since x minutes** _.

---

<div class="post-metadata">

**Author:** ![Lane\_Canada](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/lane_canada/32/92195_2.png) [@Lane\_Canada](https://community.homey.app/u/Lane_Canada)\
**Post date:** [August 23, 2024, 12:45pm UTC](https://community.homey.app/t/ubiquiti-unifi-protect-motion-sensor-state-status/114854/4 "2024-08-23T12:45:22Z")

</div>

I have re-asked the question in the appropriate topic section. Thank you for the suggestions and advice here.

---

<div class="post-metadata">

**Author:** ![Peter\_Kawa](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/peter_kawa/32/173848_2.png) [@Peter\_Kawa](https://community.homey.app/u/Peter_Kawa)\
**Post date:** [August 23, 2024, 4:18pm UTC](https://community.homey.app/t/ubiquiti-unifi-protect-motion-sensor-state-status/114854/5 "2024-08-23T16:18:03Z")

</div>

Better, use Simple Log log cards:  
The timeline process can get rate limited (= shut down) w/o any notification whatsoever.  
Can result in many new gray hairs 😜

---

<div class="post-metadata">

**Author:** ![Lane\_Canada](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/lane_canada/32/92195_2.png) [@Lane\_Canada](https://community.homey.app/u/Lane_Canada)\
**Post date:** [August 23, 2024, 4:38pm UTC](https://community.homey.app/t/ubiquiti-unifi-protect-motion-sensor-state-status/114854/6 "2024-08-23T16:38:02Z")

</div>

Sorry, I don’t understand what you wrote

---

<div class="post-metadata">

**Author:** ![Rmb](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/rmb/32/79135_2.png) [@Rmb](https://community.homey.app/u/Rmb)\
**Post date:** [August 23, 2024, 8:01pm UTC](https://community.homey.app/t/ubiquiti-unifi-protect-motion-sensor-state-status/114854/7 "2024-08-23T20:01:03Z")

</div>

In that case you would notice a lot of messages in the time line. And it is making things complexer as you can see by the response of the topic starter 😥  
So it is even better to start with simple flows, so see the difference between triggers/events and conditions. In Homey terms in WHEN and AND carts. Quite basic but essential principles to know.  
Some how advanced flows seem very attractive to novice Homey users. Probably because it does not look like programming, but it is. A pitfall.

---

<div class="post-metadata">

**Author:** ![Lane\_Canada](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/lane_canada/32/92195_2.png) [@Lane\_Canada](https://community.homey.app/u/Lane_Canada)\
**Post date:** [August 24, 2024, 3:40am UTC](https://community.homey.app/t/ubiquiti-unifi-protect-motion-sensor-state-status/114854/8 "2024-08-24T03:40:38Z")

</div>

Appreciate the feedback. It is definitely not programming. The issue isn’t that I am a novice. It is that the motion alarm NEVER stops… still going 8 hours later. Yes, I get that my initial post here looked bad… I fixed it quickly here on my end.

I put the Hue motion sensor back in the entryway and it uses a “motion alarm” as well but when motion stops the alarm turns off. The UniFi Protect sensor integration with Homey just simply does not work. A pitfall of community or open source I suppose. Always bugs, always something broken.

Here is the flow I have now using the Hue motion sensor and it works fine.

 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/b/5/b55054bb53d29c7af481ec8418e2a35de6582bf9.png)

---

<div class="post-metadata">

**Author:** ![Rmb](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/rmb/32/79135_2.png) [@Rmb](https://community.homey.app/u/Rmb)\
**Post date:** [August 24, 2024, 7:48am UTC](https://community.homey.app/t/ubiquiti-unifi-protect-motion-sensor-state-status/114854/9 "2024-08-24T07:48:23Z")

</div>

In the Advanced Settings there might be a “Time out to reset sensor value” which you can set for example to 1 minute.

---

<div class="post-metadata">

**Author:** ![DirkG](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/dirkg/32/118897_2.png) [@DirkG](https://community.homey.app/u/DirkG)\
**Post date:** [August 24, 2024, 11:35am UTC](https://community.homey.app/t/ubiquiti-unifi-protect-motion-sensor-state-status/114854/10 "2024-08-24T11:35:07Z")

</div>

Please don’t use the build-in delay card to turn off the lights. Instead of _ **The motion alarm turned off** _ in combination with the build-in delay card, please use the flow card _ **The zone is inactive for 2 minutes** _ → _ **Turn All Lights off** _.  
In this [post](https://community.homey.app/t/philipps-hue-aussenbewegungsmelder-was-fur-ein-schrott/94239/15) I tried to explain the reason, why the build-in delay card can lead to an unwanted behavior. It’s just in German, but with a translator I guess it will be understandable. If not, just ask.
