Coder Social home page Coder Social logo

nagyrobi / home-assistant-custom-components-linkplay Goto Github PK

View Code? Open in Web Editor NEW

This project forked from limych/media_player.linkplay

159.0 159.0 28.0 1.23 MB

LinkPlay based media devices integration for Home Assistant. Supports multiroom, Media Browser, and snapshot and restore functionality for TTS. Compatible with Mini Media Player card.

Python 100.00%
arylic cvte harman-kardon home-assistant linkplay media-player speaker tts

home-assistant-custom-components-linkplay's Issues

Can you please add sleep mode please

Please can you build in a sleep timer function in your component, I really need that because I use your component to play relaxing music when I’m going to sleep and I don’t want it to play all night I need a function that stops music after 30/60/120 minutes

Missing config flow...unable to load custom component

Hi
I getting this error in the logg. I think i may have seen it before but from Home Assistant 2022.5.5 i'm unable to load the integration.
It's strange since the manifest.json declare config_flow to false.

Logger: homeassistant.config_entries
Source: config_entries.py:316
First occurred: 21:10:30 (1 occurrences)
Last logged: 21:10:30

Error importing platform config_flow from integration linkplay to set up linkplay configuration entry: No module named 'custom_components.linkplay.config_flow'

TTS does not work when player is turned off [AudioPro C10, C5]

If the speaker is turned off (white led off) and a tts-command is sent, the speaker turns on but it newer "talks". It seems like the tts-audio is shorter than the time it takes to turn on the speaker. This should be no problem for an internet radio stream but not for tts.

With the speaker on it works just fine.

I've tried fiddling with inserting a delay i HA but I haven't found any configuration that works properly.

upnpclient is required

The installation instructions don't mention the installation of upnpclient in the manual installation. This is however required and easily solved with pip3 install upnpclient.

Media Player State in HA is not very accurate, shows 'playing' even if paused

Hello!

I noticed something when trying to write some automations that have different actions depending on the playing status of a linkplay media player. HA shows the state for the player as 'playing' for a long time after media is paused or stopped. How does the integration get the playing status of a player?

I was doing some digging myself, and saw that you can perform some direct HTTP API calls from https://github.com/AndersFluur/LinkPlayApi. If I use this API call, I can see that the player status is paused immediately after I send a pause command. This may be a better way to update entity state if it is not currently used?

Media player wont states

Hello Dev..
first thanks so much for the code.. i have been using it for so long.
i would like to report that i face a condition where i need to restart HA to make media player on a state condition
and it wont last long then media player in a off condition. i use 3 Arylic up2stream.
i have checked few variable like ip address, HA media player configuration, all good thought.

thanks

Icons don't update on player

After latest HA upgrade I've notice that play / pause icons don't update on my mini-media-player component. In the logs I can only find error related to Linkplay integration.
Anyone having such issue?

Home Assistant 2021.12.9
core-2021.12.9
User interface: 20211229.1 - latest
Device: iEAST AudioCast M5

My config:

media_player:
   - platform: linkplay
      host: 192.x.x.x
      name: iEAST
      icecast_metadata: 'StationNameSongTitle'
      lastfm_api_key: xxxxxxxxxx
      volume_step: 10
      sources: {}
   - platform: frontier_silicon
      host: 192.x.x.x
      name: MedionSypialnia
Logger: homeassistant.helpers.entity
Source: custom_components/linkplay/media_player.py:1826
Integration: Linkplay (documentation, issues)
First occurred: 11:52:35 (212 occurrences)
Last logged: 12:26:57

Update for media_player.salon_link_play fails
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 487, in async_update_ha_state
    await self.async_device_update()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 691, in async_device_update
    raise exc
  File "/usr/local/lib/python3.9/concurrent/futures/thread.py", line 52, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/config/custom_components/linkplay/media_player.py", line 2265, in update
    self._update_from_icecast(no_throttle=True)
  File "/usr/src/homeassistant/homeassistant/util/__init__.py", line 195, in wrapper
    result = method(*args, **kwargs)
  File "/config/custom_components/linkplay/media_player.py", line 1826, in _update_from_icecast
    import chardet
