make-all / tuya-local

Local support for Tuya devices in Home Assistant
MIT License
1.07k stars 432 forks source link

Request support for Smart Curtain Motor WiFi #1781

Closed Dexter-Lucky closed 1 month ago

Dexter-Lucky commented 3 months ago

Log Message

2024-03-28 15:31:45.585 WARNING (MainThread) [custom_components.tuya_local.config_flow] Device matches feit_dimmer with quality of 100%. DPS: {"updated_at": 1711629102.9648023, "2": 100, "3": 0}

Information about DPS mappings

"result": {
    "properties": [
      {
        "code": "control",
        "custom_name": "",
        "dp_id": 1,
        "time": 1670098914961,
        "value": "open",
        "range": [
          "open",
          "stop",
          "close",
          "continue"
        ]
      },
      {
        "code": "percent_control",
        "custom_name": "",
        "dp_id": 2,
        "time": 1711382147562,
        "value": 100,
        "unit": "%",
        "min": 0,
        "max": 100
      },
      {
        "code": "percent_state",
        "custom_name": "",
        "dp_id": 3,
        "time": 1711600214718,
        "value": 0
      },
      {
        "code": "control_back",
        "custom_name": "",
        "dp_id": 5,
        "time": 1678577188718,
        "value": "forward",
        "range": [
          "forward",
          "back"
        ]
      },
      {
        "code": "fault",
        "custom_name": "",
        "dp_id": 12,
        "time": 1670098914961,
        "value": 0,
        "label": [
           "motor_fault"
        ]
      }
    ]
  },
  "success": true,
  "t": 1711630203283,
  "tid": "b20078ceed0111ee825bba8975aefeef"

Product ID

wraaecjqfiirj8go

Information about how the device functions

https://icombo.en.made-in-china.com/product/NOgnkeWlruho/China-Tuya-WiFi-Intelligent-Smart-Curtain-Motor.html

make-all commented 3 months ago

The log message is missing, seems to be replaced by a filename. Also the dps information is insufficient, it is missing the list of possible values or range for each dp.

Dexter-Lucky commented 3 months ago

I don't know why, but link in topic doesn't work. I'll leave it here. Log Message: home-assistant_tuya_local_2024-03-28T12-31-52.201Z.log

dps: CodeTypeValues Curtain Motor.txt

Dexter-Lucky commented 2 months ago

It's got same problem: 2024-04-12 19:13:53.345 DEBUG (MainThread) [custom_components.tuya_local.helpers.device_config] Loaded device config yueqingcombo_yet848pc_curtain.yaml 2024-04-12 19:13:53.345 DEBUG (MainThread) [custom_components.tuya_local.helpers.device_config] Not match for Curtain, missing required DPs: [{'2': 'int'}] I've add to code "optional: true" and its adds to HA, but it don't work, when curtains fully open or fully close. When its open button "close" is deactiv. I can use only button "open", but curtains already opened.

Dexter-Lucky commented 2 months ago

It's has the same problem as Zemismart ZM25TQ (id jzmy5ut0vishwscm) (discussion #1823). I made the same change (add "invert" config for the position dps). Now it works correct. ` - id: 2 name: position type: integer range: min: 0 max: 100 mapping: