Hello all,
I have a day-night sensor wired into a Shelly2.5 which is wired directly to two security lights. Using the input switch, binary_sensor.security_day_night
, I have created various other automations to turn on lights, and generally prepare the house for evening.
One issue is that because of the wiring, which I’m not able to change immediately, if the security lights are turned off at the switch, the sensor and Shelly both lose power and thus a number of my automations are never activated.
I additionally have about 10 Unifi Protect cameras in HA, and each of these cameras (since a recent update?) now have a binary_sensor.is_dark_*
entity. I could conceivably wire up my automations to one of these camera attributes quite easily. However, individual cameras can fail and thus the automations are reduced to a single point of failure.
I have created a group
of these camera sensors and included the day-night sensor in this group. Using the group is possible but groups are either turned on by “ONE” or “ALL”. With these two states, the system is either prone to increased false positives or at least subject to the most sensitive reading. Requiring “ALL” again increases issues of failure.
I would thus like to consider it “dark” only when, for example, 33% or more of the sensors in the group report that it is dark. This allows for some to be sensitive, and for others to fail without having overly serious effects on the automations that are linked to the arrival of darkness.
How can I do this? I am very new at Home Assistant! While I’ve found articles within this forum which supposedly answer my question, I’ve been unable to get anything working. My guess is that many of the configuration options and YAML code provided is simply not getting to the right place. If you could please keep in mind that I may need highly simplified instructions, that would be appreciated.