vmakeev / hass_tplink_easy_smart

Home Assistant custom component for control TP-Link Easy Smart switches over LAN.
MIT License
31 stars 9 forks source link

This integration disables web access to the switch #7

Closed emilianogetino closed 1 year ago

emilianogetino commented 1 year ago

When this integration is installed when accessing the switch via the web, with the browser, it is authenticated, but clicking on any option leaves it out. This happens to me with two TL-SG1016PE. It is necessary to disable the integration in homeasisstant to have access to the configuration via web.

All the best.

vmakeev commented 1 year ago

Hello! Unfortunately, yes, by design. Authorization in the web interface is implemented by Tp-Link in a very specific way, and several users cannot work with it at the same time.

I use a workaround to configure the switch: Easy Smart Configuration Utility, which is available for free download on the Tp-Link website.

It uses a broadcast with simple static key encryption to communicate with the device, and, unlike the web interface, it gets along well with my integration.

Of course, configuring via the Web UI is more familiar, and in some cases more convenient, but so far I have not been able to achieve simultaneous integration in HA and web interface

emilianogetino commented 1 year ago

Thanks, that's how I'm doing it, I access them through the tplink utility and if I need web access I disable your integration in homeasisstant.

Regards, good job.

vmakeev commented 1 year ago

I'm afraid that I initially chose the wrong way to develop the component. Maybe I should have tried using the protocol that the Easy Smart Configuration Utility uses. Instead, I focused on trying to use GET/POST requests and then parsing the resulting html pages.

Perhaps I will try to add support for the broadcast protocol used in EasySmart to the component, but it is difficult for me to predict when this will be implemented

emilianogetino commented 1 year ago

I will be attentive to the improvements, I hope soon, if you need something ask me. Thanks for sharing your work.