Monday, November 23, 2015

Supercharge your DLink DSL-2750u with OpenWrt

This articles talks about how to install OpenWrt on D-Link DSL-2750U-C1 router. if both terms are new for you, then probably you are in the wrong place. But for the curious, DSL-2750U is a wireless ADSL2 router with 4 LAN ports and the product page is here and OpenWrt is a Linux distribution for embedded devices with a special emphasis on routers.

Note: This article talks only about DSL-2750U-C1 which is based on Broadcom chipset and the steps will not help for DSL-2750U-U1, which is based on RTL chipset. Please contact openwrt if you happen to have the latter.

Disclaimer

Please pay attention as there is a fair chance that you might brick the router and make it completely useless. You are completely on your own and I am not responsible for any direct or indirect consequences for following these steps or any recommendations that I a make. So turn back now if you are unsure.

Why OpenWrt

So you don't go by warnings, lets risk it then.
The benefits of installing OpenWrt is that you can do almost anything with your router respecting the hardware capabilities. OpenWrt is still limited by the fact that there is no ADSL support, so if you are looking to use as an ADSL router then you are better off with the default firmware.

There is already a long list of OpenWrt supported routers but unfortunately as of this writing this particular model is not supported. This router is completely supported by the OpenWRT firmware, see below for details. My main interest was that I have this router and want to use this to extend  my wireless connection to an old wired desktop computer.

How to flash

The trick is that  you can use the firmware for A4001N for flashing this device, like this one here,  https://downloads.openwrt.org/chaos_calmer/15.05/brcm63xx/generic/openwrt-15.05-brcm63xx-generic-A4001N-squashfs-cfe.bin.
I have picked the latest firmware linked on this page here and the wireless and ethernet work fine with this firmware. My primary use of the unit is as a router, connecting wirelessly to my home wifi and providing connectivity to my desktop (no wireless capability) and printer in my garage.

For flashing, the OEM firmware-update through the web interface will not work. You have to use the CFE (bootloader) web interface (hold on reset button while powering on the router), refer https://wiki.openwrt.org/doc/techref/bootloader/cfe#using_cfe_web_http_server.

Just to summarize the flashing steps,
- Assigning static ip to your machine which is connected to router using a LAN cable
- power off the router, press the reset, power on the router *keeping* the reset pressed, release after few seconds when the light goes red
- Point your browser to 192.168.1.1 (remember to clear caches of the browser if you have problems in accessing the page)
- upload the firmware through the web interface, it will take few minutes and restart
- Remove the static IP for your machine and configure to do DHCP and Enjoy

How did I find it

 Initially, I tried with the closest-matching name logic and picked up the DSL-2740 firmware.  I was able to flash it and the ethernet port worked but the WiFi didn't as it had an Atheros chip. I slipstreamed various bcm drivers but it all failed in the step "get the SPROM". Later I worked through the code and found out that the board files have static  SPROM entries for each of the bcm43xxx chips. So I had to pair with a OpenWrt firmware configuration which matched the SoC 63xx and wifi chip BCM43225, so that it can use the static SPROM definition.  This is how when I found A4001N as one such configuration. I had to use the serial port to examine the boot loader and kernel output. I used an Arduino Uno for connecting to the serial port of the device  and minicom terminal (115200bps, no-hw/no-sw flow control, 8bit, 1-stop bit) in Linux to capture the output/input.


Every now and then I see questions in OpenWrt forums about this device, so thought of sharing this info hoping to be useful for someone. Thanks for reading.