Xiaomi Gateway V3 not showing in hardware

On various Hardware and OS systems: pi / windows / routers / nas, etc

Moderator: leecollings

Post Reply
Dutch2005
Posts: 1
Joined: Wednesday 15 May 2019 21:11
Target OS: Raspberry Pi / ODroid
Domoticz version: beta
Contact:

Xiaomi Gateway V3 not showing in hardware

Post by Dutch2005 »

Domoticz V4.10717
Build Hash: b38b49e5, Date: 2019-05-09 13:04:08
Startup Path: /opt/domoticz/
PluginSystem: Started, Python version '3.5.3'.

Product: https://aliexpress.com/item/32946410922 ... 4c4dsFi66h
( https://nl.aliexpress.com/item/32946410 ... 4c4dsFi66h )

Log:
2019-05-15 19:21:23.337 Status: Domoticz V4.10717 (c)2012-2019 GizMoCuz
2019-05-15 19:21:23.350 Status: Build Hash: b38b49e5, Date: 2019-05-09 13:04:08
2019-05-15 19:21:23.351 Status: Startup Path: /opt/domoticz/
2019-05-15 19:21:24.301 Status: PluginSystem: Started, Python version '3.5.3'.
2019-05-15 19:21:24.364 Status: WebServer(HTTP) started on address: :: with port 80
2019-05-15 19:21:24.392 Status: WebServer(SSL) started on address: :: with port 443
2019-05-15 19:21:24.406 Status: RxQueue: queue worker started...
2019-05-15 19:21:24.407 Status: TCPServer: shared server started...
2019-05-15 19:21:26.408 Status: P1 Smart Meter: Using serial port: /dev/ttyUSB0
2019-05-15 19:21:26.413 Status: OpenWeatherMap: Started
2019-05-15 19:21:26.415 Status: XiaomiGateway (ID=5): Delaying worker startup...
2019-05-15 19:21:26.415 Status: P1 Smart Meter: Worker started...
2019-05-15 19:21:26.828 Status: P1 Smart Meter: Meter reports as DSMR 5.0
2019-05-15 19:21:26.848 Status: P1 Smart Meter: Found gas meter on M-Bus channel 1
2019-05-15 19:21:31.416 Status: XiaomiGateway (ID=5): Selected as main Gateway
2019-05-15 19:21:31.420 Status: EventSystem: reset all events...
2019-05-15 19:21:31.432 Status: XiaomiGateway (ID=5): Worker started...
2019-05-15 19:21:31.442 Status: EventSystem: reset all device statuses...
2019-05-15 19:21:31.449 Status: XiaomiGateway (ID=5): Using 192.168.3.30 for local IP address.
2019-05-15 19:21:31.786 Status: PluginSystem: Entering work loop.
2019-05-15 19:21:32.111 Status: Python EventSystem: Initalizing event module.
2019-05-15 19:21:32.113 Status: EventSystem: Queue thread started...
2019-05-15 19:21:32.114 Status: EventSystem: Started
2019-05-15 19:26:43.837 Status: Incoming connection from: 192.168.1.163
2019-05-15 19:28:48.834 Status: XiaomiGateway (ID=6): Delaying worker startup...
2019-05-15 19:28:53.834 Status: XiaomiGateway (ID=5): stopped
2019-05-15 19:28:53.837 Status: XiaomiGateway (ID=5): Delaying worker startup...
2019-05-15 19:28:58.838 Status: XiaomiGateway (ID=5): Selected as main Gateway
2019-05-15 19:28:58.841 Status: XiaomiGateway (ID=6): Worker started...
2019-05-15 19:28:58.842 Status: XiaomiGateway (ID=6): Using 192.168.3.30 for local IP address.
2019-05-15 19:28:58.843 Status: XiaomiGateway (ID=5): Worker started...
2019-05-15 19:28:58.844 Status: XiaomiGateway (ID=5): Using 192.168.3.30 for local IP address.
2019-05-15 19:29:05.890 Status: XiaomiGateway (ID=6): stopped
2019-05-15 19:29:05.893 Status: XiaomiGateway (ID=6): Delaying worker startup...
2019-05-15 19:29:10.894 Status: XiaomiGateway (ID=6): Selected as main Gateway
2019-05-15 19:29:10.894 Status: XiaomiGateway (ID=5): stopped
2019-05-15 19:29:10.906 Status: XiaomiGateway (ID=6): Worker started...
2019-05-15 19:29:10.907 Status: XiaomiGateway (ID=6): Using 192.168.3.30 for local IP address.
2019-05-15 19:29:15.545 Status: XiaomiGateway (ID=6): stopped
2019-05-15 19:29:24.511 Status: XiaomiGateway (ID=5): Delaying worker startup...
2019-05-15 19:29:29.511 Status: XiaomiGateway (ID=5): Selected as main Gateway
2019-05-15 19:29:29.514 Status: XiaomiGateway (ID=5): Worker started...
2019-05-15 19:29:29.515 Status: XiaomiGateway (ID=5): Using 192.168.3.30 for local IP address.
2019-05-15 20:00:00.728 Status: Starting automatic database backup procedure...
2019-05-15 20:00:01.283 Status: Ending automatic database backup procedure...
2019-05-15 20:46:19.982 Status: Incoming connection from: 192.168.1.163
2019-05-15 20:46:31.748 Status: New sensors allowed for 5 minutes...
2019-05-15 20:46:50.401 Status: XiaomiGateway (ID=5): stopped
2019-05-15 20:46:50.409 Status: XiaomiGateway (ID=5): Delaying worker startup...
2019-05-15 20:46:55.410 Status: XiaomiGateway (ID=5): Selected as main Gateway
2019-05-15 20:46:55.412 Status: XiaomiGateway (ID=5): Worker started...
2019-05-15 20:46:55.413 Status: XiaomiGateway (ID=5): Using 192.168.3.30 for local IP address.
2019-05-15 20:47:21.489 Status: XiaomiGateway (ID=5): stopped
2019-05-15 20:47:45.334 Status: XiaomiGateway (ID=5): Delaying worker startup...
2019-05-15 20:47:50.334 Status: XiaomiGateway (ID=5): Selected as main Gateway
2019-05-15 20:47:50.336 Status: XiaomiGateway (ID=5): Worker started...
2019-05-15 20:47:50.337 Status: XiaomiGateway (ID=5): Using 192.168.3.30 for local IP address.
2019-05-15 21:00:00.688 Status: Starting automatic database backup procedure...
2019-05-15 21:00:01.151 Status: Ending automatic database backup procedure...
2019-05-15 21:05:56.032 Status: Incoming connection from: 192.168.1.163
Information about the device via Xiaomi Mi App
Version no:245
Gateway ID:132388799
Zigbee Channel:15

Gateway Information:
{"ap":{"bssid":"xx:xx:xx:xx:xx:xx","rssi":-52,
"ssid":"xxxxxx_iot"},
"cfg_time":0,
"fw_ver":"1.4.1_167",
"hw_ver":"MW300",
"life":164,
"mac":"04:CF:8C:97:xx:yy",
"mcu_fw_ver":"0158",
"mmfree":170328,
"model":"lumi.gateway.v3",
"netif":{"gw":"192.168.x.x",
"gw_mac":"xx:xx:xx:xx:xx:xx",
"localIp":"192.168.x.xx",
"mask":"255.xxx.xxx.xxx"},
"ot":"otu",
"ott_stat":[0,0,0,0],
"otu_stat":[445,686,13,0,13,419],
"token":"d1ca4abaf124621a8fecfa8bf6c80367",
"uid":6165567161,
"wifi_fw_ver":"SD878x-14.76.36.p84-702.1.0-WM"}
SubDevice Information:
[No sub-devices added (yet)]
Eternity
Posts: 63
Joined: Saturday 06 December 2014 16:26
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Xiaomi Gateway V3 not showing in hardware

Post by Eternity »

Have you managed to solve this?
I am stuck with the same problem...
Synology DS218+
Homey controller
Z-Wave stuff (Fibaro / Aeotec / NEO Coolcam)
Zigbee stuff (Aqara)
HUE lights
Logitech Harmony Ultimate + Hub
IP camera's
krizzz
Posts: 200
Joined: Wednesday 20 November 2013 20:36
Target OS: Linux
Domoticz version:
Location: The Netherlands
Contact:

Re: Xiaomi Gateway V3 not showing in hardware

Post by krizzz »

There are several topics here were is mentioned that their are issues getting a V3 to play nicely with Domoticz.
The problem most of the times I know about is that the port 9898 which is needed in Domoticz is closed.

The reason why some V3’s do not have this issue, and some do is very unclear.
Probably has to do something with updating the FW before enabling the LAN control.

To check if the 9898 is closed on your device you can check it with a device with the Nmap utility installed, using the command sudo nmap - sU {gateway_ip} -p 9898).


