Xiaomi Zigbee Door/Window Sensor, Motion Sensor, & Smart Button Device Type [beta]

How can I install the temperature/humidity sensor?
Which device type do I have to install?



Have you manage to get it to work?


See above.

Dear Fabrizio

I live in florence and i’m a ST newbie!

I believe your are a good expert about ST.

I will still a lor from you :slight_smile:



Hello Brian

How do you add it? I press the button on the device and try to add thing on the app but it does not add.


To add the temperature sensor:

  1. From the app start “Add a thing”
  2. Press and hold the button on the temp sensor until you get 3 flashes
  3. When complete make sure that when you press the button the device give you two flashes on the LED, if not repeat step 2 until that happens.
  4. Using the IDE look at the logs, not the live logging but the hub log (select hub, then select events)
  5. Look for a catchall event at the same time as you pressed and held the button. You will see something like this:
    catchall: 0104 0000 01 01 0100 00 B46D 00 04 115F 0A 01 01FF4231641000032814983900000000953900000000
  6. Make a note of the device ID, in the case above it’s B46D (7th set of chars from the left)
  7. Return to the IDE and manually add a device.
  8. Enter the details and when asked select "Temperature Sensor and make sure you set the Zigbee and network id to the same value you found in step 6.

That should work. The main issue I had was that I was looking in the live log and not the hub log.

Good luck!


Hi all,

Do you think is possible to let a Button become a presence sensor?

Coul be used as keyfob and same time presence sensor.

Because the ST presence sensor is expensive and the batteries drain very fast.

Maybe writing a specific code…

Should be important because Geofancing and presence sensor are to much complicated,

What do you think?

I have thought of that too. But since the button does not regularly ping the hub, you’ll need to physically press the button to send a signal to the hub to let the hub know you’re home. If you can accept the fact that you have to physically click a button, then i guess it will be fine provided the Zigbee device does not drop off the networK being away from the network for a long time

I’m currently planning to develop a Wifi based presence detector using esp8266 but since it uses quite a lot of battery, it needs to be chargeable

1 Like

Thank you Rave your answer arrive very fast and very detailed, i want to link another question regardinf the button.

I actually programmed the button with one click i set the mode ‘home’ and the action i’m back’, with long pressure i set ‘away’ and ‘goodbye’.

It means i activate and deactivate the alarm.

My question is: do you think is possible to set a combination of click to make a specific action?

EG. i press in sequence 3 times the button i activte the alarm, one click then held than one click again i disarm, all of this action combined with a charm of siren then let u know thaat the mode is changed.

It is possible. You just need to code the handler

But i guess it doesn’t make a lot of sense because you already automate the click again unless you put a delay. Let’s say if you click once and there’s no click in 2 second, it will recognize as a click. If you click within 2 second, it can recognize as another action.

But it’s not simple cause you need to write a smart app for that

I’m too much newbie :grin:

The sense is to put outside a button and use a code to disarm the alarm before enter in the home

Then i guess it’s easier to just buy 2 button then…

I see what you’re doing. But i think that’s not a very good idea

I believe on you so i close this topic

I have a weird issue with the temp/humidity sensor. The catchall didn’t quite look right as it showed 0000 for the id. The sensor is sending the temperature and humidity to the log. I put it in the freezer to be sure it wasn’t from something else I have paired and didn’t realize was sending that info. Is there a way to get the correct Id from the data sent. Everything I’ve tried doesn’t work. Thanks for any help.

Edit: I got it. Luckily a raw data event got sent with the zigbee and network id’s.

thanks a lot. It really works…


1 Like

Hi my devices just arrive…

I connect Temperature Sensor on Xiaomi Hub

I got this information from Xiaomi App on Android app

I believe the ID: 158d00010fc280

I removed Temperature Sensor from Xiaomi Hub

I added on IDE

But I can see temperature and Hunmidity

You can always use these instructions to get the temp sensor working:


Hi @brumster, Thank you for this instructions, I tried this too yesterday, I cant see nothing on IDE :(.

I will try again this night.

about step 4 - Using the IDE look at the logs, not the live logging but the hub log (select hub, then select events)

Could confirm this instructions

My Hubs > List Events > Wanting for information…