[Deprecated] Xiaomi / Aqara / Opple Drivers with Presence!

@markus thanks so much for the quick response.

everything look perfect so far, except this one, (unit is wrong by 100)
2020-08-11 10:03:50.159 am [info]Sending pressure event (Pressure: 10020.60, old pressure: 100.10, change: 9920.50)

1 Like

Exactly which model is it that you are using?

this is from aqara model, that has the pressure sensor. original xiaomi does not have it.

Ok, there is also the Keen sensor that has it. That is why I asked. The code has been updated to compensate for this.

Wow, i was away for a few months, i see Markus has taken over the world!!
Nice work @markus!

Glad to see the decimals option made it, i modified the driver to only show 1 decimal.

Done updating all the drivers.
Have a big list of "markusl" drivers now...

5 Likes

The Beta drivers have been updated so that they disable the Recovery feature when on platform version 2.2.3. The Release version will have that update in a few more minutes. There's 18 drivers affected.

First reported here:

EDIT: All drivers have been updated in both Beta and Release

1 Like

What does this mean going forward? No notification when these items drop off the mesh? Or is this a temporary workaround until it can be re-coded?

You will get notifications that they drop, the driver just won't be doing as much to try to bring them back.

For now I don't know how hard that limit is that they have imposed, to do what is needed a message need to go out with a rather high frequency, if they have blocked that and won't fix it in the platform I'm not sure functionality can be restored. So far I've just woken up about 1 hour ago, seen this and made an emergency patch of the 18 affected drivers. I will try to talk with Hubitat about this later when I have time, I've also seen it affect other drivers already, so I'm sure we'll know more in a few days.

8 Likes

I think I will hold on upgrading my Hubitat platform... hopefully, this can be resolved soon! I will keep an eye on the number of reconnections per devices... this automatic reconnection is an awesome feature, and I really hope it can be enabled again!

Hey @markus, today I've received my HE and I am trying to add my devices to it. I started with the ones that are not currently paired with any hub and I've successfully added my sonoff sensors. After that I've started with the xiaomi stuff and everything was going great, until I hit an issue with the vibration sensor and the xiaomi button I have. They get to the stage in which the HE finds them, but they stay in the initializing phase: https://i.imgur.com/TcApMB0.png

Do you have any idea what might be causing the issue? I'm using the latest HE drivers. Here are the logs from the hub: https://i.imgur.com/SHVhdRl.png.

Edit: I've successfully added an aqara motion sensor and xiaomi luminance sensor.

Some xiaomi devices need to be woke up while pairing to complete correctly as it goes to sleep to fast. Try resetting the device and while pairing press the reset button ONCE every few seconds until the pairing completes.

When the pairing is completed you will see 3 blue flashes after you press the reset button 1 time. If you only see 1 blue flash after you press the reset button that means its not paired yet.

1 Like

I thought I would post my RM for Xiaomi presence checking. It checks every 30 minutes and if presence is not present it alerts me.

3 Likes

I use the notifications app for my tasmota lights but same use case.
I went with this as it is easier to set up and add the restriction I need.

3 Likes

Adding to what @Evilborg already mentions regarding the pairing would be to pair it closer to the hub to, mostly, rule out mesh issue. If that works, you can then wait for your mesh to settle (you mention you got your HE today). If you power it down for 30 minutes that should speed up the process, but it can take 24-48 hours before a new mesh settles on routes. How many repeaters and of what kind do you have in your mesh?

Well this morning I've tried what @Evilborg suggested and it actually worked. There was this warning, but other than that it seems to log the correct presses.

To answer the other questions, currently the pairing proccess was happening in the same room, 2 meteres between the 2 devices. I currently have paired only the sensors and the HE somehow discovered my 2 Yeelights, that are still paired to the Xiaomi Hub 3rd gen, so I'm not sure what should I do about those. Today I will be probably fighting the Sonoff Basic ZBR3 and one of the "new" ([New Arrival] Xiaomi Mijia Smart Switch Wall Switch Single/Doubl/Three Open Dual - US$10.49) Xiaomi switches that I have. I'm having high expectations towards the ZBR3s, as those would probably be the baseline for my mesh. For the Xiaomi switches I'm not so optimistic about, because even if I get them to work, they are without neutral wire and they have a square box, so I wouldn't be able to use them most likely, but I still want to try and connect them. As far as the Sonoff Basic goes, I've never flashed devices like these, but I'll see what happens.

Either way, thanks for your help guys, much appreciated!

2 Likes

Those warnings are fine, it is part of a precautionary change I did to the drivers for 2.2.3. This may change when the true issue is fully known.

These are good in terms of HOW they repeat, but in terms of transmitting power they are very/rather weak. Depending on your RF environment they may or may not work well for you. There are threads about this device discussing this in more detail.

These should work, any issue please report them and I'll see about updating the drivers. I don't have the fingerprints for all three of them, so please report the fingerprints using my Zigbee Toolbox Driver and the GetInfo command in that driver.

If you're talking about the Zigbee version, ZBR3, there is no flashing needed, that would be for the Wifi version you would flash with Tasmota.

2 Likes