Verzonden vanaf mijn iPhone met Tapatalk
ismo67
Posts: 13
Joined: Friday 21 April 2017 23:21
Target OS: Raspberry Pi / ODroid
Domoticz version: beta
Location: Finland, Kerava
Contact:

Re: Xiaomi Gateway V3 not showing in hardware

Post by ismo67 »

I Hope someone updates Domoticz Wiki as I suppose only old "V2" version Gateway works without this trick:
https://community.openhab.org/t/solved- ... /52963/265
---------------------------- cut with some mods. ----------------
You need:
  • A special bit to open the housing of the gateway.
    I used regular tools...
    It´s called “security bit” .
    Then replace by normal screws of similar size.
    UART to USB tool like CP2102 USB from Aliexpress.
    Maybe the driver to run it.
    PuTTY . A software to send commands via UART to the gateway.
    nmap / zenmap. This software is used to scan the network.
    Soldering equipment
Steps
  • UART and gateway power off.
    Get your gatway running with the xiaomi app.
    Click on the gateway, top right “…” will bring you to settings.
    Click “About”.
    Click 5 times on the white area until the secret menu/developer mode pops up.
    Enable the switch and note or screenshot your password.
    NOTE Screenshot your password!
    Start soldering.
    Connect the blue cable to"GND" on the UART.
    Connect the brown cable to “RXD” (Receiver) on the UART.
    Do NOT connect "TXD".
    Connect UART to Computer.
    Check the device on your device list to find the COM.(Control Panel Devices at Windows )
    If your device doesn´t show the COM number you might need the driver.
    Open PuTTY.
    Select serial and your COM port of the UART.
    Set Speed 115200.
    Don´t open yet.
    Turn on the gateway / connect to power.
    Press open in PuTTY.
    A Window opens.
    You will see the messages of the gateway.
    Wait until the gateway finnished booting.
    NOW Connect the red cable to “TXD” (transmitter) of the UART.
    Now you are able to send commands to the gateway.
    Press few times enter to see:

