TILTED Homematic rotary-window-handle in a group

Hello all,
I have a few HM-Sec-RHS and HmIP-SRH (rotary-window-handles) which are string items as per definition. They can have the values OPEN, CLOSED & TILTED.
I’ve added them all to a group (gWindows) and wanted to also show the ammount of open windows. As long as they are OPEN or CLOSED it works like charm. But the TILTED windows are treated like closed which is expected from the group definition but not the way I’d like to have it.

When I leave home and alarm system is turned on, a TILTED window should be considered as OPEN.
Anyone an idea how to achive the same? Ideally without adding virtual items (contacts) that are updated accordingly by some rules.
Here’s a sample definition and the corresponding view in OH:

 Group:Contact:OR(OPEN, CLOSED) gWindow
     "Alle Fenster [(%d)]"

 String eg_buero_fenster
     "Büro [MAP(contact3.map):%s]"
     { channel="homematic:HM-Sec-RHS:ccu2:KEQ1097XXX:1#STATE" }

As you can see, even though office window is tilted, the quantity of open windows is 0. Any help to treat this as OPEN, would be appreciated. Btw, I’m still on 2.3 :slight_smile:
Thanks much

1 Like

Another group definition could work:

Group:Contact:AND(CLOSED, OPEN) gWindowsClosed

Will only be closed when ALL windows are CLOSED

I use a Design Pattern: Proxy Item for that. I can post the definition and the rule when I’m at home if you need it.

Thanks for your replies guys,
@thorsten_gilfert, yeah I had proxy items in mind already. But trying to avoid the overhead and complexity of proxies in favor of a neat solution. I also thought since counting CLOSED windows works, to always substract the no. of closed from total qty of windows to have the OPEN ones.

But @vzorglub suggestion seems to work just nice. I have to admit, I dont understand why, but the TILTED and OPEN windows as properly counted as OPEN.
Thanks much