[OBSOLETE] Original & Aqara Xiaomi Zigbee Sensors (contact, temp, motion, button, outlet, leak, etc)

Hello,

I’m using the Aqara Temperature Sensor on the bathroom and found out that the temperature and humidity report takes a while to appear on the hub.
Is there a way to change this DTH to force the Aqaras Temp/Humidity Sensor to report every time they see a 2% change like with the Aeotec Multisensor 6?
I’m asking this because I bought an aeotec multisensor 6 to test the humidity levels and reporting, and noticed a huge difference between the reporting of the aeotec and the xiaomis.
I put the “advanced” DTH for the aeotec, to change the intervals and enable reporting, with those settings I can easily get more reporting from the aeotec humidity sensors.

Is there a way to do the same on the Aqaras?

Thank you!

I’m sorry to say the answer is no. Someone just asked this question a few days ago. See my explanation below:

I am not certain of the amount of change required for Xiaomi / Aqara Temp/Humidity sensors to send a report, because there are varying accounts from different sources, but I’m pretty sure it’s not 2% like the Aeotec Multisensor 6. Also, it is not 100% consistent, and will sometimes wait longer, presumably in order to conserve on battery power.

Thank you, veeceeoh

Hello,

I have ST3 and webCore working.
I bought a WXKG02LM (2016) and a WXKG11LM and they are sync and working with ST Classic, but both only report only 1 button pressed. I´m working with the DH Version 1.3.5b.

Does someone know how to operate 100% this to devices?
Like double click, hold and recognize the 2 buttons instead of just one (WXKG02LM)?

Thanks!! :wink:

Hey all.

I bought some Keen Smart Vents and their Temperature Sensors. I’m trying to get the Aqara Temperature Humidity Sensor Device Handler to work for these but finding a few issues.

  • The DeviceId in the Fingerprint doesn’t seem to match the Keen Temp Sensor
  • The Model showing up in the Devices screen is " RS-THP-MP-1.0" and not “lumi.weather”
  • The attrId returned by my sensor for Pressure is “0020” instead of “0000” that is in the Device Handler

I’m still testing, so there may be other things that I catch as well.

Before I try to update the Device Handler to deal with these differences, I wanted to make sure I’m not just missing something simple here.

did you get anywhere with this @bodonovan9 ? I have the same issue.

Single wired non neutral wall switch, paired as a Thing via the app, can see it’s status in the app but can’t control it via the app.

First of all, thanks for the device handler, just purchased aqara temperature/humidity sensor (square) and connected to ST2, i added some sonoff S26 and linked the sonoff on smartthings via ifttt.

Value reading for umidity seems to be working but perhaps not as good as i need personally :slight_smile:
Here weather is very dry during winters and i need humidifier on depending on the value i receive from sensor.

My questions:

1 - How often does the device updates?
2 - Can/how to change the interval for updates if possible?

Thanks in advance!

Hi @veeceeoh , i’m hoping to find some help on my 1 button Aqara light switch I just bought and perhaps I can help to add a device into the mix?

I have this as my device type Id, is this what you need? da8277f7-ce41-4614-8d4b-40ce7c2a98cf

i’ve 1.3.5b bspranger Device handler for the Xiaomi Aqara Button, the ST classic app can see physical pushes, but when the app tries to toggle the switch it looks to work in the app but doesn’t actually switch the light on or off.

I’d be most grateful for any help and will do what I can to input back with the info about my device to add to the communal knowledge.

I’ve a v2 ST hub and i’m in the UK if it makes any odds

Looks like SmartThings is starting to develop native handlers for the Lumi (Xiaomi/Aqara) sensors. Not surprising with them entering the Chinese market. I’m guessing the fingerprints are for the newer zigbee 3.0 version of the sensors. So far they have started on the contact and water sensors.

1 Like

I’m leaving a comment here in case someone have the same issue.
I can’t seem to have a stable connection between Smartthings hub v1 and Xiaomi sensors.
I can pair them without any issues, but after 3-4 hours, the sensors goes offline.

