What hardware are you using to Host? That'll influence the answer.
homeassistant
Home Assistant is open source home automation that puts local control and privacy first. Powered by a worldwide community of tinkerers and DIY enthusiasts. Perfect to run on a Raspberry Pi or a local server. Available for free at home-assistant.io
MA and HA are hosted on a RPi4 in the garage, not near the speakers.
Squeezelite with a USB spdif out might work? (I'm unsure myself, I have my squeeze server able to connect to my casting devices)
Bonus: a USB spdif out isn't pricey says a very quick search
Edit: I'm dumb. https://github.com/sle118/squeezelite-esp32?tab=readme-ov-file#spdif
So they suggest either a specialized chip, which will likely need more hardware, or this little circuit. (See link) I would say if you had an extra coax cable, to cut an end and solder away, but that's assuming a lot.
Second edit: they can connect to Bluetooth as well.
Thanks mate, much appreciated. That's what I mean, it's complicated... I have no idea what extra hardware I'd need. I just want to connect it via Coaxial and the only thing I can find is very complicated docs like you found :)
BT is not an option as I'd like to keep using the tablet directly to BT in case MA/HA is down.
Ok someone has mentioned Logitech Media Player. There is Raspotify too.
Both of these options are Pi compatible and I run both myself.
So here's the use cases for me:
LMS or Squeezebox is a full blown audio media server. I have pulled the music off and old iPod and put it on a server that LMS can "see" and I can play via speakers and Bluetooth.
There's plugins for LMS and Spotify is one of them. Another that I use is the Chromecast Bridge that allows LMS to connect to Google devices. There's an Apple Bridge, a UPNP bridge and a DLNA bridge too. Meaning you can connect all sorts of shit to this server and play your own music, Tidal, Spotify, SoundCloud, YouTube, etc.
It's far more involved in it's set up but if you have a pi lying around it's a great option.
Raspotify is also known as Spotify Connect. You can install this in Home Assistant but your HA device will need speakers. You can also install it on any pi and it just shows up as a connection in Spotify.
I see you're talking about a tablet you have. I run Fully Kiosk on a tablet myself and recently noticed that it shows in HA as a media player. I haven't tried to play media through it yet but maybe a quick and easy option for you.
Edit: I just tried using the Fully Kiosk Browser media player on my tablet and it worked just fine. No idea how to get Spotify in there but there you go.
Thanks for the long reply! I've tested Fully Kiosk again and now it seems to work perfectly. Previously it was not reliable, guess they have fixed it.
You could try getting a Raspberry Pi Zero together with some kind of SPDIF output card, but that will probably go over $30.
I have no idea what pricing is like, but you could possibly try getting a used Logitech Squeezebox player.
If you're desperate to stay on the cheap and don't mind BT quality, you could also install Snapcast on an old phone, enable the Snapcast player provider and then use the phone to connect to your speakers over Bluetooth.