ModuleNotFoundError: No module named 'chardet'

repeat sources in configuration.yaml

Hi,

this might not be a linkplay integration question

I am trying to find a way how I could change the sources in one yaml file and include that at all linkplay platforms
does anyone has an idea?

Thanks for constructive feedback

(...)
    - platform: linkplay
      host: 192.168.1.80
      name: linkplay_0
      icecast_metadata: 'StationNameSongTitle'
      multiroom_wifidirect: True
      lastfm_api_key: 'secretkey'
      sources:
        {
!include linkplay-radio-sources.yaml
        }

    - platform: linkplay
      host: 192.168.1.81
      name: linkplay_1
      icecast_metadata: 'StationNameSongTitle'
      multiroom_wifidirect: True
      lastfm_api_key: 'secretkey'
      sources:
        {
!include linkplay-radio-sources.yaml
        }

    - platform: linkplay
      host: 192.168.1.82
      name: linkplay_2
      icecast_metadata: 'StationNameSongTitle'
      multiroom_wifidirect: True
      lastfm_api_key: 'secretkey'
      sources:
        {
!include linkplay-radio-sources.yaml
        }
(...)

Audiopro A10

My simple config looks like:

media_player:
  - platform: linkplay
    host: 192.168.20.145
    name: AudioPro A10
    volume_step: 1
    sources: { "line-in": "line-in" }

Everything works fine (nice intergation)
image
Except my on / off button.
Does not work at loveance cards and not with node-red.

Maybe a hint is in the enity window, because there is no on/off button.
image

And separate issue, but sometimes it starts by it self, without music.. Maybe not relevant, but then, maybe it is

Link_play creating new entities

Hi,

Once again, nothing works, yet again I find that there are new entities created without me touching the system, more than doing normal HA releases and possibly Link_play upgrades. The reason is that new entities has been created, media_player.stereon, referred to in scripts lovelace and automations has been changed to media_player.stereon_1 then media_player.stereon_2, then media_player.stereon_3. Firstly can this behavior be stopped in the future, Secondly is there a smart way to get it back to working state without changing everything referring to the first entity. It is quite a job and quite annoying.

BR
Tobe

Suggestion for linkplay device (ethernet)

Hey there,

I'm wondering if you have any suggestions for linkplay devices that have an ethernet work (not wifi only)? I have a bunch of the Muzo Cobblestones but to be honest I'm not too happy with them. They often lose connection, freeze, and require a reset command.

Thanks!

Linkplay shows title when pressing start but after 2 seconds it stops

Hi There,

I have a strange problem with link player. Configuration is like this:

