Since Asuswrt-Merlin is mostly a variant of the original Asuswrt, it means that there is no special procedure to flash it. Just flash it the same way you would flash any regular Asus firmware (Administration -> Firmware Upgrade -> New firmware File).
Starting with Asus's 22.214.171.124.380_3000, a new firmware format is used. To flash Asuswrt-Merlin on one of these newer firmwares, you will need 380.61 or newer. Likewise, downgrading to an older version is not supported. (Try firmware recovery mode if you really need to downgrade.)
The RT-AC68U and RT-AC56U need to be at least on firmware 378.55 (or the last 378.xxx version from Asus) before you can flash 380.xx, due to the partition size change.
It's recommended to reboot the router before flashing it, to free up sufficient memory. Otherwise, there's a chance the router might reject the firmware, due to running too low of free RAM.
If coming from a non-Asuswrt firmware, you will have to do a factory default reset.
While it is generally not necessary to restore to factory defaults, it's not a bad idea, especially if there is a big jump in version number (e.g. from 112 to 178). No need to do the 30/30/30 dance as required by DD-WRT - just do a plain Factory Default reset, or turn the device on while keeping the WPS button pressed. (The procedure can be different from one model to another.)
It is very hard to brick an Asus router. If something goes wrong during flashing, you can put your router in Recovery mode by powering it on while you keep Reset pressed. After your release it, the power LED will either blink or stay off (depending on the model). At that point, you can either access it through http://192.168.1.1 (make sure you first give your PC a static IP within the same range, e.g. 192.168.1.100), or through the Firmware Recovery Tool provided on Asus' support CD. You will then be able to flash a working firmware.
If something looks weird, don't waste too much time: save your settings, reset to factory default, reconfigure the basics, and see if the issue is resolved. If not, you can always restore your saved settings and do some more advanced troubleshooting.
It is not recommended to restore settings saved under a different firmware version. It might work, but there is no guarantee.
Step 3 - Enable SSH
Click "Administration" on the left side, then the System tab and the Yes option for Enable SSH and Allow SSH password login. Then scroll down and click Apply
Step 4 - Sign up for IPCT DDNS
If you haven't already, sign up for IPCT DDNS and create a hostname. The hostname will be the URL that to use for your DDNS. By default your current IP address and username will be used, but you can change that if you want.
The hostname will be assigned a unique API key after it is added. Make sure to keep this API key private. You can reset it at any time.
Step 5 - Turn off JFFS Formatting
We are going to put the custom DNS script on a partition that is wiped when the router reboots. You can disable wiping of this partition so the script stays there forever.
Log in to the Asus web interface. In the left pane under the Advanced Settings section, click Administration
Now click the System tab, under Persistent JFFS2 partition set Format JFFS partition at next boot to No
Set Enable JFFS custom scripts and configs to Yes
Scroll down and click Apply
Step 6 - Create Custom DDNS Script
You will need a program to SSH into your router. I recommend using PuTTY.
SSH into your Asus router (admin as user) and enter the jffs scripts folder
Create the ddns-start script by editing ddns-start by typing
Now copy these lines and paste them into the vi editor (in Putty right-click pastes). Make sure you first replace APIKEY with the API Key assigned to your host name in Step Four.
wget -q https://ipcamtalk.com/dyn?api=APIKEY -O - >/dev/null
if [ $? -eq 0 ]; then
Vi can be a little finicky and tricky, so make sure the entire code is there. You may have to type out some of the beginning part of the code. It cut off everything before the : in the url the first time I did it.
To save this file, click the ESC button on your keyboard, then type :wq and press Enter.
We need to make the script executable by typing the following code
chmod a+x /jffs/scripts/ddns-start
Step 7 - Enable the Custom DDNS Script
Log back into the Asus router web interface to enable custom DDNS.
Under Advanced Settings choose WAN
Click the DDNS tab and set Enable the DDNS Client to Yes
Set Method to retrieve WAN IP to Internal
Set Server to Custom (which uses the script we created before)
Enter your API key as the Host Name
After the router applies the new settings you should receive a message saying "Registration is successful.". Good job, you're done! Your hostname is now set to your global IP address and is fully integrated with your Asus router. If you do not receive this message then go over the integration again and make sure you typed the code exactly.
You can confirm it's working by checking the IPCT DDNS page. Your hostname should reflect your IP address.