MadMonkey87 / HomeyCONZ

deCONZ app for Athom Homey smart home controller
3 stars 14 forks source link

Aqara Vibration sensor: Vibration alarm "last triggered" state resets every few minutes #48

Closed iisworks closed 3 years ago

iisworks commented 3 years ago

Describe the bug:

On all Aqara Vibration sensors when I look at the data fields, the "Vibration alarm" state will automatically reset approximately every 10 minutes ("X minutes ago"), even when no vibration alarm was detected. This makes it impossible to see when it last actually triggered if it was for example hours ago. Note: flows trigger correctly only when the alerts is actually triggered, and the history also shows correct alert times. So it seems to be a UI issue.

How to reproduce:

How it should work:

The "Vibration alarm" state should indicate the last time the alarm actually triggered, so if it triggered 55 minutes ago it should display "55 minutes ago" and not reset every 10m.

Screenshots:

The "X minutes ago" will go from 1 - 10m and reset again, even when the last actual alarm was hours ago: image

iisworks commented 3 years ago

@MadMonkey87 Could you please comment if this can be looked at? This would make a huge difference in usability for these devices.

MadMonkey87 commented 3 years ago

This is not exactly a bug but rather a philosophical question. First of all, there are two ways how a capability value get's updates: 1) trough a push message from the deconz hub to Homey (WebSocket) 2) trough a periodical query from homey to deconz (api call, can be configured in the app settings)

The first one is not a problem as deconz only sends a push message when the actual value has changed. The second one on the other hand does update the capability but this does not mean the actual value has changed. So the philosophical question is: what does the indicator in homey actualy mean? Is it the last time the value actually changed or is it the last time this value was updated. For binary values this kind of makes sense to show the last time the value has changed. But for other values it does not make sense. For example the vibration strength: here it is in my opinion better to show the last time the value was checked and not the last time the value was actually updated. If you would go and check the insights for example this would give you a wrong impression.

I'll check if I can update the behaviour of binary values and write back when I have news

iisworks commented 3 years ago

Thanks, I completely agree it would make no sense on any of the metrics!

I was only talking about the Alert/Binary value, and it would be great if that behavior could be changed so that we can see when the alert triggered last. :)

MadMonkey87 commented 3 years ago

It seems this behaviour is intended by homey, please check the answer from athom over there: https://github.com/athombv/homey-apps-sdk-issues/issues/193

iisworks commented 3 years ago

Thanks, but even then I still think it makes much more sense to see the "Last alert time" there. So it would be great if that could be implemented? Also the vibration sensor alert also does not trigger with the orange exclamation mark alert indicator on the device in the WebApp.

BTW: I'm pretty sure this is both working as suggested in the Aqara Zigbee app?