# Xiaomi devices hacks

**URL:** <https://community.homey.app/t/xiaomi-devices-hacks/1321>\
**Category:** Devices\
**Tags:** tools\
**Created:** [September 7, 2018, 8:59pm UTC](https://community.homey.app/t/xiaomi-devices-hacks/1321 "2018-09-07T20:59:19Z")\
**Posts on this page:** 12\
**Page:** 1

<div class="post-metadata">

**Author:** ![Wessel](https://avatars.discourse-cdn.com/v4/letter/w/53a042/32.png) [@Wessel](https://community.homey.app/u/Wessel)\
**Post date:** [September 7, 2018, 8:59pm UTC](https://community.homey.app/t/xiaomi-devices-hacks/1321/1 "2018-09-07T20:59:19Z")

</div>

There was a threat started on the old forum about Xiaomi Hacks.  
Thanks to @bullseye1977

“Pretty new to all the homey possibilities. What i created is a cheap proof of concept zigbee wall switch.  
Bought a “puls drukker” at the local Hornbach and soldered the switch to the internal contacts of the Xiaomi Aqara Smart Wireless Switch. Now i can select 4 scenes with this wall switch (on - off - dim 20% - sexy time) of my phillips Hue / Ikea lighting.  
Nice thing it fits my current wall switches and i have one uniform look on the wall.”

![2018-09-07%2022_53_01-Xiaomi%20devices%20hacks%20%E2%80%94%20Athom%20Community%20Forum](https://us1.discourse-cdn.com/flex025/uploads/athom/original/1X/66fbffb1999da100509cb740b28eb2344e6c00a3.jpeg)  
 ![2018-09-07%2022_53_20-Xiaomi%20devices%20hacks%20%E2%80%94%20Athom%20Community%20Forum](https://us1.discourse-cdn.com/flex025/uploads/athom/original/1X/98f90b3cd6decbbdf1b04e72ab8f373dd84c5910.png)

There where a lot of people interested in the schema to connect the “puls drukker”.  
I’ve take a multimeter and came with this conclusion:  
Connect the “puls drukker” on the two holes.

 ![IMG20180907224216](https://us1.discourse-cdn.com/flex025/uploads/athom/original/1X/d8babd3334a8e61e5271c2c7100a4f343844fcdf.jpeg)

---

<div class="post-metadata">

**Author:** ![vaderag](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/vaderag/32/150_2.png) [@vaderag](https://community.homey.app/u/vaderag)\
**Post date:** [September 9, 2018, 10:49am UTC](https://community.homey.app/t/xiaomi-devices-hacks/1321/2 "2018-09-09T10:49:10Z")

</div>

I am VERY interested in this (UK switch tho)  
Presumably a momentary switch right?

More detail you can give as I’d love to get this hooked up to a lightswitch for the UK!!

---

<div class="post-metadata">

**Author:** ![Robin\_van\_Kekem](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/robin_van_kekem/32/8187_2.png) [@Robin\_van\_Kekem](https://community.homey.app/u/Robin_van_Kekem)\
**Post date:** [September 10, 2018, 9:07am UTC](https://community.homey.app/t/xiaomi-devices-hacks/1321/3 "2018-09-10T09:07:22Z")

</div>

Yes: “Pulsdrukker” is Dutch for momentary switch 😉

---

<div class="post-metadata">

**Author:** ![PhilS](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/phils/32/12941_2.png) [@PhilS](https://community.homey.app/u/PhilS)\
**Post date:** [September 10, 2018, 10:00am UTC](https://community.homey.app/t/xiaomi-devices-hacks/1321/4 "2018-09-10T10:00:03Z")

</div>

I would like to see how i connect the two cables from th switch to the xiaomi device. Door sensor or one button-switch.

Is this possible?  
Thx

---

<div class="post-metadata">

**Author:** ![Wessel](https://avatars.discourse-cdn.com/v4/letter/w/53a042/32.png) [@Wessel](https://community.homey.app/u/Wessel)\
**Post date:** [September 10, 2018, 11:38am UTC](https://community.homey.app/t/xiaomi-devices-hacks/1321/5 "2018-09-10T11:38:26Z")

</div>

On the old forum are pictures including the switch:

> **[Xiaomi devices hacks](https://forum.athom.com/discussion/5484/xiaomi-devices-hacks)**
>
> Pretty new to all the homey possibilities. What i created is a cheap proof of concept zigbee wall switch.

  
You have to connect the two wires on the L and N from the switch.

---

<div class="post-metadata">

**Author:** ![PhilS](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/phils/32/12941_2.png) [@PhilS](https://community.homey.app/u/PhilS)\
**Post date:** [September 10, 2018, 11:41am UTC](https://community.homey.app/t/xiaomi-devices-hacks/1321/6 "2018-09-10T11:41:12Z")

</div>

yes i know, but i was interessted how you connect it at the xiaomi device 😉

---

<div class="post-metadata">

**Author:** ![vaderag](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/vaderag/32/150_2.png) [@vaderag](https://community.homey.app/u/vaderag)\
**Post date:** [September 11, 2018, 2:27pm UTC](https://community.homey.app/t/xiaomi-devices-hacks/1321/7 "2018-09-11T14:27:27Z")

</div>

How did you get it out of the casing?

---

<div class="post-metadata">

**Author:** ![TedTolboom](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/tedtolboom/32/12081_2.png) [@TedTolboom](https://community.homey.app/u/TedTolboom)\
**Post date:** [September 11, 2018, 2:33pm UTC](https://community.homey.app/t/xiaomi-devices-hacks/1321/8 "2018-09-11T14:33:53Z")

</div>

> [@Wessel](#):
>
> ![IMG20180907224216](https://us1.discourse-cdn.com/flex025/uploads/athom/original/1X/d8babd3334a8e61e5271c2c7100a4f343844fcdf.jpeg)

@vaderag Xiaomi / Aqara typically use the same connections to fix the housing parts… 2 sides with 1 clamp and 2 sides with 2 clamps.  
If you gently use a sharp knife you can unclamp the clamps at 2-3 positions and then you are able to open the housing

---

<div class="post-metadata">

**Author:** ![vaderag](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/vaderag/32/150_2.png) [@vaderag](https://community.homey.app/u/vaderag)\
**Post date:** [September 11, 2018, 2:44pm UTC](https://community.homey.app/t/xiaomi-devices-hacks/1321/9 "2018-09-11T14:44:56Z")

</div>

Great, thanks.

And, presumably, it doesnt matter which way i connect these little holes, just that they are connected, right?  
[edit] answering my own question… of course it doesnt.

Just managed to whack it together - my soldering skills are terrible, my soldering iron too big and I nearly de-soldered a piece next to the holes, but it’s working and held together with electrical tape  
Can’t get the back on the thing again since i have the wires poking out a hole so the battery is held in with tape too.  
Also the actual button seems to be stuck depressed so that a sqeeze of the unit activates it. No idea how that’s happened!

But, it works.  
Momentary switch on it’s way so wiring it in when it arrives and I should be in business 🙂

---

<div class="post-metadata">

**Author:** ![vaderag](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/vaderag/32/150_2.png) [@vaderag](https://community.homey.app/u/vaderag)\
**Post date:** [September 12, 2018, 1:33pm UTC](https://community.homey.app/t/xiaomi-devices-hacks/1321/10 "2018-09-12T13:33:31Z")

</div>

Has anyone come across a small inline switch or terminal block that has a switch which could sit inside the light fitting alongside this?

I don’t particularly want to hard wire the switch since resetting the bulbs requires multiple clicks, and while it doesnt happen often i’d like to be able to do it if needed…

---

<div class="post-metadata">

**Author:** ![Wessel](https://avatars.discourse-cdn.com/v4/letter/w/53a042/32.png) [@Wessel](https://community.homey.app/u/Wessel)\
**Post date:** [April 12, 2020, 1:44pm UTC](https://community.homey.app/t/xiaomi-devices-hacks/1321/11 "2020-04-12T13:44:12Z")

</div>

The round switch has more triggers, the long is press extra. So today I created a switch for in the wall, behind a momentary switch.

Here a picture with the soldering points:

 ![IMG_20200412_153946_1_1](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/8/c/8c026b32939c9fc8d7996f6a7c2277e2fc25020b.jpeg)

This is the product label:

 ![IMG_20200412_154228_1](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/1/8/182382eb8c0e4d4a9bc5279a6a3879eb34ba55ab.jpeg)

---

<div class="post-metadata">

**Author:** ![jaron](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/jaron/32/34924_2.png) [@jaron](https://community.homey.app/u/jaron)\
**Post date:** [July 12, 2021, 10:19am UTC](https://community.homey.app/t/xiaomi-devices-hacks/1321/12 "2021-07-12T10:19:06Z")

</div>

Awesome hack! Thanks!

I couldnt find a product that offers zwave or zigbee with battery and that can be build in behind a normal momentary (pulsdrukker) switch (in my case Berker switch). This solution is great.

I can confirm it also works with model WXKG11LM, can be bought at Amazon: [https://www.amazon.nl/gp/product/B07D19YXND/](https://www.amazon.nl/gp/product/B07D19YXND/)

The soldering wasnt easy for me (first timer), but I got it in the end and it works perfect.

I made 4 flows to mimic the Fibaro Dimmer 2: 1 press (on/off), long press (true=dim up, set bool==false), long press again (false=dim down, set bool==true), release (stop dimming)
