Jason-Morcos / homebridge-magic-occupancy

Occupancy sensor linked to one or more switches with a built-in delay not-unoccupied delay for Homebridge
GNU General Public License v3.0
78 stars 3 forks source link

Set the time range #23

Closed marmitol closed 2 years ago

marmitol commented 2 years ago

HI. Thank you very much for the hard work. I propose to add the possibility to set a maximum time range in each plugin definition. This would be very useful because when setting a time remaining rule. It is very difficult to define the remaining seconds to finish, since there is no limit of seconds and it is very difficult to set the seconds. I use the EVE application. For example in the EVE app I create a rule that when a "Stay Occupied Delay" has a time less than 30 seconds, it performs an action. The problem comes when it comes to be able to set the 30 seconds since there is no time limit in the definition scale and to adjust the time is almost impossible. It would be great to be able to define a range to be able to define the time on a scale. I show a picture as an example. image

In the first picture the selection bar is shown almost at the end and in the other picture almost at the beginning. As it is shown it is almost impossible to define a time of a few seconds because the scale you are using is very wide. What I indicate is to be able to define this scale. For example a scale of 1 to 100 seconds or a scale of 1 or 1000 seconds. Thank you.

Jason-Morcos commented 2 years ago

Hey there! I'm not sure that a limit is something I can actually define. Are you aware of a way I can do this and expose it to HomeKit? Perhaps a better path here is to request the Eve app allow numeric entry for time remaining delay? If you can find a way that we could make that limit work, I'd be happy to review a PR to implement it!

Jason-Morcos commented 2 years ago

Additionally, have you tried using another app like Controller for HomeKit? That one let me enter a manual value to set up a time remaining-based automation. https://apps.apple.com/us/app/controller-for-homekit/id1198176727

image

marmitol commented 2 years ago

Hello. I will try to find a way of setting a time range. If I find it I will let you know. Thank you very much.