Dashboard - motion sensor status

Good evening,
I am a new user of Gladys 4. First, congratulations to everyone for the work accomplished.
I’m taking it step by step. I installed a Sonoff Zigbee motion sensor (SNZB-03) and I’m displaying the parameter values on the dashboard. But for the parameter « détection mouvement oui/non » it shows me the time elapsed since the last state change (whether that change was from true to false or false to true).
Is this a bug on my end? Is it intentional?
For my part I would have liked it to return the occupied or not value (which is correctly provided on the z2b interface), because as it stands I don’t know whether the room is occupied, I only know that something happened x time ago.

Thanks for your help.

Hello and welcome!
Motion detectors do indeed send a state change to Gladys, which can then tell you how much time has passed since the last information was received.
It’s up to you to tell Gladys what to do with that information (turn on a lamp? Send a message? Trigger the alarm? Mark a user as present? Etc.) via scenes by setting the device’s state change as the trigger…

Hello,
and @GBoulvin thank you for your reply. I did indeed test using the detector in a scene and it works very well (I turn on a lamp when the state becomes true and turn it off when it goes back to false). But it’s in the dashboard that I’m surprised by the information displayed for the parameter « motion detection ». For the other parameters, it correctly returns the value and not the date when it was modified.

In fact, a motion detection is an event and not a state.
If we displayed the state, you would see Presence for half a second then back to No Presence.
It was chosen to show when the last event occurred.

Very well, thanks for the info :ok_hand:
I thought I had a bug because in the zigbee2mqtt console you can see a variable

Ah yes, you’re right. I’ll run a test by changing the type of this variable and see how it looks in the dashboard. I’ll keep you posted.

1 Like

I have the same sensor and I can confirm to you that there is a 1-minute delay between each trigger.

Hello,
For some models it is possible, in the exposé, to adjust this delay.

Indeed, this is the case for Aqara devices in particular.

Good evening to you
I’m taking advantage of this thread, which is about the motion detector
I also have these sensors (Aqara and MI), but I’m having trouble managing scenes with the wait function.
I trigger a scene when the Aqara detector switches to « true », I turn on a ceiling light and wait 10 minutes to turn it off.
If I walk past the sensor several times, it disrupts the timeout duration
and the ceiling light turns off before the 10 minutes.
I think it’s due to multiple consecutive passes in front of the sensor, which trigger multiple starts of the timer and therefore multiple ends of the timer, and the ceiling light would turn on at the start of one timer and turn off at the end of another (I hope I’m being clear).
Do you encounter this problem or am I managing my scene incorrectly?
thanks for your help

You shouldn’t put a « wait » in your scene, but have 2 separate scenes: one for turning on and one for turning off :slight_smile:

I invite you to watch my video on the subject: https://youtu.be/gNlZ2bId8Z0?si=z5C78yM6_JDM71hQ\u0026t=848

I’ll try your scene, thank you again

1 Like

[quote=« cicoub13, post:6, topic:8508, full:true »]
Ah yes, you’re right. I’ll run a test by changing the type of this variable and see

So, I have two proposals.

If I modify the motion detectors to display them in a binary way, it looks like this.

If I create a specific type for motion detectors, we’re freer and we could have something like this

What do you think?

2 Likes

For me it’s the second option :+1:

Same here but not sure about the red color haha (infraction: yes, otherwise no ^^)

2nd choice as well

2D too :+1:

I don’t understand, isn’t that already the current behavior?

Good point, on my side I have:
Presence Detector 1\t5 minutes ago
Presence Detector 2\ta few seconds ago