AirPlay 2 speakers can be used in HomeKit automations in many ways. You don’t have to limit yourself to just playing your favorite music. In our article“HomeKit alarm system: Protect your home from burglars” we already mentioned that you can also use the speakers as a siren through an alarm sound. Today we would like to show you how you can implement this.
The easiest way to monitor the house is with door and window sensors and motion detectors. If no one is home and the sensors detect an open window or movement, the loudspeakers in the entire house should play this alarm sound. The prerequisite for the correct functioning of the automation is that all residents use an iPhone and also carry it with them when leaving the house.
Before we create the actual automation via the paid HomeKit app Home+, we need to add a new scene in Apple’s Home app, which we call “Siren”. As devices, we select all HomePods that should play the sound in case of an alarm.
Under “Media” we go to “Audio”, then to “Select Audio” and add the alarm sound.
Then we activate the “Repeat” switch, so that the alarm is not over again after a few seconds, and set the volume to 100%. Click “Done” to create the scene.
To avoid having to create a separate automation for each contact sensor and motion detector, we switch to Matthias Hochgatterer’s paid Home+ app. Unfortunately, we cannot use the free app from Eve Systems at this point, because in automations the absence of people cannot be used as a condition.
Under “Automation” we create a new automation via the “+”.
As an event, we add all contact and motion sensors that will be used for the alarm system.
If you have a security system in place, such as Aqara’s hubs, you can add the “Out of Office” status as a condition. Otherwise, you can also use the “Presence of people”, or more precisely “Nobody is at home” here.
Now you just need to add as a scene the “Siren” you just created. Via Save the automation is created and activated.
As soon as the security system has the status “Out of home” or no one is at home and one of the sensors detects something, the siren will be played on the selected AirPlay 2 speakers.
Leave a Reply