Heos Group support

Hi,

  1. You are still using the custom integration, did you try the official one after grouping was implemented?

  2. If you have issues with the custom integration, please report it on the github site with a proper description of exactly what you are trying to do, what is not working, and more details on the error.

I’m still using the custom integration myself, and it is working fine here (I’m on HA 2021.12.7). I don’t see any errors, but then I only have HEOS-speakers and not Denon AVR. I didn’t have time to test the official integration after grouping was implemented, but if it is working fine, the plan is to deprecate the custom integration.

I’m still using the custom integration as well, because as far as I understand, the mini media player doesn’t support the new grouping feature at the moment. I asked a question about that here, but no luck.

Yeah, I saw direx mentioned something on that. When I get to testing it myself, I can propose a PR to the mini-media-player to fix it since I am using it myself for the same purpose.

PS! Perhaps you have better luck opening an issue on the github of mini-media-player. The developer is probably paying more attention there than on the community. Anyway he may need some help testing it for Heos.

1 Like

@quizzical & others: I did some testing with the mini-media-player and the official integration join/unjoin features. It seems to me that the card is working fine as it is. I only did some basic join/unjoin testing and didn’t test all the buttons, but at least the basic stuff is working already.

However, it is necessary to modify the card config parameter platform from heos to media_player. Then it seems to be working fine. I realized this when looking at the code of the card here.

Example:

type: custom:mini-media-player
entity: media_player.heos_office
speaker_group:
  platform: media_player         # Notice this!!
  show_group_count: true
  entities:
    - entity_id: media_player.heos_office
      name: HEOS Office
    - entity_id: media_player.heos_kitchen
      name: HEOS1 Kitchen
    - entity_id: media_player.heos_bathroom
      name: HEOS1 Bathroom
    - entity_id: media_player.heos_livingroom
      name: HEOS Livingroom
2 Likes

I did some testing based on your example.
The grouping doesn’t work for me. I have not uninstalled the hack, but assume that should not have an influence.
I must also say my case seems less straightforward than yours. You seem to only have Heos devices. While I have a normal Heos1 in the bathroom but then I have a Denon AVR in the entertainment room that is controlling the speakers over there as well as in the kitchen (trough it’s zone1 output).
THe AVR has HEOS integrated but the Home assistant HEOS integration can only control it to a very limited extent. For many features I have to use the Denon AVR integration.
In any case the HEOS hack works fine for me for grouping so I guess I’ll continue using that for now.

I think you need to remove the custom integration for it to work, because when a custom integration is installed with the same domain as an official, the official will be disregarded. So the services won’t be available unless you remove the custom integration (to my understanding at least).

Ah yes you seem to be correct. The steps seem to be:

  • Go to the integrations page and remove HEOS (which is a custom integration).
  • Go to the HACS page and remove Denon HEOS (Custom)
  • Reboot Home Assistant
  • Install the default HEOS integration
    Haven’t done this yet. A bit afraid that I’ll break what works :joy:

It works :wink:
The heos integration installs itself after you deleted everything! You need to remove heos from the configuration.yaml too

1 Like

I have a similar configuration. 3x HEOS1 speakers and 1x HEOS3 speaker.
I’ve noticed the following difference in grouping with the official integration vs the custom one.
Whereas selecting additional speakers in the custom integration would add them to the Group, the official integration does not. Eg: The TV replaces the Kitchen speaker below rather than being added along with it:

Also, GROUP ALL behaves as expected, but UNGROUP does not.
heos

Can anyone confirm this behavior, or am I doing something wrong?

You’re right, I get the same behavior on my system. I’m not sure if this is perhaps a problem in the card or if it is in the integration. Maybe this is what direx meant when he said the card neeeded some updates to support it. I will try to check this later.

Hi,

I did some more testing, and I was able to tweak the mini-media-card to achieve what we want. I opened an issue on github, let’s see what the card owner thinks. Used your animation as illustration, hope thats ok.

2 Likes

hey,
i am not quite sure if somebody allready answered it, but i am quite confused by the configuration of the heos group thing:

  • i have an denon avr 2400xh with two zones - i allready saw that in the docu that zones arent supported yet - or is there an possibility?
    • mostly i would need an option to activated my second zone from my home assistent
  • i used the code of tormagj to setup my mini-media-player, but i am not able to stop my heos1 in the kitchen - any idea what i am doing wrong?
