LinkPlay Integration

Hello, how can I add a functionality, when I trigger nabucasa.tts engine, and when it plays the TTS, to return autoamtically to radio station?
I tried announce tag but it doesn’t work.
Im currently use snapshot media_player, but I want to skip that, and to leave it for linkplay to do it a job for me

Hi @Kamil-u , I’ve now reached a point where there is some basic functionality appearing in the ‘Mini Media Player’ Lovelace card, but most of the functionality is not working. In addition most of the really useful functionality, such as changing the input source, doesn’t even appear to be accessible.

I have had a poke around using the http API and via that means the Arylic box appears to be responding as expected. My confusion now is, why does the LinkPlay integration mention “Fully compatible with Mini Media Player card for Lovelace UI by kalkih, including speaker group management.” when in my instance at least that doesn’t appear to be the case. Or am I still naively missing something in the set-up somewhere?

There sadly isn’t a media player card that fully supports the linkplay platform currently. Mini and maxi media player do work with some features, but no grouping etc. Although stated in the linkplay docs, the standard ‘media_player.join’ service also does not work.

I spent quite a lot of time to build a media player card myself for that reason. Problem is that the linkplay integration is quite buggy and weird for some things, so the cards yaml code got huge and full of custom helpers. But I’m currently trying to declutter that mess and am going to share the whole thing here soon, here’s a preview:

1 Like

Can anyone assist with the H50 integration. I’m trying to get a button to change input sources. I run calls for media_player.select_source and choose HDMI, Bluetooth, etc but it doesn’t actually change them on the H50. Any suggestions on how I could achieve this?

Hi! I updated Home Assistant to 2024.5.0 and I get an error saying the linkplay integration couldn’t load properly. Anyone else having the same issue?

There was a new release - make sure your linkplay integration is up to date.

1 Like

Since the latest firmware update (4.6.415145.55) on my Arylic A50+, I’ve been experiencing issues with selecting the source using automation. Oddly, when I manually select the source (optical) from the dashboard, it works fine. However, when I create an automation to switch the source to optical, it doesn’t work. Has anyone else encountered this issue?

Configuration:

- platform: linkplay
    host: 192.168.1.30
    name: "Woonkamer Linkplay"
    uuid: 'FF31F09EACCEED3E0B6B51B6'
    volume_step: 10
    icecast_metadata: 'StationNameSongTitle'
    multiroom_wifidirect: False
    sources: 
      {
        'optical': 'TV',
        'line-in': 'Platenspeler',
        'bluetooth': 'Bluetooth',
      }
    common_sources: !include linkplay-radio-sources.yaml

Automation:

alias: Audio bij Apple TV
trigger:
  - platform: state
    entity_id:
      - media_player.woonkamer_appletv
    to: null
condition: []
action:
  - choose:
      - conditions:
          - condition: state
            entity_id: media_player.woonkamer_appletv
            state: playing
        sequence:
          - service: linkplay.unjoin
            metadata: {}
            data:
              entity_id: media_player.woonkamer_linkplay
          - service: media_player.select_source
            metadata: {}
            data:
              source: TV
            target:
              entity_id: media_player.woonkamer_linkplay
mode: single

When the automation changes the source according to the status-viewer in developer-tools the input is changed to “TV”, but there is nu sound. Also the LED indicator in de Arylic turns to white instead of purpel.

When selecting “TV” input from the dashboard everything works fine.

Yes. Up to date your linkplay integration.

"Logger: homeassistant.setup
Source: setup.py:481
First occurred: 12:50:42 (2 occurrences)
Last logged: 12:50:42

Unable to prepare setup for platform ‘linkplay.media_player’: Unable to set up component."

I have the same error in logs but it does nothing to interfere with device.

Failed communicating with LinkPlayDevice (httpapi) 'Arylic': <class 'aiohttp.client_exceptions.ClientConnectorError'>
Failed communicating with LinkPlayDevice (httpapi) 'Arylic': <class 'TimeoutError'>

I’m using Mini Media Player and it works just great.

Maybe You have some typo in config.yaml?

Hi all,

Not sure whether this is too off-topic but I couldn’t see an obvious place to post it.

I recently bought a WiiM Pro and am generally very happy with it. I want to use it with HA and it’s a Linkplay device so I’ve been following this thread as well as looking at various third party integrations (plus this PR to get a Linkplay integration added to core!).

This all looks very promising but all of the integrations I’ve seen seem to poll using the Linkplay API rather than subscribing to UPnP events - which should be preferable for both the device and for HA. (This comment from the author of the WiiM fork of the Linkplay integration gives the impression that these devices don’t cope well with frequent polling.)

So it has been bugging me that the standard HA UPnP integration doesn’t seem to work with my WiiM Pro. I’ve taken a closer look and realised that it is a due to what looks like a bug in the WiiM. The events that it sends back to HA are not formatted correctly.

TL:DR → In a nutshell, the upnp:class property should be inside the item object in the DIDL-Lite xml in the state_variables in the event message. Unfortunately it seems to be in the wrong place - or at least not where the didl_lite python package expects it to be.

I’ve made a small but very nasty hack to didl_lite.py in my HA installation and the HA integration now works perfectly:

I have raised his as an issue with WiiM support and there is a precedent for them fixing UPnP message issues so I’m hoping that this will just be sorted out in time. However, if it drags on then I might think a bit more about workarounds.

I’m interested to understand whether this issue affects Linkplay products other than WiiM. Does the core UPnP integration work for other devices?

Anyway, FYI.

@Kamil-u

I had the same problem. After a HA reboot the arylic up2stream is working again.