Xiaomi Gateway no Longer connecting on latest firmware - "Invalid Config"

Glad to help, no problem.
A cc2531 should be fine in a small flat. The combination of cc2530 + cc2591 is of a coordinator and an signal enhancer. The explanation of the cc2591 is: “Power Amplifier (PA) for higher output power and a Low Noise Amplifier (LNA) for improved receiver sensitivity.” See link.
One more tip/advice: I use an 1 mtr USB cable between the Pi and the cc2531 because Wifi, Zigbee (and also Bluetooth) use the same radiofrequency (2.4 Ghz) and can interfere. It works better in my experience and is a tiny investment. Good luck!

Great, will definitely use a usb extension from the usb hub because the rpi is located in a very corner area near lots of computer equipment which might interfere. I will raise the board and put it next to my RF Link legacy arduino receiver (behind a shelf) :slight_smile:

Anything new?
Sadly I’ve upgraded before finding this thread :frowning:

It feels like xiaomi switched the gateway to miio with version 161.

PORT      STATE         SERVICE
4321/udp  closed        rwhois
9898/udp  closed        monkeycom
54321/udp open|filtered bo2k

Looks like the mi home app for iOS won’t let you use it unless you update the firmware.

So I can’t add any new devices until we have a solution here :frowning:

You can follow this instruction.

Or this one.

1 Like

I also ran into this and decided to update the firmware. After doing so, I kept getting an error ‘unable to obtain’ when trying to generate a key. I restarted the hub and then it worked. Everything seems to be working again.

Hi guys. I see I’m not alone. I bought the gayeway few days ago and updated it to latest firmware even before I activated lan access. So now I can’t connect it to hass because enabling of wireless communication protocol has no effect. Ports 9898 and 4123 stay closed no matter I do. I tried enable\disable and key regeneration a lot of times but no luck. It looks like we will have to wait for the next firmware update where xiaomi hopefully fix the issue…

If xiaomi have removed this functionality, then the prospect of them putting it back is minimal IMHO.

Don’t know what the best way to ask xiaomi to fix the access. I used Feedback feature from Mi Home app (enter gateway in the app and open menu with button … -> General Settings -> Feedback). I believe the more people write them – more chance to get it fixed soon. The issue is really frustrating…

1 Like

Agreeing with this.

Hope that everybody writes Xiaomi. Especially since some people report the gateway to be working fine after a while of resetting etc. If that really is the case, and why wouldn’t it be, it is a strong hint that Xiaomi has not disabled the functionality, which means that likely a bug is in the firmware.

This topic https://www.reddit.com/r/homeassistant/comments/a4tl9m/xiaomi_aqara_gateway_connection_problems_when/ suggests problems might occur when you are blocking the internet access of the gateway. Which might make sense. They don’t like to sell cheap quality products but lose control of it.

Can’t confirm. Didn’t block anything from or too xiaomi. The communication port is simply closed.
Seen that someone wrote about 164 firmware. Anyone has experience with it? This firmware isn’t provided on both of my gateways :frowning:

1 Like

No problem with connecting the hub to my wifi on 164. Although with the 164 firmware on the hub I can’t add any new ZigBee devices. At least one more person has confirmed having the same issue.
Would be great if someone else could confirm if you have updated and CAN or CAN’T add new devices.

As stated above, try using the HASS xiaomi add device service

Thank you for your suggestion although I’ve tried that several times.

Guys, it’s cool to hear that you managed to receive firmware updates! Is there any way to get it faster? I’m still
with 1.4.1_161.0143 and my MiHome app says that it is the latest version. Should I use some VPN or proxy? Is it necessary for MiHome app or gateway itself? Could you please advise some working China VPN you used etc.?

Thanks in advance

I didn’t need to use any VPN to update but I use PIA VPN service for other stuff.
Only thing I did that might have speed up my update roll out(although I don’t think so) is I reported an issue about the firmware under help & feedback in the Mi Home app.

Thanks SweAdelpha!
I’ve received 1.4.1_161.0158 update today but still can’t connect from hass to my gateway :frowning: Any luck from anybody else?

Same mate new firmware, still cant connect it to HA

My Hub also stopped working after firmware upgrade. I’ve managed to make it working after a lot of retries using this config:

xiaomi_aqara:
  discovery_retry: 10
  gateways:
    - mac: !secret xiaomi_mac
      key: !secret xiaomi_key
      host: !secret xiaomi_ip