I tried changing my wifi channel to 11 and 1. I also disconnected every zigbee device in the house before pairing (philips hue and logitech harmony).
I also tried to put the sensor within 1 meter of the ST hub.

The device I tried are Aqara motion sensor, aqara door sensor and original door sensor.
They all behave the same.

Someone here can help me understand what is going on? Is is because I have a v1 hub?
thanks a lot

Using the 2016 model WXKG02LM (2-button Aqara Wireless Smart Light Switch) with SmartThings, pressing button 1, button 2, or both buttons simultaneously results in the same message passed on from the SmartThings API to the DTH. So there’s no way to know which button has been pressed. This is explained both in the header section of the DTH as well as in my previous release posts for the beta DTH, for example here:

As for the model WXKG11LM button you have, there are actually TWO revisions. The only way to know which one you have is to look at the ZigBee Model listed for it. This can be found by logging into your hub’s SmartThings Groovy IDE, navigating to the My Devices tab, clicking on the Display Name for your model WXKG11LM button, and looking in the Data row of the information listed for the device. There you should see the ZigBee model listed, for example:

If the ZigBee model listed is lumi.sensor_switch.aq2 then you have the 2015 revision of the WXKG11LM button, and only single-click (button 1) is supported in SmartThings. The newer 2018 revision of the WXKG11LM button has better support in SmartThings, again as explained in both the header of the DTH, and my previous release posts:

If you don’t see any ZigBee model listed, then that means you paired the button using the “catchall” method, and the DTH has no way to know which revision the button is and is programmed to assume only 1 button is available.



Thanks for the report. The Keen version of Aqara’s Temperature / Humidity sensor is pretty clearly not the same, and will require either custom modifications to the DTH or a new separate DTH to provide proper support in SmartThings.

If you know how to use GitHub, earlier this year someone opened a Pull Request to update the Aqara Temp & Humidity DTH to add Keen sensor support, but it needs more work before it can be incorporated. You are welcome to make further edits to that pull request and if they work with your testing then I’d be happy to update the DTH to share with everyone. Otherwise, I can try to do it, if you don’t mind testing the modified DTH, since I have no way of testing it myself.



For #2, the answer is the interval cannot be changed. This has been asked a couple of times in the last week and a half. See my explanation below:

MMR:

Hi, I have tried to search but nothing came up, maybe I’m searching for the incorrect words. I have recently added a couple of the Aqara temp and hunidity sensors. Is there a way to make it report less often? I don’t need that accurate updates, once an hour or so would be fine to save battery.

Unfortunately no. The Xiaomi / Aqara sensors’ configuration cannot be changed. The temp / humidity sensors’ hardware is designed to send reports only when the temperature / humidity / pressure has changed by a certain amount. So that could be as frequent as every few seconds, and as infrequent as a few times a day. The regular check-in / battery level message is sent every 50-60 minutes.

I am not certain of the amount of change required for Xiaomi / Aqara Temp/Humidity sensors to send a report, because there are varying accounts from different sources, though it is probably 5-6% for changes in humidity and .5 degrees C for changes in temperature. Also, reporting is not 100% consistent and the sensors will sometimes wait longer to send reports, presumably in order to conserve on battery power.



No, sorry, what I need is both the manufacturer model (from the back side of the button/switch itself,) and also the ZigBee model, which you can get from logging into your Hub’s SmartThings Groovy IDE, navigating to the My Devices tab, clicking on the Display Name for button/switch, and looking in the Data row of the information listed for the device.

If you have one of the Aqara wired light switches, I am limited in my ability to help because I don’t own any (and have no way to test one even if I did!)



Great! So that means less work for me! :smile: However, I’m going to guess the person who opened the Pull Request, FenMei007S, is actually with LUMI, so hopefully they are making submissions for official SmartThings support.



Well, yes, it’s because you have a v1 hub, but in reality the issue is on the side of the Xiaomi / Aqara devices.

The reason for this is that the Xiaomi / Aqara devices don’t check in as often as expected by the the hub, and as a result they are “kicked” off the ZigBee mesh network. In normal circumstances, this would be fine as the ZigBee protocol allows devices to re-join when they attempt to check in. The hub sends a re-join request, but with Xiaomi / Aqara devices, they don’t re-join as requested, meaning they don’t follow ZigBee protocol.

