iRayanKhan / homebridge-tuya

A Homebridge plugin to control Tuya devices locally.
MIT License
402 stars 166 forks source link

New Device: Ceiling Fan with TW Light #488

Open megusd opened 3 weeks ago

megusd commented 3 weeks ago

Describe your device Ceiling Fan with possibility to adjust light color temperature Model: GRID Connect DCF4002WHA, available in Australian Bunning Warehouse

Partial Support? Existing template is working but missing color temperature and fan direction switching. Was able to set up the device in Home Assistant with custom integration "Local Tuya", had to reverse light color temperature (there is in option in HA plugin) Pls add adaptiveLightingSupport same as in TWLightAccessory.js

Device Schema


      "category": "fsd",
      "name": "GRID Ceiling Fan",
      "product_id": "1wadkk3gy2dgjuis",
      "product_name": "Ceiling Fan DCF4002WHA"
      {
        "code": "switch",
        "dp_id": 1,
        "type": "bool",
        "values": "{}"        
      },      
      {
        "code": "fan_speed",
        "dp_id": 3,
        "type": "enum",
        "values": "{\"range\":[\"1\",\"2\",\"3\",\"4\",\"5\",\"6\"]}"
      },
      {
        "code": "fan_direction",
        "dp_id": 4,
        "type": "Enum",
        "values": "{\"range\":[\"forward\",\"reverse\"]}"
      },
      {
        "code": "light",
        "dp_id": 9,
        "type": "bool",
        "values": "{}"        
      },      
      {
        "code": "bright_value",
        "dp_id": 10,
        "type": "value",
        "values": "{\"unit\":\"\",\"min\":0,\"max\":100,\"scale\":0,\"step\":2}",
      },
      {
        "code": "temp_value",
        "dp_id": 11,
        "type": "value",
        "values": "{\"unit\":\"\",\"min\":0,\"max\":100,\"scale\":0,\"step\":2}"
      },
      {
        "code": "run_mode",
        "dp_id": 102,
        "type": "enum",
        "values": "{\"range\":[\"nature\",\"sleep\"]}"
      },
      {
        "code": "timer_stop",
        "dp_id": 103,
        "type": "enum",
        "values": "{\"range\":[\"cancel\",\"1h\",\"2h\",\"4h\",\"8h\"]}"
      }