Lovelace: Mini Media Player

I’m trying to use the group configuration to obtain a setup like the docs (see below):

My audio setup is I have 2 Sonos AMPS that connect to either living_room or outside so I have:

media_player.living_room
media_player.outside

I used the following YAML:

type: entities
entities:
  - type: 'custom:mini-media-player'
    entity: media_player.multiroom_player
    group: true
    source: icon
    info: short
    hide:
      volume: true
      power: true
  - type: 'custom:mini-media-player'
    entity: media_player.living_room
    group: true
    hide:
      controls: true
  - type: 'custom:mini-media-player'
    entity: media_player.outside
    group: true
    hide:
      controls: true

and get this result:

Ideally I think I’m supposed to have the media_player.multiroom_player control the source, play, pause, next and then the power buttons for media_player.living_room and media_player.outside are controlled by the power buttons.

I have looked and can’t figure out how to setup the media_player.multiroom_player which would control the stations from my sonos system. Hopefully someone has this working with Sonos and it’s easy. Any guidance is greatly appreciated.

This card does not create a media_player.

hello you made a very nice card could you share the configuration? thanks in advance

I have a question and a response to Jarne_Roussard:

Question: So it appears like I need to setup a media player to act as the source. I have Sonos which I thought was a media player but it doesn’t appear to be working if I put in in the yaml in the place of media_player.multiroom_player. Does everyone setup a separate media player on their machines?

The card first shown in my request above is developed by Kalkih and can be found here:

Yes this whole thread is about that custom card.

Sonos is a media_player integration. You need to set it up of course. https://www.home-assistant.io/integrations/sonos/ and can be used in this card.

https://community.home-assistant.io/t/fully-loaded-media-player-card-picture-elements-project/

Hello everyone. I am using the mini media player with a google nest mini. The issue that i encounter is that the controls are not all visible: previous and next track do not appear on the card. Is this behaviour normal for a nest mini? Thank you in advance for your help.

It will kinda depend on what you are streaming to the device I think. As long as you don’t have the controls hidden in the card config they should be there and work.

@sparkydave, You are absolutely right. sorry for not testng before. i was using the database on my nas and i suppose that the player does not see all the tracks. by using a spotify playlist, the button do appear. thank You for the reply.

Off topic - how are you playing music from a NAS in HA?

Thank you for this great app. It works fine in my HA. Quite fine, I have one only issue.
I use a set of squeezebox (SB) that I want to synchronize. I can synchronize every SB by clicking on their own sync button.

Capture

But when I hit the “group all” button, i get this error message:

Échec d'appel du service (trad: fail to call service) "squeezebox/sync". value should be a string for dictionary value @ data['other_player']

The “ungroup all” button works fine.

What could be the problem ?

hi guys. i use mini-media-player but i’m unable to change icon of the device.

Does anyone has same problem?

I am using a mount commande for a smb share that runs at startup.

Can you share your configuration for this card? Because I’m trying to set up a speaker group for squeezebox myself and I can not even get a single box of them to sync.

I have several Squeezebox Speakers and tried to use the speaker group functionality, which is not working for me. I have used the example configuration.

The error I receive is: Failed to call service squeezebox/sync. required key not provided @ data[‘other_player’]

I can group my speakers when issuing a service call through the Home Assistant GUI.

Here it is:

type: entities
entities:
  - type: 'custom:mini-media-player'
    entity: media_player.squeezebox_madame_ma_femme
    group: true
    source: icon
    info: short
    hide:
      volume: false
      power: false
  - type: 'custom:mini-media-player'
    entity: media_player.moode
    group: true
    hide:
      controls: false
      power: false
  - type: 'custom:mini-media-player'
    entity: media_player.squeezelite_ordimajik
    group: true
    hide:
      controls: false
      power: false
  - type: 'custom:mini-media-player'
    entity: media_player.squeezelite_x_kender
    group: true
    hide:
      controls: false
      power: false

But that is not for the speaker group, right?

Sorry, you’re right:

type: 'custom:mini-media-player'
entity: media_player.squeezebox_madame_ma_femme
hide:
  power: true
  icon: true
  source: true
speaker_group:
  platform: squeezebox
  show_group_count: true
  entities:
    - entity_id: media_player.squeezebox_madame_ma_femme
      name: sbox madame ma femme
    - entity_id: media_player.moode
      name: sbox moode
    - entity_id: media_player.squeezelite_ordimajik
      name: sbox ordimajik
    - entity_id: media_player.squeezelite_x_kender
      name: sbox kender

Thank you! That’s really weird. Your configuration is the same as mine, but yours is working and mine isn’t. I can now also connect another box if I use the switch for a single box.

But I also have the same problem that the Ungroup button isn’t working for me either.

What version of home assistant are you using? Grouping for squeezebox hasn’t always been there.

Also, try clearing the browser cache (ctrl-f5)

EDIT here is mine, not sure it is any different really:

group: true
hide:
  icon: true
  info: false
info: short
speaker_group:
  entities:
    - entity_id: media_player.laundry
      name: Study
    - entity_id: media_player.radio
      name: Radio
    - entity_id: media_player.bedroom
      name: Bedroom
    - entity_id: media_player.outside
      name: Outside
  platform: squeezebox
  show_group_count: true
type: 'custom:mini-media-player'

I’m using the latest Home Assistant version. Cache was cleared but that didn’t help.