Presence sensor not recognized in CentraLite Sensor

Hello!

I’ve been using a CentraLite motion detector for about a year. It is the “SMART+ Motion Sensor” from Ledvance: ledvance.com product page It senses motion via PIR and also measures the room tempetarure.

Now I’ve moved and added numerous new motion detectors of the same type. Just like the old sensor, these were recognized as a temperature sensor. But the detection as a motion detector did not work.

I then deleted the old sensor as well and paired it again. Now it is no longer listed as a motion sensor.

How can I find out what the problem is? I would like to use all the sensors as motion detectors.

Best wishes

MaMaKow

Do you already run deCONZ 2.14.1 and firmware 26720700?

Can you check if you see 2 endpoints in deCONZ as shown in this screenshots? They are grey and named with 01 HA and 02 HA in the screenshots. This is only possible if deCONZ is running with GUI and not headless.

If you only see one endpoint maybe another try to add the device will bring success. Please do not klick immediately the green “ready” button after its appearance. While adding the device you can try keep the device upwoken by pressing the button every 1-2 second.

deCONZ is running headless on a raspberry pi 4 with openhabian installed as distro.
Version is 2.13.04 / 18.12.202 with fimware 26660700.

Hm, you don’t want to update?

Do you try another adding as describe?

Let’s set up a test system on an separate SD card with our image with Desktop (based on Raspbian) and check if the device work and all endpoints are visible in deCONZ GUI.

I updated to deCONZ 2.14.1 and firmware 26720700.
I then tried to add one of the sensors. I waited for two minutes after the first part of the sensor was recognized. But it is again only visible as a thermometer.
Can there be an information in some logfile anywhere? Is there a verbose mode?

Right now i cannot install your image, as I have to go buy another SD-card for that.

OK, I set up a test system on a separate SD card and connected exacly one sensor.

As far as I can see in the PhosconApp the sensor still has only temperature data.
Which information do I see on my screenshot? Where do we go from here?

It’s wich one sensor ?
On top you have a not receonized one and on bottom a presence sensor.
To expend cluster list clic on the second circle on the node title.

I am not sure what I see here. I guess it might be the presence sensor on the bottom.
Please see the image attached:

The thing is called “Motion Sensor” but it contains an element “Temperature Measurement”. By now a lot of lights “automatically” connected to this instance. They seem to remember the usb-stick and ignore the changed operating system?

PS: It seems that the occupancy information is there in deconz:


But it is not presented in the phoscon app and to openhab (which is not part of your image right now, is it?)

What do I have to do next? @Smanar @ich

Strange, the code look ok at a first glance. I’ll schedule a test and likely create a DDF for it. Have this sensor in my bathroom running for years but never re-joined :slight_smile:

Yeah it’s strange, and more if deconz have choose as name “motion sensor”.
You have check direclty in the API, for exemple using Phoscon / help / API Information / Sensors (You need to have 2 entries for this sensor)

More and more of my devices automatically join the new system, whenever I come to insert the debug-SD-card.

In the “API Information” I find the following image and json data:

{
“config”: {
“battery”: null,
“offset”: 0,
“on”: true,
“reachable”: true
},
“ep”: 1,
“etag”: “b8ad06ab54f985258b6e0940eb4098ae”,
“lastannounced”: “2022-04-03T20:50:31Z”,
“lastseen”: “2022-03-27T20:36Z”,
“manufacturername”: “CentraLite”,
“modelid”: “Motion Sensor-A”,
“name”: “Motion Sensor”,
“state”: {
“lastupdated”: “2022-04-03T20:56:51.415”,
“temperature”: 2028
},
“type”: “ZHATemperature”,
“uniqueid”: “00:0d:6f:00:0b:b2:70:5d-01-0402”
}

Full json information without filter:

Ha yes effectively, funny.
I can see in code why this device is not creating the ZHAPresence but why it rename the device “Motion sensor” … Probably because the second endpoint.

But yes I think too it can be solved using a DDF.

If manup don’t have time to do it, wana make a try yourself ? I can complete your DDF, but I need at least you have a base (the device reconised) to be sure all is in place.

What is a DDF and how do I create it?

You have a video and a description here DDF cheat sheet · dresden-elektronik/deconz-rest-plugin Wiki · GitHub

As your device is partially discovered, you will probably have all the starting part already done. So You just need to copy paste the third tab to show the result (“preview” in the editor)
Else fill at least the “basic cluster identification” and drag and drop a ZHAPresence.

Can save the file and look in the editor title to see the file path, will be faster to edit the file than explain my manipulation on editor later.

OK, so I created a DDF via drag & drop:

