Universal Media Player for Sonos Beam & Streaming Stick - not possible?

My living room media centre isn’t too complex. TV has a Roku Streaming stick, Sonos Beam used mostly for TV sound but also music, and a PS4.

Problem? I currently have three mini media players on my dashboard and would love to condense them into one. I did try and configure a universal media player a while back with limited success. Seems straightforward that I’d want the currently active media player showing cover art, volume controls fixed on the Sonos Beam, and play pause etc. on either the Roku or Sonos depending on which is playing. When I tried before I couldn’t get the state/child player to switch reliably depending on activity.

Does anyone do a similar thing and willing to share some tips/advice before I give it another bash?

Universal is the way to go. What is not working for you?

I think the Sonos was causing issues as it can end up in paused state instead of idle. Meaning the child media players didn’t ‘take over’ when they should.

It was a while ago that I tried and am fairly sure my templating is a fair bit more advanced now, but I was just looking for any pointers before I give it another bash. Particularly from anyone with a similar setup.

Best to have the Sonos Beam as the main player? How to ensure the currently active player is always showing artwork/transport controls? How much templating required in the config vs mini media player config to customise behaviour? That sort of thing. Or maybe even some example configs beyond the one in the docs would help.

Ok so here’s the issue. According to the docs:

The Universal Media Player will control the first child on the list that is active (not idle/off).

So what do you do when your media players are rarely off or idle, but the currently used player changes frequently? For example - watching Netflix on the Roku and then decide to listen to some music on the Sonos Beam. Music starts playing, volume and controls are fine as I have them configured as commands, but the player is still showing Netflix rather than the music cover art from the Sonos.

If I change the order of the ‘children’ so the Sonos is first, it will always show ‘TV’ when using the Roku and not show that Netflix is the currently active source.

Correct me if I’m wrong, but the Universal Media Player attributes > source option can’t be templated. And the state_template option only changes the state label rather than allowing customisation of which should be the active media player in certain circumstances.

I feel this should be possible, but I’m no further ahead than I was a few months ago when I tried before. Someone must have a similar scenario or some words of wisdom on how to come to a solution??

I suspect that could be an issue with the Roku integration.
I’ll do some tests this WE, with the AndroidTV one that I have.

Interesting. For what it’s worth, I had an Amazon Fire Stick when I tried a few months ago but now have a Roku. Problem was the same. Are you meaning an issue with how the Roku integration interacts with Universal Media Player?

No, that the roku wouldn’t properly go to idle when you stop netflix playback…
But it’s been a while. I just played with the universal MP, so could be an issue there as well.

The more I think about this, the more I think that the universal media player is missing some vital options for allowing flexibility.

The Roku going into idle state is not the whole picture. What if I pause Netflix and start to listen to music? Roku is in paused state but I want the Sonos as currently active in the player. Same goes the other way around. Simply relying on one or more of the media player being ‘off’ doesn’t cut it.

I would have thought an option for ‘inactive_mode’ with options for ‘when idle’ or ‘when not playing’ would be an important configuration element.

Of course I was half expecting that some templating could achieve the same thing, but I can see how that can be done either. Someone must have the same situation. Anyone??

Makes sense.
I’ve created a PR that puts playing player “above” paused ones

1 Like

Any joy on this one?

I have a sonos beam, and nvidia shield id like to combine.

This was included in 2022.8 I think so yes, UMP now has ordered states. I have my Sonos Beam, Roku stick and PS4 configured as a universal media player and it works well. Apart from the Roku having a state of ‘home’ which was throwing errors. This is resolved in 2022.9 - I just haven’t updated yet.

I believe the docs still need updating to reflect the behaviour changes as a result of this PR.