Expire binding remaining time

I’m using the expire binding as a timer to override a rule triggering a fan based on humidity. This is my item:

Switch Expire_fan_ff_bath "Fan timer" (FF_bath, Timers) { expire="60m,OFF" }

Is there any way to get the remaining time before the switch expires and show this in the sitemap or maybe use it in a rule?

Good question. I am looking to the answer for this as well. Anyone?

I don’t think there’s a way to get it - what would be your use case?

I use Switch items with the Expire binding to handle presence and light timers. - Getting the remaining time, would allow to show the remaining time until lights turn off etc. in the UI.

just turn it around: use a proxy item for it, which starts with your update with the respected items. I know, it’s a bit more complicated…
or open an feature request for the expire-binding… :wink:

+1 on this feature request :+1:

I would expect such a function with a expire2 binding, based on things (and then a channel providing remaining time). :wink:

just found this topic because I was asking myself the same question :wink: does anyone know if this is on the roadmap?

As I understand it, there are more fundamental decisions to made heading into openHAB-3 with more flexible timing tools. To include “expire-3” capability.

Which is a way of saying - do not expect an expire-2 really.

Meantime this may be of use

1 Like