{
  "schema": "devcap1.schema.json",
  "manufacturername": "CentraLite",
  "modelid": "Motion Sensor-A",
  "product": "Motion Sensor-A",
  "sleeper": false,
  "status": "Bronze",
  "path": "/devices/motion_sensor-a.json",
  "subdevices": [
    {
      "type": "$TYPE_TEMPERATURE_SENSOR",
      "restapi": "/sensors",
      "uuid": [
        "$address.ext",
        "0x01",
        "0x0402"
      ],
      "fingerprint": {
        "profile": "0x0104",
        "device": "0x0402",
        "endpoint": "0x01",
        "in": [
          "0x0000",
          "0x0001",
          "0x0402"
        ]
      },
      "items": [
        {
          "name": "attr/id"
        },
        {
          "name": "attr/lastannounced"
        },
        {
          "name": "attr/lastseen"
        },
        {
          "name": "attr/manufacturername"
        },
        {
          "name": "attr/modelid"
        },
        {
          "name": "attr/name"
        },
        {
          "name": "attr/swversion"
        },
        {
          "name": "attr/type"
        },
        {
          "name": "attr/uniqueid"
        },
        {
          "name": "config/battery",
          "description": "The current device battery level in 0–100 %."
        },
        {
          "name": "config/offset",
          "description": "Relative offset to the main measured value.",
          "default": 0
        },
        {
          "name": "config/on"
        },
        {
          "name": "config/reachable"
        },
        {
          "name": "state/lastupdated"
        },
        {
          "name": "state/temperature",
          "parse": {
            "at": "0x0000",
            "cl": "0x0402",
            "ep": 0,
            "eval": "Item.val = Attr.val + R.item('config/offset').val + 99",
            "fn": "zcl"
          },
          "default": 0
        }
      ]
    },
    {
      "type": "$TYPE_PRESENCE_SENSOR",
      "restapi": "/sensors",
      "uuid": [
        "$address.ext",
        "0x01",
        "0x0406"
      ],
      "items": [
        {
          "name": "attr/id"
        },
        {
          "name": "attr/lastannounced"
        },
        {
          "name": "attr/lastseen"
        },
        {
          "name": "attr/manufacturername"
        },
        {
          "name": "attr/modelid"
        },
        {
          "name": "attr/name"
        },
        {
          "name": "attr/swversion"
        },
        {
          "name": "attr/type"
        },
        {
          "name": "attr/uniqueid"
        },
        {
          "name": "config/duration"
        },
        {
          "name": "config/on"
        },
        {
          "name": "config/reachable"
        },
        {
          "name": "state/lastupdated"
        },
        {
          "name": "state/presence"
        }
      ]
    }
  ]
}

It works, but only for one of my sensors. (I guess it might be my old one. Maybe it is another hardware/software version inside?)

However when I deleted this file another DDF was autocreated. Where did that come from?

{
  "schema": "devcap1.schema.json",
  "manufacturername": "CentraLite",
  "modelid": "Motion Sensor-A",
  "product": "Motion Sensor-A",
  "sleeper": false,
  "status": "Bronze",
  "path": "/devices/motion_sensor-a.json",
  "subdevices": [
    {
      "type": "$TYPE_PRESENCE_SENSOR",
      "restapi": "/sensors",
      "uuid": [
        "$address.ext",
        "0xff",
        "0x0406"
      ],
      "items": [
        {
          "name": "attr/id"
        },
        {
          "name": "attr/lastannounced"
        },
        {
          "name": "attr/lastseen"
        },
        {
          "name": "attr/manufacturername"
        },
        {
          "name": "attr/modelid"
        },
        {
          "name": "attr/name"
        },
        {
          "name": "attr/swversion"
        },
        {
          "name": "attr/type"
        },
        {
          "name": "attr/uniqueid"
        },
        {
          "name": "config/duration",
          "description": "The duration until presence is automatically turned back to false."
        },
        {
          "name": "config/on"
        },
        {
          "name": "config/reachable"
        },
        {
          "name": "state/lastupdated"
        },
        {
          "name": "state/presence"
        }
      ]
    },
    {
      "type": "$TYPE_TEMPERATURE_SENSOR",
      "restapi": "/sensors",
      "uuid": [
        "$address.ext",
        "0x01",
        "0x0402"
      ],
      "fingerprint": {
        "profile": "0x0104",
        "device": "0x0402",
        "endpoint": "0x01",
        "in": [
          "0x0000",
          "0x0001",
          "0x0402"
        ]
      },
      "items": [
        {
          "name": "attr/id"
        },
        {
          "name": "attr/lastannounced"
        },
        {
          "name": "attr/lastseen"
        },
        {
          "name": "attr/manufacturername"
        },
        {
          "name": "attr/modelid"
        },
        {
          "name": "attr/name"
        },
        {
          "name": "attr/swversion"
        },
        {
          "name": "attr/type"
        },
        {
          "name": "attr/uniqueid"
        },
        {
          "name": "config/battery",
          "description": "The current device battery level in 0–100 %.",
          "parse": {
            "at": "0x0020",
            "cl": "0x0001",
            "cppsrc": "power_configuration.cpp:44",
            "ep": 255,
            "eval": "const vmin = 20,0; const vmax = 30,0; let bat = Attr.val; if (bat > vmax) { bat = vmax; } else if (bat < vmin) { bat = vmin; } bat = ((bat - vmin) / (vmax - vmin)) * 100; if (bat > 100) { bat = 100; } else if (bat <= 0)  { bat = 1; } Item.val = bat;"
          }
        },
        {
          "name": "config/offset",
          "description": "Relative offset to the main measured value.",
          "default": 0
        },
        {
          "name": "config/on"
        },
        {
          "name": "config/reachable"
        },
        {
          "name": "state/lastupdated"
        },
        {
          "name": "state/temperature",
          "description": "The current temperature in °C &times; 100.",
          "default": 0
        }
      ]
    }
  ],
  "bindings": [
    {
      "bind": "unicast",
      "src.ep": 1,
      "dst.ep": 1,
      "cl": "0x0001"
    }
  ]
}