I have posted about this a number of times before, including this post with a few interesting links to more information, but really the only way to get around this problem is if what’s called the hub’s “End Device Aging” timeout period is longer that the check-in interval of the Xiaomi / Aqara devices so that they never get booted off the network. My guess is that the SmartThings v1 hub has a End Device Aging timeout that is shorter than the check-in intervals of your Xiaomi / Aqara devices.

It’s also very very important to note that this issue can also happen with Xiaomi / Aqara devices connecting through a ZigBee repeater device (usually any non-battery powered ZigBee device except certain brands of Zigbee bulbs like Sengled bulbs). This is because ZigBee repeater devices also boot devices off the network which haven’t checked in before the repeater’s End Device Aging timeout period. So, if you have any ZigBee repeater devices, it/they could be the reason for the Xiaomi / Aqara devices dropping their connection(s).

3 Likes

I think they works for Samsung Asia. They have made PR for other devices recenty.

thanks veeceeoh that’s what I thought too after reading all your posts (which were awesome btw) but I wasn’t quite sure that the v1 had a different End Device Aging.
I will try with a v2 hub and report back.

btw, any way to know for sure if a zigbee device is connected through another device? I can see the “parentID” (or something like that, can’t quite remembre) section while pairing the device, but I’m not a 100% sure that what this parameter is for.

The only way to do this is to use a Digital International XBee ZigBee module with their free XCTU configuration software that includes ZigBee Mesh Network mapping functionality. I use one myself, and it’s very helpful, considering the number of Zigbee devices I have.

See this thread for more helpful information on the XBee:

1 Like

Thanks, I’ll take a look.

Interestingly the Keen team actually pointed me to your Device Handler saying there was already one built for the Temp Sensor. I’ll let them know that this is not the case.

Physically on the device the only readable non Chinese text is “QBKG04LM”

On the IDE:

Data:

  • application:
  • endpointId: 04
  • manufacturer:
  • model:

Yes indeed it is a wired Aqara switch. In the interest of making this work though, I would even be tempted to buy a wireless one (which I believe pairs to this wired one??)

I’ve tried a few DHs now, no joy

So you’ve got the Aqara Wall Switch - Single (no Neutral).

The only source for a SmartThings DTH is the thread that you’ve already posted on. Based on your post it sounds as though the command being sent from SmartThings to turn on/off the switch is incorrect. The changes suggested by Kelvin_Kueh probably aren’t working for you because they were for the Dual wired switch with Neutral.

Personally, I have almost completely migrated over to the Hubitat platform from SmartThings, and from my Hubitat community thread to support the Xiaomi / Aqara device handlers I ported over, I know there’s a user by the name of @guyeeba who has developed Hubitat drivers for all the variants of the Aqara Wired Wall Switches, including the one you use.

guyeeba’s Hubitat drivers can be found on GitHub here, and although they definitely won’t work on SmartThings as-is, there might be some code in them which could be adapted for use with SmartThings.

I hope that helps!

it’s very kind of you to post that Hubitat thread, thank you! I am teetering on the edge of sacking ST and going to Home Assistant, but will persist a while longer with this switch in ST.

The thing I don’t get about @Kelvin_Kueh post is where he’s talking about changing those numbers, if I could work that out and do some tests in the Groovy IDE I don’t mind changing them, but I see nothing similar to “st cmd 0x${device.deviceNetworkId} 3 6 0 {}” in the device handler.

FYI I did find one more DH for the Aqara Wall Switch - Dual (no Neutral) .by @Dschich but alas, it didn’t work for my single switch (I think it was aimed at the double switch, but one poster reported success with my model once)

Hi all,
Does any body happen to know any way of making ST to recognise the 2 buttons of the WXKG02LM model? Any way of processing the button id info? I have 3 of those !!!
Thank you!

I replaced the motion sensor few days ago and no problems so far. Removing the battery didn’t help so I guess it was a faulty sensor