IKEA Vallhorn: Set off-delay and dark-only mode with zha-toolkit

I figured out, that what the 2 buttons at the back allow configuring, also can be set by writing to zigbee attributes.

  • cluster: 0xfc81 (manufacturer specific)
  • manufacturer: 4476
  • attributes: 0x0000 == mode, 0x0002 == off delay

Buttons only allow 1 (60s) or 5 (300s) minutes for off delay. It seems its possible to set any integer with writing directly. Don’t know if other values than 60 or 300 actually correctly work.

There is another attribute 0x0004 which I haven’t figured out that it does. Default value is 60. Could be the illuminance reporting frequency, which seem to happen every 60 seconds.

zha-toolkit action examples:

# Off delay
# 60 or 300 seconds
action: zha_toolkit.attr_write
data:
  ieee: binary_sensor.vallhorn_8_belegung
  cluster: 0xfc81
  attribute: 0x0002
  attr_val: 300
  manf: 4476
  tries: 10
  
# Mode
# 0: all the time
# 1: only when dark
action: zha_toolkit.attr_write
data:
  ieee: binary_sensor.vallhorn_8_belegung
  cluster: 0xfc81
  attribute: 0x0000
  attr_val: 1
  manf: 4476
  tries: 10

the zha-toolkit scan output from this cluster:

        "0xfc81": {
          "cluster_id": "0xfc81",
          "title": "Manufacturer Specific",
          "name": "manufacturer_specific",
          "attributes": {
            "0x0000": {
              "attribute_id": "0x0000",
              "attribute_name": "0",
              "value_type": [
                "0x10",
                "Bool",
                "Discrete"
              ],
              "access": "READ|WRITE|REPORT",
              "access_acl": 7,
              "manf_id": 4476,
              "attribute_value": 0
            },
            "0x0002": {
              "attribute_id": "0x0002",
              "attribute_name": "2",
              "value_type": [
                "0x21",
                "uint16_t",
                "Analog"
              ],
              "access": "READ|WRITE|REPORT",
              "access_acl": 7,
              "manf_id": 4476,
              "attribute_value": 60
            },
            "0x0004": {
              "attribute_id": "0x0004",
              "attribute_name": "4",
              "value_type": [
                "0x21",
                "uint16_t",
                "Analog"
              ],
              "access": "READ|WRITE|REPORT",
              "access_acl": 7,
              "manf_id": 4476,
              "attribute_value": 60
            },
            "0xfffd": {
              "attribute_id": "0xfffd",
              "attribute_name": "65533",
              "value_type": [
                "0x21",
                "uint16_t",
                "Analog"
              ],
              "access": "READ|REPORT",
              "access_acl": 5,
              "manf_id": 4476,
              "attribute_value": 1
            }
          },
          "commands_received": {},
          "commands_generated": {}
        }

I’ve created an initial quirk:

Looks like:

grafik