Monday, 15 August 2016

WRT610N v1 / LEDE / Compiling

This router, the WRT610n v1, provides more challenges than normal.

Firstly, the 5 GHz chip is not supported by the opensource OpenWRT drivers. That means, if you install 15.05.01, there will be no 5 GHz support.

Luckily, you have the option of using the proprietary Broadcom wireless drivers -- the only catch here is that you need to compile your own firmware.  For this, you will need a computer running a Linux OS or any BSD or even a Mac. Cgywin on Windows does not meet the requirements.

Before downloading the source, you will need to have the following installed:

gcc, binutils, bzip2, flex, python, perl, make,
find, grep, diff, unzip, gawk, getopt, subversion, libz-dev and libc headers.

With that done, you will need to make the following decision: do you want to stay with the stable OpenWRT version (15.05.1) or do you want to try the 'trunk' version.

If you want to try the trunk version, then the next question: do you want to stay with OpenWRT or do you want to try LEDE? Sadly, there was a disagreement within the OpenWRT project, which resulted many of the most active developers leaving and starting their own project, LEDE.

It seems to have been a very amicable divorce, as both projects are now working together.

In this example, we will be using LEDE (where now most of the active development is taking place).

Firstly, you will need to download the source. For this, you will need to have 'git' installed.

The git command to do that is:

git clone https://git.lede-project.org/source.git

The following steps are to set things up before compiling. It is very handy to have LuCI (the web-interface) already installed. The steps for this are:

cd source/
./scripts/feeds update packages luci
./scripts/feeds install -a -p luci

Now you're ready to set up your '.config' file, which you'll need to do the compile.

To do this, type (in the source directory) 'make menuconfig'

If you're using 'make menuconfig' for the first time, take a while to look around at all of the options.

Then choose which options you'll want for the compile. After saving your options, the next step is to do a 'make' -- and this could last a while (depending on your computer).

Once the compile is done, check the '/bin' directory for the results.

If you want to stay with OpenWRT, here are the git links:

git clone git://git.openwrt.org/15.05/openwrt.git <- stable branch
git clone git://github.com/openwrt/openwrt.git <- 'trunk' branch

To keep your directories up to date, use 'git pull' (of course, in the source directory).

Regarding the WRT610n v1, it's running fine on LEDE as a repeater. Until the first LEDE stable version comes out, I'll update the bin file about once a month.

https://wikidevi.com/wiki/Linksys_WRT610N_v1
https://wiki.openwrt.org/toh/linksys/wrt610n

And a screenshot for those who care:




Thursday, 11 August 2016

Linksys EA6500 with DD-WRT

The EA6500 (Version 2) is a very high quality router. In fact, it's almost as powerful as a Raspberry PI 3 -- if it had one gig of memory and more disk space, it could be used as a cheapo computer.

DD-WRT has very good firmware for the EA6500. The install was very painless and the performance of the firmware has been great.

root@ea6500:~# uname -a
Linux ea6500 4.4.6 #565 SMP Mon Apr 4 05:06:33 CEST 2016 armv7l DD-WRT

It seems that the wireless supported is limited on OpenWRT (which is such a shame). 

Shibby Tomato also supports the EA6500. 

CPU:

root@ea6500:/proc# cat cpuinfo
model name : ARMv7 Processor rev 0 (v7l)
processor : 0
BogoMIPS : 1594.16
Features : half fastmult edsp tls 
CPU implementer : 0x41
CPU architecture: 7
CPU variant : 0x3
CPU part : 0xc09
CPU revision : 0

model name : ARMv7 Processor rev 0 (v7l)
processor : 1
BogoMIPS : 1594.16
Features : half fastmult edsp tls 
CPU implementer : 0x41
CPU architecture: 7
CPU variant : 0x3
CPU part : 0xc09
CPU revision : 0

Hardware : Northstar Prototype
Revision : 0000
Serial : 0000000000000000

https://wikidevi.com/wiki/Linksys_EA6500_v2

http://linuxwireless.org/en/users/Drivers/b43/

https://forum.openwrt.org/viewtopic.php?id=44218 (OpenWRT discussion about the EA6500)

