OpenWRT works! Many thanks to you all! 
I'll test the router in the next few days to make sure everything functions correctly.
Flashing
Like the previous revision, this router has two bootloaders - the second one of which has to be copied from the original TP-Link firmware into the recovery image.
For this step, I've downloaded the TP-Link firmware image from here.
The length of the boot partition seems to be the same, so the V5 instructions can be used: https://openwrt.org/toh/tp-link/archer_c20_v5#installing_via_tftp
I've only tested flashing via TFTP though (set up TFTP server at 192.168.0.66, then start router with reset button held down until second green LED starts flashing).
Build configuration
I checked out OpenWRT v24.10.5, then made the following changes recommended by @idcrisis:
diff --git a/target/linux/ramips/image/mt76x8.mk b/target/linux/ramips/image/mt76x8.mk
index f1873a794e..a5e7de71fa 100644
--- a/target/linux/ramips/image/mt76x8.mk
+++ b/target/linux/ramips/image/mt76x8.mk
@@ -645,7 +645,7 @@ define Device/tplink_archer-c20-v5
TPLINK_FLASHLAYOUT := 8MSUmtk
TPLINK_HWID := 0xc200005
TPLINK_HWREVADD := 0x5
- DEVICE_PACKAGES := kmod-mt76x0e
+ DEVICE_PACKAGES := kmod-mt7615e kmod-mt7663-firmware-sta
IMAGES := sysupgrade.bin
endef
TARGET_DEVICES += tplink_archer-c20-v5
Here's the build configuration I chose for my image:
CONFIG_TARGET_ramips=y
CONFIG_TARGET_ramips_mt76x8=y
CONFIG_TARGET_ramips_mt76x8_DEVICE_tplink_archer-c20-v5=y
CONFIG_LUCI_SRCDIET=y
CONFIG_PACKAGE_cgi-io=y
CONFIG_PACKAGE_liblua=y
CONFIG_PACKAGE_liblucihttp=y
CONFIG_PACKAGE_liblucihttp-lua=y
CONFIG_PACKAGE_liblucihttp-ucode=y
CONFIG_PACKAGE_libubus-lua=y
CONFIG_PACKAGE_lua=y
CONFIG_PACKAGE_luci=y
CONFIG_PACKAGE_luci-app-firewall=y
CONFIG_PACKAGE_luci-app-package-manager=y
CONFIG_PACKAGE_luci-base=y
CONFIG_PACKAGE_luci-lib-base=y
CONFIG_PACKAGE_luci-lib-ip=y
CONFIG_PACKAGE_luci-lib-json=y
CONFIG_PACKAGE_luci-lib-jsonc=y
CONFIG_PACKAGE_luci-lib-nixio=y
CONFIG_PACKAGE_luci-light=y
CONFIG_PACKAGE_luci-lua-runtime=y
CONFIG_PACKAGE_luci-mod-admin-full=y
CONFIG_PACKAGE_luci-mod-network=y
CONFIG_PACKAGE_luci-mod-rpc=y
CONFIG_PACKAGE_luci-mod-status=y
CONFIG_PACKAGE_luci-mod-system=y
CONFIG_PACKAGE_luci-proto-ipv6=y
CONFIG_PACKAGE_luci-proto-ppp=y
CONFIG_PACKAGE_luci-theme-bootstrap=y
CONFIG_PACKAGE_rpcd=y
CONFIG_PACKAGE_rpcd-mod-file=y
CONFIG_PACKAGE_rpcd-mod-iwinfo=y
CONFIG_PACKAGE_rpcd-mod-luci=y
CONFIG_PACKAGE_rpcd-mod-rpcsys=y
CONFIG_PACKAGE_rpcd-mod-rrdns=y
CONFIG_PACKAGE_rpcd-mod-ucode=y
CONFIG_PACKAGE_ucode-mod-html=y
CONFIG_PACKAGE_ucode-mod-lua=y
CONFIG_PACKAGE_ucode-mod-math=y
CONFIG_PACKAGE_uhttpd=y
CONFIG_PACKAGE_uhttpd-mod-ubus=y
OpenWRT bootlog
This is what the UART output looks like with the OpenWRT firmware flashed:
[05000B0F][05000C0C]
DDR Calibration DQS reg = 00008A87
U-Boot 1.1.3 (Mar 7 2023 - 11:05:20)
Board: Ralink APSoC DRAM: 64 MB
relocate_code Pointer at: 83fac000
gpiomode1 54154404.
gpiomode2 05540554.
gpiomode2 05550555.
flash manufacture id: 20, device id 40 17
Warning: un-recognized chip ID, please update bootloader!
============================================
Ralink UBoot Version: 4.3.0.0
--------------------------------------------
ASIC 7628_MP (Port5<->None)
DRAM component: 512 Mbits DDR, width 16
DRAM bus: 16 bit
Total memory: 64 MBytes
Flash component: SPI Flash
Date:Mar 7 2023 Time:11:05:20
============================================
icache: sets:512, ways:4, linesz:32 ,total:65536
dcache: sets:256, ways:4, linesz:32 ,total:32768
##### The CPU freq = 580 MHZ ####
estimate memory size =64 Mbytes
RESET MT7628 PHY!!!!!!
continue to starting system.
0
U-Boot 1.1.3 (Dec 31 2024 - 14:37:19)
Board: Ralink APSoC DRAM: 64 MB
relocate_code Pointer at: 83fb8000
gpiomode1 54154404.
gpiomode2 00000000.
gpiomode2 05550555.
flash manufacture id: 20, device id 40 17
Warning: un-recognized chip ID, please update bootloader!
============================================
Ralink UBoot Version: 4.3.0.0
--------------------------------------------
ASIC 7628_MP (Port5<->None)
DRAM component: 512 Mbits DDR, width 16
DRAM bus: 16 bit
Total memory: 64 MBytes
Flash component: SPI Flash
Date:Dec 31 2024 Time:14:37:19
============================================
icache: sets:512, ways:4, linesz:32 ,total:65536
dcache: sets:256, ways:4, linesz:32 ,total:32768
##### The CPU freq = 580 MHZ ####
estimate memory size =64 Mbytes
RESET MT7628 PHY!!!!!!
continue to starting system.
0
disable switch phyport...
3: System Boot system code via Flash.(0xbc050000)
do_bootm:argc=2, addr=0xbc050000
## Booting image at bc050000 ...
Uncompressing Kernel Image ... OK
No initrd
Starting kernel ...
[ 0.000000] Linux version 6.6.119 (REDACTED@REDACTED) (mipsel-openwrt-linux-musl-gcc (OpenWrt GCC 13.3.0 r29087-d9c5716d1d) 13.3.0, GNU ld (GNU Binutils) 2.42) #0 Wed Dec 17 21:08:22 2025
[ 0.000000] Board has DDR2
[ 0.000000] Analog PMU set to hw control
[ 0.000000] Digital PMU set to hw control
[ 0.000000] SoC Type: MediaTek MT7628AN ver:1 eco:2
[ 0.000000] printk: bootconsole [early0] enabled
[ 0.000000] CPU0 revision is: 00019655 (MIPS 24KEc)
[ 0.000000] MIPS: machine is TP-Link Archer C20 v5
[ 0.000000] Initrd not found or empty - disabling initrd
[ 0.000000] Primary instruction cache 64kB, VIPT, 4-way, linesize 32 bytes.
[ 0.000000] Primary data cache 32kB, 4-way, PIPT, no aliases, linesize 32 bytes
[ 0.000000] Zone ranges:
[ 0.000000] Normal [mem 0x0000000000000000-0x0000000003ffffff]
[ 0.000000] Movable zone start for each node
[ 0.000000] Early memory node ranges
[ 0.000000] node 0: [mem 0x0000000000000000-0x0000000003ffffff]
[ 0.000000] Initmem setup node 0 [mem 0x0000000000000000-0x0000000003ffffff]
[ 0.000000] Kernel command line: console=ttyS0,115200 rootfstype=squashfs,jffs2
[ 0.000000] Dentry cache hash table entries: 8192 (order: 3, 32768 bytes, linear)
[ 0.000000] Inode-cache hash table entries: 4096 (order: 2, 16384 bytes, linear)
[ 0.000000] Writing ErrCtl register=00004f1e
[ 0.000000] Readback ErrCtl register=00004f1e
[ 0.000000] Built 1 zonelists, mobility grouping on. Total pages: 16256
[ 0.000000] mem auto-init: stack:off, heap alloc:off, heap free:off
[ 0.000000] Memory: 57576K/65536K available (4545K kernel code, 577K rwdata, 740K rodata, 1232K init, 191K bss, 7960K reserved, 0K cma-reserved)
[ 0.000000] SLUB: HWalign=32, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
[ 0.000000] NR_IRQS: 256
[ 0.000000] intc: using register map from devicetree
[ 0.000000] CPU Clock: 580MHz
[ 0.000000] clocksource: MIPS: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 6590553264 ns
[ 0.000002] sched_clock: 32 bits at 290MHz, resolution 3ns, wraps every 7405115902ns
[ 0.007614] Calibrating delay loop... 385.84 BogoMIPS (lpj=1929216)
[ 0.073547] pid_max: default: 32768 minimum: 301
[ 0.086798] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes, linear)
[ 0.093855] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes, linear)
[ 0.111957] RCU Tasks Trace: Setting shift to 0 and lim to 1 rcu_task_cb_adjust=1 rcu_task_cpu_ids=1.
[ 0.127287] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[ 0.136843] futex hash table entries: 256 (order: 0, 3072 bytes, linear)
[ 0.143374] pinctrl core: initialized pinctrl subsystem
[ 0.151800] NET: Registered PF_NETLINK/PF_ROUTE protocol family
[ 0.161656] /pinctrl: Fixed dependency cycle(s) with /pinctrl/pinctrl0
[ 0.434130] PCI host bridge to bus 0000:00
[ 0.438062] pci_bus 0000:00: root bus resource [mem 0x20000000-0x2fffffff]
[ 0.444748] pci_bus 0000:00: root bus resource [io 0x10160000-0x1016ffff]
[ 0.451340] pci_bus 0000:00: No busn resource found for root bus, will use [bus 00-ff]
[ 0.459057] pci 0000:00:00.0: [14c3:0801] type 01 class 0x060400
[ 0.464826] pci 0000:00:00.0: reg 0x10: [mem 0x00000000-0x7fffffff]
[ 0.470882] pci 0000:00:00.0: reg 0x14: [mem 0x00000000-0x0000ffff]
[ 0.476991] pci 0000:00:00.0: supports D1
[ 0.480801] pci 0000:00:00.0: PME# supported from D0 D1 D3hot
[ 0.488312] pci 0000:00:00.0: bridge configuration invalid ([bus 00-00]), reconfiguring
[ 0.496286] pci 0000:01:00.0: [14c3:7663] type 00 class 0x000280
[ 0.502136] pci 0000:01:00.0: reg 0x10: [mem 0x00000000-0x000fffff 64bit pref]
[ 0.509087] pci 0000:01:00.0: reg 0x18: [mem 0x00000000-0x00003fff 64bit pref]
[ 0.516074] pci 0000:01:00.0: reg 0x20: [mem 0x00000000-0x00000fff 64bit pref]
[ 0.523142] pci 0000:01:00.0: supports D1 D2
[ 0.527220] pci 0000:01:00.0: PME# supported from D0 D1 D2 D3hot D3cold
[ 0.533623] pci 0000:01:00.0: 2.000 Gb/s available PCIe bandwidth, limited by 2.5 GT/s PCIe x1 link at 0000:00:00.0 (capable of 4.000 Gb/s with 5.0 GT/s PCIe x1 link)
[ 0.548362] pci_bus 0000:01: busn_res: [bus 01-ff] end is updated to 01
[ 0.554728] pci_bus 0000:00: busn_res: [bus 00-ff] end is updated to 01
[ 0.561171] pci 0000:00:00.0: BAR 0: no space for [mem size 0x80000000]
[ 0.567512] pci 0000:00:00.0: BAR 0: failed to assign [mem size 0x80000000]
[ 0.574251] pci 0000:00:00.0: BAR 9: assigned [mem 0x20000000-0x201fffff pref]
[ 0.581205] pci 0000:00:00.0: BAR 1: assigned [mem 0x20200000-0x2020ffff]
[ 0.587781] pci 0000:01:00.0: BAR 0: assigned [mem 0x20000000-0x200fffff 64bit pref]
[ 0.595249] pci 0000:01:00.0: BAR 2: assigned [mem 0x20100000-0x20103fff 64bit pref]
[ 0.602739] pci 0000:01:00.0: BAR 4: assigned [mem 0x20104000-0x20104fff 64bit pref]
[ 0.610203] pci 0000:00:00.0: PCI bridge to [bus 01]
[ 0.614990] pci 0000:00:00.0: bridge window [mem 0x20000000-0x201fffff pref]
[ 0.623922] clocksource: Switched to clocksource MIPS
[ 0.642152] NET: Registered PF_INET protocol family
[ 0.647296] IP idents hash table entries: 2048 (order: 2, 16384 bytes, linear)
[ 0.655430] tcp_listen_portaddr_hash hash table entries: 1024 (order: 0, 4096 bytes, linear)
[ 0.663593] Table-perturb hash table entries: 65536 (order: 6, 262144 bytes, linear)
[ 0.671119] TCP established hash table entries: 1024 (order: 0, 4096 bytes, linear)
[ 0.678504] TCP bind hash table entries: 1024 (order: 1, 8192 bytes, linear)
[ 0.685323] TCP: Hash tables configured (established 1024 bind 1024)
[ 0.691634] UDP hash table entries: 256 (order: 0, 4096 bytes, linear)
[ 0.697994] UDP-Lite hash table entries: 256 (order: 0, 4096 bytes, linear)
[ 0.705699] NET: Registered PF_UNIX/PF_LOCAL protocol family
[ 0.711276] PCI: CLS 0 bytes, default 32
[ 0.721422] workingset: timestamp_bits=30 max_order=14 bucket_order=0
[ 0.728110] squashfs: version 4.0 (2009/01/31) Phillip Lougher
[ 0.733700] jffs2: version 2.2 (NAND) (SUMMARY) (LZMA) (RTIME) (CMODE_PRIORITY) (c) 2001-2006 Red Hat, Inc.
[ 0.748136] mt7621_gpio 10000600.gpio: registering 32 gpios
[ 0.753990] mt7621_gpio 10000600.gpio: registering 32 gpios
[ 0.759765] mt7621_gpio 10000600.gpio: registering 32 gpios
[ 0.766049] Serial: 8250/16550 driver, 3 ports, IRQ sharing disabled
[ 0.774708] printk: console [ttyS0] disabled
[ 0.779492] 10000c00.uart0: ttyS0 at MMIO 0x10000c00 (irq = 28, base_baud = 2500000) is a 16550A
[ 0.788087] printk: console [ttyS0] enabled
[ 0.788087] printk: console [ttyS0] enabled
[ 0.796512] printk: bootconsole [early0] disabled
[ 0.796512] printk: bootconsole [early0] disabled
[ 0.825921] spi-mt7621 10000b00.spi: sys_freq: 193333333
[ 0.838478] spi-nor spi0.0: XM25QH64C (8192 Kbytes)
[ 0.843679] 7 fixed-partitions partitions found on MTD device spi0.0
[ 0.850327] OF: Bad cell count for /palmbus@10000000/spi@b00/flash@0/partitions
[ 0.857826] OF: Bad cell count for /palmbus@10000000/spi@b00/flash@0/partitions
[ 0.865672] Creating 7 MTD partitions on "spi0.0":
[ 0.870562] 0x000000000000-0x000000030000 : "factory-uboot"
[ 0.880331] 0x000000030000-0x000000050000 : "boot"
[ 0.888028] 0x000000050000-0x0000007c0000 : "firmware"
[ 0.896510] 2 tplink-fw partitions found on MTD device firmware
[ 0.902559] Creating 2 MTD partitions on "firmware":
[ 0.907676] 0x000000000000-0x0000001c7cd3 : "kernel"
[ 0.912718] mtd: partition "kernel" doesn't end on an erase/write block -- force read-only
[ 0.923739] 0x0000001c7cd4-0x000000770000 : "rootfs"
[ 0.928892] mtd: partition "rootfs" doesn't start on an erase/write block boundary -- force read-only
[ 0.940753] mtd: setting mtd4 (rootfs) as root device
[ 0.946093] 1 squashfs-split partitions found on MTD device rootfs
[ 0.952377] 0x0000005c0000-0x000000770000 : "rootfs_data"
[ 0.960613] 0x0000007c0000-0x0000007d0000 : "config"
[ 0.968430] 0x0000007d0000-0x0000007e0000 : "rom"
[ 0.976086] OF: Bad cell count for /palmbus@10000000/spi@b00/flash@0/partitions
[ 0.984068] 0x0000007e0000-0x0000007f0000 : "romfile"
[ 0.991906] 0x0000007f0000-0x000000800000 : "radio"
[ 1.000174] OF: Bad cell count for /palmbus@10000000/spi@b00/flash@0/partitions
[ 1.042742] rt3050-esw 10110000.esw: mediatek esw at 0xb0110000, irq 25 initialized
[ 1.051709] mtk_soc_eth 10100000.ethernet eth0: mediatek frame engine at 0xb0100000, irq 5
[ 1.063512] NET: Registered PF_INET6 protocol family
[ 1.076439] Segment Routing with IPv6
[ 1.080339] In-situ OAM (IOAM) with IPv6
[ 1.084587] NET: Registered PF_PACKET protocol family
[ 1.089755] 8021q: 802.1Q VLAN Support v1.8
[ 1.137228] clk: Disabling unused clocks
[ 1.156273] VFS: Mounted root (squashfs filesystem) readonly on device 31:4.
[ 1.170411] Freeing unused kernel image (initmem) memory: 1232K
[ 1.176466] This architecture does not have kernel memory protection.
[ 1.183012] Run /sbin/init as init process
[ 4.889028] init: Console is alive
[ 4.893066] init: - watchdog -
[ 5.136324] rt3050-esw 10110000.esw: port 4 link up
[ 7.540549] kmodloader: loading kernel modules from /etc/modules-boot.d/*
[ 8.248757] gpio_button_hotplug: loading out-of-tree module taints kernel.
[ 8.271962] kmodloader: done loading kernel modules from /etc/modules-boot.d/*
[ 8.290224] init: - preinit -
[ 15.823960] random: crng init done
[ 18.509070] rt3050-esw 10110000.esw: port 4 link down
Press the [f] key and hit [enter] to enter failsafe mode
Press the [1], [2], [3] or [4] key and hit [enter] to select the debug level
[ 22.534413] rt3050-esw 10110000.esw: port 4 link up
[ 24.454551] jffs2: notice: (372) jffs2_build_xattr_subsystem: complete building xattr subsystem, 8 of xdatum (0 unchecked, 2 orphan) and 9 of xref (2 dead, 0 orphan) found.
[ 24.472859] mount_root: switching to jffs2 overlay
[ 24.480800] overlayfs: upper fs does not support tmpfile.
[ 24.498514] urandom-seed: Seeding with /etc/urandom.seed
[ 24.598872] procd: - early -
[ 24.602175] procd: - watchdog -
[ 25.950338] procd: - watchdog -
[ 25.956116] procd: - ubus -
[ 26.990163] procd: - init -
Please press Enter to activate this console.
[ 32.186315] kmodloader: loading kernel modules from /etc/modules.d/*
[ 34.569685] Loading modules backported from Linux version v6.12.61-0-gdcbeffaf66d0
[ 34.577475] Backport generated by backports.git v6.1.110-1-35-g410656ef
[ 35.178687] mt76_wmac 10300000.wmac: ASIC revision: 76280001
[ 35.975934] mt76_wmac 10300000.wmac: Firmware Version: 20151201
[ 35.981985] mt76_wmac 10300000.wmac: Build Time: 20151201183641
[ 36.089407] urngd: v1.0.2 started.
[ 36.093305] mt76_wmac 10300000.wmac: firmware init done
[ 36.266628] mt76_wmac 10300000.wmac: registering led 'mt76-phy0'
[ 36.712374] mt7615e 0000:01:00.0: card - bus=0x1, slot = 0x0 irq=4
[ 36.994859] mt7615e 0000:01:00.0: registering led 'mt76-phy1'
[ 37.084022] mt7615e 0000:01:00.0: HW/SW Version: 0x65326363, Build Time: 2005101654debug
[ 37.084022]
[ 37.152035] mt7615e 0000:01:00.0: N9 Firmware Version: 7663mp1827, Build Time: 20200512032642
[ 37.160813] mt7615e 0000:01:00.0: Region number: 0x4
[ 37.165868] mt7615e 0000:01:00.0: Parsing tailer Region: 0
[ 37.227517] mt7615e 0000:01:00.0: Region 0, override_addr = 0x00118000
[ 37.234228] mt7615e 0000:01:00.0: Parsing tailer Region: 1
[ 37.280075] mt7615e 0000:01:00.0: Parsing tailer Region: 2
[ 37.297403] PPP generic driver version 2.4.2
[ 37.325632] mt7615e 0000:01:00.0: Parsing tailer Region: 3
[ 37.334383] mt7615e 0000:01:00.0: override_addr = 0x00118000, option = 3
[ 37.345274] NET: Registered PF_PPPOX protocol family
[ 37.414425] kmodloader: done loading kernel modules from /etc/modules.d/*
[ 68.313141] rt3050-esw 10110000.esw: port 4 link down
[ 72.387978] rt3050-esw 10110000.esw: port 4 link up
[ 79.874744] br-lan: port 1(eth0.1) entered blocking state
[ 79.880275] br-lan: port 1(eth0.1) entered disabled state
[ 79.885896] eth0.1: entered allmulticast mode
[ 79.890334] mtk_soc_eth 10100000.ethernet eth0: entered allmulticast mode
[ 79.897659] eth0.1: entered promiscuous mode
[ 79.902031] mtk_soc_eth 10100000.ethernet eth0: entered promiscuous mode
[ 80.670949] br-lan: port 1(eth0.1) entered blocking state
[ 80.676555] br-lan: port 1(eth0.1) entered forwarding state