Xiaomi Gateway (EU Version)

Hi to all,
I’ve purchased a Xiaomi Gateway kit but have some problems with it.
I’ve opened the device and I’ve seen my EU board looks like this: https://community.openhab.org/t/solved-openhab2-xiaomi-mi-gateway-does-not-respond/52963/188?u=cadavre
I’ve not soldered anything for now.
I THINK I’ve got the key (downloaded from iPhone backup, extracted via miio-extract-tokens and then converted the 32 char HEX to 16char ASCII.
After that I’ve cofigured the device like that:

 xiaomi_aqara:
   gateways:
     - mac: 50EC5041B540
       key: <my_key>
       host: 192.168.3.20

After restart, in the logs, I’ve got:

2019-05-22 21:13:57 WARNING (MainThread) [homeassistant.setup] Setup of xiaomi_aqara is taking over 10 seconds.
2019-05-22 21:13:57 ERROR (SyncWorker_6) [xiaomi_gateway] Cannot connect to Gateway
2019-05-22 21:13:57 ERROR (SyncWorker_6) [xiaomi_gateway] No data in response from hub None
2019-05-22 21:13:57 INFO (SyncWorker_6) [xiaomi_gateway] Discovering Xiaomi Devices
2019-05-22 21:14:07 ERROR (SyncWorker_6) [xiaomi_gateway] Cannot connect to Gateway
2019-05-22 21:14:07 INFO (SyncWorker_6) [xiaomi_gateway] Discovering Xiaomi Devices
2019-05-22 21:14:17 ERROR (SyncWorker_6) [xiaomi_gateway] Cannot connect to Gateway
2019-05-22 21:14:17 INFO (SyncWorker_6) [xiaomi_gateway] Discovering Xiaomi Devices
2019-05-22 21:14:27 ERROR (SyncWorker_6) [xiaomi_gateway] Cannot connect to Gateway
2019-05-22 21:14:27 INFO (SyncWorker_6) [xiaomi_gateway] Discovering Xiaomi Devices
2019-05-22 21:14:37 ERROR (SyncWorker_6) [xiaomi_gateway] Cannot connect to Gateway
2019-05-22 21:14:37 INFO (SyncWorker_6) [xiaomi_gateway] Discovering Xiaomi Devices
2019-05-22 21:14:47 ERROR (SyncWorker_6) [xiaomi_gateway] Cannot connect to Gateway
2019-05-22 21:14:52 INFO (SyncWorker_6) [xiaomi_gateway] Gateway discovery finished in 5 seconds
2019-05-22 21:14:52 INFO (SyncWorker_6) [xiaomi_gateway] Creating Multicast Socket
2019-05-22 21:14:52 INFO (MainThread) [homeassistant.setup] Setup of domain xiaomi_aqara took 65.2 seconds.
2019-05-22 21:14:52 INFO (MainThread) [homeassistant.components.binary_sensor] Setting up binary_sensor.xiaomi_aqara
2019-05-22 21:14:52 INFO (MainThread) [homeassistant.components.sensor] Setting up sensor.xiaomi_aqara
2019-05-22 21:14:52 INFO (MainThread) [homeassistant.components.switch] Setting up switch.xiaomi_aqara
2019-05-22 21:14:52 INFO (MainThread) [homeassistant.components.light] Setting up light.xiaomi_aqara
2019-05-22 21:14:52 INFO (MainThread) [homeassistant.components.cover] Setting up cover.xiaomi_aqara
2019-05-22 21:14:52 INFO (MainThread) [homeassistant.components.lock] Setting up lock.xiaomi_aqara
2019-05-22 21:15:35 INFO (MainThread) [homeassistant.components.discovery] Found new service: xiaomi_gw {'host': '192.168.3.20', 'port': 54321, 'hostname': 'lumi-gateway-mieu01_miio264420999.', 'properties': {'path': '/mydevice'}}

And now?
I cannot find any discovered devices under states.
I’m not sure thats the right way.

Thanks, Simon

You could try to go to your Xiaomi home app, there in the settings of the gateway under about press with your finger fast many times and a secret menu will apear.
There you should enable your gateway.

Thanks @Flipso for your reply, but seems there is a problem with that:
The new EU version is able to be registered / accessible only via EU servers. I can setup the device from Cina, so I could have the “About” menu, but the device is not accessible after the initial setup. If I setup it via EU servers, it works, but there is NO “About” menu. :frowning:
Simon

im sorry man, i hope support will come soon. did you manage to get it working now?

That is a very interesting thread.
Seems like someone has hacked the Mi home gateway to send MQTT :slight_smile:

Hi @hijinx and @Flipso
Yep, I’m following the thread and testing the hack.
Until now all is working expect pairing (but seems will come soon). I mean I’ve access to the gateway, which includes light, light sensor, media player (siren, ecc…) and so I can alarm it and disarm it. Here you can find all the details:
https://github.com/home-assistant/home-assistant/issues/22078
Great job from cadavre!
Cheers, Simon

1 Like

Nice.
I have a spare gateway sitting my desk since I moved all my xiaomi sensors to zigbee2mqtt.
Now all I need is time :wink:

So , there is no other way to do this than solder the wires?

AFAIK no. This gives you a first console access to the device, which is required to enable then ssh service.

Moved my sensors to my deconz conbee. Works for me , as i can setup my alexa to play alarm sounds when motion or open door us detected.

I have EU version too. It’s ridiculous that we can’t connect and use with China server (because of error Failed to initialize device (7)), it’s ridiculous that we don’t have radio, it’s ridiculous that’s we don’t have location and weather based triggers, we don’t have About menu to found a key and local connection mode. What can I do? I don’t know. I hope someone to have a solution.

Martin

check this:

Got myself the sensor set with the EU gateway. I already had a bunch of Yeelight bulbs (color, white, old and new) on the Yeelight App and LAN control enabled.

I figured out that my bulbs are on mainland China and the gateway is possible only in non mainland. This sucks as I can’t do any automation without Home Assistant. I tried to add the Bulbs in the non Chinese server and I loose the LAN Control option.

The above hacks looks outside of my skills for now.

So, there’s no hope for the European Version right?

1 Like