apatsufas / homebridge-tapo-p100

Homebridge TP-LINK Tapo P100 Platform Plugin
Apache License 2.0
64 stars 14 forks source link

P100 stopped working all of a sudden with HomeKit #12

Closed ChopsKingsland closed 2 years ago

ChopsKingsland commented 2 years ago

Describe The Bug:

All of a sudden, my Tapo P100 has stopped working all of a sudden without me changing anything. I can still control it using the Tapo app, however. (also, using the 'accessories' tab in the Homebridge UI doesn't work either.) I have removed the accessory/plugin from Homebridge and re-added it, and it didn't help...

To Reproduce:

not sure

Expected behavior:

Turn the plug on and off (doesn't happen)

Logs:

Nothing showing in logs

Plugin Config:

{
            "name": "Tapo Smart Platform",
            "username": "****",
            "password": "****",
            "devices": [
                {
                    "name": "Fan",
                    "host": "192.168.1.122",
                    "type": "Plug"
                }
            ],
            "platform": "TapoP100"
        }

Environment:

ChopsKingsland commented 2 years ago

@apatsufas Any ideas on how to fix this?

ChopsKingsland commented 2 years ago

I have also noticed that there are no logs whatsoever for this plugin, so I have no idea what was happened

ChopsKingsland commented 2 years ago

Ok, i sorted it... Somehow removing "type": "plug" fixed it... very odd

apatsufas commented 2 years ago

Hello @ChopsKingsland. The issue you are describing seems weird. Indeed if no type is defined the plug-in defaults to the plug type. It also seems weird you are not seeing any logs. My best guess is that something went wrong with the cached state of the accessory in homebridge went wrong.

James-Bovis commented 2 years ago

Just to add some extra context to anyone like me running into 111 Error: connect like Errors.

@ChopsKingsland 's comment of removing the type: "plug" item in the config.json file fixed the issue for me too. Even after removing/installing homebridge-tapo and Updating Homebridge itself etc.

Not sure why this change suddenly made it start working again 🤷🏻 but give it a go if you're running into similar errors.

@apatsufas Here's the previous erroneous logs from my Homebridge UI FYI:

[15/11/2021, 17:07:12] [Tapo Smart Platform] 111 Error: connect EHOSTUNREACH 192.XXX.X.XX:XX
[15/11/2021, 17:07:12] [Tapo Smart Platform] Get Device Info failed

Other information: Plugin Version: homebridge-tapo v1.4.9 Homebridge Version: v.1.3.6 P100 Firmware Version: 1.4.9 P100 Hardware Version: 1.20.0

apatsufas commented 2 years ago

@James-Bovis thank you for your feedback. I have one question that might help me identify the issue. Are you setting the configuration manually in the config file or are using the plugin settings UI in Homebridge UI?

James-Bovis commented 2 years ago

@apatsufas I set the plug-in up originally in the Homebridge UI first where I selected the “Plug” option as the device type in the drop down menu.

To remove the device type option, I edited the JSON directly in the Homebridge UI editor.

Hopefully that answers your question :)