Media play source selection

I have been trying to see if its possible to change the source speaker in a tile used for Spotify.
I have a Spotify device I brought over from Home assistant. I know I have the ability to change the connected Alexa speaker to play music in different rooms. How can I go about doing so with HomeRemote? I was not able to see anything in the MediaPlayerDetails.xaml. . Would MediaInputSouce work somehow as a button?

Yes, MediaInputSouce can be set with a Button. It’s really no different than the DataActions you use to turn a switch On or Off. The only difference is instead of On or Off you will write the name of the MediaInputSource source that you’d like to play. I generally recommend binding the attribute you wish to set to a Label 1st so you can see its current value. A Label can also help you determine the exact value you need to write to this attribute.

OK Simple enough. what I was looking to do was go a step further an maybe have the button popup a menu selection with the selections so when I click the selection then it would change. I think this would be similar to the security system and instead of Arm or Disarm I would have my speaker selection

You can design a popup if you want. You can do something like the “Sound Mode” popup in MediaPlayerDetails.xaml. Bind a GridView ItemsSource to SupportedInputSources.

@bill Thanks for all your help thus far. I have really learned a lot.
your suggestions have worked perfectly. I’m really liking what I’m able to do and my displays seem much snappier. Even more so then the Lovelace dashboards with Home Assistant.
I’m looking forward to creating a more professional looking display that I couldn’t seem to get with Home Assistant.
I wish the community had more examples on display option and or templets.

1 Like