TcBoot is a minimalist bootloader for EcoNet devices derived from TrendChip's TC3262.
It is unfortunately also something that is often patched and modified by vendors, so its behavior is not always the same. We describe the common behavior found on many devices here.
You can stop the bootloader from UART by pressing enter in the first seconds of device startup, it will leave you with a command prompt bldr>.
Press any key in 3 secs to enter boot command mode. .............. bldr>
tclinux.trx, then flash <flash addr> 80020000 <file length hex>initramfs-kernel.bin, then jump 80020000telecomadmin / nE7jA%5mIf it always boots the factory firmware, that just means you need to switch the OS, see device pages for OS switching.
TcBoot has a builtin TFTP server. By design it will only accept two filenames, tcboot.bin (the bootloader) or tclinux.bin (the firmware), then writes the content to the corresponding flash address. However, the upload happens before the filename check, so we may provide a wrong filename and use it to upload any file into the memory.
192.168.1.Xtcboot.bin or tclinux.bin: tftp 192.168.1.1 -m binary -v -c put image.bin.Starting the TFTP download...
...
Total 5624466 (0x55D292) bytes received
Received file: image.bin
rcvdata_size = 5624466
start = 0x80020000
Invalid filename, upload failed
Valid filename: Bootloader : tcboot.bin
Linux Kernel: tclinux.bin
...
jump 80020000 to boot the kernel from memory, or flash with flash <flash addr> 80020000 <file length hex>.Go to > Setup > Serial port...File → New connection→ Choose Serial and your active COM[x] port.picocom --send-cmd lsx -vv -b 115200 /dev/ttyUSB0printf '%X\n' “$(stat -c%s *tclinux.trx)”xmdm 80020000 <file length hex>File→ Transfer→ XMODEM→ Send → .. and select your trx openwrt file.ctrl+a ctrl+s <paste-the-file-name> enter.bldr> xmdm 80020000 <file length hex> CCCC *** file: openwrt-en75-en751221-smartfiber_xp8421-b-squashfs-tclinux.trx $ lsx -vv openwrt-en75-en751221-smartfiber_xp8421-b-squashfs-tclinux.trx Sending openwrt-en75-en751221-smartfiber_xp8421-b-squashfs-tclinux.trx, 61644 blocks: Give your local XMODEM receive command now.
jump 80020000 to boot the kernel from memory, or flash with flash <flash addr> 80020000 <file length hex>.For reference only. Your mileage may vary.
bldr> ? ? Print out help messages. help Print out help messages. go Booting the linux kernel. decomp Decompress kernel image to ram. memrl <addr> Read a word from addr. memwl <addr> <value> Write a word to addr. dump <addr> <len> Dump memory content. jump <addr> Jump to addr. flash <dst> <src> <len> <oob> Write to flash from src to dst(oob: write nand oob if 1). imginfo Show images info. spi nand rw test SPI NAND Test bdstore <flash dst> <bin src> Do backdoor config store bdshow Show backdoor config bdswitch[1|0] Enable or disable backdoor function ddrcalswitch[1|0] Enable or disable ddr calibration funciton drambistswitch[0|1|2] disable or enable, and quick or normal test xmdm <addr> <len> Xmodem receive to addr. miir <phyaddr> <reg> Read ethernet phy reg. miiw <phyaddr> <reg> <value> Write ethernet phy reg. cpufreq <freq num> / <m> <n> Set CPU Freq <156~450>(freq has to be multiple of 6) ipaddr <ip addr> Change modem's IP. httpd Start Web Server ddrdrv <..> Change DDR driving length
All size arguments must be unprefixed hex values, for example if the memory location is 0x80020000, you write 80020000, if the length is 256, you write 100.
The HTTP upload form accepts two filenames: tcboot.bin, which overwrites the bootloader (!!!), and tclinux.bin, which vendors may forget to change and writes to a completely wrong address (!!!). Just don't use it.
Most devices come with dual boot support, unfortunately it's where vendors patched heavily. Please refer to device pages for details.