Handle 3.4 protocol, fix CI (#1251)
* Use refresh interval in version 3.4 * Scan interval convert to integer * Try to fix CI * Try to fix CI
This commit is contained in:
@@ -817,7 +817,7 @@ class TuyaProtocol(asyncio.Protocol, ContextualLogger):
|
|||||||
Args:
|
Args:
|
||||||
dps([int]): list of dps to update, default=detected&whitelisted
|
dps([int]): list of dps to update, default=detected&whitelisted
|
||||||
"""
|
"""
|
||||||
if self.version in [3.2, 3.3]: # 3.2 behaves like 3.3 with type_0d
|
if self.version in [3.2, 3.3, 3.4]: # 3.2 behaves like 3.3 with type_0d
|
||||||
if dps is None:
|
if dps is None:
|
||||||
if not self.dps_cache:
|
if not self.dps_cache:
|
||||||
await self.detect_available_dps()
|
await self.detect_available_dps()
|
||||||
|
@@ -23,7 +23,7 @@
|
|||||||
},
|
},
|
||||||
"power_outlet": {
|
"power_outlet": {
|
||||||
"title": "Add subswitch",
|
"title": "Add subswitch",
|
||||||
"description": "You are about to add subswitch number `{number}`. If you want to add another, tick `Add another switch` before continuing.",
|
"description": "You are about to add subswitch number `{number}`. If you want to add another, tick `Add another switch` before continuing.",
|
||||||
"data": {
|
"data": {
|
||||||
"id": "ID",
|
"id": "ID",
|
||||||
"name": "Name",
|
"name": "Name",
|
||||||
@@ -101,10 +101,10 @@
|
|||||||
"fan_speed_min": "minimum fan speed integer",
|
"fan_speed_min": "minimum fan speed integer",
|
||||||
"fan_speed_max": "maximum fan speed integer",
|
"fan_speed_max": "maximum fan speed integer",
|
||||||
"fan_speed_ordered_list": "Fan speed modes list (overrides speed min/max)",
|
"fan_speed_ordered_list": "Fan speed modes list (overrides speed min/max)",
|
||||||
"fan_direction":"fan direction dps",
|
"fan_direction": "fan direction dps",
|
||||||
"fan_direction_forward": "forward dps string",
|
"fan_direction_forward": "forward dps string",
|
||||||
"fan_direction_reverse": "reverse dps string",
|
"fan_direction_reverse": "reverse dps string",
|
||||||
"fan_dps_type": "DP value type",
|
"fan_dps_type": "DP value type",
|
||||||
"current_temperature_dp": "Current Temperature",
|
"current_temperature_dp": "Current Temperature",
|
||||||
"target_temperature_dp": "Target Temperature",
|
"target_temperature_dp": "Target Temperature",
|
||||||
"temperature_step": "Temperature Step (optional)",
|
"temperature_step": "Temperature Step (optional)",
|
||||||
@@ -136,4 +136,4 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"title": "LocalTuya"
|
"title": "LocalTuya"
|
||||||
}
|
}
|
@@ -167,7 +167,7 @@
|
|||||||
"fan_speed_min": "minimum fan speed integer",
|
"fan_speed_min": "minimum fan speed integer",
|
||||||
"fan_speed_max": "maximum fan speed integer",
|
"fan_speed_max": "maximum fan speed integer",
|
||||||
"fan_speed_ordered_list": "Fan speed modes list (overrides speed min/max)",
|
"fan_speed_ordered_list": "Fan speed modes list (overrides speed min/max)",
|
||||||
"fan_direction":"fan direction dps",
|
"fan_direction": "fan direction dps",
|
||||||
"fan_direction_forward": "forward dps string",
|
"fan_direction_forward": "forward dps string",
|
||||||
"fan_direction_reverse": "reverse dps string",
|
"fan_direction_reverse": "reverse dps string",
|
||||||
"fan_dps_type": "DP value type",
|
"fan_dps_type": "DP value type",
|
||||||
@@ -198,5 +198,29 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"services": {
|
||||||
|
"reload": {
|
||||||
|
"name": "Reload",
|
||||||
|
"description": "Reload localtuya and reconnect to all devices."
|
||||||
|
},
|
||||||
|
"set_dp": {
|
||||||
|
"name": "Set datapoint",
|
||||||
|
"description": "Change the value of a datapoint (DP)",
|
||||||
|
"fields": {
|
||||||
|
"device_id": {
|
||||||
|
"name": "Device ID",
|
||||||
|
"description": "Device ID of device to change datapoint value for"
|
||||||
|
},
|
||||||
|
"dp": {
|
||||||
|
"name": "DP",
|
||||||
|
"description": "Datapoint index"
|
||||||
|
},
|
||||||
|
"value": {
|
||||||
|
"name": "Value",
|
||||||
|
"description": "New value to set"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
"title": "LocalTuya"
|
"title": "LocalTuya"
|
||||||
}
|
}
|
@@ -188,5 +188,29 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"services": {
|
||||||
|
"reload": {
|
||||||
|
"name": "Reload",
|
||||||
|
"description": "Reload localtuya and reconnect to all devices."
|
||||||
|
},
|
||||||
|
"set_dp": {
|
||||||
|
"name": "Set datapoint",
|
||||||
|
"description": "Change the value of a datapoint (DP)",
|
||||||
|
"fields": {
|
||||||
|
"device_id": {
|
||||||
|
"name": "Device ID",
|
||||||
|
"description": "Device ID of device to change datapoint value for"
|
||||||
|
},
|
||||||
|
"dp": {
|
||||||
|
"name": "DP",
|
||||||
|
"description": "Datapoint index"
|
||||||
|
},
|
||||||
|
"value": {
|
||||||
|
"name": "Value",
|
||||||
|
"description": "New value to set"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
"title": "LocalTuya"
|
"title": "LocalTuya"
|
||||||
}
|
}
|
||||||
|
@@ -188,5 +188,29 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"services": {
|
||||||
|
"reload": {
|
||||||
|
"name": "Reload",
|
||||||
|
"description": "Reload localtuya and reconnect to all devices."
|
||||||
|
},
|
||||||
|
"set_dp": {
|
||||||
|
"name": "Set datapoint",
|
||||||
|
"description": "Change the value of a datapoint (DP)",
|
||||||
|
"fields": {
|
||||||
|
"device_id": {
|
||||||
|
"name": "Device ID",
|
||||||
|
"description": "Device ID of device to change datapoint value for"
|
||||||
|
},
|
||||||
|
"dp": {
|
||||||
|
"name": "DP",
|
||||||
|
"description": "Datapoint index"
|
||||||
|
},
|
||||||
|
"value": {
|
||||||
|
"name": "Value",
|
||||||
|
"description": "New value to set"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
"title": "LocalTuya"
|
"title": "LocalTuya"
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user