`media_player:

Visualization and handling is over mini media player.

The problem is, that when I want to start the soma lifestream it shows the current title for about 2-3 seconds and then stops again. With The third source (Eins Live) it works fine. I turned already the log on but but there is no entry about this topic.

Does anyone has the same problem?

Error with "snapshot" service on AudioPro C5

Hello,

I am getting an error while using the snapshot service on a Linkplay powered device
My script is very simple :

action:
  - service: linkplay.snapshot
    data:
      entity_id: media_player.pdronoise

Error log is:

Logger: homeassistant.components.automation.door_opens_greetings
Source: custom_components/linkplay/media_player.py:1442
Integration: Automation (documentation, issues)
First occurred: 3:05:00 PM (8 occurrences)
Last logged: 3:16:41 PM

Door opens, greetings: Error executing script. Unexpected error for call_service at pos 1: 'NoneType' object has no attribute 'makeelement'
While executing automation automation.door_opens_greetings
Traceback (most recent call last):
  File "/config/custom_components/linkplay/media_player.py", line 1439, in _preset_snap_via_upnp
    xml_tree.find('Key'+presetnum+'/Name').text = "Snapshot set by Home Assistant ("+result+")"
AttributeError: 'NoneType' object has no attribute 'text'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 262, in _async_step
    await getattr(
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 463, in _async_call_service_step
    await service_task
  File "/usr/src/homeassistant/homeassistant/core.py", line 1488, in async_call
    task.result()
  File "/usr/src/homeassistant/homeassistant/core.py", line 1527, in _execute_service
    await self._hass.async_add_executor_job(handler.job.target, service_call)
  File "/usr/local/lib/python3.8/concurrent/futures/thread.py", line 57, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/config/custom_components/linkplay/__init__.py", line 131, in service_handle
    device.snapshot(switchinput)
  File "/config/custom_components/linkplay/media_player.py", line 1144, in snapshot
    self._preset_snap_via_upnp(str(self._preset_key))
  File "/config/custom_components/linkplay/media_player.py", line 1442, in _preset_snap_via_upnp
    snap=ET.SubElement(data,'Name')
  File "/usr/local/lib/python3.8/xml/etree/ElementTree.py", line 454, in SubElement
    element = parent.makeelement(tag, attrib)
AttributeError: 'NoneType' object has no attribute 'makeelement'

You have any idea of what's happening? I didn't tried to dig into the Python script yet.

Thanks!

Q: Arylic device with Mono setup

Guys, i want to buy the Arylic A50 device to integrate in HA

i have 2 speakers outside, but far from each other
is it possible to setup the A50 as a mono setup? so all sound is going to both speakers instead of stereo?

thnx in advance

Parse radio track titles

Thank you for tweaking and improving this component. I will then remove my component version from HACS as obsolete so that users do not confuse it with yours.

When using your component, track titles appeared when radio listening. But these track titles look a little odd. Here are some sample strings:

ELODIE~Guaranà~~~~~2020-08-13T08:11:53.252527~2020-08-13T08:11:53.252527~United Music Subasio +
GAIA~Chega~~~~~2020-08-13T08:15:04.497720~2020-08-13T08:15:04.497720~United Music Subasio +
LP~The One That You Love~~~~~2020-08-13T08:17:59.475604~2020-08-13T08:17:59.475604~United Music Subasio +

Note: Each string contains a line feed character at the end.

Please make an improvement so that such variants of track titles are automatically recognized and rendered in a human-friendly form.

Input source wifi

Hi,
for me the input source wifi does not work/exist. My hardware is an Arylic Up2Stream Mini v3. According to their docs wifi should be supported as input source (they also mention at the top that they are using standard Linkplay API).

This is my configuration.yaml:

media_player:
    - platform: linkplay
      host: 192.168.0.181
      name: Wohnzimmer
      volume_step: 10
      icecast_metadata: 'StationNameSongTitle'
      multiroom_wifidirect: False
      sources: 
        {
          'bluetooth': 'Bluetooth',
          'wifi': 'Wifi'
        }

Wifi is kinda the most important input source since it plays all kinds of sources like Spotify, Airplay, Amazon Music etc. Would be fantastic if I could get this to work. See screenshot below where wifi input source is missing.

Thx a lot.

Screenshot 2021-11-15 at 21 47 39

Duration when playing tts and mp3 via play_media

Hi!

I just re-installed HA after a break from the project for a couple of years and realized that the linkplay component was still actively developed, which makes me very happy :-)

I'm trying to get my old NodeRed flows up and running and stumbled into an issue. I'm playing a dynamically generated tts text and need to know the duration of the playback in order to start another stream (online mp3 file) when the tts is "done". However the "media_duration" attribute is not returned by the component when playing tts. I looked at the linkplay API and the "totlen" parameter is there and looks correct when playing the stream. I have the same issue when playing an online mp3 via the "play_media" service by the way.

Looking at the code I see that in media_position(self) and media_duration(self) the actual values are not returned when playing tts. I suspect there is some reason for this that I don't know of :-). Otherwise I would be happy to submit a PR if that's ok.

Really nice work with this custom component!

BR,
Niclas

Not compatible with : Plex Assistant

Guys, i installed this add-on yesterday, when i comment out the media_player config, no issues
whn i add below back , my component "plex assistant" is throwing an error on this link -play media player

not sure what component is giving the issue? seems plex is looking for somekind of incompatible media_player

media_player:
    - platform: linkplay
      host: !secret arylica50
      name: Luidspeker_Buiten
      volume_step: 5
      sources: 
        {}   
2021-08-26 13:44:17 ERROR (MainThread) [homeassistant.config_entries] Error setting up entry Synology for plex_assistant
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 293, in async_setup
    result = await component.async_setup_entry(hass, self)  # type: ignore
  File "/config/custom_components/plex_assistant/__init__.py", line 79, in async_setup_entry
    pa = await hass.async_add_executor_job(pa_executor, server, list(start_script.keys()))
  File "/usr/local/lib/python3.9/concurrent/futures/thread.py", line 52, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/config/custom_components/plex_assistant/__init__.py", line 75, in pa_executor
    get_devices(hass, _pa)
  File "/config/custom_components/plex_assistant/helpers.py", line 50, in get_devices
    for entity in list(hass.data["media_player"].entities):
KeyError: 'media_player'

Linkplay Snapshot xml error

When I try to call a snapshot of my linkplay device from an automation it fails with the following error:

SubElement() argument 1 must be xml.etree.ElementTree.Element, not None

Here's my automation, very simple:

service: linkplay.snapshot
data:
entity_id: media_player.kitchen_speakers

Playing my ripped CD's

Hi,

I'm using linkplay and it works great, some some things but generally good. (Using audiocast)
I run radiostreams and spotify. Thanks!!!
I'm not sure this is a linkplay issue or if I should ask elsewhere, but this is my wish.
I have ripped my favorite CD's to a harddisk on my old PC. Via the audiocast app, I can send the music to my speakers via both windows media server running on the PC as well as the PLEX server running on the same PC. When playing the music I can see what is playing in mini media player card and the normal media card. I can even see my CD's on the PC in HA Media browser through the PLEX integration, but I have no control from HA, can not play start or select the music from HA, the only thing I can do is change the volume. Would it be possible to add PLEX as a source to link-play integration, or even better, the windows player which I believe is just DLNA source? As said, I'm not sure this would help, Spontaously I would think that the media browser should have both a source and an output selection, but that don't seem to the general plan. I'm happy for any good ideas on how to play from one source to another output player.

Thanks
Tobe

Always offline with UpStream V1

Hi

I have two Arylic boards: an Up2Stream Amp 1.0 board and an Up2Stream board.
The integration is working fine and well with the Up2Stream Amp but not the Up2Stream. This later always shows up offline in HA. Both boards are in latest avalaible firmware.
I get that in HA logs:

Logger: custom_components.linkplay.media_player
Source: custom_components/linkplay/media_player.py:1853
Integration: Linkplay (documentation, issues)
First occurred: 10:25:57 (107 occurrences)
Last logged: 10:43:17
Erroneous JSON during update player_status: media_player.sdb_hp, SDB_HP 

Board too old to be supported ?The Linkplay board on it has these references if it can help: A31 V04

Thanks for help and that great integration ;)

Vincèn

Player becoming unavailable and impacting other services

HASSOS 8.1
HA 2022.06.4

I am having an issue with the integration - I see a lot of messages in the logs.:

2022-06-10 16:07:00 WARNING (MainThread) [homeassistant.components.media_player] Updating linkplay media_player took longer than the scheduled update interval 0:00:03

2022-06-10 16:16:27 WARNING (MainThread) [custom_components.linkplay.media_player] Failed communicating with LinkPlayDevice (httpapi) 'Office': <class 'asyncio.exceptions.TimeoutError'>

Eventually it will cause other things to start timing out - I removed the integration for 24 hours and the issue disappeared. I'm really not sure what the problem could be.

image

Currently playing media meta-data not being send with media.player-play.media

When i use the media_player.play_media service and send an url, thumbnail and name. I can't see the thumbnail and name that i specified.

Here is code:

      - entity: media_player.overkapping_aan_tuinhuis
        type: custom:mini-media-player
        name: Plafondspeakers / Veranda Aan Tuinhuis
        info: short
        icon: mdi:speaker
        artwork: material
        hide:
          power: true
          icon: true
        shortcuts:
          columns: 4
          column_height: 80
          label: "> Radio Zenders"
          list:
            #RADIO 538
            - type: service
              image: /local/radiozenders/538.png
              name: Radio 538
              id: media_player.play_media
              data:
                media_content_type: url
                media_content_id: >-
                  http://25493.live.streamtheworld.com/RADIO538.mp3
                extra:
                  title: Radio 538
                  thumb: >-
                    /local/radiozenders/538.png
                entity_id: media_player.overkapping_aan_tuinhuis
  • In this image you can see that the player above (chromecast) does get the meta data but the LINK player below doesn't:
    image

play/paused doesn't update

hi, I am using an audiocast m5 and I just installed yout integration, thank you so much btw.
But the play/pause button isn't working in homeassistant. when music is playing and i press it, the music stops but the button doesn't update, also when I press it again the music doesn't start playing and the history tab in home assistant show that the state still shows playing. When I used my browser to go to the httpapi, the state did show right.

linkplay tunein multiroom-wifi 128kbps errors

Hi

I have
2 x A31 FW 4.2 (Audiocast M5)
4 x A11 FW 3.5 (DOSS Cloudfox)

i use them in the app Audiocast S on Android now, because my HA is dead at the moment :)

i wrote to Linkplay, but as you know they did not answer me (yet) and might never answer me
i just wanted to document this maybe someone knows a solution
it's not a problem of nagyrobi's integration
the problem exists on HA in multiroom wifi=true
the problem exists on Audiocast S App on android too

its a problem of FW 3.5 and 4.2 most likely

if i use 4.2 or 3.5 as master and connect the 5 other linkplays to it i cannot listen to multiroom at 128 kbps streams
i can listen 192, 256 and 320 kbps streams
maybe it is also a problem of wrong casting format but on tunein radio i cannot chose a different stream

this is a working stream
in browser i dont see exact details at inspect
<source src="https://ice.somafm.com/gsclassic" type="audio/mpeg">
this a a non working stream:
<source src="https://ice.somafm.com/u80s" type="audio/mpeg">

i found out when i use 192/256 or 320 fixed streams at that somafm.com stations i can use the mixed FW 3.5 and 4.2
but in tunein radio i cannot chose source like in nagyrobi's integration
if i have a 128 kbps stream i cannot use it because the 4.2 FW is late 10 seconds :) when FW 3.5 is master

any ideas?

Toogle play/pause doesn't work

Hi,

Thanks first of all for the integration.

I was trying to use media_player.media_play_pause but it seems doesn't work with the linkplay modules.

Just works media_player.media_play and media_player.media_pause

Is this a know issue?

Thanks,

Support for Wiim mini casting device?

Hello,

I just bought some Wiim mini cast devices (link: https://wiimhome.com/Overview.html). These devices are developed by Linkplay technology, but when I try to add them into HA with this integration, I immediately notice that they are unavailable.

From HA logg:

2022-04-26 23:07:41 WARNING (MainThread) [custom_components.linkplay.media_player] Failed communicating with LinkPlayDevice (httpapi) 'spisestue': <class 'aiohttp.client_exceptions.ClientConnectorError'>

Is it possible to add function for these devices? Or is this something completely different?

Best regards,

Spotify Play and pause does not toggle

I'm having the issue that was mentioned here,
#34

I have 6 Up2stream Amp V4 boards.

When I click pause the audio does pause but does not toggle to the play button. So I am not able to actually play from home assistant. I've experienced this with all 6 boards while using the default media player card as well as the custom:mini-player card.

I use Spotify and bluetooth as sources with these devices and I have the same issues in each source.

It seems to me the play/pause state is not being updated somewhere when the pause button is clicked

Linkplay-based speakers and devices unvailable

Hi all,

Any help please?

I have three speakers linkplay based and right now they are unavailable on home assistant.

This issue start after I upgrade Home assistant.
Version core-2021.9.7
Version supervisor-2021.09.0

The speakers are working and connecting to the WiFi network but not working throughout home assistant.

Any one with the same problem?

Regards,
João Alves

Artist Name is missing on 3 of 4 multiroom speakers

Hi

I try this homeassistant integration with DOSS Cloudfox A1

i own 4 pieces, bought all of them used from different sources
all have same firmware 3.5 something

still they are a little bit different, for example at boot one of the 4 (called green) has a lower default volume then the other three (called orange, yellow and blue)

Thank you very much first of all for this great integration!, i am in in testing and integrating this to make them work better
sorry i am not a developer

How could I debug the following?

I still use lovelace because i have no clue how to change it :)
just started 2 weeks ago with homeassistant

I see already lastfm albumcover and songtitle on all of the 4 mediaplayers
I see the artist only on the mediaplayer named blue
I see in the customization of the entity orange that artist is there, but its not shown on lovelace

I know this is off topic, but i will contribute more interesting stuff :)

Multiroom logic not compatible with Arylic A50/Up2Stream

cmd = "ConnectMasterAp:ssid={0}:ch={1}:auth=OPEN:".format(self._ssid, self._wifi_channel) + "encry=NONE:pwd=:chext=0"

This does not work with my arylic devices, which are supposedly compatible to the Muzo Cobblestone API described here: https://github.com/AndersFluur/LinkPlayApi/blob/master/api.md#multi-room-management
Do you by chance have an idea how to distinguish between these devices and those you wrote the integration for? The media playback commands seem to be compatible. I'll try to integrate the different commands

Edit: Also to me it looks like this would break when people use the SetRandomWifiKey command you provided. It's a really bad idea to use the open wifi mode as the devices will route between the AP and Station interfaces, effectively exposing your home wifi without password protection.

Question: How do I update firmware?

Hello,

Sorry for opening an issue here, but I didn't know where to ask. How do I update the firmware on my devices? I can't seem to find the option in the app.

Any help much appreciated :)

I cannot turn on/off an Audio Pro C10 speaker with media_player.turn_on/off/toggle from script

Hello,

I have successfuly added an Audio Pro C10 speaker with your component, and with a media_player card I can control it.

But I need to be able to turn it on/off via script, and that way I cannot control it. Any ideas?

My script:

sound_apro_on:
alias: sound_Audio Pro ON
sequence:

  • service: media_player.turn_on
    data:
    entity_id: media_player.audio_pro
  • service: media_player.select_source
    data:
    entity_id: media_player.audio_pro
    source: 'RCA'
    mode: single
    icon: mdi:speaker

thanks

Attempting to automate speaker join/unjoin with template

Hello:

I am enjoying using this to manage my linkplay speakers from home assistant, but I am having a hard time with an automation.

I am trying to use state-icons in a picture template card to trigger an automation that joins or un-joins a speaker group based on its current state. The template editor seems to recognize the speaker's state and feeds the right info into the automation, but nothing seems to happen.

Here is the automation:

- alias: "Add-Remove Bedroom" initial_state: true trigger: action: service: > {% if (is_state_attr('media_player.bedroom', 'slave', true)) %} linkplay.unjoin {% else %} linkplay.join {% endif %} data_template: entity_id: >- {% if (is_state_attr('media_player.bedroom', 'slave', true)) %} entity_id: media_player.bedroom {% else %} entity_id: media_player.bathroom master: media_player.jam_wifi_main {% endif %}

unavailable devices

Hi,

Since the last update 3.0.3 the devices allways become unavailable for few seconds

This error originated from a custom integration.

Logger: custom_components.linkplay.media_player
Source: custom_components/linkplay/media_player.py:383
Integration: Linkplay (documentation, issues)
First occurred: 12:43:56 (15 occurrences)
Last logged: 12:53:34

Failed communicating with LinkPlayDevice 'Bathroom': <class 'asyncio.exceptions.TimeoutError'>
Failed communicating with LinkPlayDevice 'Bedroom': <class 'asyncio.exceptions.TimeoutError'>

volume_set: sequence item 0: expected str instance, Optional found

Calling media_player.volume_set on a linkplay device doesn't work and reports an error:

sequence item 0: expected str instance, Optional found

I have tried both from an automation and from a script. My test script is:

alias: Linkplay volume_set test
sequence:
  - service: media_player.volume_set
    data:
      volume_level: 0.23
mode: single

My relevant config:

media_player:
  - platform: linkplay
    host: 192.168.3.195
    name: Linkplay Music
    icecast_metadata: 'Off'
    sources: {
      'https://stream.qmusic.nl/qmusic/aachigh': 'Qmusic',
      'https://19993.live.streamtheworld.com/SKYRADIO.mp3': 'Sky Radio',
      'https://21253.live.streamtheworld.com/RADIO538.mp3': '538',
      'http://19993.live.streamtheworld.com/RADIO10.mp3': 'Radio 10',
      'bluetooth': 'Bluetooth',
      'line-in': 'Line-in',
    }

Full trace:

Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 371, in _async_step await getattr(self, handler)()
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 571, in _async_call_service_step await service_task
File "/usr/src/homeassistant/homeassistant/core.py", line 1445, in async_call processed_data = handler.schema(service_data)
File "/usr/local/lib/python3.9/site-packages/voluptuous/validators.py", line 218, in __call__ return self._exec((Schema(val) for val in self.validators), v)
File "/usr/local/lib/python3.9/site-packages/voluptuous/validators.py", line 337, in _exec v = func(v)
File "/usr/local/lib/python3.9/site-packages/voluptuous/schema_builder.py", line 272, in __call__ return self._compiled([], data)
File "/usr/local/lib/python3.9/site-packages/voluptuous/schema_builder.py", line 817, in validate_callable return schema(data)
File "/usr/local/lib/python3.9/site-packages/voluptuous/schema_builder.py", line 272, in __call__ return self._compiled([], data)
File "/usr/local/lib/python3.9/site-packages/voluptuous/validators.py", line 215, in _run return self._exec(self._compiled, value, path)
File "/usr/local/lib/python3.9/site-packages/voluptuous/validators.py", line 339, in _exec v = func(path, v)
File "/usr/local/lib/python3.9/site-packages/voluptuous/schema_builder.py", line 817, in validate_callable return schema(data)
File "/usr/src/homeassistant/homeassistant/helpers/config_validation.py", line 134, in validate raise vol.Invalid("must contain at least one of {}.".format(", ".join(keys)))
TypeError: sequence item 0: expected str instance, Optional found

Any suggestions how to fix this?

StationName

Hello,

I'm using IEAST M5 players
Having settled icecast_metadata: 'StationName' I can't get the played url back in HA while available from HTTP command sent to my player.

HA status:
sound_mode_list:

  • Classic
  • Jazz
  • Normal
  • Pop
  • Vocal
    volume_level: 0.77
    is_volume_muted: false
    media_content_type: url
    media_position_updated_at: '2021-01-19T17:06:32.721727+00:00'
    media_title: ''
    sound_mode: Normal
    shuffle: false
    repeat: 'off'
    linkplay_group: []
    master: false
    slave: false
    firmware: 4.2.8920
    debug_info: UPnP detected
    friendly_name: Bureau
    icon: 'mdi:speaker-wireless'
    supported_features: 88589
    device_class: speaker

HTTP command:
Sent:
http://192.168.1.61/httpapi.asp?command=getPlayerStatus
Response:
{"type":"0","ch":"0","mode":"10","loop":"0","eq":"0","status":"play","curpos":"208267","offset_pts":"208267","totlen":"0",
"Title":"http://radios.rtbf.be/musiclab-128.mp3",
"Artist":"556E6B6E6F776E","Album":"556E6B6E6F776E","alarmflag":"0","plicount":"0","plicurr":"0","vol":"77","mute":"0","iuri":"687474703A2F2F726164696F732E727462662E62652F6D757369636C61622D3132382E6D7033","uri":"687474703A2F2F726164696F732E727462662E62652F6D757369636C61622D3132382E6D7033"}

HA Configuration Validation stuck after editing config

Hi,
I am new to HA, so I am probably just missing an important piece of information. But as soon as I add linkplay to the configuration.yaml, the config validation doesn't work anymore.

I installed linkplay via HACS, restarted everything and am adding following lines to the config:

media_player:
    - platform: linkplay
      host: 192.168.178.52
      name: pc speaker

Without these lines the config validation works jsut fine. After adding these lines the validation gets stuck and never shows "Configuration valid!" or similar.

Arylic Up2Stream HD Dac state unavailable

I have several Arylic devices in my house with no problem, i have recently bought an Arylic up2stream HD Dac, also with Linkplay. State is always unavailabe in HA.
I get the following error in HA log:
2022-07-04 23:31:41 WARNING (MainThread) [custom_components.linkplay.media_player] Failed communicating with LinkPlayDevice (start) '192.168.1.216': uuid: FF970023601DD7574229E08A <class 'aiohttp.client_exceptions.ClientConnectorError'>

Is it able to call an action to play a playlist on Linkplay device?

I've installed this linkplay component and it works great.

By the way, I have not found the linkplay action of this component to play a playlist from local storage instead of selecting only 1 media file as current.

Is there a solution to support playing a playlist on Home assisstant action from Script/Automation?

Thank you.

Turn on not always detected by automation

My linkplay speaker is not always powered. When it's powered on I'd like it to start playing a radio station. The automation I use is detailed below and is based on detecting a status change from unavailable to idle.

This is however not always detected and sometimes quite delayed.

Is there anything you could do to help me figure out the issue here?
Anything I can do/check for additional information?

alias: Badkamer Qmusic
description: ''
trigger:
  - platform: state
    entity_id: media_player.badkamer_muziek
    from: unavailable
    to: idle
condition: []
action:
  - service: media_player.select_source
    target:
      entity_id: media_player.badkamer_muziek
    data:
      source: Qmusic
mode: single

Linkplay voice module

Hi @nagyrobi,

I use your integration in Home Assistant, and my speakers have integrated a Linkplay C02 voice module.

I was wondering if somehow, this module can be integrated in HA for voice commands. Any thoughts or projects that you may be aware of?

Thanks

Help: Problems with sync between devices.

Hello,

I have 3 linkplay devices:
2x https://www.amazon.co.uk/dp/B084R8N8KD/
1x https://www.aliexpress.com/item/1005002087732418.html

The two Arylic devices can link successfully and play music in sync (when wifidirect is disabled). However, when I try to link the other one (linkplay board) nothing really happens, the integration indicates they are linked but nothing is playing from it. App doesn't acknowledge the link as well.

I tried the option: multiroom_wifidirect: True
But when this is enabled, nothing will sync. If I try to sync any device the sync fails with audio prompt: "Failed to connect to network" from the device that is trying to sync to master. Arylic won't sync to each other or to linkplay board.

Any suggestions?

Many thanks!

Keepalive request

I have configured linkplay sucessfully with custom lovelace card. Everything works, but my device (old Venz A501, but available in some store) go sleep after half hour when in idle. (I want to build it under cover, cannot access buttons)
Can I send any dummy command via httpapi.cgi to keep alive? How can I send entity command to device with your lib (instead of hass internal http get)? Or you can implement a 5 minute (configurable) dummy command, ex. IncVolume 0?

Volume issues

Hello,

I have two Audio Pro A10s. They are paired in the Audio Pro app such that Kitchen is the main speaker and Living Room is a sub speaker to Kitchen. I'm not sure if that makes them paired in WiFi direct mode och Router mode. Since about a week (or two) back, when I change the volume of the speaker Kitchen in Home assistant, only the Kitchen speaker changes volume. However, if I start Spotify on my laptop and play music to kitchen and change the volume from within the app the volume changes fine on both speakers.

Any one else experienced anything similar? Any thoughts on what could be wrong?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.