LG WebOS TV Update on HA 0.104.0 not working

Hi!
I assume Andrew’s config should work in that case.
I haven’t tried - my config works for my one TV Setup

   # LG TV Notify
   - platform: webostv
     host: 192.168.1.xxx
     name: 'Living Room TV'
     
   - platform: webostv
     host: 192.168.1.xxx
     name: 'Master Bedroom TV'

I can’t get this to work at all, what is the domain? media_player? I tried webostv: but it didn’t work.

It should be under media_player.NAME
NAME is what you defined when you setup the webostv integration.

In your configuration remove the data under media player and notify for your webos tv that the previous integration required.

OK seen there has been a bit of a conversation in my absence but i have managed to link both my LG TVs, however there seems to be some strange behaviour.

When i first installed it i was prompted to configure both TVs which i did and it successfully connected, however every reboot of my HASS.IO device triggers another pairing request for the first TV i paired again suggesting that its only saving the conf file for the last device to be paired.

This in the past was dealt with by using the filename variable to specify a conf file for each TV, now that this option has been deprecated it appears to only save a conf file for one TV at a time.

Take that aside also i don’t seem to be able to get the notify function working or indeed be able to use the remote control buttons, this is something i a, going to look into today see if i can get to the bottom of it.

2 Likes

I have 4 LG TVs and this missing filename isn’t an option for me… I can’t re-pair all of them every time.

I saw on another post that you can rebuild the webostv.conf

I only have 1 LG tv, so not sure if it works…

However, I seem to have another issue, it looks like my automation isn’t triggered properly:
the state: ‘media_player.living_room_tv’ doesn’t detect the state change from 'Off" to ‘*’

Did you see in the breaking changes that the on state is now called “on” instead of “playing”? Not sure if that’s your issue or not, but my automations are working properly after making this change.

Neh…tried from ‘Off’ to ‘On’ also…
( the original automation is from state ‘Off’ to *, so that should include ‘On’ right?)

Multiple TV’s are supposed to work with a single configuration file. This was broken in 0.104.0, but fixed in 0.104.1.

There are major changes in 0.104 both to the upstream library and in the webostv component to support the new features (input commands, non-polling state updates, etc), so it’s possible there are still some remaining bugs, or issues with certain TV models, etc. If you’re still having issues with 0.104.1 please open a github issue with detailed config and log info, etc.

Hello! i see others have more lg tvs. please, who knows the correct configuration, describe it. Unfortunately, it doesn’t work out for me. Thank you!

I also have problems with my LG WebOS notifications. I see this error in my log (Hassio v. 0.104.1):

Big issue is that - now when LS WebOS is no media device anymore I cannot check weather it is turn on or not. Now I cannot turn-off my lights when my TV is turned off…

The conf file seems to be fixed by the last update, notify still knackered.

Don’t know if it’s a coincidence but all my Fire Sticks have disappeared as well :see_no_evil:

Well I think it is all working now - notifications and states:

What I did was:

  • Remove all WebOStv in configuration.yaml and groups.yaml
    image
    in notification.yaml
    image
  • Added new lines in configuration.yaml
    image
  • Changed condition state from “Playing” to “on” in automations:
    image

ok notify fixed with help of @MrBorg

will open a seperate item for my fire tv issues

Try this. You should pair only once.

webostv:
  - host: 192.168.1.222
    name: LGTV1
            .
            .
            .
  - host: 192.168.1.223
    name: LGTV2
            .
            .
            .

I’ve changed config as it is described to:

webostv:
  host: 192.168.1.xxx
  name: "main_tv"
  turn_on_action:
    service: script.tv_turn_on

On previous version 0.103 everything worked like a charm via media_player, platform: webostv.
I have WebOS 2.0 LG TV and was able to control it via HA.
After update to 0.104.2 it shows errors:

Error during setup of component webostv
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/setup.py", line 170, in _async_setup_component
    hass, processed_config
  File "/usr/src/homeassistant/homeassistant/components/webostv/__init__.py", line 93, in async_setup
    await asyncio.gather(*tasks)
  File "/usr/src/homeassistant/homeassistant/components/webostv/__init__.py", line 109, in async_setup_tv
    await async_setup_tv_finalize(hass, config, conf, client)
  File "/usr/src/homeassistant/homeassistant/components/webostv/__init__.py", line 141, in async_setup_tv_finalize
    await async_connect(client)
  File "/usr/src/homeassistant/homeassistant/components/webostv/__init__.py", line 118, in async_connect
    await client.connect()
  File "/usr/local/lib/python3.7/site-packages/aiopylgtv/webos_client.py", line 126, in connect
    return await self.connect_result
  File "/usr/local/lib/python3.7/site-packages/aiopylgtv/webos_client.py", line 156, in connect_handler
    close_timeout=self.timeout_connect),
  File "/usr/local/lib/python3.7/site-packages/websockets/client.py", line 385, in __init__
    factory, host, port, **kwds)
TypeError: create_connection() got an unexpected keyword argument 'ping_interval'
Connection lost. Reconnecting…

Restarts of HA and any other changes to config has no affect.
I do not use it in any automation.

The same happened for me. Works now, just requested to repair.

Did someone got sources to show in Homekit?

Hello!
Yes - this is what works for me:

webostv:
  - host: 192.168.x.xxx
    name: TV
    turn_on_action:
      service: wake_on_lan.send_magic_packet
      data:
        mac: "xx:xx:xx:xx:xx:xx"
    customize:
      sources:
        - livetv
        - youtube
        - hdmi1
        - 'Amazon Prime Video'
        - 'Sky X'

That’s what I have, but the sources in Homekit are still missing.