Tuya liquid level sensor TZE200_lvkk0hdg

Hello!

I plan to purchase a Tuya liquid level sensor TZE200_lvkk0hdg, but I’m not sure if it is supported.

According to this thread, there are some problems, but I don’t know if this means that it won’t work with deCONZ, specifically with my ConBee III stick:

More is there:

Thanks for sharing your thoughts! :+1:

Nope, there is nothing in Deconz tu support this device.
And we need lot of new field, like percent, height, depth, and ect, so will be problem for integration.

1 Like

Please excuse my question (as I’m just a user with little experience about development): Could I contribute to make it work by buying the device and providing any kind of helpful debug info etc.?

If this is a dead end, should I rather follow the guidance from the Home Assistant forum, introducing a “quirk” and using ZHA?

Alternatively, there is the same device with WiFi instead of ZigBee.

This device is used a lot, I can see lot of issue with it, and lot of informations, but if you want a basic support not so hard
for exemple

{
  "schema": "devcap1.schema.json",
  "manufacturername": "_TZE200_lvkk0hdg",
  "modelid": "TS0601",
  "vendor": "Tuya",
  "product": "Tuya liquid level sensor",
  "sleeper": true,
  "status": "Gold",
  "subdevices": [
    {
      "type": "$TYPE_WATER_LEAK_SENSOR",
      "restapi": "/sensors",
      "uuid": [
        "$address.ext",
        "0x01",
        "0xEF00"
      ],
      "items": [
        {
          "name": "attr/lastannounced"
        },
        {
          "name": "attr/lastseen"
        },
        {
          "name": "attr/manufacturername"
        },
        {
          "name": "attr/modelid"
        },
        {
          "name": "attr/name"
        },
        {
          "name": "attr/type"
        },
        {
          "name": "attr/uniqueid"
        },
        {
         "name": "config/tuya_unlock"
        },
        {
          "name": "attr/swversion",
          "parse": {
            "fn": "zcl:attr",
            "ep": 1,
            "cl": "0x0000",
            "at": "0x0001",
            "script": "tuya_swversion.js"
          },
          "read": {
            "fn": "zcl:attr",
            "ep": 1,
            "cl": "0x0000",
            "at": "0x0001"
          }
        },
        {
          "name": "cap/measured_value/max",
          "parse": {
            "fn": "tuya",
            "dpid": 7,
            "eval": "Item.val = Attr.val;"
          },
          "write": {
            "fn": "tuya",
            "dpid": 7,
            "dt": "0x2b",
            "eval": "Item.val;"
          },
          "read": {
            "fn": "none"
          }
        },
        {
          "name": "cap/measured_value/min",
          "parse": {
            "fn": "tuya",
            "dpid": 8,
            "eval": "Item.val = Attr.val;"
          },
          "write": {
            "fn": "tuya",
            "dpid": 8,
            "dt": "0x2b",
            "eval": "Item.val;"
          },
          "read": {
            "fn": "none"
          }
        },
        {
          "name": "cap/measured_value/quantity",
          "static": "level"
        },
        {
          "name": "cap/measured_value/substance",
          "static": "percent"
        },
        {
          "name": "cap/measured_value/unit",
          "static": "%"
        },
        {
          "name": "config/on"
        },
        {
          "name": "config/reachable"
        },
        {
          "name": "state/measured_value",
          "read": {
            "fn": "none"
          },
          "parse": {
            "dpid": 22,
            "eval": "Item.val = Attr.val;",
            "fn": "tuya"
          },
          "default": 0
        },
        {
          "name": "state/lastupdated"
        }
      ]
    }
  ]
}

This DDF can support min/max set and return a % level.
But This DDf is random I have used min/max, but I think it will be better to use installation_height (19) and liquid_depth_max(21) to set min/max.

And I m using a ZHAWater, so can be a problem in HA, better to use for exemple a ZHAGauge.

1 Like

I’ve ordered it and wait for its delivery. When it has arrived, I’ll revisit this thread and might have more questions and hopefully also something to give back to you and the community. :blush:

Sure, I can use bad dpid on the previous DDF (I realy have no clue how this device is working), but the logic is here.
Unfortunately as it use Tuya cluster, not possible to use the GUI to set value, we will need to use the debug log.
For memory dpid from Z2M (I m using 22/7/8 on the DDF)

      [1, 'liquid_state', tuya.valueConverterBasic.lookup({'low': 1, 'normal': 0, 'high': 2})],
      [2, 'liquid_depth', tuya.valueConverter.divideBy100],
      [22, 'liquid_level_percent', tuya.valueConverter.raw],
      [7, 'max_set', tuya.valueConverter.raw],
      [8, 'mini_set', tuya.valueConverter.raw],
      [19, 'installation_height', tuya.valueConverter.raw],
      [21, 'liquid_depth_max', tuya.valueConverter.raw],