entity: media_player.kuche
speaker_group:
  platform: media_player
  show_group_count: true
  entities:
    - entity_id: media_player.heos_kuche
      name: HEOS Kuche
    - entity_id: media_player.denon_avr_x2400h
      name: Wohnzimmer
toggle_power: true
volume_stateless: false
group: true
  • the power off button doesnt work at all
  • i getting the follwing errors:
Logger: homeassistant.components.heos
Source: components/heos/__init__.py:303
Integration: Denon HEOS (documentation, issues)
First occurred: 17:34:51 (42 occurrences)
Last logged: 17:54:26

Failed to group media_player.denon_avr_x2400h with ['media_player.heos_kuche']: System error -9 (12)
Failed to group media_player.kuche with ['media_player.heos_kuche', 'media_player.denon_avr_x2400h']: Processing previous command (13)
Failed to group media_player.kuche with ['media_player.heos_kuche']: Processing previous command (13)
Failed to group media_player.kuche with ['media_player.denon_avr_x2400h']: Command timed out
Failed to group media_player.kuche with ['media_player.heos_kuche', 'media_player.denon_avr_x2400h']: Command not executed (7)

thanks everbody:)

Hi,

In HEOS at least, the power off feature is not implemented. I believe the reasons is that you actually don’t power the HEOS units off, but merely stop then and they go into sleep mode by themselves. In my custom-integration I did add the power-off feature to do a stop just as a hack, but it is not in the official integration. I considered making a PR for it, but instead I changed the card config to something like this:

cards:
  - type: custom:mini-media-player
    artwork: cover
    source: icon
    toggle_power: false
    hide:
      power: true
      power_state: false
      play_stop: false
      icon: true

In my case this hides the power button, and shows a play/stop button which I use to stop :slight_smile: See if that works for you too.

PS! I also have had some issues with the Processing previous command (13) error, and this seemed to be some hickup in my system so I rebooted my players and it solved my issue.

You shouldn’t name the master speaker also in the group list. So your Kuche speaker is the master, and the added group speaker is the living room speaker.

Are you sure about this @bjornb? I see that I have all speakers in the group list, including the main entity (or master) as well. It seems to be working fine in my case.

The grouping for heos is a bit different. From the heos integration page:

So far I understood heos always need to assign a master and you shouldn’t name it in the list. Working fine here done as per the screenshot.

But the service used here is media_player.join. Not grouping.

i am not quite sure if i totaly understand it right, but here is my analysis what i have to do (sorry when this isnt the right topic to put out the questions - then i will open up a new one):

As i tested out, i can switch on my denon zone 2 trough meda_player.turn_on and select an source (not quite sure what the source is called because in the gui i get printed out an “heos music” → is their an option to look that up?)

Now i thinking about using my own input_select that triggers states that turn on the right device and select the heos source.

Not quite sure how to let them join the devices then? media_player.join would be they way… that i understand but not quite sure how to create the right groups…

Hi! I did a PR to add/improve the handling of HEOS grouping for the mini-media-card, and card author kalkih released a new version today (v.1.16.0).

Note that platform must be changed to ‘heos’ again and not ‘media_player’. This may be changed later though, but was necessary to add some tweaks for HEOS different than for other devices in media_player domain.

type: custom:mini-media-player
entity: media_player.heos_office
speaker_group:
  platform: heos         # Notice this!!

Try it out and see if it works better, at least it did on my installation when I did the PR. Open an issue on the card github in case anything doesn’t work and I can assist kalkih to look at it.

1 Like

Yes, I’ve been meaning to thank you! I’ve been using it in beta a couple days now and grouping seems to be working perfectly.
I’m curious to know what your experience has been with the media browser. I just upgraded to 2022.3 and was hoping to play around with the new features now I have access to a lot more media. But my speakers (3 x Heos1, 1 x Heos3) do not appear as options to play on. Is this expected? Are we likely to get this functionality with a future update in the media browser or HEOS integration?

Sounds good!

Media Browser is not implemented for HEOS yet, but I have been playing around with it and have some extremely basic stuff working. My plan is to find some time to first add it and test it out on the custom integration, and then hopefully propose a PR to the official integration. Media browser has really got a lot of love lately, and I really liked the recent Radio Browser integration too. Currently I’m able to play favorites and some stuff, but I haven’t figure out Spotify yet, so it is really work in progress.

2 Likes