home-assistant-konnected-tutorial icon indicating copy to clipboard operation
home-assistant-konnected-tutorial copied to clipboard

Create Group for all sonos players

Open johnny-co opened this issue 2 years ago • 3 comments

Just like your family group, create an all sonos speakers group like:

media_players_all: name: Media Players All entities: - media_player.family_room - media_player.sonos_move - media_player.master_bedroom

Then use group.media_players_all for your sonos entity ids like:

  • service: script.sonos_say data: sonos_entity: - group.media_players_all volume: 0.1 message: The intrusion alarm is now disarmed. delay: '00:00:06'

I have sonos throughout house and not sure what door people come in from. just an idea.

johnny-co avatar Mar 24 '22 17:03 johnny-co

This also has the benefit of making your yaml examples more universal for copy/paste efforts without additional edits.

johnny-co avatar Mar 24 '22 17:03 johnny-co

I have to think about this for a minute. I'm reluctant to play all announcements on all Sonos at the same time because one is in the children's room :)

scarpazza avatar Mar 24 '22 17:03 scarpazza

Good point and for consistency this might be better and not include the kids room:

intrusion_media_players: name: Intrusion Media Players entities:

  • media_player.family_room
  • media_player.sonos_move
  • media_player.master_bedroom

johnny-co avatar Mar 24 '22 18:03 johnny-co