Table of Contents

ASUS RT-AX52

The RT-AX52 is a Dual Band WiFi 6 router based on the MediaTek Filogic SoC with a dual-core ARM Cortex-A53 @ 1.3 GHz, featuring three 1Gbit LAN ports and one 1Gbit WAN port.

asus23_022-03.jpg asus23_022-01.jpg

Supported Versions

Hardware Highlights

Installation

Vendor-UI Method

:!: The installation will only work if your device is unused, or been reset prior to attempting to install OpenWRT.

Note: If your router doesn't accept the TRX image, and boots back into the stock firmware, use the ASUS Firmware Restoration tool available at Asus' RT-AX52 support page (OEM link in the table above), to downgrade to the oldest firmware available, retry the OpenWRT image afterwards.

Asus restoration tool Windows

Follow this guide on how to use the ASUS tool. You will need to hold the RESET button during powerup, until the LED blinks slowly, before you can use the tool.

Asus restoration DIY Linux

If you are on Linux you can emulate the ASUS' tool by executing commands from the prompt. Supposing your network card is eth0 you paste the commands one by one, you can take your time between the lines, and check that the ping does work, which means that the previous commands worked and it's going to accept the image, I'm using atftp here but you can use whatever tftp you like best, just make sure the upload is in binary mode:

ifconfig eth0 192.168.1.10

ip r add 255.255.255.255 dev eth0

echo -e -n "\x0\x01ASUSSPACELINK1\x1\xA8\xC0\x0octet\x0"|socat - UDP4:255.255.255.255:69,broadcast

ping -c 1 192.168.1.49

atftp --put -l RT-AX52_3.0.0.4_388_32682-g6115f25.trx -r ASUSSPACELINK 192.168.1.49

TFTP Method

  $ setenv ipaddr 192.168.1.1
  $ setenv serverip 192.168.1.70
  $ tftpboot 0x46000000 rtax52.bin
  $ bootm 0x46000000
  $ sysupgrade -n <path-to-sysupgrade.bin>

or browse to http://192.168.1.1/cgi-bin/luci/admin/system/flash , upload asus_rt-ax52-squashfs-sysupgrade.bin file to router.

Revert to stock firmware:

Using facinstall

Using TFTP

  $: ubi remove linux
  $: ubi remove jffs2
  $: ubi remove rootfs
  $: ubi remove rootfs_data
  $: ubi create linux 0x45fe000
  $: reset

then the dut will reboot, interrupt the autoboot process by pressing '2' when prompted.

  2: Load System code then write to Flash via TFTP.
  Warning!! Erase Linux in Flash then burn new one. Are you sure?(Y/N)
  $: enter y

you will see the follow, type enter directly:

  Input device IP (192.168.1.1) ==:
  Input server IP (192.168.1.70) ==:
  Input Linux Kernel filename (RT-AX52.trx) ==:

Upgrading OpenWrt

FIXME Missing content!

→ generic.sysupgrade

Debricking

Asus Firmware Restoration tool can recover a bricked device:

https://www.asus.com/networking-iot-servers/wifi-routers/asus-wifi-routers/rt-ax52/helpdesk_download?model2Name=RT-AX52

Configuration

Set WiFi country code

Before enabling each SSID set your Country Code to ensure the correct WiFi channels and transmit power are used:

  1. In LuCI go to Network → Wireless
  2. Click “Edit” on the SSID you want to enable
  3. Select your “Country Code” from the dropdown
  4. Save and Apply

Alternatively, set via SSH with iw reg set.

Hardware Acceleration

MediaTek supports hardware acceleration for their SoCs which increases throughput and greatly reduces load off the CPU. It does this by processing traffic on their Packet Processing Engine (aka Network Accelerator). The downside to this approach is it cannot be used in combination with QoS features such as SQM and AQL. This is not enabled by default in OpenWrt. To enable, read below.

Hardware Flow Offloading

