talrhv / tuya-homebridge

Homebridge custom plugin for controlling Powered by Tuya (PBT) devices in HomeKit. This plugin is officially maintained by the Tuya Developer Team.
MIT License
4 stars 7 forks source link

White control not supported by Homekit plugin #6

Open shashchatter opened 1 year ago

shashchatter commented 1 year ago

Describe the bug Not sure if this is a bug, or a feature request. These lights (Novostella Bloom 100W) have a pure white mode set by simply switching to the white tab in SmartLife (screenshot 1). There's no way to get pure white from the Home app -would be nice to be able to do this. The other way to approximate white is to set the saturation to zero on the color tab in SmartLife (screenshot 2). In this case, using temp tab in Home app results in a quite orange or quite blue color (screenshots 3 and 4). Using the Color tab in Home App, some colored hue of white can be had using the middle section of the color picker, but it is far from white.

Also, if SmartLife app is set to White mode, then selecting color tab to set colors has seemingly random colors at first. I have yet to characterize the full behavior.

Expected behavior Support of pure white color from Home app.

Screenshots IMG_3589

IMG_3590

IMG_3588

IMG_3587

IMG_3585

Device info (please complete the following information, which can be found in log): request path = /v1.0/iot-01/associated-users/devices

  {
    "active_time": 1668989117,
    "biz_type": 18,
    "category": "dj",
    "create_time": 1633816845,
    "icon": "smart/icon/ay1530625888062OnLeq/abec6ccb0b8b7ab5eeb3cb082fe6282e.png",
    "id": "10517386483fdac0e46c",
    "ip": "47.187.120.169",
    "lat": "32.9728",
    "local_key": "0ace472b3e776ce0",
    "lon": "-96.9612",
    "model": "YL.DY.0639",
    "name": "Backyard Main",
    "online": true,
    "owner_id": "33474261",
    "product_id": "oxd7vmtrlrp41izs",
    "product_name": "RGBC WIFI Smart light-DIP",
    "status": [
      {
        "code": "switch_led",
        "value": false
      },
      {
        "code": "work_mode",
        "value": "colour"
      },
      {
        "code": "bright_value_v2",
        "value": 1000
      },
      {
        "code": "colour_data_v2",
        "value": "{\"h\":222,\"s\":200,\"v\":1000}"
      },
      {
        "code": "scene_data_v2",
        "value": "{\"scene_num\":1,\"scene_units\":[{\"bright\":200,\"h\":0,\"s\":0,\"temperature\":1000,\"unit_change_mode\":\"static\",\"unit_gradient_duration\":13,\"unit_switch_duration\":14,\"v\":0}]}"
      },
      {
        "code": "countdown_1",
        "value": 0
      },
      {
        "code": "control_data",
        "value": ""
      }
    ],
    "sub": false,
    "time_zone": "-06:00",
    "uid": "az1611357486861HktlX",
    "update_time": 1668989120,
    "uuid": "10517386483fdac0e46c"
  }

Device functions (please complete the following information, which can be found in log): request path = /v1.0/devices/functions { "category": "dj", "devices": [ "10517386483fdac0e46c" ], "functions": [ { "code": "switch_led", "desc": "switch led", "name": "switch led", "type": "Boolean", "values": "{}" }, { "code": "work_mode", "desc": "work mode", "name": "work mode", "type": "Enum", "values": "{\"range\":[\"white\",\"colour\",\"scene\",\"music\"]}" }, { "code": "bright_value_v2", "desc": "bright value v2", "name": "bright value v2", "type": "Integer", "values": "{\"min\":10,\"max\":1000,\"scale\":0,\"step\":1}" }, { "code": "colour_data_v2", "desc": "colour data v2", "name": "colour data v2", "type": "Json", "values": "{\"h\":{\"min\":0,\"scale\":0,\"unit\":\"\",\"max\":360,\"step\":1},\"s\":{\"min\":0,\"scale\":0,\"unit\":\"\",\"max\":1000,\"step\":1},\"v\":{\"min\":0,\"scale\":0,\"unit\":\"\",\"max\":1000,\"step\":1}}" }, { "code": "scene_data_v2", "desc": "scene data v2", "name": "scene data v2", "type": "Json", "values": "{\"scene_num\":{\"min\":1,\"scale\":0,\"max\":8,\"step\":1},\"scene_units\": {\"unit_change_mode\":{\"range\":[\"static\",\"jump\",\"gradient\"]},\"unit_switch_duration\":{\"min\":0,\"scale\":0,\"max\":100,\"step\":1},\"unit_gradient_duration\":{\"min\":0,\"scale\":0,\"max\":100,\"step\":1},\"bright\":{\"min\":0,\"scale\":0,\"max\":1000,\"step\":1},\"temperature\":{\"min\":0,\"scale\":0,\"max\":1000,\"step\":1},\"h\":{\"min\":0,\"scale\":0,\"unit\":\"\",\"max\":360,\"step\":1},\"s\":{\"min\":0,\"scale\":0,\"unit\":\"\",\"max\":1000,\"step\":1},\"v\":{\"min\":0,\"scale\":0,\"unit\":\"\",\"max\":1000,\"step\":1}}}" }, { "code": "countdown_1", "desc": "countdown 1", "name": "countdown 1", "type": "Integer", "values": "{\"min\":0,\"max\":86400,\"scale\":0,\"step\":1}" }, { "code": "control_data", "desc": "control data", "name": "control data", "type": "Json", "values": "{\"change_mode\":{\"range\":[\"direct\",\"gradient\"]}, \"bright\":{\"min\":0,\"scale\":0,\"unit\":\"\",\"max\":1000,\"step\":1}, \"temperature\":{\"min\":0,\"scale\":0,\"unit\":\"\",\"max\":1000,\"step\":1}, \"h\":{\"min\":0,\"scale\":0,\"unit\":\"\",\"max\":360,\"step\":1},\"s\":{\"min\":0,\"scale\":0,\"unit\":\"\",\"max\":255,\"step\":1},\"v\":{\"min\":0,\"scale\":0,\"unit\":\"\",\"max\":255,\"step\":1}}" } ], "product_id": "oxd7vmtrlrp41izs" }

Additional context