From 0290b11dae95724ecb9eb5b82f758b7bfe975f80 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre=20St=C3=A5hl?= Date: Tue, 15 Sep 2020 19:24:58 +0200 Subject: [PATCH] Request DPS 1-150 in config flow --- custom_components/localtuya/config_flow.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/custom_components/localtuya/config_flow.py b/custom_components/localtuya/config_flow.py index 6de33ec..12f32bc 100644 --- a/custom_components/localtuya/config_flow.py +++ b/custom_components/localtuya/config_flow.py @@ -78,7 +78,7 @@ async def validate_input(hass: core.HomeAssistant, data): data[CONF_LOCAL_KEY], ) pytuyadevice.set_version(float(data[CONF_PROTOCOL_VERSION])) - pytuyadevice.set_dpsUsed({}) + pytuyadevice.set_dpsUsed({str(dps): None for dps in range(1, 151)}) try: data = await hass.async_add_executor_job(pytuyadevice.status) except (ConnectionRefusedError, ConnectionResetError):