Asus RT-N13U

From DD-WRT Wiki

Revision as of 03:58, 12 August 2010 by MicroClue (Talk | contribs)
Jump to: navigation, search

The Asus RT-N13U rev 1 is now supported and the latest builds are quite stable.

Recently Asus released the revision B1 of the RT-N13U. The B1 revision has a different flash chip, and current images will NOT work on revision B1 of the device. There should be B1 clearly printed on the bottom of your device, if it is of revision B1.

Much thanks to those who got DD-WRT working on the RT-N13U!


Device Specifications

Power Supply = 12VDC 1,0A

Ethernet Ports = 1x WAN RJ-45 10/100 Base T, 4x LAN RJ-45 10/100 Base T

Antennas = 3x internal antennas

USB ports = 1x USB2.0

Wireless standards supported: 802.11b (max. 11 Mbit/s), 802.11g (max. 54 Mbit/s), 802.11n (max. 300 Mbit/s, 2.4 GHz only)

RAM = 32 MB (64 MB in rev B1)

Flash = 4 MB (8 MB in rev B1)

CPU = Ralink RT3052F clocked at 384 MHz

Flashing DD-WRT to a stock Asus RT-N13U

Firefox sometimes has problems with newer DD-WRT builds. It is recommended that you use either Internet Explorer or Chrome

This works ONLY on revision 1, NOT revision B1!!!

1. Get the latest firmware from the main page (Just search for RTN13U):

You need the asus-to-ddwrt.trx file for initial flashing.

2. To prevent issues and delays while waiting for DHCP to assign an IP, just set a static IP.

IP: through

It is also recommended that you disconnect all other connections, apart from the one you're working on. Also disable all network adapters, except the one that the RT-N13U is connected to, on the machine you're working on. This is to prevent issues with the Asus Firmware Restoration Utility.

3. Disconnect power adapter from the RT-N13U.

4. Push and hold the button located under the router labeled "restore". While continuing to hold the restore button, plug the power adapter back into the router. If the power LED starts to blink, you can let go of the restore button. The router is now in restore mode.

5. You can now use the Asus Firmware Restoration utility to flash the asus-to-ddwrt.trx image to the router. If you do not have the Asus Firmware Restoration utility, you can install it from the CD included with the router. The process should only take about a minute or two. The Firmware Restoration utility will complete and report that the router is being rebooted, you can now close the utility. Give the router a minute, pull the plug, wait a few seconds, and then reconnect the power.

6. You can now set your network adapter to automatically obtain its IP address again.

7. If the flash was successful, you should be able to access the Web GUI. Enter into your browser, and set a username and password.

Automounting ext3/FAT/FAT32

