gafich10’s question is exactly the right one: what principle should be used to determine the status of a group?
For example, should a group of windows or doors be open when one window is open, or should they all be open, or should at least two or three be open?
That’s why I would suggest defining this yourself using automations.
Create an automation that represents the sensor group. This could be an automation that never triggers. For example, something like this:
Define the status of the automation in your mind:
- Automation activated: at least one window is open.
- Automation deactivated = all windows closed.
Do not forget to set the initial status of the automation depending on the current status of the sensors. Set the automation to deactivated if all windows are closed.
Then you need another automation to activate the first one when a window is opened.
You also need an automation that deactivates the automation when all windows have been closed.
Then you can use the status of the first automation in other automations. For example, like this:
This principle can also be applied to other sensors, such as multiple presence sensors, which can activate or deactivate an automation, e.g. ‘someone is at home’.
However, this will not work for a group of temperature sensors in the Aqara app. Here, too, the question arises: what should the group of temperature sensors represent? The maximum value, the minimum value, or the average?
In Home Assistant, this would be possible with a template sensor:
{{ (states(‘sensor.temp1’)|float +
states(‘sensor.temp2’)|float +
states(‘sensor.temp3’)|float) / 3 }}
However, I currently do not see any way to pass the value on to Aqara (for example, with Matter).