How to send commands to Russound MBX PRE through Rio?

I installed the player using this configuration - Russound RIO - Home Assistant. I see the entity showing in Home Assistant. It is showing minimal information such as song playing, etc. My question is how do I send RIO commands to it? I am familiar with RIO as I have them setup in another platform but I am not that familiar with Home Assistant and couldn’t figure out how to send commands to it? also it puts out a constant stream of data on playback status etc. How do I capture this and process it? Thanks for any help.

Hi Simon,

I recently took over the development of the Russound RIO integration and have been working on making it more stable and adding more features. Which RIO commands are you looking to send in particular? Most basic features are already implemented into the Media Player. If you are looking to use the EVENT command for sending IR/remote commands, I’ll be adding that as an action soon.

Thanks for following up on this. I have two MBX-PRE streamers. I have scripts written for homeseer that do two things with the players. As far as I know they are the only streamers you can get that Support SiriusXM - which is why I use them.

First I open a port to the players and read the data coming back from them. The players send out a string every second showing the time count and other information such as the name of the song and a whole bunch of additional information.

This does require a RIO command to turn on this outbound data flow (e.g. WATCH S[1] ON). I haven’t looked into switching that to Home Assistant but I assume there is an IP plugin somewhere that will help me accomplish this. Not sure if this would be the domain of the RIO plugin although I assume it would be helpful to have all under one roof?

Second, I issue RIO commands to the players to play, stop, select playlists, etc.

The latest RIO doc I have is 1.16.01. I have access to the Russound dealer web site but the search for some reason is not great so I usual stumble onto new RIO specs.

Happy to help out to test this moving forward.

Hi Simon,

Understood. The Russound RIO integration handles most of this out of the box, so you don’t have to do anything related to handling the IP. The integration automatically subscribes to all zones and sources (WATCH command), so there is no need for you to manually issue that command.

The RIO commands for play, stop, skip are all part of the media player object when the integration is used. Selecting playlists and such are device-specific and aren’t currently supported in the integration. The song name, artist, and metadata are currently supported but I’m still testing it so results may vary until I work out those details. It seems the main functionality that you are interested in that is currently missing is the ability to select the media from HA, is that correct?

I’ll be adding the capability to issue manual commands soon using actions so that should suffice for your requirements until the library fully supports your device. I’ll keep you posted on when that’s released.

I’d love to test the integration against your streamers since I currently only have an older MCA-C5 unit and can’t fully test the streaming features (SiriusXM, Spotify, etc).

FYI, the new changes to the integration will be available in the upcoming release of HA (2024.8).

I have listed the commands I am using at the end of the thread.

I have to monitor the incoming strings all of the time for two reasons - to trap issues, and to check and change states. I parse all of the “variables” coming back from the player and use that information to perform actions. Presumably I can do that with automations, or is it the intent of the plugin to do that? I am not that experienced with Home Assistant and haven’t really done any yaml but happy to start learning as needed.

Some examples of what I do:

On certain sources, such as Spotify, it is desirable to have Random and Repeat All turned on when you select a playlist. So I check the incoming state of these two conditions and then issue the appropriate commands. Annoyingly there are not explicit commands for this.

When you listen to the streamers for an extended period of time it pauses and returns a “Are you still listening?”. Then I send the OK command. This is designed to work with their touchscreens and having the user push the OK button - but apparently they didn’t think that someone would be using them without the touchscreens.

Also, the streamers sometimes get themselves into a stuck state which I can detect through the incoming strings. This can happen in more than one way. When it happens I actually cut power through automated plugs forcing a clean boot and then issue the play command.

Favorites need to be programmed on the app and then selected through the FAVORITE command. These can be a specific station, a channel on Sirius, a playlist on Spotify, etc. It’s kludgy but it works.

Commands

Version
GET C[1].Z[1].currentSource
GET C[1].Z[1].mode
EVENT C[1].Z[1]!MMSelectOk
EVENT C[1].Z[1]!restoreSystemFavorite #
EVENT C[1].Z[1]!KeyPress Volume ##
EVENT C[1].Z[1]!Zoneoff # - I don’t think I am using this
EVENT C[1].Z[1]!Zoneon # - ditto
EVENT C[1].Z[1]!KeyRelease Stop
EVENT C[1].Z[1]!Reboot
EVENT C[1].Z[1]!Repeat
EVENT C[1].Z[1]!Shuffle
EVENT C[1].Z[1]!KeyRelease Next
EVENT C[1].Z[1]!KeyRelease Previous
EVENT C[1].Z[1]!KeyRelease Play