The following tutorial is provided by Gouryella (taken from

The RT-N13U only has 4 MB flash, which is almost full with DD-WRT installed. Ext3 needs an extra 200 KB of storage, and the driver is not present in the DD-WRT firmware yet [BS].

I wrote a smart script that downloads the ext3 driver and mounts the 1st partition to /opt during boot (after WAN is up)

1. Just paste the following into the text box in Administration -> Commands and click Save Startup when complete:

mkdir /tmp/etc/config/
echo "wget -P /tmp/root/" >> /tmp/etc/config/ext3.wanup
echo "wget -P /tmp/root/" >> /tmp/etc/config/ext3.wanup
echo "wget -P /tmp/root/" >> /tmp/etc/config/ext3.wanup
#echo "wget -P /tmp/root/" >> /tmp/etc/config/ext3.wanup
#echo "wget -P /tmp/root/" >> /tmp/etc/config/ext3.wanup
#echo "wget -P /tmp/root/" >> /tmp/etc/config/ext3.wanup
#echo "wget -P /tmp/root/" >> /tmp/etc/config/ext3.wanup
echo "insmod /tmp/root/jbd.ko" >> /tmp/etc/config/ext3.wanup
echo "insmod /tmp/root/mbcache.ko" >> /tmp/etc/config/ext3.wanup
echo "insmod /tmp/root/ext3.ko" >> /tmp/etc/config/ext3.wanup
#echo "insmod /tmp/root/fat.ko" >> /tmp/etc/config/ext3.wanup
#echo "insmod /tmp/root/vfat.ko" >> /tmp/etc/config/ext3.wanup
#echo "insmod /tmp/root/nls_iso8859-1.ko" >> /tmp/etc/config/ext3.wanup
#echo "insmod /tmp/root/nls_cp437.ko" >> /tmp/etc/config/ext3.wanup
#echo "rm /tmp/root/*.ko" >> /tmp/etc/config/ext3.wanup
echo "mount /dev/scsi/host0/bus0/target0/lun0/part1 -o noatime,nodiratime /opt" >> /tmp/etc/config/ext3.wanup
chmod +x /tmp/etc/config/ext3.wanup
echo "nobody:*:65000:65000:nobody:/mnt:/bin/false" >> /etc/passwd

Enable the following under Services -> USB:

Core USB Support
USB 2.0 Support
USB Storage Support
Automatic Drive Mount

2. Reboot router with an ext3 formatted USB drive plugged in

If the drive was successfully mounted (which may take some time), uncomment the last echo to save +-500 KB RAM. Uncomment other lines for fat/fat32 support.


ls /tmp/root
cat /tmp/etc/config/ext3.wanup
ls /tmp/etc/config/

Installing Optware Light

The following tutorial is provided by Gouryella (taken from

1. Installing Optware (only to an ext3 drive)

wget -O - | tr -d '\r' > /tmp/
sh /tmp/
ipkg update
ipkg upgrade
wget -P /opt/bin
chmod +x /opt/bin/sort
ipkg install htop iperf libuclibc++ nano samba2 tftp-hpa vsftpd
killall xinetd
rm /opt/etc/samba/smb.conf
rm /opt/etc/vsftpd.conf
rm /opt/etc/xinetd.d/tftp
rm /opt/etc/init.d/S80samba
wget -P /opt/etc/samba/
wget -P /opt/etc/
wget -P /opt/etc/xinetd.d
wget -P /opt/etc/xinetd.d
wget -P /opt/etc/xinetd.d
wget -P /opt/etc/xinetd.d
wget -P /opt/etc/init.d
wget -P /opt/etc/init.d
chmod +x /opt/etc/init.d/S98iperf
sh /opt/etc/init.d/S10xinetd
chmod 777 /opt

You now should be able to access /opt/ through or through samba \\, swat.

Note: Change the gateway in, if you have different IP range.

2. My choices for basic testing:

htop - 0.8.3-1 - An interactive process viewer.
iperf - 2.0.4-1 - A tool for measuring TCP and UDP bandwidth performance.
nano - 2.2.4-1 - A pico like editor
samba2 - 2.2.12-2 - Lightweight Samba suite provides file and print services to SMB/CIFS clients.
tftp-hpa - 5.0-1 - A tftp package (for pxe booting)
vsftpd - 2.2.2-1 - ftp daemon with an emphasis on speed and security
xinetd - 2.3.14-9 - Highly configurable, modular and secure inetd

3. Test results:

USB flash vsftpd speed:

dither 1-2,5MB/s write (checked also USB 2.5" HDD 3.5MB/s constant)
6MB/s read

USB flash samba2 speed:

1MB/s write
4MB/s read


67,6Mbit/s CPU usage near max

Transmission daemon running:

Installing a Network Printer onto Asus RT-N13U

As of v24-PreSp2 (first versions to work on Asus RT-N13U) jffs was removed due to the lack of space available. However, Brainslayer put the support of network printing onto the firmware, enabling use of a network printer. Special Thanks for TimeKiller for figuring out most of the solution.

1. First enable USB support

Enable the following under Services -> USB:

Core USB Support
USB 1.1 Support (UHCI)
USB 1.1 Support (OHCI)
USB 2.0 Support
USB Printer Support

2. Startup Settings

Go to Administrations -> Commands, and add this:

sleep 4
mkdir -m 755 -p /dev/usb
mknod -m 660 /dev/usb/lp0 c 180 0
/usr/sbin/p910nd -f /dev/usb/lp0 1 

Save on the Startup.

3. Reboot and Install Drivers

Reboot the router, then install drivers through tcp/ip (9101)

For Windows 7:

Go to Devices and Printers
Then, press Add a Printer
Got to Network Printers
Skip the detection, as Windows will not find anything
Go to "Add a printer using a tcp/ip address or hostname"
Device type: Autodetect
Hostname and ip address: your router's ip (default
Port Name: Anything (puts your router's ip by default)
After it says it could not detect a printer, select custom, then Advanced
Make sure the protocol is RAW and change the Port Number is 9101
Install your drivers and finish.

You should print a test page to see if it works.

4. Troubleshooting If the test page does not come, try these settings instead:

Go to Administrations -> Commands, and add this:

sleep 4
chmod +rwx /usr/sbin/p910nd 
mkdir -m 755 -p /dev/usb
mknod -m 660 /dev/usb/lp0 c 180 0
chmod +rwx /dev/usb/lp0
/usr/sbin/p910nd -b -f /dev/usb/lp0 0 

Save again on the Startup. Reboot then follow the steps above but instead of port 9101, put in 9100. You should print a test page again to see if it works. If it doesn't work, you somehow did not follow the instructions correctly.