The second one does not work at all (for motion sensing).

Ha yes, your device have 2 endpoints, the 0x01 and the 0x02, only the first one is used (the ias), but the second one is a presence sensor too, and it was bugged on the DDF, the endpoint is 0xFF.
You can delete this one.

it works, but only for one of my sensors

Strange not possible it can work as it, because the DDF use the presence sensor and your device the IAS. And the status is still bronze on it.

Now we need to add the stuff for IAS sensor, can you try this DDF

{
  "schema": "devcap1.schema.json",
  "manufacturername": "CentraLite",
  "modelid": "Motion Sensor-A",
  "product": "Motion Sensor-A",
  "sleeper": false,
  "status": "Gold",
  "subdevices": [
    {
      "type": "$TYPE_TEMPERATURE_SENSOR",
      "restapi": "/sensors",
      "uuid": [
        "$address.ext",
        "0x01",
        "0x0402"
      ],
      "fingerprint": {
        "profile": "0x0104",
        "device": "0x0402",
        "endpoint": "0x01",
        "in": [
          "0x0000",
          "0x0001",
          "0x0402"
        ]
      },
      "items": [
        {
          "name": "attr/id"
        },
        {
          "name": "attr/lastannounced"
        },
        {
          "name": "attr/lastseen"
        },
        {
          "name": "attr/manufacturername"
        },
        {
          "name": "attr/modelid"
        },
        {
          "name": "attr/name"
        },
        {
          "name": "attr/swversion"
        },
        {
          "name": "attr/type"
        },
        {
          "name": "attr/uniqueid"
        },
        {
          "name": "config/battery",
          "description": "The current device battery level in 0&ndash;100&thinsp;%."
        },
        {
          "name": "config/offset",
          "description": "Relative offset to the main measured value.",
          "default": 0
        },
        {
          "name": "config/on"
        },
        {
          "name": "config/reachable"
        },
        {
          "name": "state/lastupdated"
        },
        {
          "name": "state/temperature",
          "parse": {
            "at": "0x0000",
            "cl": "0x0402",
            "ep": 0,
            "eval": "Item.val = Attr.val + R.item('config/offset').val + 99",
            "fn": "zcl"
          },
          "default": 0
        }
      ]
    },
    {
      "type": "$TYPE_PRESENCE_SENSOR",
      "restapi": "/sensors",
      "uuid": [
        "$address.ext",
        "0x01",
        "0x0500"
      ],
      "items": [
        {
          "name": "attr/id"
        },
        {
          "name": "attr/lastannounced"
        },
        {
          "name": "attr/lastseen"
        },
        {
          "name": "attr/manufacturername"
        },
        {
          "name": "attr/modelid"
        },
        {
          "name": "attr/name"
        },
        {
          "name": "attr/swversion"
        },
        {
          "name": "attr/type"
        },
        {
          "name": "attr/uniqueid"
        },
        {
          "name": "config/duration"
        },
        {
          "name": "config/on"
        },
        {
          "name": "config/reachable"
        },
        {
          "name": "config/enrolled",
          "public": false
        },
        {
          "name": "config/pending"
        },
        {
          "name": "state/lastupdated"
        },
        {
          "name": "state/lowbattery"
        },
        {
          "name": "state/tampered"
        },
        {
          "name": "state/presence"
        }
      ]
    }
  ],
  "bindings": [
    {
      "bind": "unicast",
      "src.ep": 1,
      "cl": "0x0001",
      "report": [
        {
          "at": "0x0021",
          "dt": "0x20",
          "min": 60,
          "max": 3600
        }
      ]
    },
    {
      "bind": "unicast",
      "src.ep": 3,
      "cl": "0x0402",
      "report": [
        {
          "at": "0x0000",
          "dt": "0x29",
          "min": 60,
          "max": 600,
          "change": "0x0000000A"
        }
      ]
    }
  ]
}

I think it only miss the binding for the cluster 0x0500, but not all device need it, so make a try.
After making hot reload, wait a little, this device need a special enrollement. If it still don’t work on the second tab add a binding for the cluster 0x0500 and only the cluster, no attributes.