Closed Ivanverdonck closed 3 years ago
Hi all, I noticed a similar behaviour: starting the integration when the teufel device is off, triggers the error. Best, Alex
Hi @Ivanverdonck and @alexludwigklein,
Thanks for filing and pointing out this issue!
In the current implementation the Teufel host is validated during configuation/startup. If the host does not reply within 3 seconds or is not considered as a valid host, the setup fails.
I think it would be better, if it only fails during configuration and pauses the setup during startup while polling for availability.
Can you confirm that it works as before, when forcing the validation from above to succeed?
Hi Marc,
your proposal seem valid, but unfortunately I don't understand what I should confirm and/or test. I just did another test and restarted the server while the teufel device responded to 'http://
Best, Alexander
Thanks for the feedback @alexludwigklein! Best, Marc
is there a way to wake up a device so it gets properly detected? if host_is_not_valid --> wake up, wait x seconds, poll again
.
is there a way to wake up a device so it gets properly detected?
A Raumfeld device configured as host cannot be switched off and will always be on to receive commands. Devices controlled by a host may turn to stand-by or be disabled. Since these devices, resp. speakers are controlled by the host, this does not impact their manageability. The power status of speakers can be managed via teufel_raumfeld.set_power_state
. See: https://github.com/B5r1oJ0A9G/teufel_raumfeld/wiki#services
The issue here is rather that the configured Raumfeld host is not running (e.g. unplugged), not reachable or not properly setup as a Host on the device side.
is there a way to wake up a device so it gets properly detected?
A Raumfeld device configured as host cannot be switched off and will always be on to receive commands. Devices controlled by a host may turn to stand-by or be disabled. Since these devices, resp. speakers are controlled by the host, this does not impact their manageability. The power status of speakers can be managed via
teufel_raumfeld.set_power_state
. See: https://github.com/B5r1oJ0A9G/teufel_raumfeld/wiki#servicesThe issue here is rather that the configured Raumfeld host is not running (e.g. unplugged), not reachable or not properly setup as a Host on the device side.
That is great news!
I have a single Raumfeld unit running (Connector 2) that goes asleep after x minutes of inactivity. It wakes when I start my favorite streaming service. I am experiencing exactly what is described in the OP. My thinking is to set the connector to on
when restarting Home Assistant. The Teufel integration should then be able to find the Connector.
alias: 'Speakers: Raumfeld on at reboot'
description: ''
trigger:
- platform: homeassistant
event: shutdown
condition: []
action:
- service: teufel_raumfeld.set_power_state
data:
entity_id: sensor.room_woonkamer_powerstate
power_state: 'on'
mode: single
Just tested. Connector pops "on". But still the "Invalid Host" error 👎
@Ivanverdonck ,
I created a branch dev-grace-time-host-setup. In the commit 8973495 I implemented a grace time about 30 seconds to wait for the configured Raumfeld host to become ready. Can you please test whether this resolves your issue and report back?
@balk77 ,
Just tested. Connector pops "on". But still the "Invalid Host" error -1
Well, I have to admit that I cannot speak for the various possible Raumfeld setups. My setup is a One M as host and multiple One S connected to it. This is the setup teufel_raumfeld
was developed around.
The Spotify issue #4 showed me a new and unexpected aspect already. There it was due to the fact that I am using Tidal and not Spotify.
Concernign the Connector I'd have expectd that whatever status the device claims to have, that it would still be available for requests by teufel_raumfeld
. However, It could be that the behavior having a single Connector is different.
Could you perhaps test whether teufel_raumfeld
is working after reboot, when having the validatoin removed - see https://github.com/B5r1oJ0A9G/teufel_raumfeld/issues/8#issuecomment-835539614?
Wait, I made a mistake. Do not read this :) (I made a copy of the teufel folder which was found by HA)
Could you perhaps test whether
teufel_raumfeld
is working after reboot, when having the validatoin removed - see #8 (comment)?
I have commented these 4 lines and tried with the Connector in eco
mode (without my pre-shutdown automation) and in on
mode. It works:
2021-05-20 20:28:38 WARNING (MainThread) [custom_components.teufel_raumfeld] You are using teufel_raumfeld, which is still in alpha phase and therefore subject to change. This includes, among other things, the addition, redesign or removal of functionality.
2021-05-20 20:28:38 INFO (MainThread) [homeassistant.setup] Setup of domain teufe_raumfeld took 0.0 seconds
2021-05-20 20:28:56 INFO (MainThread) [homeassistant.components.media_player] Setting up media_player.teufel_raumfeld
2021-05-20 20:28:59 INFO (MainThread) [homeassistant.components.sensor] Setting up sensor.teufel_raumfeld
The player is found
Thanks for the feedback @balk77! Could you then please also give it a try with the grace time mod mentioned in https://github.com/B5r1oJ0A9G/teufel_raumfeld/issues/8#issuecomment-844435997?
Thanks for the feedback @balk77! Could you then please also give it a try with the grace time mod mentioned in #8 (comment)?
also works 👍 (I had the Connector on
when restarting)
and also works 👍 (with Connector eco
when restarting)
@B5r1oJ0A9G : I also tested "dev-grace-time-host-setup" , seems to work OK.
Thanks!
Thanks folks! I just merged the changes to the master branch.
That was fast, just my 50 cents: I have been testing your addition as well without any problems and avoiding any 'invalid host' problems
Thanks for the feedback @alexludwigklein! Glad we were able to find a quick solution.
Best, Marc
Hi,
After installing teufel_raumfeld (using HACS), the integration works perfectly, but after a restart of homeassistant i get following error:
After removing the integration and installing it again the host is discovered correctly.
I am using docker:
System Health
Home Assistant Community Store
GitHub API | ok -- | -- Github API Calls Remaining | 4664 Installed Version | 1.12.3 Stage | running Available Repositories | 777 Installed Repositories | 17Home Assistant Cloud
logged_in | false -- | -- can_reach_cert_server | ok can_reach_cloud_auth | ok can_reach_cloud | okLovelace
dashboards | 14 -- | -- resources | 7 views | 34 mode | storage