The original firmware in upgrade contains a 96 bytes SEAMA-header followed by the kernel padded to 64KB, followed by the rootfs. Thus the rootfs is 96 bytes off from a 64 KB boundary. Note that the SEAMA-header is variable size.
Download Firmware OpenWrt Install as shown above (*-squashfs-factory.bin)
Log in your routers admin interface
Tools → Firmware → Firmware Upgrade → Choose the file you just downloaded
OEM installation using the TFTP method
There may be an easier way to do this but this is what worked for me.
First, get your serial port going. At the moment the network interfaces aren't coming up so you'll need the console to work with it.
The file you're looking for is this DIR645A1_GPL101.tar.gz
Read the instructions and follow them till you get a successful build.
Once you get a build of the d-link linux, get your OpenWrt build going for this device (rt3883) but build an initramfs image.
You can use the usual tftp setup to get the initramfs running on there or you can burn it to the flash. The flash isn't supported out of the box with openwrt (as far as I can tell) so it'll need to be the initramfs kernel so that it loads everything in to ram. Hopefully someone can get the flash support going.
If you want to burn it in there you'll need to package it properly. Here's the generic procedure for this device using the dlink source for packaging it.
1. Get a kernel and a rootfs (if you build openwrt from the trunk these files will be in trunk/build_dir/linux-ramips_rt3883 as vmlinux and root.squashfs).
2. run these commands from the dlink directory (DIR645A1_GPL101).
(replace vmlinux and root.squashfs with correct location and names of appropriate files)
3. your image is in images as DIR645A1_FW101B06_c5fl.bin use options 2 in the serial console to burn the image to the device.
Again, if you use the kernel that comes from doing an initramfs build you'll be able to get in and work with it in ram and hopefully get the flash suport going so that a regular build can be put on.
Tftp is simple. Just set up a tftp server on a computer (probably the one that you built the image on). When the device boots up hit option 1 or 2 as appropriate (1 for ram image, 2 to burn it). The first option is the ip address for the device (the address you want the device to have), the second is the ip address of the tftp server and the third is the filename you want to grab (DIR645A1_FW101B06_c5fl.bin if you used the steps above).
Like other D-Link routers it has a built-in firmware recovery mode.
To access, simply hold down the reset button while powering on the router. The WAN LED should blink. Set your computer with a static IP in the 192.168.0.x range, and open 192.168.0.101 in a web browser. Recovery mode loads up within a few seconds, but doesn't respond to pings. If the power LED is blinking the above page should be accessible.
You will need to flash either a stock firmware image or OpenWrt-factory image, *not* a sysupgrade image.
→ Basic configuration After flashing, proceed with this.
Set up your Internet connection, configure wireless, configure USB port, etc.
The default network configuration is:
LAN & WiFi
LAN ports (1 to 4)
Switch Ports (for VLANs)
Numbers 0-3 are Ports 1-4 as labeled on the unit, number 4 is the Internet (WAN) on the unit, 5 is the internal connection to the router itself. Don't be fooled: Port 1 on the unit is number 3 when configuring VLANs. vlan0 = eth0.0, vlan1 = eth0.1 and so on.