Bladeren bron

Default device address to Auto.

A new, undocumented feature of tinytuya is that if you give "Auto" or
None as the IP address, it will automatically search for the device
(and protocol version, but we probably override that with our own auto
detection).

Entering "Auto" seems to work without any code changes, so default to
that as a quick way to leverage this feature.
Jason Rumney 3 jaren geleden
bovenliggende
commit
d4fbb5d59e
1 gewijzigde bestanden met toevoegingen van 1 en 1 verwijderingen
  1. 1 1
      custom_components/tuya_local/config_flow.py

+ 1 - 1
custom_components/tuya_local/config_flow.py

@@ -29,7 +29,7 @@ class ConfigFlowHandler(config_entries.ConfigFlow, domain=DOMAIN):
     async def async_step_user(self, user_input=None):
     async def async_step_user(self, user_input=None):
         errors = {}
         errors = {}
         devid_opts = {}
         devid_opts = {}
-        host_opts = {}
+        host_opts = {"default": "Auto"}
         key_opts = {}
         key_opts = {}
         proto_opts = {"default": "auto"}
         proto_opts = {"default": "auto"}
         polling_opts = {"default": False}
         polling_opts = {"default": False}