Hi,
I have just bought an used AR300M-EXT (with white antennas) on ebay. The seller mentioned something about a bad buy and that it is basically unused. Good for me!
Though it boots only into the NOR flash. Neither âbootcount 3â nor âboot_dev onâ plus the switch show any effect.
The device came to me with the NOR firmware 2.261 which I updated to 2.264 and in the meantime to 2.27-testing without problems. For NOR it works from within the firmware and via uboot. For the NAND image via uboot something does not work though. The WLAN LED switches off, then the LAN LED blinks once and thatâs it. Both LEDâs are dead.
Two more issues are perplexing me:
- In Luciâs kernel log (under 2.77) I can see:
[ 0.896864] nand: device found, Manufacturer ID: 0xa1, Chip ID: 0xe1
[ 0.903437] nand: FW Device PN256GO1 1G 3.3V 8-bit
[ 0.908484] nand: 128 MiB, SLC, erase size: 128 KiB, page size: 2048, OOB size: 128
[ 0.916408] nand: WARNING: spi0.1: the ECC used on your system is too weak compared to the one required by the NAND chip
[ 0.927642] Scanning device for bad blocks
[ 2.871841] Bad eraseblock 1022 at 0x000007fc0000
** [ 2.878537] Bad eraseblock 1023 at 0x000007fe0000**
So first of all the NAND is there. But what about the âBad eraseblockâ? Is the NAND damanged?
- On the cli under the NOR the output of fw_printenv shows:
root@GL-AR300M:~# fw_printenv
bootargs=board=CUS531-NAND console=ttyS0,115200 ubi.mtd=5,2048 root=/dev/mtdblock8 mtdparts=spi0.0:256k(u-boot)ro,64k(u-boot-env),128k(reserved),64k(art);spi0.1:2m(kernel),20m(rootfs),106m(data),22m@0x0(firmware) rootfstype=squashfs,jffs2 noinitrd
bootcmd=if nand bad; then nboot 0x81000000 0 || run blf; else run blf; fi
bootdelay=1
baudrate=115200
ethaddr=0x00:0xaa:0xbb:0xcc:0xdd:0xee
ipaddr=192.168.1.1
serverip=192.168.1.2
loadaddr=0x80800000
dir=
bootlimit=3
altbootcmd=run blf
blf=bootm 0x9f050000 || run lf; boot
dlf=if ping 192.168.1.2; then echo ok; elif ping 192.168.1.2; then echo ok; elif ping 192.168.1.2; then echo ok; elif echo ping 192.168.1.2; then echo ok; elif echo ping 192.168.1.2; then echo ok; else echo ping finally failed; fi; tftp 0x81000000 openwrt-ar71xx-nand-gl-ar300m-ubi.img && nand erase && nand write $fileaddr 0 $filesize
rlf=if ping 192.168.1.2; then tftp 0x80060000 ${dir}openwrt-gl-ar300m.bin && erase 0x9f050000 +$filesize && cp.b $fileaddr 0x9f050000 $filesize; else echo ping 192.168.1.2 failed; fi
lu=tftp 0x80060000 ${dir}uboot_for_gl-ar300m.bin && erase 0x9f000000 +50000 && cp.b $fileaddr 0x9f000000 $filesize; reset
lf=if ping 192.168.1.2; then tftp 0x80060000 ${dir}openwrt-gl-ar300m.bin && erase 0x9f050000 +$filesize && cp.b $fileaddr 0x9f050000 $filesize; if nand bad; then run dlf; fi; else echo ping 192.168.1.2 failed; fi
lc=if ping 192.168.1.2; then tftp 0x81000000 config.bin && cp.b 0x9fff0040 0x81000040 0xffc0 && cp.b 0x81000000 0x81001002 0x06 && erase 0x9fff0000 +0xffff && cp.b 0x81000000 0x9fff0000 0xffff; else setenv bootcount 1 && saveenv && bootm 0x9fe80000; fi
ethact=eth0
wlf=if=nand bad
stdin=serial
stdout=serial
stderr=serial
bootcount=0
What about âwlf=if=nand badâ. That command looks incomplete. What does it cause? What would be the correct command?
Is there any way to figure out more about what is going on the the NAND flash than using a USB UART adapter which I do not have?
Regards