/dev/mtd1 0x0 0x20000 0x20000 1
Perhaps? I took a look at my RT3200 and 0x0 was the device offset there, also in @Borromini’s suggestions earlier.
/dev/mtd1 0x0 0x20000 0x20000 1
Perhaps? I took a look at my RT3200 and 0x0 was the device offset there, also in @Borromini’s suggestions earlier.
Looks good:
root@OpenWrt:~# cat /etc/fw_env.config
/dev/mtd1 0x0 0x20000 0x20000 1
root@OpenWrt:~# fw_printenv
baudrate=115200
boot_nmrp_clr_str_blks=nand erase.spread ${stringtableoffset} ${stringtablefreesize}
boot_nmrp_wr_str=mtkupgrade str
boot_version=20210408
boot_wr_img=writeimg
bootcmd=mtkautoboot
bootdelay=0
ethaddr=34:98:B5:0F:B0:6F
fenv_factory=off
fenv_model=WAX202
fenv_region=EU
invaild_env=no
ipaddr=192.168.1.1
netmask=255.255.255.0
serverip=192.168.1.2
root@OpenWrt:~#
Hoewer it doesn't seem to be everything that's in mtd1? Netgear WAX202 WiFi 6 $30 at Amazon - #27 by TomH
So maybe it needs to be "longer"?
Doesn't seem to be all the contents indeed but progress for sure .
/dev/mtd1 0x0 0x80000 0x20000 4
Maybe?
Does it need to be all of the contents? Maybe @Ansuel can chime in if the missing strings are necessary, or if the previous results are good enough
yep think we are just using the wrong size... Anyway nobody manage to make the compatible work?
Nope (btw. I have tried several variations, but none of mine seemed to help):
root@OpenWrt:/# cat /etc/fw_env.config
/dev/mtd1 0x0 0x80000 0x20000 4
root@OpenWrt:/# fw_printenv
Warning: Bad CRC, using default environment
bootcmd=bootp; setenv bootargs root=/dev/nfs nfsroot=${serverip}:${rootpath} ip=${ipaddr}:${serverip}:${gatewayip}:${netmask}:${hostname}::off; bootm
bootdelay=5
baudrate=115200
Within the U-Boot console printenv
presents itself as following:
=> nand info
Device 0: nand0, sector size 128 KiB
Page size 2048 b
OOB size 64 b
Erase size 131072 b
subpagesize 512 b
options 0x00010000
bbt options 0x00008000
=> printenv
baudrate=115200
boot_nmrp_clr_str_blks=nand erase.spread ${stringtableoffset} ${stringtablefreesize}
boot_nmrp_wr_str=mtkupgrade str
boot_version=20210408
boot_wr_img=writeimg
bootcmd=mtkautoboot
bootdelay=0
bootmenu_0=Startup system (Default)=mtkboardboot
bootmenu_1=Upgrade firmware=mtkupgrade fw
bootmenu_2=Upgrade bootloader=mtkupgrade bl
bootmenu_3=Upgrade bootloader (advanced mode)=mtkupgrade bladv
bootmenu_4=Load image=mtkload
ethact=eth@1e100000
ethaddr=34:98:B5:0F:B0:6F
fdtcontroladdr=9bff05e0
fenv_factory=off
fenv_model=WAX202
fenv_region=EU
invaild_env=no
ipaddr=192.168.1.1
nand_erasesize=20000
nand_oobsize=40
nand_writesize=800
netmask=255.255.255.0
serverip=192.168.1.2
stderr=uartlite0@1e000c00
stdin=uartlite0@1e000c00
stdout=uartlite0@1e000c00
Environment size: 766/131068 bytes
If I have all my ducks in a row, then the first address (0x0
) is an offset and the second (0x80000
) is the partition size.
These are the strings /dev/mtd1
output @TomH posted earlier that were supposedly cut off and don’t appear in fw_printenv
with /dev/mtd1 0x0 0x20000 0x20000 1
:
factory_mode=off
pcba_sn=241BXXXXXXXX
region=EU
model=WAX202
axmodel=AX1800
mac=3498XXXXXXXX
sn=6MT31XXXXXXXX
ssid=NETGEXXXXXXXX
passphrase=niftyXXXXXXXX
hardware=V1
default_region=EU
(I know you said the identifiable info didn’t matter, @TomH, but I removed it anyway in case you changed your mind later.)
@Ansuel or anyone else who knows, is it possible these values are write-protected so they can’t be changed later? The whole point of getting a correct fw_printenv
is to be able to safely change the variables with fw_setenv
, right, so if they weren’t allowed to be modified, they wouldn’t appear in fw_printenv
output perhaps?
Just a read-only
flag in the DTS is sufficient, e.g.:
It's on sale again, not as low as $30, but $40, at Office Depot.
FYI I created a data entry, should lighten the burden for anyone creating an actual device page:
2,4 GHz apparently 802.11bgn only.
Were there reports of this somewhere?
Yes:
No FCC or Wikidevi entry I could find to verify this though.
Im pretty sure that i've had a wifi 6 connection on 2,4 GHz with the WAX202.
Feel free to correct the data page. I don't have the device myself so I cannot test.
Edit: Netgear's own datasheet says 802.11ax on both bands so I'll change the data entry accordingly.
It's expected that those strings do not appear in fw_printenv
because the Config partition contains uboot env for the first 0x20000 bytes only. The passphrase and other data are contained in a separate data block starting at 0x20000. This can be seen by examining the file posted by @TomH in a hex editor: http://0x0.st/ojP6.backup Note that also since the CRC check passes with the size of 0x20000, I believe this also confirms that it is the correct size of the uboot env (you can confirm that the CRC check does not pass with other sizes).
I sent a proposed fix here: https://github.com/openwrt/openwrt/pull/10366
I've compiled a firmware with those two patches (not master, but a backport on top of the 22.03 branch) and got the following:
root@64xxx-3498b50fb06f:~# cat /etc/fw_env.config
/dev/mtd1 0x0 0x20000 0x20000
root@64xxx-3498b50fb06f:~# fw_printenv
baudrate=115200
boot_nmrp_clr_str_blks=nand erase.spread ${stringtableoffset} ${stringtablefreesize}
boot_nmrp_wr_str=mtkupgrade str
boot_version=20210408
boot_wr_img=writeimg
bootcmd=mtkautoboot
bootdelay=0
ethaddr=34:98:B5:0F:B0:6F
fenv_factory=off
fenv_model=WAX202
fenv_region=EU
invaild_env=no
ipaddr=192.168.1.1
netmask=255.255.255.0
serverip=192.168.1.2
root@64xxx-3498b50fb06f:~#
(obviously i've installed it with sysupgrade -n
)
@looi To me that looks really good.
It was included in 2022.03rc6
I have just bought 2 of these a few days ago because they were in the table of hardware and now they are already in rc6
Using them as ap's with vlan's, works perfectly so far.
Thanks for all your efforts!