I have a WD-02 router (Same hardware as the HooToo TM-02 router) that I installed OpenWRT on long ago.
I have several issues with the current firmware. Specifically, I want to set up Samba and a Web File Manager on the router with read-only permissions on both, but with an option to log in to upload files. The intention was to use it as a NAS.
Sadly, I suck at finding answers on Google, apparently. I have looked high and low, and can't figure out how this sort of thing works at all. I have some idea of some of it, but only from poking at it and making "Oook?" noises.
There's also the won'tfix bug that shuts off the WiFi radio hardware if it can't connect to a host AP in client mode (It has a client connection to get Internet, and an AP that provides the same Internet (bridge) AND file access. If it worked the way I wanted. I have a script to fix it, but it relies on pinging 8.8.8.8 rather than checking to see if the client connection is down or not (there has to be a way to do that, right? The router knows it's down, otherwise I would have it broadcasting its own AP!). There's an old script for that, but it is either broken or I have a special case. I assure you, I do know for a fact that it's not working, and it isn't because I am doing it wrong. I've managed to focus my tiny brain on figuring that out, at least. While I can add it into the firmware image, I don't know what to add as well so that I can trigger the script by any means other than SSH and a keyboard. That rather negates the purpose of fixing the WiFi when I can't connect in the first place.
So, I managed to keep the files that the OpenWRT installer left behind, and ALL.bin sounds promising.
I'll keep the mysterious and slightly crippled Manufacturer OS, since it at least works -- mostly.
It did all that I wanted, but I could not access Samba or the WFM from the external wifi network it subscribes to. At this point, I don't care. (The previous version had external access, but the file upload window used Flash. That didn't work too well with my Linux PCs. It's not like they warn you that they are about to break a little-known feature you relied upon...)
Here's the problem:
The image contains the U-Boot loader as well as the rest of the OS. (I'll also note that it's 8.4 MB, and I thought the router had only 8MB of flash...)
binwalk Router\ Debugging/SDCARD/ALL.bin
DECIMAL HEXADECIMAL DESCRIPTION
--------------------------------------------------------------------------------
0 0x0 uImage header, header size: 64 bytes, header CRC: 0x30C9CE94, created: 2014-05-14 04:33:42, image size: 128280 bytes, Data Address: 0x80200000, Entry Point: 0x80200000, data CRC: 0x5FB9F5C9, OS: Linux, CPU: MIPS, image type: Standalone Program, compression type: none, image name: "SPI Flash Image"
104736 0x19920 U-Boot version string, "U-Boot 1.1.3 (May 14 2014 - 12:33:39)"
105216 0x19B00 CRC32 polynomial table, little endian
327680 0x50000 uImage header, header size: 64 bytes, header CRC: 0xECF78960, created: 2015-01-27 02:36:17, image size: 1441838 bytes, Data Address: 0x80000000, Entry Point: 0x80441000, data CRC: 0x5F3B4B40, OS: Linux, CPU: MIPS, image type: OS Kernel Image, compression type: lzma, image name: "Linux Kernel Image"
327744 0x50040 LZMA compressed data, properties: 0x5D, dictionary size: 33554432 bytes, uncompressed size: 4608121 bytes
1966096 0x1E0010 gzip compressed data, maximum compression, from Unix, last modified: 2015-11-28 05:31:57
2031632 0x1F0010 gzip compressed data, maximum compression, from Unix, last modified: 2012-01-01 00:12:25
2097152 0x200000 Squashfs filesystem, little endian, non-standard signature, version 3.0, size: 5695992 bytes, 1316 inodes, blocksize: 65536 bytes, created: 2015-01-29 07:22:24
(A normal sysupgrade image:
binwalk Router\ Debugging/openwrt-15.05.1-ramips-rt305x-ht-tm02-squashfs-sysupgrade.bin
DECIMAL HEXADECIMAL DESCRIPTION
--------------------------------------------------------------------------------
0 0x0 uImage header, header size: 64 bytes, header CRC: 0x415C456E, created: 2016-11-13 18:41:01, image size: 1125066 bytes, Data Address: 0x80000000, Entry Point: 0x80000000, data CRC: 0x5C4596FA, OS: Linux, CPU: MIPS, image type: OS Kernel Image, compression type: lzma, image name: "MIPS OpenWrt Linux-3.18.23"
64 0x40 LZMA compressed data, properties: 0x6D, dictionary size: 8388608 bytes, uncompressed size: 3339140 bytes
1125130 0x112B0A Squashfs filesystem, little endian, version 4.0, compression:xz, size: 5370830 bytes, 1664 inodes, blocksize: 262144 bytes, created: 2016-11-13 18:40:59
)
What do I use to install this original image (and I assume it would be wise to install the original U-Boot, since I don't know what start address or command set is expected by the manufacturer one vs. the OpenWRT one)?
I would assume Sysupgrade method is out, unless that's smart enough to detect the extra content.
I don't even know what other methods exist, and the kernel is supposed to be read-only, and I also don't know about everything else that might also need to be installed that might have issues.
The images supplied by the factory directly also cannot be used, since they are actually a shell script that the vanilla image would execute. There's a binary image contained in there that is then installed by the script. I don't have to confidence to tamper with that much. Besides, for all I know, they have the same issue(s).
Please read this post and help me. I am sick and tired of being mushroomed on here.
I don't think I have ever gotten an answer to any of my posts yet (There have been a few on some of my earliest ones, but none of them ended up helping, save for the one on how to tell the router it has more than 16 MB of RAM. *shudder*). I have had to "solve" everything myself, and there's only so far luck can take you.
Thanks, and goodbye.