Xiaomi MiWiFi R1D working build (Tested)

Post new topic   This topic is locked: you cannot edit posts or make replies.    DD-WRT Forum Index -> Broadcom SoC based Hardware
Goto page 1, 2, 3, 4, 5, 6, 7  Next
Author Message
bubbl3
DD-WRT Novice


Joined: 19 Feb 2010
Posts: 19

PostPosted: Sun Nov 09, 2014 12:42    Post subject: Xiaomi MiWiFi R1D working build (Tested) Reply with quote
Moderator note 05.13.21: The original thread linked in this post is no longer accessible. Official support for this device has never happened. Also, all images were removed from their original location and not archived on the internet, but what I could find has been given updated links from web.archive.org.

I claim no credit for the build or the flashing procedure, this is the original chinese thread: http://bbs.xiaomi.cn/thread-10591878-1-2.html

Build is based on Kong 24880, everything is working, WiFi 2.4GHz and 5GHz, USB, NAS. Don't mind the disabled WAN in my screens as I flashed DD-WRT mainly because I wanted to use this as AP/NAS.

Suggested build is now DD-WRT v24-sp2 (11/08/14) - build fkpwolf@24880 for MiWiFi R1D -> dd-r1d-2014.11.8.trx







I also repartitioned the HD and reserved some space for future experiments with optware.


Flashing is not that hard, but you need to enable SSH access on your stock firmware R1D, the official procedure is here:

https://d.miwifi.com/rom/ssh

