I'm looking to add support for F@ST 4320 by Sagemcom, it's a Windstream modem I bought at a vintage store years ago (if the ISP needs to be redacted, please do so. I just added it so anyone else with the same modem can find the modem more easily via Google).
This post is long as I try to put as much info I can to help figure out how to add support for this modem. I'm using a combination of https://openwrt.org/docs/guide-developer/adding_new_device#collecting_relevant_data and my own knowledge of Linux to pull the information.
I sadly do not have access to the source code for this modem like I do for the Sagem 1704N (which works fine with the 2704N firmware). Sagemcom only ever released the source code for 1704N.
The router identifies itself as BCM963268 Broadband Router
when connecting to the telnet port.
The CPU info is:
# cat /proc/cpuinfo
cat /proc/cpuinfo
system type : F@ST4320
processor : 0
cpu model : Broadcom4350 V8.0
BogoMIPS : 399.36
wait instruction : yes
microsecond timers : yes
tlb_entries : 32
extra interrupt vector : no
hardware watchpoint : no
ASEs implemented :
shadow register sets : 1
core : 0
VCED exceptions : not available
VCEI exceptions : not available
unaligned exceptions : 76
processor : 1
cpu model : Broadcom4350 V8.0
BogoMIPS : 402.43
wait instruction : yes
microsecond timers : yes
tlb_entries : 32
extra interrupt vector : no
hardware watchpoint : no
ASEs implemented :
shadow register sets : 1
core : 0
VCED exceptions : not available
VCEI exceptions : not available
unaligned exceptions : 76
The meminfo is:
# cat /proc/meminfo
cat /proc/meminfo
MemTotal: 123436 kB
MemFree: 62096 kB
Buffers: 0 kB
Cached: 17196 kB
SwapCached: 0 kB
Active: 6692 kB
Inactive: 15412 kB
Active(anon): 4908 kB
Inactive(anon): 0 kB
Active(file): 1784 kB
Inactive(file): 15412 kB
SwapTotal: 0 kB
SwapFree: 0 kB
Dirty: 0 kB
Writeback: 0 kB
AnonPages: 4936 kB
Mapped: 4964 kB
Slab: 33684 kB
SReclaimable: 436 kB
SUnreclaim: 33248 kB
PageTables: 388 kB
NFS_Unstable: 0 kB
Bounce: 0 kB
WritebackTmp: 0 kB
CommitLimit: 61716 kB
Committed_AS: 10040 kB
VmallocTotal: 1032148 kB
VmallocUsed: 4888 kB
VmallocChunk: 1017952 kB
The cmdline is:
# cat /proc/cmdline
cat /proc/cmdline
root=mtd:rootfs ro rootfstype=jffs2 console=ttyS0,115200
The devices are:
# cat /proc/devices
cat /proc/devices
Character devices:
1 mem
2 pty
3 ttyp
4 ttyS
5 /dev/tty
5 /dev/console
5 /dev/ptmx
10 misc
13 input
90 mtd
108 ppp
128 ptm
136 pts
166 ttyACM
180 usb
188 ttyUSB
189 usb_device
206 brcmboard
208 adsl
227 p8021ag
228 bcmxtmcfg
233 spu
238 bcmvlan
240 pwrmngt
241 bcmfap
242 fcache
243 ingqos
244 bpm
245 bcmarl
246 chipinfo
249 gmac
254 usb_endpoint
Block devices:
259 blkext
8 sd
31 mtdblock
65 sd
66 sd
67 sd
68 sd
69 sd
70 sd
71 sd
128 sd
129 sd
130 sd
131 sd
132 sd
133 sd
134 sd
135 sd
Also,
# ls /sys/devices/platform
ls /sys/devices/platform
bcmhs_spi.1 bcmleg_spi.0 brcmnand.0 uevent
So, I just learned how to get the mtd maps from https://openwrt.org/docs/guide-developer/adding_new_device#collecting_relevant_data:
# cat /proc/mtd
cat /proc/mtd
dev: size erasesize name
mtd0: 03d60000 00020000 "rootfs"
mtd1: 03d60000 00020000 "rootfs_update"
mtd2: 00400000 00020000 "data"
mtd3: 00020000 00020000 "nvram"
IfConfig Info:
# ifconfig -a
ifconfig -a
bcmsw Link encap:Ethernet HWaddr 90:72:82:D9:F5:B0
UP BROADCAST RUNNING MULTICAST MTU:2048 Metric:1
RX packets:0 multicast:0 unicast:0 broadcast:0
RX errors:0 dropped:0 overruns:0 frame:0
TX packets:0 multicast:0 unicast:0 broadcast:0
TX errors:0 dropped:0 overruns:0 carrier:0 collisions:0
txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
RX multicast bytes:0 (0.0 B) TX multicast bytes:0 (0.0 B)
Base address:0xda00
br0 Link encap:Ethernet HWaddr 90:72:82:D9:F5:B0
inet addr:192.168.254.254 Bcast:192.168.254.255 Mask:255.255.255.0
inet6 addr: fe80::9272:82ff:fed9:f5b0/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:210 multicast:75 unicast:116 broadcast:19
RX errors:0 dropped:0 overruns:0 frame:0
TX packets:561 multicast:0 unicast:561 broadcast:0
TX errors:0 dropped:0 overruns:0 carrier:0 collisions:0
txqueuelen:0
RX bytes:23669 (23.1 KiB) TX bytes:164820 (160.9 KiB)
RX multicast bytes:19790 (19.3 KiB) TX multicast bytes:0 (0.0 B)
dsl0 Link encap:UNSPEC HWaddr 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00
[NO FLAGS] MTU:0 Metric:1
RX packets:0 multicast:0 unicast:0 broadcast:0
RX errors:0 dropped:0 overruns:0 frame:0
TX packets:0 multicast:0 unicast:0 broadcast:0
TX errors:0 dropped:0 overruns:0 carrier:0 collisions:0
txqueuelen:0
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
RX multicast bytes:0 (0.0 B) TX multicast bytes:0 (0.0 B)
eth0 Link encap:Ethernet HWaddr 90:72:82:D9:F5:B0
inet6 addr: fe80::9272:82ff:fed9:f5b0/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:2048 Metric:1
RX packets:227 multicast:0 unicast:227 broadcast:0
RX errors:0 dropped:0 overruns:0 frame:0
TX packets:134 multicast:20 unicast:110 broadcast:4
TX errors:0 dropped:0 overruns:0 carrier:0 collisions:0
txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:13532 (13.2 KiB)
RX multicast bytes:0 (0.0 B) TX multicast bytes:0 (0.0 B)
eth1 Link encap:Ethernet HWaddr 90:72:82:D9:F5:B0
UP BROADCAST MULTICAST MTU:2048 Metric:1
RX packets:0 multicast:0 unicast:0 broadcast:0
RX errors:0 dropped:0 overruns:0 frame:0
TX packets:0 multicast:0 unicast:0 broadcast:0
TX errors:0 dropped:0 overruns:0 carrier:0 collisions:0
txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
RX multicast bytes:0 (0.0 B) TX multicast bytes:0 (0.0 B)
eth2 Link encap:Ethernet HWaddr 90:72:82:D9:F5:B0
UP BROADCAST MULTICAST MTU:2048 Metric:1
RX packets:0 multicast:0 unicast:0 broadcast:0
RX errors:0 dropped:0 overruns:0 frame:0
TX packets:0 multicast:0 unicast:0 broadcast:0
TX errors:0 dropped:0 overruns:0 carrier:0 collisions:0
txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
RX multicast bytes:0 (0.0 B) TX multicast bytes:0 (0.0 B)
eth3 Link encap:Ethernet HWaddr 90:72:82:D9:F5:B0
UP BROADCAST MULTICAST MTU:2048 Metric:1
RX packets:0 multicast:0 unicast:0 broadcast:0
RX errors:0 dropped:0 overruns:0 frame:0
TX packets:0 multicast:0 unicast:0 broadcast:0
TX errors:0 dropped:0 overruns:0 carrier:0 collisions:0
txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
RX multicast bytes:0 (0.0 B) TX multicast bytes:0 (0.0 B)
eth4 Link encap:Ethernet HWaddr 90:72:82:D9:F5:B2
UP BROADCAST MULTICAST MTU:2048 Metric:1
RX packets:0 multicast:0 unicast:0 broadcast:0
RX errors:0 dropped:0 overruns:0 frame:0
TX packets:0 multicast:0 unicast:0 broadcast:0
TX errors:0 dropped:0 overruns:0 carrier:0 collisions:0
txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
RX multicast bytes:0 (0.0 B) TX multicast bytes:0 (0.0 B)
gre0 Link encap:UNSPEC HWaddr 00-00-00-00-7E-0F-7F-EE-00-00-00-00-00-00-00-00
NOARP MTU:1476 Metric:1
RX packets:0 multicast:0 unicast:0 broadcast:0
RX errors:0 dropped:0 overruns:0 frame:0
TX packets:0 multicast:0 unicast:0 broadcast:0
TX errors:0 dropped:0 overruns:0 carrier:0 collisions:0
txqueuelen:0
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
RX multicast bytes:0 (0.0 B) TX multicast bytes:0 (0.0 B)
ifb0 Link encap:Ethernet HWaddr 7E:FA:19:B9:43:4E
BROADCAST NOARP MTU:1500 Metric:1
RX packets:0 multicast:0 unicast:0 broadcast:0
RX errors:0 dropped:0 overruns:0 frame:0
TX packets:0 multicast:0 unicast:0 broadcast:0
TX errors:0 dropped:0 overruns:0 carrier:0 collisions:0
txqueuelen:32
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
RX multicast bytes:0 (0.0 B) TX multicast bytes:0 (0.0 B)
ifb1 Link encap:Ethernet HWaddr DA:91:00:EE:3F:26
BROADCAST NOARP MTU:1500 Metric:1
RX packets:0 multicast:0 unicast:0 broadcast:0
RX errors:0 dropped:0 overruns:0 frame:0
TX packets:0 multicast:0 unicast:0 broadcast:0
TX errors:0 dropped:0 overruns:0 carrier:0 collisions:0
txqueuelen:32
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
RX multicast bytes:0 (0.0 B) TX multicast bytes:0 (0.0 B)
ip6tnl0 Link encap:UNSPEC HWaddr 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00
NOARP MTU:1460 Metric:1
RX packets:0 multicast:0 unicast:0 broadcast:0
RX errors:0 dropped:0 overruns:0 frame:0
TX packets:0 multicast:0 unicast:0 broadcast:0
TX errors:0 dropped:0 overruns:0 carrier:0 collisions:0
txqueuelen:0
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
RX multicast bytes:0 (0.0 B) TX multicast bytes:0 (0.0 B)
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:89 multicast:0 unicast:0 broadcast:0
RX errors:0 dropped:0 overruns:0 frame:0
TX packets:89 multicast:0 unicast:0 broadcast:0
TX errors:0 dropped:0 overruns:0 carrier:0 collisions:0
txqueuelen:0
RX bytes:12424 (12.1 KiB) TX bytes:12424 (12.1 KiB)
RX multicast bytes:0 (0.0 B) TX multicast bytes:0 (0.0 B)
sit0 Link encap:IPv6-in-IPv4
NOARP MTU:1480 Metric:1
RX packets:0 multicast:0 unicast:0 broadcast:0
RX errors:0 dropped:0 overruns:0 frame:0
TX packets:0 multicast:0 unicast:0 broadcast:0
TX errors:0 dropped:0 overruns:0 carrier:0 collisions:0
txqueuelen:0
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
RX multicast bytes:0 (0.0 B) TX multicast bytes:0 (0.0 B)
wl0 Link encap:Ethernet HWaddr 90:72:82:D9:F5:B1
BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 multicast:0 unicast:0 broadcast:0
RX errors:0 dropped:0 overruns:0 frame:3273
TX packets:0 multicast:0 unicast:0 broadcast:0
TX errors:0 dropped:0 overruns:0 carrier:0 collisions:0
txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
RX multicast bytes:0 (0.0 B) TX multicast bytes:0 (0.0 B)
Interrupt:15
wl0.1 Link encap:Ethernet HWaddr 5A:72:82:D9:F5:B2
BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 multicast:0 unicast:0 broadcast:0
RX errors:0 dropped:0 overruns:0 frame:3273
TX packets:0 multicast:0 unicast:0 broadcast:0
TX errors:0 dropped:0 overruns:0 carrier:0 collisions:0
txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
RX multicast bytes:0 (0.0 B) TX multicast bytes:0 (0.0 B)
wl0.2 Link encap:Ethernet HWaddr 5A:72:82:D9:F5:B3
BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 multicast:0 unicast:0 broadcast:0
RX errors:0 dropped:0 overruns:0 frame:3273
TX packets:0 multicast:0 unicast:0 broadcast:0
TX errors:0 dropped:0 overruns:0 carrier:0 collisions:0
txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
RX multicast bytes:0 (0.0 B) TX multicast bytes:0 (0.0 B)
wl0.3 Link encap:Ethernet HWaddr 5A:72:82:D9:F5:B0
BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 multicast:0 unicast:0 broadcast:0
RX errors:0 dropped:0 overruns:0 frame:3273
TX packets:0 multicast:0 unicast:0 broadcast:0
TX errors:0 dropped:0 overruns:0 carrier:0 collisions:0
txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
RX multicast bytes:0 (0.0 B) TX multicast bytes:0 (0.0 B)
# ls /sys/class/net
ls /sys/class/net
bcmsw eth0 eth3 ifb0 lo wl0.1
br0 eth1 eth4 ifb1 sit0 wl0.2
dsl0 eth2 gre0 ip6tnl0 wl0 wl0.3
# brctl show
brctl show
bridge name bridge id STP enabled interfaces
br0 8000.907282d9f5b0 no eth0
eth1
eth2
eth3
Neither, /sys/class/mtd/mtd*/offset
, nor /sys/kernel/debug/gpio
exists. I figured the gpio didn't as I didn't see any gpio pins, however, I'm not sure what's up with mtd offsets. The sysfs-class-mtd link now 404s, and this isn't Linux 4.1+ anyway.
# cat /proc/version
cat /proc/version
Linux version 2.6.30 (cookiechen@SZ01007.DONGGUAN.CN) (gcc version 4.4.2 (Buildroot 2010.02-git) ) #1 SMP PREEMPT Tue Sep 8 18:34:23 CST 2015
I also pulled the rootfs and data partition off of the modem via netcat. The rootfs is stored at /dev/mtdblock0 and the data partition is stored at /dev/mtdblock2. Both of them are jffs2 partitions. Block 1 is jffs2 but has no files when mounted as mount -t jffs2 /dev/mtdblock1 /tmp/block1
. Blocks 4 through 7 returns a No such device
error when attempting to mount them. I had verified the transfer of the rootfs and data partitions by using sha256sum that I statically compiled for mips32 from coreutils (I did remount rootfs as rw to put a test.txt at the root in order to determine that I had the right block for rootfs).
I know the adsl line driver chip is a BCM6306KMLG from opening up the casing on the modem. I determined that the board chip id is 63268 from seeing what happens by loading a wrong firmware against the modem via tftp. Using the command, tftp -g -t i -f openwrt_cfe_image_filename.bin my_computers_ip_assigned_by_this_modem_via_ethernet
.
I get the message:
# tftp -g -t i -f openwrt-brcm63xx-smp-FAST2404-squashfs-cfe.bin 192.168.254.1
tftp -g -t i -f openwrt-brcm63xx-smp-FAST2404-squashfs-cfe.bin 192.168.254.1
tftp: Allocating 64356372 bytes for flash image.
tftp: Memory allocated
tftp: Got image via tftp, total image size: 3932164
tftp:error:697.092:matchChipId:96:Chip Id error. Image Chip Id = 6348, Board Chip Id = 63268.
tftp:error:697.096:verifyBroadcomFileTag:187:chipid check failed
tftp:error:697.465:cmsImg_validateImage:1032:The format isn't broadcom image
tftp: Tftp Image failed: Illegal image.
The tftp command is from busybox: BusyBox v1.17.2 (2015-09-08 18:40:00 CST) multi-call binary.
.
The modem has a DSL port, WAN port, 4 ethernet ports, two usb ports, a reset button, one unlabeled light, an "@" light (forgot what that means), a DSL light, a Bonding Light (whatever that means, it uses the same icon as the DSL icon right next to it), an ECO button with a light below it, a WPS button also with a light, a Wireless button with a light (it looks like a radio antenna), and a power button also with a light. As for power, it receives a 12 V DC and a minimum of 2 Amps.
For some reason, I wrote "F@ST 4320 US" on the box years ago, not sure where I got the US part from.
Here are a couple of images of the board itself and one image of me showing how to open the casing (after removing the screws). As the images are too big to open here, and I'm not trying to make the quality poorer than it needs to be, here's an Imgur link: https://imgur.com/a/bkNUtL0
This board has 2 cores and should work with smp builds. I saw mention of the ability to do Symmetric multiprocessing somewhere on the Windstream HTTP server.
I know the stock firmware can automount a MBR table with a single FAT32 partition from a usb drive plugged into it.
What I would like to do is be able to add support for this modem. I have full root access to sh through telnet as well as Debian running in Virtualbox and a TFTP server running on my Mac.
If we can figure out how to get the modem to boot from usb and/or tftp without flashing the firmware, that'll be great as then I can test a built firmware without worrying about bricking the modem. I don't have access to a jtag, and have to find my solder if using serial. I don't know if the RPi is stable enough for flashing firmware, but I've used the RPI before to communicate with a sim900 over serial.
Thanks for any help you can give!
Edit: I believe BCM963268 is the bootloader. It seems that quite a few devices share this id and on this mirror of Wikidevi (cause the original site is dead and well search isn't going to work on the Wayback machine), a random device I found in search shows this id refers to a bootloader. I did find out where I got the US from back then. https://wikidevi.wi-cat.ru/Sagemcom_F@ST_4320US
Edit 2: I'm currently trying to work out if the source code named bcm963xx_4.12L.08_consumer_release.tar.gz, would contain the necessary data for being able to compile OpenWRT for this router. The source of my link is https://www.reddit.com/r/teksavvy/comments/62wvwb/smartrg_gpl_violation/dfxglda?utm_source=share&utm_medium=web2x&context=3. That'll most likely be a no as other devices with that bootloader can have different hardware configuration. E.g. SKY SR102 from the old OpenWRT Wiki does not have USB.