dresden-elektronik / deconz-rest-plugin

deCONZ REST-API plugin to control ZigBee devices
BSD 3-Clause "New" or "Revised" License
1.88k stars 490 forks source link

Bosch ZigBee Wireless Motion Detector RFDL-ZB-MS #2289

Closed geelenbert closed 4 years ago

geelenbert commented 4 years ago

I tried to pair a couple of Bosch zigbee motion detectors.

I was hoping it would work out of the box as the devices should support Zigbee HA1.2: https://zigbeealliance.org/zigbee_products/radion-tritech-zb-4/

For the Zigbee2mqtt project there has also been a request: https://github.com/Koenkk/zigbee2mqtt/issues/769

It pairs ok, but not shure what i need to do to get it working. Ultimate i want to connect it to Home Assistant.

image

SwoopX commented 4 years ago

Can you please provide additional info as described in the wiki? Also, please make sure having the attributes read before taking the screenshots.

geelenbert commented 4 years ago

image

image

image

image

image

image

image

image

image

image

geelenbert commented 4 years ago

Is there any insigt in when the next build will be done?

I don't want to be pushing anyone, but i just want to know when the next build will be. The last one was from over 2 months ago, and i'm ready to test the fix.

SwoopX commented 4 years ago

The last one was from over 2 months ago, and i'm ready to test the fix.

You may want to compile the current version yourself and give it a try?

geelenbert commented 4 years ago

I would like to do this, but it's not that easy. My setup is running deconz in as Hass.io addon. I can run deconz in a Ubuntu VM for testing.

But what should be te expected behaviour?

SwoopX commented 4 years ago

Well, from your initial post, I conclude you do not see any sensors exposed through deconz' REST API and therefore also not in Hass.io. Since the updates have been merged, but .73 is not available yet, compiling the plugin and doing the pairing should expose those sensors now. Pretty much straigh forward.

jensflorian commented 4 years ago

Does anyone know whether the RFDL-ZB-MS is identical to the model sold as Smart Home motion sensor https://www.bosch-smarthome.com/uk/en/shop?url=products/smart-system-solutions/motion-detector ?

geelenbert commented 4 years ago

So i compiled the latest version and runned the rest plugin into a virtual machine:

image

image

I removed the old Deconz integration from home assistant. I started Home assstant again and paired the new Deconz instance.

All my sensors are now added, but I can't find a new motion sensor.

Am i looking into the wrong place? Or is there anything i'm missing ?

SwoopX commented 4 years ago

Did the sensor search give you a green indication of a successful pairing process with the Bosch sensor? Have you queried the deconz REST API for all sensors and double checked?

geelenbert commented 4 years ago

I paired the sensor again and now it shows up in Home Assistant.

I enabled the light indicator on the device to see if motion is detected.

But the state of the sensor does not change in Home Assistant:

Screenshot 2020-01-28 at 23 31 26

Any suggestions ?

SwoopX commented 4 years ago

Hm, can you double check in deconz GUI (IAS Zone cluster) if the sensor is enrolled? Also, please check deconz REST API if the state changes there.

geelenbert commented 4 years ago
Screenshot 2020-01-29 at 07 45 11 Screenshot 2020-01-29 at 07 46 59
SwoopX commented 4 years ago

I'm afraid the screenshots are not much of a help since they neither show the read attributes of the IAS Zone cluster nor answer the question, if you've checked the REST API.

geelenbert commented 4 years ago
Screenshot 2020-01-30 at 20 07 15

I paired a second one. Looks the same. I read the IAS zone attribute.

Do you think the device needs to be configured ? Or should the motion sensor work all the time ?

I'm not sure how to test the rest api. Should a debug log help ? If so, which log ?

SwoopX commented 4 years ago

Thanks for the screenshot, that one is workable. It is strange that it hasn't been enrolled automatically (which should have happened). I can check the code once mor to see if I've overlooked something.

You can have a look here regarding API usage: https://github.com/dresden-elektronik/deconz-rest-plugin/issues/2373#issuecomment-578511439 You may also follow the whole threat to learn how to manually enroll the sensor. Doing so might resolve the device not working as expected.

geelenbert commented 4 years ago

Did you have a momment to check if there was an issue in the code ?

I'm not technical enough I think to enroll it manually

SwoopX commented 4 years ago

Yes, but haven't spotted anything suspicious so far.

I'm not technical enough I think to enroll it manually

This is really just like 3 clicks and typing the MAC address of your conbee/raspbee in there. Looks worse than it is. I'm dependent on you with this since I don't have that device, otherwise I cannot really help.

geelenbert commented 4 years ago

It was a bit of a struggle, but i finally found the steps that need to be taken.

By putting the mac address into the field the status changed to enrolled. Home assistant does look like it reports changes of motion state.

So for now it looks like it is working!

Screenshot 2020-02-09 at 14 18 27 Screenshot 2020-02-09 at 14 22 01
SwoopX commented 4 years ago

That doesn't sound too bad, great. Say, do you get reasonable battery readings from your device? My feeling would say no.

geelenbert commented 4 years ago

I don't get any battery readings. Is there any way to check or improve this ?

SwoopX commented 4 years ago

Already prepared an update.

geelenbert commented 4 years ago

Cool! Let me know when I can test it.

SwoopX commented 4 years ago

Available already in my repo, so go for it.

Mimiix commented 4 years ago

It seems this issue is resolved. If it is not, please re-open or create another issue.

geelenbert commented 3 years ago

I dusted off this project again and i would like to mention that the device works out of the box. Motion,

Motion, temperature, lux and battery level: image

Not sure yet if the battery level indicator is realistic, but 90% for a device that has been laying in the storage for some time seems reasonable.

One issue i'm having tough is that Phoscon does not show all these devices. I have now added 7 of these sensors:

Deconz: image

Home Assistant shows this: image

Phoscon: image

The problem is that Phoscon only shows 4 of the 7 devices. I can use Phoscon to automate lights and rename the devices.

Here is the node info per node: image image image image image image image

From my perspective, i don;t see any difference between the devices being shown in Phoscon, and the ones that are not. Removing and adding them again results in the same result.

Any idea what is going on ?

SwoopX commented 3 years ago

I'll have a look later. Anyway, thanks for confirming!

geelenbert commented 3 years ago

@SwoopX any change of pointing me in a direction ? i want to integrate the sensors, but i don't want to change the entities further on.

SwoopX commented 3 years ago

This one drowned, sorry for that. Can you please read the IAS cluster attributes of both? I'd assume the missing ones are not enrolled.

geelenbert commented 3 years ago

This is from one that is not detected: Screenshot 2021-01-08 at 18 06 04

This is one that has been detected: Screenshot 2021-01-08 at 18 08 06

I think they are enrolled successfully. When i started this thread, the devices did not enrol at all, so somewhere along updates of deconz or my system this looks fixed. Now they do not show up in Phoscon yet.

SwoopX commented 3 years ago

Hm, that's odd. You could try entering sensor search in Phoscon again and trigger one of the problematic devices my provocing motion. In addition to that, it might be a good idea to push the physical button on the device.

Alternatively, you may want to try removing the batteries and re-inserting them while searching for sensors.