Hope this is helps?

Hi Simon,

Yes this all makes sense.

Presumably I can do that with automations, or is it the intent of the plugin to do that?

The Russound RIO integration allows you to interact with the functionality of the devices by using Home Assistant entities (Media Player, Switches, and Sensors). The integration itself handles the interfacing with the RIO API so you don’t have to talk to it directly. Yep, automations are going to be what you want. The integration exposes each zone (I assume the MBX-PRE is considered a single zone in this case) as a media player with information regarding current song, next, previous, and play/pause, volume, source, and power controls. You can pretty much setup an automation that does any number of things with that information.

I am not that experienced with Home Assistant and haven’t really done any yaml but happy to start learning as needed.

Fortunately, HA makes it pretty easy to get started with automations without writing any YAML using the UI. YAML is always an option if that’s something you prefer. See Automation editor - Home Assistant

On certain sources, such as Spotify, it is desirable to have Random and Repeat All turned on when you select a playlist. So I check the incoming state of these two conditions and then issue the appropriate commands.

I am still working on supporting the multimedia features for the newer Russound devices so this won’t be available directly at launch. I’d expect this functionality to be integrated by mid August.

When you listen to the streamers for an extended period of time it pauses and returns a “Are you still listening?”. Then I send the OK command. This is designed to work with their touchscreens and having the user push the OK button - but apparently they didn’t think that someone would be using them without the touchscreens.

I’m currently adding the ability to issue the remote (EVENT) commands as a service. This should be available with HA 2024.8, and I’ll update the integration documentation once it’s live.

Also, the streamers sometimes get themselves into a stuck state which I can detect through the incoming strings. This can happen in more than one way.

Do you have an example of a condition that you are detecting? Just wondering what it looks like to see what can best be done to read this. Is the streamer getting stuck, or is it just the connection?

At the moment, a bit of work needs to be done to better support the MBX series line, but I’m pretty quick at development and just need to test against the unit. If you are able to setup the integration once the new release comes out to report on functionality it’d help me be able to dial in these features.

Awesome. Looking forward to playing with this. This is one of the reasons I keep homeseer running and would be happy to move it off onto Home Assistant.

The player sends strings like the one below. This is what I have to parse to figure out what is going on. I also pull the image references as I display those on my touchscreens.

Going from memory and looking at my code -

The player puts out strings every second beginning with an “S”. When watch is not turned on it only outputs an S and then I turn Watch On. Players boot up with Watch Off but I have also noticed that they can arbitrarily turn watch off - so I am always checking to make sure it sends a Watch ON if that happens.

I think on start of new source it normally displays “Connecting to Media Source” in the songname field then starts outputting fully formed strings with the details. I have seen it when it displays this message and then only “S”'s after that. I trap and reboot the streamer in those cases.

The previously mentioned “Are you still listening?” also displays in the songname field. But it also displays in another field - MMInfoBlock.text - which is used for Russound touchscreen displays. In this field I watch out for a number of things below. I don’t think I have docs on this so I record them as I run into them.

N S[1].MMInfoBlock.text=Account logged in on another device. Press PLAY to continue. - Caused by Spotify account being used on another device
N S[1].MMInfoBlock.text=Are you still listening? Please press PLAY to continue playing. - Caused when streaming Sirius for an extended period
N S[1].MMInfoBlock.text=Playback stopped. - Caused by an error in Sirius playback

I also trap for these errors as this can arise under certain situations - such as when it shows “Playback Stopped” and I send a play command to get it moving again - sometimes it works and sometimes I get the error:

N S[1].MMTitle.text=Error Message
N S[1].MMTitle.text=Error

And sometimes it just stops playing and it reports:

N S[1].playStatus=“stopped”

So I send a play command. No idea why it does this.

Recent firmware updates have ironed out a few of these issues.

Here is a sample output from the streamer.