Note: the EA6500 has no fan and the CPU can run very hot -- make sure that room temperature is not that hot, otherwise the router will crash.



Tuesday, 5 July 2016

E1200v2 with DD-WRT

DD-WRT works very well on the E1200v2, it's very solid.

However, there is one little bug (or maybe feature?).

Just after DD-WRT has been installed and you need to access the router for the very first time, the wired connection will not work. Odd.

Luckily, the wireless connection (ssid: DD-WRT) will work. Use the wireless connection to make the username and the password for the unit, then reboot the unit. After that, the wired and the wireless connections will both work fine.

Sadly, there are no wireless drivers with OpenWRT. Thus, DD-WRT would be the very best to use on this little router. I have it working as a router bridge, and it's doing very well.

Saturday, 2 July 2016

Unbricking a TP-Link Archer C7 Version 1.1 router

For those who like to play around with routers, we all know of the dangers of 'bricking' the router.

This can happen for many reasons, far more reasons than with your basic computer. Routers are nothing more than very, very cheap (and sometimes) very badly made computers. They are designed to do a very simple function -- routing packets.

When something has gone wrong, like that new version of DD-WRT or OpenWRT doing something which it should not do, your router could get bricked. Ouch. That can be painful.

Luckily, the TP-Link Archer C7 Version 1.x was well enough engineered for idiots like me. Yes, if you brick your Archer C7 Version 1.x, you can put the TP-Link firmware back on it.

When you have determined that you have bricked your router (like when it is not responding anymore and doing a 30/30/30 reset does nothing), then you would need to do the following:

Firstly, what you will need to do is to set up a TFTP server on your computer. Since I use Lubuntu, I installed atftpd. Secondly, you will need to put a static IP number on your ethernet card. It must be 192.168.0.66 (netmask: 255.255.255.0, no need for a gateway setting).

From the tcpdump I did (sudo tcpdump -i eth0 -- it's a good idea to run this so you can see what is happening), I saw the following:

15:18:51.119586 IP 192.168.0.66.40064 > 192.168.0.86.tftp:  35 WRQ "ArcherC7v1_tp_recovery.bin" octet

There you can see that the very well designed Archer C7 is looking for a TFTP server on 192.168.0.66 (the Archer C7 is on 192.168.0.86). To activate this on the Archer C7, press the reset button quickly while the unit is booting up. Make sure ufw or iptables aren't in paranoid mode, otherwise access to the router will be blocked.

And you will need to rename the Archer C7 firmware to 'ArcherCPv1_tp_recovery.bin'. On your atftpd server, you will need to place the ArcherCPv1_tp_recovery.bin in the right place -- and I wasn't sure where the right place is, so I put it in both /tftpboot and in /srv/tftp/. Make sure that the file permissions are in order.

On your tcpdump you should see the Archer C7 take the file and then reinstall the firmware. Afterwards, you should be able to boot back into the TP-Link firmware and you'll be ready again to brick your router.

We all learn from our mistakes -- and that's why I keep making them.

TP-Link Archer C7 Version 1.1 on DD-WRT


The TP-Link Archer C7 Version 1.1 is a quality router. It makes use of Atheros chips which have proven themselves often enough in many quality routers.

However, there is one little problem with the Archer C7 Version 1.x. The 5GHz wireless mini-pci card which it comes with does not have support for open source drivers. This is very sad, as the unit
is very good. The chip in question is the Qualcomm Atheros QCA9880-AR1A. As far as I know, there will never be any support for this chip (unless some type of miracle happens).

Installing OpenWRT/Lede is fairly straight forward on Archer C7 1.1. However, the 5GHz card will not work. It will boot up just fine, but don't expect the see the 5GHz card working. 

With DD-WRT there is a bigger problem -- DD-WRT won't even boot if the 5GHz card is still in the slot. If you want to use DD-WRT with this router, then you will need to take the 5GHz card out of the slot.

And keep in mind, if you are using the TP-Link firmware, the unit will not boot if the 5GHz pci-mini card is not in its slot. 

There are alternatives to the QCA9880-AR1A card, but those alternatives aren't that cheap.