It is important to login with your Xiaomi account and having the router registered under it (best way is with the android app, google it, I'm not going to spend time on this here) as the file is personalized for your router and the page will also tell you your root password.

The file you need to flash to enable SSH is miwifi_ssh.bin


Procedure to flash miwifi_ssh.bin:

1. copy miwifi_ssh.bin on the root folder of a FAT32 formatted USB key.

2. disconnect the power from the router and connect the USB key to it.

3. keep the reset button pressed while you connect the power, release the reset button when the router orange led starts flashing.

4. wait 3-5 seconds, router will restart and SSH will be available on port 22


Procedure to flash DD-WRT

1. Download somewhere on your PC the file dd-r1d-2014.11.8.trx attached to this post.

2. Open an SSH connection with the router.

3. In command line give these commands:

nvram set boot_wait=on
nvram set wait_time=10
nvram commit


4. Set your network interface address as 192.168.1.100 and open a command prompt, once opened give this command:

ping -t 192.168.1.1

5. Reboot the router and as soon as it pings open http://192.168.1.1 in Firefox/Chrome

You'll see a page like this:


Browse for dd-r1d-2014.11.8.trx and click Upload

Be patient, you'll get a message of successful upload and the router will reboot, it will take a while, as soon as it pings and the led is blue you can login on DD-WRT web interface.

The firmware language defaults to chinese, on the usual first boot screen set username, password, password confirmation.

Then follow this to set the language to English:


Scroll down and select English from the dropdown box:


Scroll at the end of the page and click Apply Settings:


Then go to Services->NAS and enable Samba, reboot the router and it will automount the internal HD.
All the files you had on it will be in /mnt/sda4

If you wish to repartition your HD, easiest way is to take it out, connect it to a PC (USB or internal) and partition it (ext2/ext3) with an utility (Acronis Disk Director for Windows or GParted for Linux).


FAN Noise

If you think the FAN is too loud, you can turn off fan speed management and it will run at the slowest speed.
Open an SSH connection and use these commands:

nvram set fancontrol=off
nvram commit


Going back to the original firmware

THIS WILL FORMAT YOUR HD, BACKUP YOUR DATA

1. Download miwifi-stock.bin attached to this post and copy it on a FAT32 formatted USB key.

1. copy miwifi_ssh.bin on the root folder of a FAT32 formatted USB key.

2. disconnect the power from the router and connect the USB key to it.

3. keep the reset button pressed while you connect the power, release the reset button when the router orange led starts flashing.

4. this will take a while so be patient, the stock firmware will be flashed and the HD formatted, when the led is blue, you're done.

Do not try to flash the firmware from DD-WRT web interface, it will get stuck and brick the router!


Revisions

20-11-2014

- new build tested and it fixes several bugs:

* long term file transfers no longer hang the router
* led is now blue after boot
* HD temp is now visible in UI
* router can be used without internal HD
* several UI fixes and enhancements

- removed the miwifi_ssh.bin attachment as each router needs its specific one
- revised the installation procedure
- better and tested back to stock procedure



dd-r1d-2014.11.8.trx
 Description:
DD-WRT v24-sp2 (11/08/14) - build fkpwolf@24880 for MiWiFi R1D

Download
 Filename:  dd-r1d-2014.11.8.trx
 Filesize:  12.39 MB
 Downloaded:  5434 Time(s)


miwifi-stock.bin
 Description:
Xiaomi R1D Stock Firmware

Download
 Filename:  miwifi-stock.bin
 Filesize:  15.63 MB
 Downloaded:  14748 Time(s)


DD-R1D.trx
 Description:
DD-WRT v24-sp2 (08/29/14) std - build fkpwolf@24880 for MiWiFi R1D

Download
 Filename:  DD-R1D.trx
 Filesize:  12.54 MB
 Downloaded:  2785 Time(s)



Last edited by bubbl3 on Thu Nov 20, 2014 7:58; edited 4 times in total
Sponsor
rkaede
DD-WRT User


Joined: 06 Aug 2009
Posts: 99

PostPosted: Mon Nov 10, 2014 7:29    Post subject: Reply with quote
this is good news Cool .

im waiting this router to be out in the market now.

if its KONG build. i believe it will be rock solid.

isnt the CPU temp abit high ?? 80 celcius u can make a coffee literaly.

thanks for the share

_________________
WZRHPG300NH - DDWRT v26854

ASUS AC68U merlin fw
Linksys EA6700 - factory firmware - sold
DD-WRT v3.0 --- 27506
r25408
bubbl3
DD-WRT Novice


Joined: 19 Feb 2010
Posts: 19

PostPosted: Mon Nov 10, 2014 8:13    Post subject: Reply with quote
rkaede wrote:
this is good news Cool .

im waiting this router to be out in the market now.

if its KONG build. i believe it will be rock solid.

isnt the CPU temp abit high ?? 80 celcius u can make a coffee literaly.

thanks for the share


The build it is based on was from Kong, but this one is from a Chinese guy.

I really doubt the temps are correct, the device is much cooler now than when it was stock.

I also got a bump in transfer speed on the internal HD, while writing to it I got 14MB/s on stock, now I was transferring on it at 47MB/s (200GB of Music collection).
rkaede
DD-WRT User


Joined: 06 Aug 2009
Posts: 99

PostPosted: Mon Nov 10, 2014 9:17    Post subject: Reply with quote
damn. thats alot of difference. is more than 2x of the stock firmware.
_________________
WZRHPG300NH - DDWRT v26854

ASUS AC68U merlin fw
Linksys EA6700 - factory firmware - sold
DD-WRT v3.0 --- 27506
r25408
bubbl3
DD-WRT Novice


Joined: 19 Feb 2010
Posts: 19

PostPosted: Sun Nov 16, 2014 9:41    Post subject: Reply with quote
Sources of the port: https://github.com/fkpwolf/dd-wrt
tsynik
DD-WRT User


Joined: 18 Apr 2014
Posts: 151

PostPosted: Mon Nov 17, 2014 6:57    Post subject: Reply with quote
As I see, there is not so much changes in sources. Main is Broatcom NAT acceleration enabled. Also, there is mention of x_netgear_6300v2 in main Chinese thread. So, probably this FW was originaly for Netgear 6300v2.

It will be cool to see support for this router in official repository! Ordered one, we'll see how it goes )
rkaede
DD-WRT User


Joined: 06 Aug 2009
Posts: 99

PostPosted: Mon Nov 17, 2014 8:04    Post subject: Reply with quote
Can i check on the WAN side. what is ur internet line speed ? i just want to know hows the routing speed of this router with ddwrt installed.
_________________
WZRHPG300NH - DDWRT v26854

ASUS AC68U merlin fw
Linksys EA6700 - factory firmware - sold
DD-WRT v3.0 --- 27506
r25408
tsynik
DD-WRT User


Joined: 18 Apr 2014
Posts: 151

PostPosted: Mon Nov 17, 2014 9:04    Post subject: Reply with quote
rkaede wrote:
Can i check on the WAN side. what is ur internet line speed ? i just want to know hows the routing speed of this router with ddwrt installed.

It must be the same as others Broadcom ARM routers like Netgear 6300v2 on Kong-s builds around 24880, because of kernel and processor are the same!

As Kong wrote about 24865:
Build 24865 15. Aug 2014 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

New:

-HW NAT option allow to switch HW NAT on and off (HW NAT is experimental and may not work for everyone, by default it is off)
-dnsmasq update 2.71
-update openssl 1.0.1i
-wireless TPC settings
-some wireless parameter optimizations (reset required)*

Fixed:

-segfault when starting 3G modem manager

*in order to get the changed params without a reset run the following params in telnet or ssh session:

nvram set wl0_frameburst=on
nvram set wl1_frameburst=on
nvram commit
reboot

HW Nat is disabled by default, so it even must be the same as BS builds witout tweaking.
bubbl3
DD-WRT Novice


Joined: 19 Feb 2010
Posts: 19

PostPosted: Mon Nov 17, 2014 12:47    Post subject: Reply with quote
The reference to 6300v2 was to specify to use that version of Xunlei optware (a chinese download manager).

For what I know this build should be based on R7000.
bubbl3
DD-WRT Novice


Joined: 19 Feb 2010
Posts: 19

PostPosted: Thu Nov 20, 2014 8:25    Post subject: Reply with quote
Finally had the time to test more, had problems with big file transfers (1h) with the router hanging so went back to stock as a new firmware was out, but still not AP mode, file transfers were fine.

Decided then to flash the newest build and boy, it's awesome, file transfers fixed and a lot more. I already updated the main post.

(I still think the temps are not correct, even with the fan at max it never goes under 65 degrees on CPU, but the unit is cool at the touch)

Some screens:




And yes, the led is finally blue again after boot!


Got the chance to hook a USB hdd dock to the router and test both internal and external file transfers (writing).
Got still 47MB/s to internal and a very good 30MB/s on external.
Phreaky
DD-WRT Novice


Joined: 01 Dec 2014
Posts: 6

PostPosted: Mon Dec 01, 2014 15:46    Post subject: Reply with quote
Excellent guide! Thanks!

However, not sure why but internet through WAN refuses to work - worked fine with the stable as well as development version of the firmware

Works fine when connected to one of the LAN ports - and even that started acting funny after a while. Thankfully, had taken a backup once the config was set and functioning - a reset and restore works fine (via LAN)

And am unable to flash the stock firmware - tried various versions too : router just keeps booting even when USB stick is plugged in, reset button pressed and turned on. But as long as this works fine, I wont be complaining Laughing
bubbl3
DD-WRT Novice


Joined: 19 Feb 2010
Posts: 19

PostPosted: Tue Dec 02, 2014 7:20    Post subject: Reply with quote
Phreaky wrote:
Excellent guide! Thanks!

However, not sure why but internet through WAN refuses to work - worked fine with the stable as well as development version of the firmware

Works fine when connected to one of the LAN ports - and even that started acting funny after a while. Thankfully, had taken a backup once the config was set and functioning - a reset and restore works fine (via LAN)

And am unable to flash the stock firmware - tried various versions too : router just keeps booting even when USB stick is plugged in, reset button pressed and turned on. But as long as this works fine, I wont be complaining Laughing


You can try the scary back to stock way:


1. Download miwifi-stock.bin and copy it on the internal HD of the router.

https://dl.dropboxusercontent.com/u/1767311/r1d/miwifi-stock.bin

2. Open an SSH connection and move to the path containing the file.

3. Use this command to flash the firmware:

mtd -r write miwifi-stock.bin linux


Reboot the router and bam! you bricked it, red led on boot and no sign of life. At least that is what happened to me probably because I repartitioned the drive.

At this point, if you get this red led situation, go and use the back to stock method in the op post.
chchia
DD-WRT User


Joined: 20 Dec 2009
Posts: 63

PostPosted: Wed Dec 03, 2014 2:17    Post subject: Reply with quote
I did a custom mod to overcome the temperature issues, this might looks very urgly but it does work well.



chchia
DD-WRT User


Joined: 20 Dec 2009
Posts: 63

PostPosted: Wed Dec 03, 2014 2:45    Post subject: Reply with quote
By the way, there is a newer version compiled on 15 Nov and posted on 24 Nov.

I do not take credit for this build, the credit should go to fkp@wolf. thank you!



DD-r1D-2014.11.24.zip
 Description:
Xiaomi Router R1D 2014.11.24 24880

fixed xunlei download which may caused router to hang.

Download
 Filename:  DD-r1D-2014.11.24.zip
 Filesize:  12.33 MB
 Downloaded:  1887 Time(s)

Phreaky
DD-WRT Novice


Joined: 01 Dec 2014
Posts: 6

PostPosted: Wed Dec 03, 2014 15:55    Post subject: Reply with quote
Looks like IP conflict was the reason for all issues - fixed now. However, the signal strength is slightly lower than what it was with stock. Need to test more on transfer speeds and the like
Goto page 1, 2, 3, 4, 5, 6, 7  Next Display posts from previous:    Page 1 of 7
Post new topic   This topic is locked: you cannot edit posts or make replies.    DD-WRT Forum Index -> Broadcom SoC based Hardware All times are GMT

Navigation

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum