I was recently given a Xiaomi Aquara hub from a friend as it was “bricked” due to port “9898” which is used for the API being blocked in a certain firmware release. This meant that the ”
https://www.home-assistant.io/integrations/xiaomi_aqara ” module is unable to communicate with the hub and homeassistant
To get around this problem you can connect and solder a jumper cable to the RX, TX and GND pins on the board, this requires taking the hub apart and doing the following.
- Solder RX,TX,GND to the pins below.
- Connect USB TTL adaptor
- Open Putty
- Select correct COM port that the USB TTL adaptor is connected
- Change Baud rate to 115200
*Make sure you connect the correct pins to the USB TTL*
You should now start seeing message in the terminal as below from the serial connection.
Send the below commands, this will allow the port to be opened.
sm-set network.open_pf 3
psm-get network.open_pf
Power Cycle the gateway.
To Ensure the port has been successfully opened run the below command in Nmap.
nmap -sU -p 9898 192.168.1.13
Starting Nmap 7.40 ( https://nmap.org ) at 2019-11-19 16:48 GMT Standard Time
Nmap scan report for 192.168.1.13
Host is up (0.0025s latency).
PORT STATE SERVICE
9898/udp open monkeycom
MAC Address: 78:11:DC:FA:B8:BF (Unknown)
Nmap done: 1 IP address (1 host up) scanned in 7.05 seconds
Port “9898” has been sucesfully opened we can now add the hub to Homeassistant.
xiaomi_aqara:
discovery_retry: 5
gateways:
- key: xxxxxxxxxxxxxxxx