Thanks for that, I was confused exactly by this.

Surely, no problems. I will post the results.

I live in a house with medium/thick walls/floors but I'll see what happens. I'm planning to move my routed and my hub in a more central place, since they are on the top floor currently, which limits the range.

I forget where I learnt that trick from but the flashes I learnt from trial and error after pairing so many Xiaomi devices. They all pair the same way with the blinking blue light. If you press the reset button once you should see 1 of 2 replies... 3 quick flashes means its paired and talking and a single long blue light means it lost pairing.

3 Likes

@markus

One of my sensor has a strange behavior.
Every time i reconnect it, it sends some multstate event, but never come back with the hourly checkin.

dev:712020-08-16 10:09:25.314 am infoSending Absolute Humidity event (Absolute Humidity: 16.5g/m³)
dev:712020-08-16 10:09:25.306 am infoSending humidity event (Humidity: 63.4%, old humidity: 57.40%, change: 6.00%)
dev:712020-08-16 10:09:20.070 am infoRestoring bind settings
dev:712020-08-16 10:09:20.065 am warnOne or several EXPECTED checkin events have been missed! Something MIGHT be wrong with the mesh for this device. Minutes since last checkin: 709 (maximum expected 90)
dev:712020-08-16 10:09:20.060 am infoMULTISTATE CLUSTER EVENT - description:catchall: 0000 0013 00 00 0040 00 B17B 00 00 0000 00 00 7C7BB106D75402008D150080 | parseMap:[raw:catchall: 0000 0013 00 00 0040 00 B17B 00 00 0000 00 00 7C7BB106D75402008D150080, profileId:0000, clusterId:0013, clusterInt:19, sourceEndpoint:00, destinationEndpoint:00, options:0040, messageType:00, dni:B17B, isClusterSpecific:false, isManufacturerSpecific:false, manufacturerId:0000, command:00, direction:00, data:[7C, 7B, B1, 06, D7, 54, 02, 00, 8D, 15, 00, 80]]

My shipment of potential disappointment arrived today! :wink:

Only hooked up one of these new Aqara D1 wired wall switches (no neutral) so far, this is from the QBKG22LM, which is the two-button version.

Shows like this in the device details:

  • endpointId: 01
  • buttonCombos: 1
  • application: 1C
  • driver: v0.8.1.0814
  • model: lumi.switch.b2lacn02
  • physicalButtons: 2
  • manufacturer: LUMI
