[OBSOLETE] Xiaomi Sensors and Button (beta)

Hey!

Sorry, am not available at the moment, in hospital but will PM as soon as possible and we will get them all paired up. Hopefully either later this evening or tomorrow.

Will PM you once free.

1 Like

I’ve have 2 of the motion sensors up and running for 3 weeks without any problems, Just paired another one yesterday straight up which took about 3-4 button resets and ST recognized it. My question how long does it take for the battery % to populate with a value? I had it paired over night and still no value. I have the latest DH, thanks in advance

I’m testing the Xiaomi Button with the handler, this is the only type of event I see in the log whenever I press or held the button, is this something normal?

06 pm

Just tried my Xiaomi Push Button and this is what I see in Live Logging

image

I’m using a4refillpad’s Zigbee Button device handler and it works well.

Battery can take a while to show. the only time battery info is sent is in the ‘Catchall’ message.

I can’t be certain but I do wonder whether Catchall is only sent when the sensor has been idle for a certain length of time as a form of check in. Each time a motion event occurs it could be resetting the Catchall timer. I don’t know if this is correct but it could explain why battery % can take a lot longer to appear on some sensors than others.

edit: Scrap that last comment. Thinking more about it I have seen Catchall show in Live Logging even when motion events have been occurring.

Thanks. I’m using the same device handler as well. I also tried remove and re-add the device again but still the same.

So I modified the dht to work with this event only.

The 2 motion sensors I added that showed battery % within an hour or a few hours was using the older DH not the most current DH

I updated some of my device handlers so they can now parse the manufacturer id. This seems to be sent over and over once the device is paired.

Does your dh for aqara motion sensor have Lux reporting as well like Kevin’s?

I don’t have one of those sensors but based on some data from someone I tried to add that logic.

I realized the button I have is from Aqara, so whoever encountered the same, use this DTH

some more data i managed to get out of the Aqara water sensor. I’ve tried to reverse engineer the battery % from @ArstenA handlers, but 10% doesn’t seem right since it is brand new. I also tried cluster 20 and it returned 0. I have a couple more en route i can test with or i’ll even ship one to somebody that knows WTF they are doing :joy:

f49b72e3-51f0-48ba-a89b-4184c1fedf93 1:08:14 PM: debug Parse returned [name:battery, value:10, descriptionText:Dishwasher Water Sensor battery was 10%]
f49b72e3-51f0-48ba-a89b-4184c1fedf93 1:08:14 PM: debug 10
f49b72e3-51f0-48ba-a89b-4184c1fedf93 1:08:14 PM: debug ${linkText} Battery
f49b72e3-51f0-48ba-a89b-4184c1fedf93 1:08:14 PM: debug Battery rawValue = 10
f49b72e3-51f0-48ba-a89b-4184c1fedf93 1:08:14 PM: debug SmartShield(clusterId: 0x0000, command: 0x0a, data: [0x01, 0xff, 0x42, 0x22, 0x01, 0x21, 0xf9, 0x0b, 0x03, 0x28, 0x17, 0x04, 0x21, 0xa8, 0x43, 0x05, 0x21, 0x0b, 0x00, 0x06, 0x24, 0x03, 0x00, 0x02, 0x00, 0x00, 0x08, 0x21, 0x03, 0x02, 0x0a, 0x21, 0x77, 0xfe, 0x64, 0x10, 0x01], destinationEndpoint: 0x01, direction: 0x01, isClusterSpecific: false, isManufacturerSpecific: true, manufacturerId: 0x115f, messageType: 0x00, number: null, options: 0x0100, profileId: 0x0104, senderShortId: 0x7b61, sourceEndpoint: 0x01, text: null)
f49b72e3-51f0-48ba-a89b-4184c1fedf93 1:08:13 PM: debug description: catchall: 0104 0000 01 01 0100 00 7B61 00 04 115F 0A 01 01FF42220121F90B0328170421A84305210B0006240300020000082103020A2177FE641001

The battery percentage on the (2) motion sensors under the old DH but now under the latest DH shows the battery % was last updated on 9/5/2017 in the IDE, still not showing a battery % on the motion detector I paired a day ago with the current DH, just saying.

Could you tell me how you successfully paired the sensor? I’ve read everyone’s posts on their experience, but more is even better…I kept running into the same cycle where I’d press the button, get two fast blinks followed by three short blinks, and that’s it, no matter how many times I pressed it. Until I reset, it would sometimes act a little different to start, but nothing ever showing up in the app, and then back to the two plus three blinks if I continued. I don’t know if I should be waiting longer between button pressed to give it a chance to show up in the app or what…

Really nothing special. I’ll have a paperclip already stuck and left in the hole of the sensor just before I click Add A Thing from ST then I click Add a Thing and press the paperclip in until I see a couple of blue flashes, wait press in paperclip again, blue flashes, repeat by that time if it hasn’t pair you’ll get "It’s taking longer than expected screen, start over Add a Thing and press in again with paperclip, blue flashes, repeat blue light. The most I’ve had to do is like 3 x’s after seeing It’s taking longer than expected…

After I reset, the first couple button pressed usually give me a brighter full light from the sensor, but eventually, it reverts to the 2+3 flash that is much dimmer, maybe jus the because their quicker I don’t know. So I should try stsrting pairing ffrom st app, reset sensor, wait for it to stop all those flashes, then jus the press the buttton once. If it doesn’t show up after that, try again? No repeated attempts of single presses?

I’ve seen the longer press, brighter blue. Go for the shorter presses light blue instead, repeat short presses waiting a 2-3 seconds between short presses.

That’s what I do, and it just keeps giving me the 2 then 3 flashes.

I see your other post that it’s actually reporting in Recent in the ide. Hmmm. I do a couple of presses and the device pairs up for me and able to rename. Not sure why it isn’t working for you. I hope you figure it out. I have the Original Xiaomi Human Body sensors not the other ones with the mount btw. I held off buying a couple of those cuz these were paring up fine for me

That could be the difference. I just successfully (I think) added one with the catchall method, fingers crossed it continues to work

1 Like