According to the CFE-Customizing Documentation the part of the CFE-Settings don't change the address the TFTP-Client ist listening to at boottime. But the address the TFTP-Server is listening to must be in the CFE-Image, so i took a look in it - and found another hard-coded IP-Address pointing to 192.168.1.1. But how could we change it? And is that the address we have to change for that purpose?

I figured out that a "diff cfe-test1.bin cfe-test2.bin" says that the files are identical, where "cfe-test.bin" is generated with "dd if=/dev/mtdblock/0 of=cfe-test1.bin", and "cfe-test2.bin" is the output of "dd if=/dev/mtdblock/0 > cfe-test2.bin". That gives the ability to put a sed in the pipe like "dd if=/dev/mtdblock/0 | sed -e "s/192.168.1.1/192.168.0.1/g" > cfe.bin". If you want other settings as well just expand the sed, so a version that implements the changes mentioned in the CFE-Customizing doc look like "dd if=/dev/mtdblock/0 | sed -e "s/192.168.1.1/192.168.0.1/g" -e "s/boardflags=0x0118/boardflags=0x0318/" -e "s/boot_wait=off/boot_wait=on/" > cfe.bin". Of course, you can use other IP-addresses than mine and other optimizations, they are just exsamples.

I think, there are checksums in the file, theese are now incorrect of course. To handle this issue i extracted the cfe.txt from the cfe.bin by typing "dd if=cfe.bin  bs=1 skip=4116 count=2048 | strings > cfe.txt", i didn't find a more elegant way for that, i haven't searched for one either. Then without touching the cfe.txt (well, i just did a "cat cfe.txt" to ensure me the changes were actually made...) i ran "nvserial -i cfe.bin -o cfe_new.bin -b 4096 -c 2048 cfe.txt" as advised in the doc. The output of a diff on theese files confirm me that there must be some kind of checksums, cause the files differ from each other.

Now i put the newly created cfe to my WRT54GSv2 with the JTAG method, crossed my fingers - the unit booted without any problems, an extract of the CFE-content on the router showed me the changed values. The next test was to try to get something via tftp from the router, so i started the tftp as mentioned in the Installing via TFTP doc, at the first time with the 192.168.1.1-address. Cause I don't want to install anything I just tried to get something from the router, so instead of "put ..." I used "get openwrt-wrt54gs-2.4-squashfs.bin". The comand timed out while the router booted completely up, as i expected. Now i tried the same at port 192.168.0.1, and got at an early boot state of the router the unexpected message "received ERROR <code=3, msg=transfer cancelled>" I hope, that is 'cause the file i want to recieve isn't on the router at least at that name or the router won't let me get the file. I'll do additionally testing on it incl. putting files on it, but that may last, so just handle the things above as an idea how it might work.

For now - happy hacking... smile

peter