<\/path><\/svg><\/span>type<\/span>:<\/span> <\/span>entities<\/span><\/span>\nentities<\/span>:<\/span><\/span>\n <\/span>-<\/span> <\/span>type<\/span>:<\/span> <\/span>custom:mini-media-player<\/span><\/span>\n <\/span>group<\/span>:<\/span> <\/span>true<\/span><\/span>\n <\/span>entity<\/span>:<\/span> <\/span>media_player.masterspeaker<\/span><\/span>\n <\/span>toggle_power<\/span>:<\/span> <\/span>false<\/span><\/span>\n <\/span>artwork<\/span>:<\/span> <\/span>cover<\/span><\/span>\n <\/span>artwork_border<\/span>:<\/span> <\/span>true<\/span><\/span>\n <\/span>power_color<\/span>:<\/span> <\/span>true<\/span><\/span>\n <\/span>show_source<\/span>:<\/span> <\/span>true<\/span><\/span>\n <\/span>sync_volume<\/span>:<\/span> <\/span>true<\/span><\/span>\n <\/span>expanded<\/span>:<\/span> <\/span>true<\/span><\/span>\n <\/span>speaker_group<\/span>:<\/span><\/span>\n <\/span>platform<\/span>:<\/span> <\/span>media_player<\/span><\/span>\n <\/span>show_group_count<\/span>:<\/span> <\/span>true<\/span><\/span>\n <\/span>entities<\/span>:<\/span><\/span>\n <\/span>-<\/span> <\/span>entity_id<\/span>:<\/span> <\/span>media_player.speaker1<\/span><\/span>\n <\/span>name<\/span>:<\/span> <\/span>Link Kitchen<\/span><\/span>\n <\/span>-<\/span> <\/span>entity_id<\/span>:<\/span> <\/span>media_player.speaker2<\/span><\/span>\n <\/span>name<\/span>:<\/span> <\/span>Link Dining Room<\/span><\/span>\n <\/span>-<\/span> <\/span>entity_id<\/span>:<\/span> <\/span>media_player.speaker3<\/span><\/span>\n <\/span>name<\/span>:<\/span> <\/span>Link Office<\/span><\/span>\n <\/span>-<\/span> <\/span>entity_id<\/span>:<\/span> <\/span>media_player.speaker4<\/span><\/span>\n <\/span>name<\/span>:<\/span> <\/span>Link Bedroom<\/span><\/span>\n <\/span>-<\/span> <\/span>entity_id<\/span>:<\/span> <\/span>media_player.speaker5<\/span><\/span>\n <\/span>name<\/span>:<\/span> <\/span>Link Living Room<\/span><\/span><\/code><\/pre><\/div>\n\n\n\nPoints to note:<\/p>\n\n\n\n
\nmedia_player.speaker is simply the Home Assistant entityid for one of your MusicCast devices. if you are unsure of the name of the speaker go to Integrations and within the MusicCast Integration all your speakers should be listed. Click through each and take a note of their names. You will need to click into settings to find the media_player.name entry.<\/li>\n\n\n\n media_player.masterspeaker is the speaker that the music\/audio will be played from. if you have different scenarios that would change the controlling speaker you will need to create additional custom mini media player cards.<\/li>\n\n\n\n I have included 5 additional speakers but you may have less or more. Amend accordingly.<\/li>\n\n\n\n You may have other media players within your Home Assistant environment, such as Alexa devices or Sonos speakers etc. Do not add anything into this other than MusicCast devices as MusicCast is not compatible for this. You can use the custom mini media player to create speaker groups of non MusicCast devices<\/li>\n<\/ul>\n\n\n\n8. Click Save<\/p>\n\n\n\n
You will have something that looks like the below (my actual speaker names are listed). Click the two speakers near the top to expand the speaker groups. Toggle speakers according to what you want to link. <\/p>\n\n\n\n <\/figure>\n\n\n\nOnce you are confident you can edit the card once more to add further customisations should you see fit. However, I have never needed anything other than this.<\/p>\n\n\n\n
So now you have a method of configuring MusicCast sapeaker groups through your Home Assistant Dashbaords. However, you may also wish to have these automated. We’ll discuss this next…<\/p>\n\n\n\n
Automate MusicCast Speaker Groups<\/strong><\/h2>\n\n\n\nDashboards can be a nice way of managing your Smart Home environment. However, dashboards require manual input. you may prefer an automation to configure your speaker groups. Some scenarios could be:<\/p>\n\n\n\n
\nMotion sensor detection at a particular time of day<\/li>\n\n\n\n Audio commands received by amazon Alexa<\/li>\n\n\n\n Smart buttons<\/li>\n\n\n\n Sunrise<\/li>\n\n\n\n The detection of another smart device changing to a particular state<\/li>\n<\/ul>\n\n\n\nI suppose the list could be endless really.<\/p>\n\n\n\n
Lets get to it…<\/p>\n\n\n\n
To automate speaker groups it is fortunately quite straight forward.<\/p>\n\n\n\n
\nCreate your automation.<\/li>\n\n\n\n Add an action to ‘Call Service’<\/li>\n\n\n\n Edit the action in yaml and add the below code making amendments for your own speaker names.<\/li>\n<\/ul>\n\n\n\n<\/circle><\/circle><\/circle><\/g><\/svg><\/span><\/path><\/path><\/svg><\/span>service<\/span>:<\/span> <\/span>media_player.join<\/span><\/span>\ntarget<\/span>:<\/span><\/span>\n <\/span>entity_id<\/span>:<\/span> <\/span>media_player.hifi<\/span><\/span>\ndata<\/span>:<\/span><\/span>\n <\/span>group_members<\/span>:<\/span><\/span>\n <\/span>-<\/span> <\/span>media_player.dining_room_musiccast<\/span><\/span>\n <\/span>-<\/span> <\/span>media_player.kitchen_musiccast<\/span><\/span><\/code><\/pre><\/div>\n\n\n\n<\/p>\n\n\n\n
\nNote, the ‘target’ speaker is the controlling speaker from which group members will share audio from.<\/li>\n\n\n\n if you switch back to ‘edit in visual editor you should see something like the below.<\/li>\n<\/ul>\n\n\n\n
<\/figure><\/div>\n\n\n\nTo automate the process to unjoin speakers follow the same process but change the yaml code to the below.<\/li>\n<\/ul>\n\n\n\n