D-Link DIR-400

From DD-WRT Wiki

Jump to: navigation, search


Contents

[edit] Hardware Specifications

CPU1: Atheros AR2318 (182 MHz)
FLA1: 4 MiB (Spansion FL032AIF)
RAM1: 16 MiB (ESMT M12L128168A)
Switch: Marvell 88E6060
ETH chip1: Atheros AR2318
USB Ports None
WI1 chip1: WI1 chip1: Atheros AR2318

[edit] Flashing Instructions

[edit] Prerequisites

  1. Download TFTP32/TFTP64
  2. See Where do I download firmware? for links to firmware. Look in the dlink-dir400 folder.
  3. Download Putty client or you can use any telnet clients(try to stay away from Windows built in telnet)

[edit] Procedure

In order to flash your router you need to do the following steps:

  1. Change your local IP adress to a static 192.168.0.2 and subnet mask to 255.255.255.0
  2. Connect an ethernet cable between your computer and DIR-400's WAN port
  3. Prepare Putty telnet session -- 192.168.0.1 port 9000
  4. Start pinging your router through a command line. Type ping 192.168.0.1 -n 900 (You don't really need to ping that many times)
  5. Power DIR-400 router on and wait for 2nd successful ping and then initiate putty telnet session.
  6. Press CTRL-C as soon as you see that boot script is executing (if you are using Putty ver. 0.60 or newer then you don't have to worry about this)
  7. Start TFTP server with linux.bin in TFTP root directory
  8. If you did everything right then you should see the following on the window of putty:

    Executing boot script in 1.140 seconds - enter ^C to abort
     ^C 
     RedBoot>
  9. Type ip_address -l 192.168.0.1/24 -h 192.168.0.2 and press Enter
  10. You should see the following:

    RedBoot> ip_address -l 192.168.0.1/24 -h 192.168.0.2
     IP: 192.168.0.1/255.255.255.0, Gateway: 0.0.0.0
     Default server: 192.168.0.2
  11. Type fis init and then
  12.  RedBoot> fis init
     About to initialize [format] FLASH image system - continue (y/n)?
  13. Type y and press Enter. Wait until the process is complete:
  14.  About to initialize [format] FLASH image system - continue (y/n)? y
     *** Initialize FLASH Image System
     And a descriptor for the configuration data size = 10000
     ... Erase from 0xbffe0000-0xbfff0000: .
     ... Program from 0x80ff0000-0x81000000 at 0xbffe0000: .
  15. Type load -r -b 0x80041000 linux.bin and press Enter>/li>
     RedBoot> load -r -b 0x80041000 linux.bin
     Using default protocol (TFTP)
     Raw file loaded 0x80041000-0x803bafff, assumed entry at 0x80041000
  16. Type fis create linux and press Enter (this one will take a while. DO NOT UNPLUG YOUR ROUTER)
  17.  RedBoot> fis create linux
     ... Erase from 0xbfc40000-0xbffba000: ........................................................
     ... Program from 0x80041000-0x803bb000 at 0xbfc40000: ........................................................
     prog_ok
     flash_addr = 0xbfc40000
     mem_addr = 0x80041000
     entry_addr = 0x80041000
     length = 0x37a000
     img_size = 0x37a000
     ... Erase from 0xbffe0000-0xbfff0000: .
     ... Program from 0x80ff0000-0x81000000 at 0xbffe0000: .
  18. Type fconfig and press Enter
  19.  RedBoot> fconfig 
     Run script at boot: true 
  20. Press Enter
  21.  Run script at boot: true
     Boot script:
     .. fis load -l linux
     .. exec
     Enter script, terminate with empty line
  22. Type fis load -l linux and press Enter
  23.  >> fis load -l linux
  24. type exec and press Enter
  25.  >> exec
  26. Press Enter
  27.  >> 
     Boot script timeout (1000ms resolution): 2 
  28. press Enter
  29.  Use BOOTP for network configuration: false
  30. press Enter
  31.  Gateway IP address: 
  32. press Enter
  33.  Local IP address: 192.168.0.1 
  34. press Enter
  35.  Local IP address mask: 255.255.255.0
  36. press Enter
  37.  Default server IP address: 192.168.0.100 
  38. press Enter
  39.  Console baud rate: 9600 
  40. press Enter
  41.  GDB connection port: 9000 
  42. press Enter
  43.  Force console for special debug messages: false  
  44. press Enter
  45.  Network debug at boot time: false 
  46. press Enter
  47.  Update RedBoot non-volatile configuration - continue (y/n)? 
  48. type y and press Enter
  49.  Update RedBoot non-volatile configuration - continue (y/n)? y
     ... Erase from 0xbffe0000-0xbfff0000: .
     ... Program from 0x80ff0000-0x81000000 at 0xbffe0000: .
  50. Type reset and press Enter
  51.  RedBoot> reset
  52. Re-connect an ethernet cable between your computer and DIR-400’s LAN port
  53. Change your local IP adress to a static 192.168.1.2 and subnet mask to 255.255.255.0
  54. [edit] Upgrading DD-WRT

    [edit] Recovery