Successful Flash upgrade on Xiaomi AC1200 Extender RC04 using breed (HiWiFi) bootloader :
Boot and Recovery Environment for Embedded Devices
Copyright (C) 2021 HackPascal <hackpascal@gmail.com>
Build date 2021-12-15 [git-f9b74d0]
Version 1.1 (r1337)
DRAM: 64MB
Platform: MediaTek MT7628AN/MT7688AN ver 1, eco 2
Board: HiWiFi HC5661A
Clocks: CPU: 575MHz, Bus: 191MHz, Ref: 40MHz
Flash: Macronix MX25L25635E (32MB) on mt7628-spi.0
Environment variables @ 0001e000 on flash bank 0, size 00001000
rt5350-eth: Using MAC address 43:ff:35:57:7c:41
eth0: MediaTek MT7628 built-in 5-port 10/100M switch
Network started on eth0, inet addr 192.168.1.1, netmask 255.255.255.0
Press any key to interrupt autoboot ... 0
Trying to boot firmware from 0x00160000 in flash bank 0 ...
Reading data into memory ...
U-Boot firmware image header detected.
Image Name: MIPS OpenWrt Linux-5.15.127
Data Size: 2296388 Bytes
Load Address: 80000000
Entry Point: 80000000
Uncompressing data (LZMA) ... done.
Flushing cache ... done.
Starting kernel at 0x80000000...
[ 0.000000] Linux version 5.15.127 (dela@ub-owrt-build) (mipsel-openwrt-linux-musl-gcc (OpenWrt GCC 12.3.0 r23389-5deed175a5) 12.3.0, GNU ld (GNU Binutils) 2.40.0) #0 Sat Aug 19 14:01:06 2023
[ 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 Xiaomi Mi AC1200 WLAN Range Extender RA75
-start with empty 32M bin (HxD)
-add breed (hiWifi) bin and pad to 0x20000
-from stock image get all mtds (config,factory,crash,cfg_bak,overlay) or get block from 0x20000 - 0x160000 and concatenate from 0x20000. Total size should be 0x160000
-adjust dts for firmware partition and build image
00160000 01EA0000
- add sysupgrade bin to file (HxD) from offset 0x160000 and pad to 0x2000000.
- burn bin using programmer
- in breed gui enable env then restart, and in env config add new line:
autoboot.command - boot flash 0x160000
-reboot
0x000000000000-0x000000020000 : "bootloader"
0x000000020000-0x000000030000 : "config"
0x000000030000-0x000000040000 : "factory"
0x000000040000-0x000000050000 : "crash"
0x000000050000-0x000000060000 : "cfg_bak"
0x000000060000-0x000000160000 : "overlay"
0x000000160000-0x000002000000 : "firmware"
USB Mod (currently only low speed working):
It's a b* to solder...
usb usb1-port1: Cannot enable. Maybe the USB cable is bad?
usb 1-1: new high-speed USB device number 3 using ehci-platform
usb 1-1: device descriptor read/64, error -71
usb 2-1: new full-speed USB device number 2 using ohci-platform
usb 2-1: not running at top speed; connect to a high speed hub
usb-storage 2-1:1.0: USB Mass Storage device detected
scsi host0: usb-storage 2-1:1.0
scsi 0:0:0:0: Direct-Access SanDisk Cruzer Edge 1.27 PQ: 0 ANSI: 6
sd 0:0:0:0: [sda] 30529536 512-byte logical blocks: (15.6 GB/14.6 GiB)
sd 0:0:0:0: [sda] Write Protect is off
sd 0:0:0:0: [sda] Write cache: disabled, read cache: enabled, doesn't support DPO or FUA
sda: sda1 sda2 sda3 sda4
sd 0:0:0:0: [sda] Attached SCSI removable disk
The issue could be the resistor values or the wiring.
Should be 15K between D+/D- and GND. Don't have them on hand, closest in series is 14,7K. Could be the wiring, no shield. Also, low speed started working only after i added ~1,5K between D+ and 3,3V (this should be done by the device to indicate high speed, which leads me to believe it's the wires/connections).
Adding 1.5K between D- and 3.3V would indicate that it's a low speed device, and this works fine.
There is no 5V on the board (at least that i could find). The PSU is 12V. Use a DC-DC converter 12V-5V.
cat /sys/kernel/debug/usb/devices
T: Bus=01 Lev=00 Prnt=00 Port=00 Cnt=00 Dev#= 1 Spd=480 MxCh= 1
B: Alloc= 0/800 us ( 0%), #Int= 0, #Iso= 0
D: Ver= 2.00 Cls=09(hub ) Sub=00 Prot=00 MxPS=64 #Cfgs= 1
P: Vendor=1d6b ProdID=0002 Rev= 5.15
S: Manufacturer=Linux 5.15.127 ehci_hcd
S: Product=EHCI Host Controller
S: SerialNumber=101c0000.ehci
C:* #Ifs= 1 Cfg#= 1 Atr=e0 MxPwr= 0mA
I:* If#= 0 Alt= 0 #EPs= 1 Cls=09(hub ) Sub=00 Prot=00 Driver=hub
E: Ad=81(I) Atr=03(Int.) MxPS= 4 Ivl=256ms
T: Bus=02 Lev=00 Prnt=00 Port=00 Cnt=00 Dev#= 1 Spd=12 MxCh= 1
B: Alloc= 0/900 us ( 0%), #Int= 0, #Iso= 0
D: Ver= 1.10 Cls=09(hub ) Sub=00 Prot=00 MxPS=64 #Cfgs= 1
P: Vendor=1d6b ProdID=0001 Rev= 5.15
S: Manufacturer=Linux 5.15.127 ohci_hcd
S: Product=Generic Platform OHCI controller
S: SerialNumber=101c1000.ohci
C:* #Ifs= 1 Cfg#= 1 Atr=e0 MxPwr= 0mA
I:* If#= 0 Alt= 0 #EPs= 1 Cls=09(hub ) Sub=00 Prot=00 Driver=hub
E: Ad=81(I) Atr=03(Int.) MxPS= 2 Ivl=255ms
T: Bus=02 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#= 3 Spd=12 MxCh= 0
D: Ver= 2.00 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs= 1
P: Vendor=1307 ProdID=0163 Rev= 1.00
S: Manufacturer=USBest Technology
S: Product=USB Mass Storage Device
S: SerialNumber=0812179677809a
C:* #Ifs= 1 Cfg#= 1 Atr=80 MxPwr= 80mA
I:* If#= 0 Alt= 0 #EPs= 3 Cls=08(stor.) Sub=06 Prot=50 Driver=usb-storage
E: Ad=01(O) Atr=02(Bulk) MxPS= 64 Ivl=0ms
E: Ad=82(I) Atr=02(Bulk) MxPS= 64 Ivl=0ms
E: Ad=83(I) Atr=03(Int.) MxPS= 64 Ivl=8ms
Let's see...