Adding OpenWrt support for Xiaomi AX3600 (Part 1)

A commit to openwrt/packages broke this a few days ago: https://github.com/openwrt/packages/commit/2ebe2b1757908ec1742bf794ca843c4a50fa9307

In your build folder, edit packages/net/ieee8021xclient/Makefile, change wpa_supplicant to wpa-supplicant

PR to fix is already open: https://github.com/openwrt/packages/issues/16525, https://github.com/openwrt/packages/pull/16532

3 Likes

Thanks, that fixed that warning. But kernel-headers are still failing to build, so that one must be unrelated.

I can build from the last commits, try running the update script and/or make clean.

I'll try get back to helping, took on a new role at work and it's been insanely busy. :slight_smile:

It's a shame that a lot of the blockers getting the ipq patches into mainline is lack of information from qca, however we could always submit updated versions documented with what we have found. It may be enough to get some of the changes in (or at least worth a shot)

2 Likes

Considering this is a new target and the support is plain shit... We have some hope

Great, well currently the biggest obstacle even when we have something working is upstreaming as QCA maintainers are so slow that it takes months for somebody to look at the patch

1 Like

these steps didn't work for me:

  1. you cannot run ubiformat on both mtd12 and mtd13 while the router is running since one of them is running the os. this is the error that I've got:
    ubiformat: error!: please, first detach mtd13 (/dev/mtd13) from ubi0

  2. about sysupgrade: xiaomi made some changes on their sysupgrade command and it recognizes that the openwrt's firmware isn't correct and refusing to continue with the process.

Probably the 1st point would not affect a router that booted from tftp, but this will require a serial connection.

You can do this while the system is running but you need to reboot into the other root partition.

For future readers, check your actual partition numbers before formatting just in case:
cat /proc/mtd and search for root_fs and root_fs1 or something like that.

Format one partition

ubiformat /dev/mtd12 -y -f /tmp/openwrt-ipq807x-generic-xiaomi_ax3600-squashfs-nand-factory.ubi

Enable UART and boot_wait just in case there are problems.

nvram set uart_en=1
nvram set boot_wait=on
nvram commit

Now you need to boot into the already formatted partition.
First check which partition are you using right now:

nvram get flag_last_success

If flag_last_success=0 you need to set flag_last_success and flag_boot_rootfs to 1 and vice versa.

nvram set flag_last_success=1
nvram set flag_boot_rootfs=1
nvram commit
reboot

Now you should boot into openwrt, from here you can format the second partition.

ubiformat /dev/mtd13 -y -f /tmp/openwrt-ipq807x-generic-xiaomi_ax3600-squashfs-nand-factory.ubi

Now you can sysupgrade normally.

BTW in openwrt the commands to check and change the boot partition are different:

fw_printenv flag_boot_rootfs
fw_setenv flag_boot_rootfs 0
fw_setenv flag_last_success 0
8 Likes

Can confirm it works.
After fixing my device with tftp recovery I managed to reinstall openwrt and now the sysupgrade succeeds.

1 Like

@Ansuel QCA finally pushed 11.4 NSS FW to the QUIC repo, my contact said that he is still working on getting the IPQ806x FW released as well.

Also, this looks interesting:
https://patchwork.kernel.org/project/linux-wireless/patch/20201004100218.311653-2-alex.dewar90@gmail.com/

6 Likes

the patch seems to be related only for the mac setup... the leak is present on something that is called every time so probably not the FIX

Nice about the firmware and finger crossed for ipq806x...

I gotta finally get WLAN working on mainline and see whether there is a leak there, getting close to that.

14 Likes

hope we can finally reach a stable condition... too much time this is stuck on this state. And it's a pitty considering the powerful soc

7 Likes

Yeah, especially with the AX900 being only half usefull due to QCN9024 not working due to too old ath11k

4 Likes

About 12 hours after using my router as AP the wifi crashed and not available anymore.
my config: about 6 wifi clients, and 1 ethernet client (beside the WAN)

before rebooting my router there is any logs that you want me to provide?

1 Like

The output of kernel log (before reboot of the router). You can use "dmesg" command in terminal, or find it in Status -> Kernel log at Luci.

I run now 2 Xiaomi AX3600 Routers together, one as dumb AP. I've setup 2 Wifi networks per Router, all with same SSID and Fast Transition activated, one 2.4 GHz and the other one 5Ghz (Qualcomm Atheros QCA9887 802.11nac). It works now since almost 12h stable with around 38 clients.

New here - looks like some great work has been done.
Which source repo is currently the most stable? A bit hard to workout from the 4000+ posts.

Thanks

Afaik is this one: link
The AX3600-5.10-restart branch.
There is a mem leak with wifi enabled but is usable.

1 Like

I tried to connect my FTDI adapter to a raspberry pi next to the router in order to investigate in case of wifi crashed (my pc is connect wirelessly).
Although the same adapter works fine with my PC, when I attach the adapter to the rpi it blocks the router from rebooting (just hangs until I disconnect the UART).

UPDATE: I tried to access from my PC again (like I did a few days ago) and the router hangs again and refuses to boot (the orange led doesn't even turn on) until I disconnect the adapter. any ideas?