From a5e085b57c02fe75b3b831719217e8f0efd22bd5 Mon Sep 17 00:00:00 2001 From: Dark4MD Date: Tue, 29 Jun 2021 11:02:15 +0200 Subject: [PATCH] ramips-mt7621: add Xiaomi Mi Router 4A (Gigabit Edition) Specifications: - SoC: MediaTek MT7621 - Flash: 16 MiB NOR SPI - RAM: 128 MiB DDR3 - Ethernet: 3x 10/100/1000 Mbps (switched, 2xLAN + WAN) - WIFI0: MT7603E 2.4GHz 802.11b/g/n - WIFI1: MT7612E 5GHz 802.11ac - Antennas: 4x external (2 per radio), non-detachable - LEDs: Programmable "power" LED (two-coloured, yellow/blue) Non-programmable "internet" LED (shows WAN activity) - Buttons: Reset Installation: Bootloader won't accept any serial input unless "boot_wait" u-boot environment variable is changed to "on". Vendor firmware won't accept any serial input until "uart_en" is set to "1". Using the https://github.com/acecilia/OpenWRTInvasion exploit you can gain access to shell to enable these options: To enable uart keyboard actions - 'nvram set uart_en=1' To make uboot delay boot work - 'nvram set boot_wait=on' Set boot delay to 5 - 'nvram set bootdelay=5' Then run 'nvram commit' to make the changes permanent. Once in the shell (following the OpenWRTInvasion instructions) you can then run the following to flash OpenWrt and then reboot: 'cd /tmp; curl https://downloads.openwrt.org/...-sysupgrade.bin --output firmware.bin; mtd -e OS1 -r write firmware.bin OS1' --- docs/user/supported_devices.rst | 4 ++++ targets/ramips-mt7621 | 7 +++++++ 2 files changed, 11 insertions(+) diff --git a/docs/user/supported_devices.rst b/docs/user/supported_devices.rst index b99014d9..35d93929 100644 --- a/docs/user/supported_devices.rst +++ b/docs/user/supported_devices.rst @@ -199,6 +199,10 @@ ramips-mt7621 - WG3526-16M - WG3526-32M + +* Xiaomi + + - Xiaomi Mi Router 4A (Gigabit Edition) ramips-mt76x8 ------------- diff --git a/targets/ramips-mt7621 b/targets/ramips-mt7621 index 528bd361..c8a42d0e 100644 --- a/targets/ramips-mt7621 +++ b/targets/ramips-mt7621 @@ -29,6 +29,13 @@ device('netgear-wndr3700-v5', 'netgear_wndr3700-v5', { }) +-- Xiaomi + +device('xiaomi-mi-router-4a-gigabit-edition', 'xiaomi_mi-router-4a-gigabit', { + factory = false, +}) + + -- ZBT device('zbtlink-zbt-wg3526-16m', 'zbtlink_zbt-wg3526-16m', {