That button controls the entity declared in the mini-media-player. According tot the docs you can’t change the behavior of the button. So only use it as a poweron/off/toggle for the entity declared. What you could do is use the Shortcut buttons to create two buttons with each it’s own script (that you need to create), one to turn on all the media_players and one to turn them all off.
This should give you two Shortcut buttons that are tied to scripts you create, that turns on/off all media_players.
Yes correct, great tip. I have one myself for some use cases. You just simply need to declare the power on/off commands in the universal media player, like this:
Mini media player card is just a card, nothing more. It can’t so stuff that HA can’t do on it’s own. Your issue is not related to this card.
You’re trying to play Spotify to a Google Nest through Chromecast, which is not natively possible. You can’t send a Spotify url to Chromecast. You either need to use the Spotify integration and then send music to Spotify Connected speakers (so NOT Chromecast). Or install a custom component called spotcast (install through HACS), which allows you to play Spotify songs/playlists through Chromecast. It has some drawbacks (like music interrupting every hour because of expiring tokens, I believe this is still the case).
Make sure you read the README of spotcast, it isn’t plug and play and requires you to retrieve tokens etc.
TL;DR: Spotify app on your computer acts like a Spotify Connect speaker which is why it shows up. Chromecast is not a Spotify Connect speaker, so won’t work with Spotify integration. Use spotcast custom component to play on Chromecast.
Tromperie
I not that along with nickrout you sing the praises of LMS. I have just tried an install and have had early success. I’m stuck trying to get spotify (premium) setup. I’m only asking in this forum as it seems you may be using the same hardware? My server is running on truenas 12.0-U5.1
Pat
Hey Pat,
I have TrueNAS Core, now 12.7 bc I aggressively update, but had Spotify Premium working on an earlier version about 12 months ago.
You need to go to Settings and install the plugin, along with, I think, whatever dependencies. Once installed (and perhaps restarted), click on the plugin settings and enter the username and password. I don’t recall it being any more difficult than that.
Is there a variable for active button colour?
I have buttons for source and the attribute: source configured, however my buttons aren’t coloured based on the active source (nest speakers).
I was wondering if there was a variable to change the active button colour or if there is a way to figure out why my active source isn’t changing the colour of the active button.
But get this error:
Logger: frontend.js.latest.
Source: components/system_log/init.py:189
First occurred: 10:26:59 PM (3 occurrences)
Last logged: 10:29:21 PM
/hacsfiles/button-card/button-card.js?hacstag=146194325342:1:0 NotSupportedError: CustomElementRegistry.define: ‘button-card-action-handler’ has already been defined as a custom element
I have also tried using the devloper tools to no avail but if I use the built in media player I can chang sources.
Meanwhile I already did the installation of spotcast and it works fine with the custom:spotify-card.
I don’t have spotify connected speakers, only chromecasts. Does this mean that the only possibility to listen to spotify is the custom:spotify-card (even if I’m already very happy like it is ). Is it for example possible to make an automatisation to play a certain spotify playlist at a certain time ?
Spotcast is an integration (custom component) and creates a new service. Which you can use with automations, scrips, front end actions (service calls) just like any other service (like turning a light on).
For further questions you should visit the Community thread (the link in my post you responed to). I don’t use Spotcast anymore, but many do so they can help you out there.
Wondering if there’s a way to break out the volume control in order to make it bigger (full width of the window/card) as on a tablet its difficult to adjust the volume because of the small travel and my large fingers .
Frank
I found the issue. I messaged the developer of spotty who graciously responded within 12 hours. There is no build or support for BSD. He made some suggestions that overextended my linux skills. I have now installed LMS server within my hassos. It is working flawlessly including integrating my spotify premium account. I’m one happy chappy.
Pat