0x5e / homebridge-tuya-platform

Make homebridge-tuya-platform great again.
MIT License
206 stars 58 forks source link

Use overrides for ValveAccessory #376

Closed monkeycatdog closed 9 months ago

monkeycatdog commented 9 months ago

Hey everyone, happy to use this plugin. There are some issues with ValveAccessory, figured out the reason.

monkeycatdog commented 9 months ago

Related to https://github.com/0x5e/homebridge-tuya-platform/issues/235

0x5e commented 9 months ago

@monkeycatdog thanks, I'm busy at school these days, I will check it later.

0x5e commented 9 months ago

For Valve Accessory currently I only display the boolean schema with "switch" prefix to hide some unused schemas. What schema do you want to show up? @monkeycatdog

monkeycatdog commented 9 months ago

Previously, it was ignoring overrides. My valve with non-standard schema was not supported. For now, valve can be overridden as well. @0x5e

0x5e commented 9 months ago

thanks @monkeycatdog , beta.50 updated.

twei7 commented 8 months ago

Hi, commit bf6f551 seems to cause a regression. I have a device that has 4 switches (category set as ggq). Before the change, they can show up as a group with 5 buttons correctly. But with this change, only the first switch (switch_1) is shown. I revert the change in my home bridge and all switch buttons come back.

"category": "kg",
    "functions": [
      {
        "code": "switch_1",
        "type": "Boolean",
        "values": "{}"
      },
      {
        "code": "switch_2",
        "type": "Boolean",
        "values": "{}"
      },
      {
        "code": "switch_3",
        "type": "Boolean",
        "values": "{}"
      },
      {
        "code": "switch_4",
        "type": "Boolean",
        "values": "{}"
      },
      {
        "code": "countdown_1",
        "type": "Integer",
        "values": "{\"unit\":\"s\",\"min\":0,\"max\":86400,\"scale\":0,\"step\":1}"
      },
      {
        "code": "countdown_2",
        "type": "Integer",
        "values": "{\"unit\":\"s\",\"min\":0,\"max\":86400,\"scale\":0,\"step\":1}"
      },
      {
        "code": "countdown_3",
        "type": "Integer",
        "values": "{\"unit\":\"s\",\"min\":0,\"max\":86400,\"scale\":0,\"step\":1}"
      },
      {
        "code": "countdown_4",
        "type": "Integer",
        "values": "{\"unit\":\"s\",\"min\":0,\"max\":86400,\"scale\":0,\"step\":1}"
      },
      {
        "code": "switch_all",
        "type": "Boolean",
        "values": "{}"
      },
      {
        "code": "power_status",
        "type": "Boolean",
        "values": "{}"
      },
      {
        "code": "dev_mode",
        "type": "Enum",
        "values": "{\"range\":[\"selflock\",\"inching\",\"interlock\"]}"
      },
      {
        "code": "jg_time",
        "type": "Integer",
        "values": "{\"unit\":\"S\",\"min\":5,\"max\":600,\"scale\":1,\"step\":5}"
      }
    ],