dev:332020-08-17 15:47:44.325 infoSending temperature event (Temperature: 22.0 °C)
dev:332020-08-17 15:47:44.318 debugKNOWN event (Xiaomi/Aqara specific data structure) - description:read attr - raw: 80E50100005A01FF42296410006510006E20006F20000121D40C0328160521060008211C360A2109DA9923000000009B210000, dni: 80E5, endpoint: 01, cluster: 0000, size: 5A, attrId: FF01, encoding: 42, command: 0A, value: 296410006510006E20006F20000121D40C0328160521060008211C360A2109DA9923000000009B210000 | parseMap:[raw:80E50100005A01FF42296410006510006E20006F20000121D40C0328160521060008211C360A2109DA9923000000009B210000, dni:80E5, endpoint:01, cluster:0000, size:5A, attrId:FF01, encoding:41, command:0A, value:[raw:[openClose:00, switch2:00, unknown10:00, unknown11:00, battery:0CD4, deviceTemperature:16, RSSI_dB:0006, unknown3:361C, routerid:DA09, gestureCounter3:00000000, unknown9:0000], openClose:false, switch2:false, unknown10:0, unknown11:0, battery:3284, deviceTemperature:22, RSSI_dB:6, unknown3:13852, routerid:55817, gestureCounter3:0, unknown9:0], clusterInt:0, attrInt:65281]
dev:332020-08-17 15:47:03.393 errorjava.lang.NullPointerException: Cannot invoke method parse() on null object on line 643 (parse)
dev:332020-08-17 15:47:03.375 infoOn/Off Button press - description:read attr - raw: 80E5050006100000100000001001, dni: 80E5, endpoint: 05, cluster: 0006, size: 10, attrId: 0000, encoding: 10, command: 0A, value: 0000001001 | parseMap:[raw:80E5050006100000100000001001, dni:80E5, endpoint:05, cluster:0006, size:10, attrId:0000, encoding:10, command:0A, value:00, clusterInt:6, attrInt:0, additionalAttrs:[[value:01, encoding:10, attrId:0000, consumedBytes:4, attrInt:0]], valueParsed:false]
dev:332020-08-17 15:47:03.060 errorjava.lang.NullPointerException: Cannot invoke method parse() on null object on line 643 (parse)
dev:332020-08-17 15:47:03.041 infoOn/Off Button press - description:read attr - raw: 80E5030006160000100000F02300E58003, dni: 80E5, endpoint: 03, cluster: 0006, size: 16, attrId: 0000, encoding: 10, command: 0A, value: 0000F02300E58003 | parseMap:[raw:80E5030006160000100000F02300E58003, dni:80E5, endpoint:03, cluster:0006, size:16, attrId:0000, encoding:10, command:0A, value:00, clusterInt:6, attrInt:0, additionalAttrs:[[value:0380E500, encoding:23, attrId:F000, consumedBytes:7, attrInt:61440]], valueParsed:false]
dev:332020-08-17 15:46:59.458 errorjava.lang.NullPointerException: Cannot invoke method parse() on null object on line 643 (parse)
dev:332020-08-17 15:46:59.442 infoOn/Off Button press - description:read attr - raw: 80E5050006100000100000001001, dni: 80E5, endpoint: 05, cluster: 0006, size: 10, attrId: 0000, encoding: 10, command: 0A, value: 0000001001 | parseMap:[raw:80E5050006100000100000001001, dni:80E5, endpoint:05, cluster:0006, size:10, attrId:0000, encoding:10, command:0A, value:00, clusterInt:6, attrInt:0, additionalAttrs:[[value:01, encoding:10, attrId:0000, consumedBytes:4, attrInt:0]], valueParsed:false]
dev:332020-08-17 15:46:59.150 errorjava.lang.NullPointerException: Cannot invoke method parse() on null object on line 641 (parse)
dev:332020-08-17 15:46:59.134 infoOn/Off Button press - description:read attr - raw: 80E5030006160000100100F02300E58003, dni: 80E5, endpoint: 03, cluster: 0006, size: 16, attrId: 0000, encoding: 10, command: 0A, value: 0100F02300E58003 | parseMap:[raw:80E5030006160000100100F02300E58003, dni:80E5, endpoint:03, cluster:0006, size:16, attrId:0000, encoding:10, command:0A, value:01, clusterInt:6, attrInt:0, additionalAttrs:[[value:0380E500, encoding:23, attrId:F000, consumedBytes:7, attrInt:61440]], valueParsed:true]
dev:332020-08-17 15:46:55.387 errorjava.lang.NullPointerException: Cannot invoke method parse() on null object on line 643 (parse)
dev:332020-08-17 15:46:55.370 infoOn/Off Button press - description:read attr - raw: 80E5040006100000100000001001, dni: 80E5, endpoint: 04, cluster: 0006, size: 10, attrId: 0000, encoding: 10, command: 0A, value: 0000001001 | parseMap:[raw:80E5040006100000100000001001, dni:80E5, endpoint:04, cluster:0006, size:10, attrId:0000, encoding:10, command:0A, value:00, clusterInt:6, attrInt:0, additionalAttrs:[[value:01, encoding:10, attrId:0000, consumedBytes:4, attrInt:0]], valueParsed:false]
dev:342020-08-17 15:46:55.061 infoSwitch turned OFF
dev:332020-08-17 15:46:55.047 infoOn/Off Button press - description:read attr - raw: 80E5020006160000100000F02336E58003, dni: 80E5, endpoint: 02, cluster: 0006, size: 16, attrId: 0000, encoding: 10, command: 0A, value: 0000F02336E58003 | parseMap:[raw:80E5020006160000100000F02336E58003, dni:80E5, endpoint:02, cluster:0006, size:16, attrId:0000, encoding:10, command:0A, value:00, clusterInt:6, attrInt:0, additionalAttrs:[[value:0380E536, encoding:23, attrId:F000, consumedBytes:7, attrInt:61440]], valueParsed:false]
dev:332020-08-17 15:46:49.675 errorjava.lang.NullPointerException: Cannot invoke method parse() on null object on line 643 (parse)
dev:332020-08-17 15:46:49.659 infoOn/Off Button press - description:read attr - raw: 80E5040006100000100000001001, dni: 80E5, endpoint: 04, cluster: 0006, size: 10, attrId: 0000, encoding: 10, command: 0A, value: 0000001001 | parseMap:[raw:80E5040006100000100000001001, dni:80E5, endpoint:04, cluster:0006, size:10, attrId:0000, encoding:10, command:0A, value:00, clusterInt:6, attrInt:0, additionalAttrs:[[value:01, encoding:10, attrId:0000, consumedBytes:4, attrInt:0]], valueParsed:false]
dev:342020-08-17 15:46:49.335 infoSwitch turned ON
dev:332020-08-17 15:46:49.326 infoOn/Off Button press - description:read attr - raw: 80E5020006160000100100F02336E58003, dni: 80E5, endpoint: 02, cluster: 0006, size: 16, attrId: 0000, encoding: 10, command: 0A, value: 0100F02336E58003 | parseMap:[raw:80E5020006160000100100F02336E58003, dni:80E5, endpoint:02, cluster:0006, size:16, attrId:0000, encoding:10, command:0A, value:01, clusterInt:6, attrInt:0, additionalAttrs:[[value:0380E536, encoding:23, attrId:F000, consumedBytes:7, attrInt:61440]], valueParsed:true]
--- Live Log Started, waiting for events ---

That's a single press on and off for the left and then the right paddle.

I can remote control what I would consider to be the 'left' relay already, but the 'right' one doesn't work remotely. I'll ignore for the moment that I wired the load into L1 and it seems that the RIGHT paddle is controlling it... :rofl:

The relay which is remote controllable is very fast, more responsive than the older model.