HFO enables hardware offloading of routing/NAT packets. The caveat being it is incompatible with SQM. This can be enabled via /etc/config/firewall or in LuCI as follows:

  1. Network → Firewall → Flow offloading type → Hardware flow offloading
  2. Save and Apply

Wireless Ethernet Dispatch

FIXME Link points to GL.iNet GL-MT6000 topic due to lack of testing on ASUS RT-AX52! WED not tested on ASUS RT-AX52.

WED enables hardware offloading of wireless traffic. The caveat being it will also bypass AQL which may result in higher WiFi latency. This feature is not yet available in LuCI. To enable it, use the command line:

  1. SSH: nano /etc/modules.conf
  2. Append: options mt7915e wed_enable=Y
  3. Save and reboot

To check if WED is enabled, the following module will return either Y or N (yes or no): cat /sys/module/mt7915e/parameters/wed_enable

To check traffic offloaded to the PPEs for wired and wireless, cat ppe0/ppe1 bind/status, e.g.: cat /sys/kernel/debug/ppe0/bind.

Other Performance Features

Packet Steering may be enabled for single-core or multi-core. Note that with HFO enabled instead this will not matter as flows are offloaded. Irqbalance may be used as well, this will not affect bandwidth however may help with other tasks. While these can be enabled via SSH using LuCI is described below:

  1. Packet Steering: Network → Interfaces → Global Network Options → Packet Steering: Enabled (all CPUs), RPS: enabled with suggested setting.
  2. Irqbalance: install the luci-app-irqbalance package and enable on: Services → irqbalance.
  3. Save and Apply.

Adjusting AQL

FIXME Link points to GL.iNet GL-MT6000 topic due to lack of testing on ASUS RT-AX52! Changing AQL limits works.

This device uses the mt76 mac80211 wifi driver which supports AQL. While the default values are sensible, reducing TX queue limits can improve latency, albeit with a reduction in peak throughput. See forum post for adjusting AQL limits showing limits in the 1500-2500 range yield the lowest latency results. As always with WiFi, results will vary due to a variety of clients, frequencies, obstructions, etc. As noted above this cannot be used with WED enabled.

Check current AQL limits: cat /sys/kernel/debug/ieee80211/phy*/aql_txq_limit

Example for setting different limits on both radios:
for ac in 0 1 2 3; do echo $ac 2500 8500 > /sys/kernel/debug/ieee80211/phy0/aql_txq_limit; done
for ac in 0 1 2 3; do echo $ac 2500 8500 > /sys/kernel/debug/ieee80211/phy1/aql_txq_limit; done

To retain configuration after reboot save to /etc/rc.local:

# AQL Tweaks
aql_txq_limit_l=2500
aql_txq_limit_h=8500
for ac in 0 1 2 3; do echo $ac $aql_txq_limit_l $aql_txq_limit_h > /sys/kernel/debug/ieee80211/phy0/aql_txq_limit; done
for ac in 0 1 2 3; do echo $ac $aql_txq_limit_l $aql_txq_limit_h > /sys/kernel/debug/ieee80211/phy1/aql_txq_limit; done

Access Point mode

If configuring this device to function only as a wireless access point (dumb AP) follow the bridgedap guide and consider leaving hardware acceleration features off as explained below.

Flow Offloading

A dumb AP does not perform routing/NAT since it is on the same LAN as the router. Flow offloading (SFO and HFO) will therefore have no impact, better to leave these off.

WED

Since a dumb AP does not perform other functions there is plenty of CPU headroom, therefore WiFi will typically have lower latency by leaving WED disabled so it will utilize AQL. Nevertheless if you would like to use WED, enable it as described above, then install the bridger package which does some BPF (Berkeley Packet Filter) magic to track and offload bridged streams. Optionally, edit /etc/config/bridger and define a device or bridge to exclude from bridge forwarding acceleration.

Hardware

Info

Photos

PCB:

dbab3c70072d922050e3cd862038f56857b36381.jpeg

Tags

How to add tags