S N S[1].name=“Media Streamer” N S[1].type=“Russound Media Streamer” N S[1].Support.favoritesV2=“TRUE” N S[1].Support.MM.longList=“TRUE” N S[1].Support.MM.restoreOption=“TRUE” N S[1].Support.availableControls=“TRUE” N S[1].Support.trackTime=“TRUE” N S[1].Support.playTime=“TRUE” N S[1].Support.playerData=“TRUE” N S[1].channelName=“” N S[1].coverArtURL=“” N S[1].channelArtURL=“” N S[1].mode=“SiriusXM” N S[1].shuffleMode=“ON” N S[1].repeatMode=“OFF” N S[1].rating=“UNKNOWN” N S[1].playlistName=“STOPPED” N S[1].artistName=“” N S[1].albumName=“” N S[1].songName=“” N S[1].availableControls=“{“contextMenu”:false,“dislike”:false,“like”:false,“next”:false,“pause”:false,“play”:true,“previous”:false,“repeat”:false,“seekBack”:false,“seekForward”:false,“seekTime”:false,“seekTrack”:false,“shuffle”:false,“stop”:true}” N S[1].trackTime=“0” N S[1].playTime=“0” N S[1].playerData=“{“breadCrumbs”:”“,“mimeType”:163565,“mode”:5,“playId”:”“,“rootPath”:“0”,“title”:“Rock”,“type”:”“,“url”:{“control”:“play”,“mediaRoles”:{“audioType”:“audioBroadcast”,“context”:{},“description”:“the latest in alternative”,“icon”:“http://pri.art.prod.streaming.siriusxm.com/images/channel/20180725/altnation-1-31-00-180x180.png",“id”:“036”,“mediaData”:{“metaData”:{“contentPlayContextPath”:"sirius:playContext?genre=rock?id=altnation?name=Alt Nation?siriusChannelNo=36”,“genre”:“Rock”,“live”:true,“playLogicPath”:“sirius:/PlayLogic”,“serviceID”:“sirius”},“resources”:[{“httpTimeout”:120,“mimeType”:“audio/mp4”,“uri”:“http://localhost:8080/api/stream/sirius:altnation;goLive"}]},“path”:“sirius:altnation”,“title”:"036 Alt Nation”,“type”:“audio”,“value”:{}}},“useUrl”:true}” N S[1].sampleRate=“0” N S[1].bitDepth=“0” N S[1].bitRate=“0” N S[1].format=“” N S[1].playStatus=“stopped”

Hope that’s helpful?

Hi Simon,

This is exactly what I’m looking for.

I’ll look at options for exposing these additional variables to be used in automations. Maybe just a sensor entity could work, I’ll let you know what I come up with.

Here is a log sequence from starting the player with Sirius and then stopping it:

|Jul-25 15:15:01| |MBX-1|Incoming string -| S N S[1].name=Media Streamer N S[1].type=Russound Media Streamer N S[1].Support.favoritesV2=TRUE N S[1].Support.MM.longList=TRUE N S[1].Support.MM.restoreOption=TRUE N S[1].Support.availableControls=TRUE N S[1].Support.trackTime=TRUE N S[1].Support.playTime=TRUE N S[1].Support.playerData=TRUE N S[1].channelName= N S[1].coverArtURL= N S[1].channelArtURL= N S[1].mode=SiriusXM N S[1].shuffleMode=ON N S[1].repeatMode=OFF N S[1].rating=UNKNOWN N S[1].playlistName=STOPPED N S[1].artistName= N S[1].albumName= N S[1].songName= N S[1].availableControls={contextMenu:false,dislike:false,like:false,next:false,pause:false,play:true,previous:false,repeat:false,seekBack:false,seekForward:false,seekTime:false,seekTrack:false,shuffle:false,stop:true} N S[1].trackTime=0 N S[1].playTime=0 N S[1].playerData={breadCrumbs:,mimeType:913732,mode:5,playId:,rootPath:0,title:Rock,type:,url:{control:play,mediaRoles:{audioType:audioBroadcast,context:{},description:the latest in alternative,icon:http://pri.art.prod.streaming.siriusxm.com/images/channel/20180725/altnation-1-31-00-180x180.png,id:036,mediaData:{metaData:{contentPlayContextPath:sirius:playContext?genre=rock?id=altnation?name=Alt Nation?siriusChannelNo=36,genre:Rock,live:true,playLogicPath:sirius:/PlayLogic,serviceID:sirius},resources:[{httpTimeout:120,mimeType:audio/mp4,uri:http://localhost:8080/api/stream/sirius:altnation;goLive}]},path:sirius:altnation,title:036 Alt Nation,type:audio,value:{}}},useUrl:true} N S[1].sampleRate=0 N S[1].bitDepth=0 N S[1].bitRate=0 N S[1].format= N S[1].playStatus=stopped|
|—|—|—|—|
|Jul-25 15:14:14| |MBX-1|Incoming string -| N S[1].albumName= N S[1].artistName= N S[1].bitDepth=0 N S[1].bitRate=0 N S[1].channelArtURL= N S[1].channelName= N S[1].format= N S[1].playStatus=stopped N S[1].playTime=0 N S[1].sampleRate=0 N S[1].songName= N S[1].playlistName=STOPPED|
|Jul-25 15:14:12| |MBX-1|Incoming string -| N S[1].albumName= N S[1].artistName= N S[1].bitDepth=0 N S[1].bitRate=0 N S[1].channelArtURL= N S[1].channelName= N S[1].format= N S[1].playStatus=stopped N S[1].playTime=0 N S[1].sampleRate=0 N S[1].songName=|
|Jul-25 15:14:11| |MBX-1|Incoming string -| S N S[1].bitRate=256013 N S[1].playTime=21|
|Jul-25 15:14:11| |MBX-1|Incoming string -| S|
|Jul-25 15:14:07| |MBX-1|Incoming string -| N S[1].playTime=17|
|Jul-25 15:14:06| |MBX-1|Incoming string -| N S[1].playTime=16|
|Jul-25 15:14:05| |MBX-1|Incoming string -| N S[1].playTime=15|
|Jul-25 15:14:04| |MBX-1|Incoming string -| N S[1].playTime=14|
|Jul-25 15:14:03| |MBX-1|Incoming string -| N S[1].playTime=13|
|Jul-25 15:14:02| |MBX-1|Incoming string -| N S[1].playTime=12|
|Jul-25 15:14:01| |MBX-1|Incoming string -| N S[1].playTime=11|
|Jul-25 15:14:00| |MBX-1|Incoming string -| N S[1].playTime=10|
|Jul-25 15:13:59| |MBX-1|Incoming string -| N S[1].playTime=9|
|Jul-25 15:13:58| |MBX-1|Incoming string -| N S[1].playTime=8|
|Jul-25 15:13:57| |MBX-1|Incoming string -| N S[1].playTime=7|
|Jul-25 15:13:56| |MBX-1|Incoming string -| N S[1].playTime=6|
|Jul-25 15:13:55| |MBX-1|Incoming string -| N S[1].bitRate=255999 N S[1].playTime=5|
|Jul-25 15:13:54| |MBX-1|Incoming string -| N S[1].playTime=4|
|Jul-25 15:13:53| |MBX-1|Incoming string -| N S[1].playTime=3|
|Jul-25 15:13:52| |MBX-1|Incoming string -| N S[1].playTime=2 N S[1].playerData={breadCrumbs:,mimeType:913732,mode:5,playId:,rootPath:0,title:Rock,type:,url:{control:play,mediaRoles:{audioType:audioBroadcast,context:{},description:the latest in alternative,icon:http://pri.art.prod.streaming.siriusxm.com/images/channel/20180725/altnation-1-31-00-180x180.png,id:036,mediaData:{metaData:{contentPlayContextPath:sirius:playContext?genre=rock?id=altnation?name=Alt Nation?siriusChannelNo=36,genre:Rock,live:true,playLogicPath:sirius:/PlayLogic,serviceID:sirius},resources:[{httpTimeout:120,mimeType:audio/mp4,uri:http://localhost:8080/api/stream/sirius:altnation;goLive}]},path:sirius:altnation,title:036 Alt Nation,type:audio,value:{}}},useUrl:true}|
|Jul-25 15:13:51| |MBX-1|Incoming string -| N S[1].albumName=Brighter Lights N S[1].artistName=The Backfires N S[1].bitDepth=32 N S[1].bitRate=255986 N S[1].format=MPEG-4 AAC N S[1].sampleRate=44100 N S[1].songName=Brighter Lights N S[1].playStatus=playing N S[1].playlistName=Rock N S[1].playTime=1|
|Jul-25 15:13:50| |MBX-1|Incoming string -| N S[1].albumName=Brighter Lights N S[1].artistName=The Backfires N S[1].bitDepth=32 N S[1].bitRate=255986 N S[1].format=MPEG-4 AAC N S[1].sampleRate=44100 N S[1].songName=Brighter Lights N S[1].playStatus=playing N S[1].playlistName=Rock|
|Jul-25 15:13:50| |MBX-1|Incoming string -| N S[1].albumName=Brighter Lights N S[1].artistName=The Backfires N S[1].bitDepth=32 N S[1].bitRate=255986 N S[1].format=MPEG-4 AAC N S[1].sampleRate=44100 N S[1].songName=Brighter Lights N S[1].playStatus=playing|
|Jul-25 15:13:49| |MBX-1|Incoming string -| N S[1].albumName=Brighter Lights N S[1].artistName=The Backfires N S[1].bitDepth=32 N S[1].bitRate=255986 N S[1].format=MPEG-4 AAC N S[1].sampleRate=44100 N S[1].songName=Brighter Lights|
|Jul-25 15:13:47| |MBX-1|playStatus: loading|
|Jul-25 15:13:47| |MBX-1|Incoming string -| N S[1].channelArtURL=http://pri.art.prod.streaming.siriusxm.com/images/channel/20180725/altnation-1-31-00-180x180.png N S[1].channelName=036 Alt Nation N S[1].playStatus=loading N S[1].songName=|
|Jul-25 15:13:46| |MBX-1|Incoming string -| S|

1 Like

Hi Simon,

Would you be able to run the following commands and grab the responses for your device? I suspect that the RIO S/E (Source Edition) protocol may be a better target for the MBX-PRE.

  1. VERSION
  2. GET C[1].type
  3. GET C[1].firmwareVersion
  4. GET System.type
  5. GET S[1].name
  6. GET S[1].type
  7. GET S[1].mode

I believe that the MBX-PRE is in zone mode by default, and there isn’t much reason to switch it to source mode unless you pair it with a Russound MCA amplifier. I suspect some of these to fail depending on how the device is configured.

Here are the responses:

It is in zone mode, and there is only one zone. So certain commands required that you specify the one, such as GET C[1].Z[1].currentSource.

Hi Simon,

Thanks for grabbing those values.

The Russound integration was updated with the release of Home Assistant 2024.8 today if you want to give it a try. I’m still ironing out many errors but intend to have most of them resolved in the upcoming development iteration.

I suspect that the current song (and relevent metadata) might not automatically update without triggering a command through the UI. (E.g. the zone callback functions properly, but the source isn’t. It’s a library issue not a RIO issue). I’d appriciate if you could give the following a try:

  1. Skip a track, or change the station
  2. See if the song name / artist updates in Home Assistant
  3. If not, click one of the buttons (volume up, mute, etc) and see if the track comes up

ok, I have updated. Not sure how to proceed from here. I have them added as integrations and I see volume control but no transport controls?


You can click on the title of the media card to reveal more controls. In this case you’d click on “MBX-PRE-CHA3”.

Sorry - I did do that but didn’t screen shot it. I don’t see any transport controls. I tried deleting and re-adding the device but no difference.

Ah got it,

I completely glanced over “transport”. Transport controls aren’t currently implemented. I will be adding them for the next major release.

When you press the volume down / up button, does the title of the current media appear?

And what options show up under the source box?

Sorry for the delay in checking this - was out of the country.

All controls work except for the mute. That returns an error: “Failed to perform the action media_player/volume_mute. unknown error”.

Nothing is showing in logbook for any controls.

Selecting Source shows one option - Media Streamer.

As there is no skip a track, change station, etc. - I couldn’t test those.

The artist and song title do not update unless you use one of the buttons in the UI.

Cover art is also showing in the UI.

Interesting that the mute function doesn’t work. Does the included remote (if the MBX has one) have a mute button?

It’s expected to see Media Streamer as the only source for now. Still working through how to control the stream mode.

The artist and song not updating until the UI is interacted with was expected. Did you happen to update to 2024.8.1? The issue should be resolved in that version. Please let me know if not.

The transport controls for skip, play/pause, and previous will be available in HA 2024.9 when it’s released in September.

No remote. There is a mute button in the UI on the app. I can share screen shots of the UI if that is helpful? Perhaps the app is issuing the RIO commands?

Artist and song still not updating on latest version.

Also, I can’t seem to name them separately as devices? See below:

image

Clarification: the app I refer to is the Russound app from the App Store.