merdok / homebridge-webos-tv

Homebridge plugin for LG webOS TVs
MIT License
663 stars 89 forks source link

Upgrade from 1.9.3 to 2.0.5 - Cannot add TV to HomeKit #309

Closed W0GER closed 4 years ago

W0GER commented 4 years ago

I upgraded the homebridge-webos-tv from v1.9.3 to 2.0.5; after which I am unable to add the TV to the Home app.

Homebridge: v1.1.6

Config:

        {
            "platform": "webostv",
            "devices": [
                {
                    "name": "Great Room TV",
                    "ip": "192.168.1.82",
                    "mac": "78:5D:C8:C4:50:97",
                    "keyFile": "/var/lib/homebridge/LGTV.webostv.keyfile",
                    "notificationButtons": [
                        "Doorbell - Ding Dong"
                    ]
                }
            ]
        }

The homebridge log shows:

Oct 06 11:11:26 raspberrypi homebridge[10649]: [10/6/2020, 11:11:26 AM] [webostv] Init - initializing devices
Oct 06 11:11:26 raspberrypi homebridge[10649]: [10/6/2020, 11:11:26 AM] [webostv] [Great Room TV] Init - got TV configuration, initializing device with name: Great Room TV
Oct 06 11:11:26 raspberrypi homebridge[10649]: [10/6/2020, 11:11:26 AM] Great Room TV is running on port 38977.
Oct 06 11:11:26 raspberrypi homebridge[10649]: [10/6/2020, 11:11:26 AM] Please add [Great Room TV] manually in Home app. Setup Code: 377-67-524
Oct 06 11:11:27 raspberrypi homebridge[10649]: [10/6/2020, 11:11:27 AM] [webostv] [Great Room TV] Connected to TV
Oct 06 11:11:27 raspberrypi homebridge[10649]: [10/6/2020, 11:11:27 AM] [webostv] [Great Room TV] Got TV information
Oct 06 11:11:27 raspberrypi homebridge[10649]: [10/6/2020, 11:11:27 AM] [webostv] [Great Room TV] TV webOS version: 4.0
Oct 06 11:11:27 raspberrypi homebridge[10649]: [10/6/2020, 11:11:27 AM] [webostv] [Great Room TV] TV turned on!
Oct 06 11:11:27 raspberrypi homebridge[10649]: [10/6/2020, 11:11:27 AM] [webostv] [Great Room TV] App launched, current appId: com.webos.app.hdmi3
Oct 06 11:11:27 raspberrypi homebridge[10649]: [10/6/2020, 11:11:27 AM] [webostv] [Great Room TV] Sound output changed. Current sound output: external_arc
Oct 06 11:11:27 raspberrypi homebridge[10649]: [10/6/2020, 11:11:27 AM] [webostv] [Great Room TV] Subscribed to TV services
Oct 06 11:11:27 raspberrypi homebridge[10649]: [10/6/2020, 11:11:27 AM] [webostv] [Great Room TV] Connected to remote pointer input socket
Oct 06 11:11:27 raspberrypi homebridge[10649]: [10/6/2020, 11:11:27 AM] [webostv] [Great Room TV] Setup finished
Oct 06 11:11:27 raspberrypi homebridge[10649]: [10/6/2020, 11:11:27 AM] [webostv] [Great Room TV] TV setup finished, ready to control tv

After restarting HomeKit - I noticed that the TV showed up as a Light Bulb in the "Great Room". I choose to ungroup the accessories, this created several buttons in the room related to the TV; at this point there was a TV accessory. I removed the TV from HomeKit thinking there might be left over registration stuff causing all the other buttons to appear. After removing the TV from HomeKit, I restarted homebridge successfully, I attempted to re-add the TV to HomeKit, however, HomeKit does not find the TV.

I've tried several things, including:

The TV does not appear in any other room.

From my iPhone running iOS 14.0.1, in the Home App, I am attempting the following:

  1. From the Great Room room, clicking the "+" icon and choosing Add Accessory +
  2. On the Add Accessory panel, touch the I Don't Have a Code or Cannot Scan button
  3. On the Select an Accessory to Add to panel, the spinner appears, but no accessories appear. Touch the My Accessory Isn't Shown Here
  4. On the Accessory Not Shown panel, touch the Enter code... link
  5. On the Enter HomeKit Setup Code panel, enter the 8-digit code from homebridge and touch Continue button
  6. Back on the Select an Accessory to Add to panel, the spinner appears, but no accessories appear.
merdok commented 4 years ago

This sounds like a cache issue for me. Try to remove your homebridge cache, also it might be that something is wrong with your home in HomeKit and usually creating a new home fixes the issue. From the log it seems that the plugin works as it should, so try to first clear the homebridge cache.

W0GER commented 4 years ago

@merdok Thank you for the suggestion. I cleared the associated AccessoryInfo and IdentifierCache files; after which I was able to re-add the TV to my homebridge and Home app.