Hey all,
i have a bit list of devices i monitor on my network with a pingtest.
the idea being that if anyone of them go offline, i would get a notification to go and fix it (eg. why has the network printer stopped working)
i have all these in a group, but when one of the devices changes to “off” the whole group stays “on” overall.
is there a way to work out if “any” member of a group state has changed?
You could just create an automation that triggers on any of your entities changing to OFF. In the action you will be able to identify the triggering entity (and show that in a notification).
Why? You only set it up once. When you need to monitor a new device, you need to add it to the group anyway. What’s the difference with adding it to the automation?
The default for a group is to be on if any of the entities is on. However you can change that so it is only on if all of the entities are on. Just add the following to the group configuration:
all: true
This way the group will change to off whenever any of the entities change to off.
Now, having said that, you’ll only get a notification when the first entity goes off. If a second goes off the automation won’t trigger again (until all of the entities go back on and then one goes off.)
So, if you want the automaton to trigger whenever any of the entities goes off, then it’s best to do as @metbril suggested and simply list each entity separately.
But if you really want to use a group, and still get a notification whenever any of the entities goes off, there is a way to do that using an event trigger and a condition.