Hi guys i am trying to port openwrt to a new board with mips cpu. Actually the card already mounts an old version of openwrt, apparently opwnrt backfire 10.03:
BusyBox v1.15.3 (2020-04-21 14:41:24 CST) built-in shell (ash)
Enter 'help' for a list of built-in commands.
_______ ________ __
| |.-----.-----.-----.| | | |.----.| |_
| - || _ | -__| || | | || _|| _|
|_______|| __|_____|__|__||________||__| |____|
|__| W I R E L E S S F R E E D O M
Backfire (10.03, r131) --------------------------
* 1/3 shot Kahlua In a shot glass, layer Kahlua
* 1/3 shot Bailey's on the bottom, then Bailey's,
* 1/3 shot Vodka then Vodka.
system type : Montage Soc
processor : 0
cpu model : MIPS 4KEc V7.0
cpu MHz : 320.00
BogoMIPS : 319.48
wait instruction : yes
microsecond timers : no
tlb_entries : 16
extra interrupt vector : yes
hardware watchpoint : no
ASEs implemented : mips16
shadow register sets : 1
core : 0
VCED exceptions : not available
VCEI exceptions : not available
Linux version 184.108.40.206.as (zhouzhiyuan@HFS1) (gcc version 4.8.3 20140401 (prerelease) (Linaro GCC 4.8-2014.04) ) #58 PREEMPT Tue Apr 21 14:52:21 CST 2020
CPU revision is: 00019070 (MIPS 4KEc)
Determined physical RAM map:
User-defined physical RAM map:
memory: 02000000 @ 00000000 (usable)
Initrd not found or empty - disabling initrd
Zone PFN ranges:
Normal 0x00000000 -> 0x00002000
Movable zone start PFN for each node
early_node_map active PFN ranges
0: 0x00000000 -> 0x00002000
On node 0 totalpages: 8192
free_area_init_node: node 0, pgdat 80265bb0, node_mem_map 81000000
Normal zone: 64 pages used for m
I tried to contact the manufacturer but they didn't answer me. so with the info I had I went in search of a toolchain to compile my tool written in rust, managing to run it on the machine. But now I would like to compile an openwrt release at least the backfire version but I don't know where to start, do you have any ideas?
Download the OpenWrt source-code from e.g. their Github-repo, find a device that resembles yours as much as possible in target/linux/, then modify the DTS-file accordingly, compile an initramfs-image and figure out how to boot it with whatever bootloader you got.
Realistically speaking, this isn't going to happen.
The SOC isn't supported by OpenWrt so far, which would mean you don't 'just' have to add a new board to an already existing (well-maintained) target, but you'd also have to develop SOC and driver support first (which would be a far bigger task, especially as there's zero mainline support either). It doesn't help at all that your device is very low-spec (below minimum system requirements) with 32 MB RAM and just 320 MHz mips 4KEc doesn't promise acceptable usability either.
I agree with your point of view, soc, ram .. they are at their lowest but for what I should do with them they may be fine. My idea is to start a mini webapp written in rust that manages periodic tasks (http requests to some devices connected to the network) and activates some pins when a certain condition occurs.
Luckily I was able to find the full build for openwrt backfire with kernel, driver... (everything). I was also able to compile a custom image. But now I'm having problems cross-compiling with rust, the kernel that mounts is at the linux-220.127.116.11 version and the uclibc toolchain doesn't help, what i would like to do is update to a newer version. I don't need luci or who knows what, i'd set everything to a minimum.
Is there a way to bring everything to a newer version by also changing the toolchain?
Forget about rust on backfire or kernel 2.6.x, it's just way too old for that, either translate your program to a different (more bare bones) language (C or lua come to mind) or (better) forward port SOC/ device support into the modern world (master/ kernel v5.15+) - but that's where the device specs come back to bite you…
The only reasonable approach would be to look on your local used markets for a more modern, supported, device with comfortable system specs (you can find pretty amazing stuff in the 1-10 buck bracket already), stuff that would just work within 10 minutes - rather than requiring you to spend months on below-spec hardware.
Yes at least the 4 * version of the kernel would be a good step forward, alternatively I should just use lua with uhttpd, but I've never used this approach.
Anyway, I chose the card because it couldn't be better for less than $ ~15. I was looking for a small card with an ethernet port on board and a few pins. You will be surprised by its size (that's why i love the Chinese market)