Code: Select all

#
Send command:

Code: Select all

psm-set network.open_pf 3 
send it a few times to be sure.
Check for success with command

Code: Select all

psm-get network.open_pf

It will say something like networkopen = 3
Turn gateway off.
Wait. Turn it on again.
Open nmap.
Put

Code: Select all

nmap -sU -p 9898 -Pn 192.168.178.48
in the action line and execute.
You have to take your gateways IP adress, not that what is in the example code.
You should see that the port is open. If not, try again.

------------------- cut -------------------
I did this this trick yesterday and now I get the Xiaomi Zigbee Gateway V3 devices to Domoticz!
Please remember to take screenshot of the Xiaomi Gateway password before doing this trick as I for me I cannot open that page at Mi Home app anymore ( maybe not permanent problem, but now I cannot )
Attachments
IMG_20200130_223955.jpg
IMG_20200130_223955.jpg (201.06 KiB) Viewed 3154 times
IMG_20200130_222947~2.jpg
IMG_20200130_222947~2.jpg (392.86 KiB) Viewed 3154 times
IMG_20200130_222615.jpg
IMG_20200130_222615.jpg (252.01 KiB) Viewed 3154 times
Last edited by ismo67 on Friday 31 January 2020 12:47, edited 3 times in total.
Rasperry Pi4, Shelly, Yeelights, Xiaomi, Tuya, Tahoma, ESPEASY, Google Home
User avatar
waaren
Posts: 6028
Joined: Tuesday 03 January 2017 14:18
Target OS: Linux
Domoticz version: Beta
Location: Netherlands
Contact:

Re: Xiaomi Gateway V3 not showing in hardware

Post by waaren »

ismo67 wrote: Friday 31 January 2020 8:58 I Hope someone updates Domoticz Wiki as I suppose only up to V2 version Gateway works without this trick:
Thx ! for sharing this information

The wiki is for and from us all so please feel free to update it.
If you do not have an account yet and experience problems to create an account (some restrictions apply because of recent spam attacks) send a PM to @gizmocuz to create one for you.
Debian buster, bullseye on RPI-4, Intel NUC.
dz Beta, Z-Wave, RFLink, RFXtrx433e, P1, Youless, Hue, Yeelight, Xiaomi, MQTT
==>> dzVents wiki
Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests