Use V3 firmware for a TP-Link TL-WR940N V4 (EU) router?

Post new topic   Reply to topic    DD-WRT Forum Index -> Atheros WiSOC based Hardware
Goto page Previous  1, 2, 3  Next
Author Message
maddoctor
DD-WRT Novice


Joined: 20 Nov 2011
Posts: 12

PostPosted: Tue Aug 22, 2017 22:05    Post subject: Reply with quote
I've been looking at it and bmon seems like a "real time" bandwidth monitor, not what you want. vnStat might be a better option and it even has a luci interface... The problem is that packeges and logs take space and that router has very little of that... Not sure it is possible...
Sponsor
Lighting
DD-WRT Novice


Joined: 21 Aug 2017
Posts: 11

PostPosted: Wed Aug 23, 2017 1:27    Post subject: Reply with quote
Thanks, for looking into it, maddoctor!

Yeah, I also found vnstat but wasn't able to roll a dice. Doesn't look like there's enough space to just install it. In fact, I kinda got it installed? but I believe there was no space to install luci interface, cause vnstat was in the list of installed in the end, but luci-vnstat wasn't and I wasn't sure how to access/run it. Should it be in the dropdown menu, some menu for custom scripts or should I refer to it straight through its service port?

Also, after realizing that I can't get a decent bandwidth monitor on this build I've tried to flash dd-wrt from LEDE's interface. Apparently, I wasn't able to so referring to your previous message "After that use sysupgrade to flash the dd-wrt firmware for wr940n v3 ou wr941nd v6, using the -F flag" did you mean using the -F flag when flashing thru TFTP? I got your build installed straight from TP-Link's original firmware (just for the record).

Edit: If possible and if that will net any additional space we can consider removing firewall from the build, as this router will be always used for the intranet purposes.

Thanks a lot!
maddoctor
DD-WRT Novice


Joined: 20 Nov 2011
Posts: 12

PostPosted: Wed Aug 23, 2017 10:55    Post subject: Reply with quote
Well, to flash dd-wrt the way I said, you'll have to use the ssh shell... The easyest way to upload the image to the temp folder is using the scp server (use winSCP for example). Anyway, dd-wrt has some limitations on this hardware - you'll loose the WAN port, for example (you'll have to disable it to get LAN working)
maddoctor
DD-WRT Novice


Joined: 20 Nov 2011
Posts: 12

PostPosted: Wed Aug 23, 2017 11:39    Post subject: Reply with quote
Sorry, but no go! I can't fit it into that size... And believe me, I've tried it!
Lighting
DD-WRT Novice


Joined: 21 Aug 2017
Posts: 11

PostPosted: Wed Aug 23, 2017 11:52    Post subject: Reply with quote
maddoctor wrote:
Sorry, but no go! I can't fit it into that size... And believe me, I've tried it!


Thank you so much for trying it, maddoctor, sad fact but no problem!

Also, WAN isn't an issue, as I've mentioned this router will be solely used as a repeater. But having LAN killed after the flash process could be a huge issue as I currently don't have offline access to it so can tweak only remotely and wifi is used for the internet connection.
Any ideas on what can be done here? And what commands do I use after uploading the image to the router using WinSCP?
maddoctor
DD-WRT Novice


Joined: 20 Nov 2011
Posts: 12

PostPosted: Wed Aug 23, 2017 21:39    Post subject: Reply with quote
Well, after flashing the router you'll have only wifi. Access it using the wifi and disable the wan... After that you'll have LAN working...

Take this with a grain of salt, as I don't remember exactly how I did it but I think it was (after uploading the file tl-wr941ndv6-webflash.bin to /tmp):

dd bs=28 skip=1 if=/tmp/tl-wr941ndv6-webflash.bin of=/tmp/firmware.bin
mtd -f -r write /tmp/firmware.bin firmware

Disclaimer: I'm not responsible if you brick it! Wink
As I said, I don't remember it exactly...
Lighting
DD-WRT Novice


Joined: 21 Aug 2017
Posts: 11

PostPosted: Wed Aug 23, 2017 22:54    Post subject: Reply with quote
So at this stage, I can skip factory-to-ddwrt.bin and get straight to flashing the newest image? Neat.

Alright, I'll let you know if I'll decide to give it a try and how it goes. I believe that's also the only way to get back the stock firmware?

Okay, thanks a bunch for all your help! (:
Lighting
DD-WRT Novice


Joined: 21 Aug 2017
Posts: 11

PostPosted: Thu Aug 24, 2017 3:53    Post subject: Reply with quote
Okay, so I was playing with one "laboratory mouse", which is TP Link 841 v11 (quite a similar piece); just to get hang on all the process of flashing that 940 v4. Cause as I've mentioned before this one I'm flashing remotely so need to put trial and error to the minimum as it's gonna be not that easy to recover it as something you can keep in your hands (:

I've started from putting a LEDE build on it (just to be as similar to the actual patient as possible). No issues here. Then, I went to the part with flashing DD-WRT on top of LEDE using the commands you provided me with.

After the flash was done, I've got this:


Basically, put a brick on it. I'm not sure what was the exact issue. I suppose it's cause I've tried to flash factory-to-ddwrt.bin? Or was just some random I/O issue (also if that's the case there might be some weird bug caused by multiple connections to the router through SCP and SSH at the same time; as I've connected to the router through SCP after the first command dd bs=28 skip=1 if=/tmp/*** of=/tmp/firmware.bin to check if the file was indeed renamed, and I've noticed huge lags just navigating thru folders. So I've closed the SCP and then noticed that SSH lost its responsiveness (it took a while for the second flashing command to take place))

...anyway, back on track! Then I met TFTP closer cause there was no way to evade this "meeting" at this point, and it was quite friendly; flashed the original firmware, then flashed LEDE and afterward used SSH to flash DD WRT again but this time using the webflash.


looking good, we have DDWRT using maddoctor's commands! (:

Then I've turned off WAN. If that's the way it meant to be turned off?

Was a bit puzzling to get it work as a repeater without WAN but it did work in the end, though, I'm not sure if that will go the same way with 940 v4. We'll see tomorrow.

One more con I've noticed:

We are losing traff monitor with WAN being disabled and that's pretty much the case we are doing this all for... Unless we will keep WAN enabled? Though, we don't really need LAN ports working after everything is setup.

A few things to keep in mind that I've encountered while flashing DDWRT and recovering router (for those who will get in the same place):
1) If you have an antivirus with a firewall (in my case NOD32) make sure you disable that firewall before using TFTP otherwise it won't be possible to get a server running. The issue here is that we don't get any prompts to open the firewall ports as what we will see if just use windows' built in firewall.
2) Flash tl-wr***nd-webflash.bin straight ignoring factory-to-ddwrt.bin
3) When using TFTP, there is no need for disabling all others LAN/WiFi adapters and also you can keep the server's interface on 127.0.0.1; there is no need for switching it to 192.168.0.66 as it's the same local machine.
Lighting
DD-WRT Novice


Joined: 21 Aug 2017
Posts: 11

PostPosted: Thu Aug 24, 2017 21:00    Post subject: End Reply with quote
Alright, so this quest is over. I was able to get DD-WRT on my TP-LINK 940 v4 up and running as a repeater; with working internet and a bandwidth monitor. Thanks a lot maddoctor for your great help throughout this whole process!



Not exactly sure why it shows as 941 v6 as I clearly flashed 940 v3 but who cares! Cool

Step by step guide for those who want to get that DD-WRT on their 940 v4 router:

1. Download the firmware. I used this one ftp://ftp.dd-wrt.com/betas/2017/08-22-2017-r33180/tplink_tl-wr940ndv3/tl-wr940ndv3-webflash.bin so it's already being tested and tend to work but you can lurk for the newer version as this one can get obsolete at the time you're following these steps
2. Download Putty and WinSCP
3. Download LEDE with LuCI GUI build provided by maddoctor on the first page in this topic ( filename - WITH_LUCI_relayd_and_igmpproxy_lede-wr940nV4.zip )
4. Flash LEDE into your router using the default TP Link GUI (If you want just LEDE with LuCI you can end on this step and go into setting up your router)
5. Connect to your router through SCP protocol using WinSCP tool and upload the file tl-wr940ndv3-webflash.bin into /tmp folder
6. Close your WinSCP and open Putty. Then connect to your router using SSH protocol (the login should be root and there should be no password)
7. Use command #1: dd bs=28 skip=1 if=/tmp/tl-wr940ndv3-webflash.bin of=/tmp/firmware.bin
8. Use command #2: mtd -f -r write /tmp/firmware.bin firmware (if you see "Rebooting ..." in the end, then most likely the process went OK; otherwise if you see ..I/O error and all lights on your router started to blink, then probably something went wrong and router bricked; don't worry, this is fixable through TFTP)
9. Connect to your router thru WiFi (SSID: dd-wrt) as LAN won't be working at this stage
10. Navigate to Setup -> Basic Setup and look for "Wan Port" section, then put a checkbox on "Assign WAN Port to Switch" and finally click on "Apply Settings" (this should bring your LAN ports back, including WAN (blue port) that will be working as another simple LAN port at this stage

Now to get repeater working:
Setup a connection to your main router. Use Status -> Wireless -> Site Survey to find it fast and join.
It should redirect you to Wireless -> Basic Setup.
Change Wireless Mode to a client then add a virtual interface Wireless Mode - AP for that one; name it as you like your repeater's network be called, press Save and switch to the Wireless Security tab. Put a wifi password that you have on your main router (to connect to it) and another password for your newly created network. Click on Apply Settings and after that try connecting to your new router and look if it has the internet on it. If it doesn't then go back to Setup -> Basic Setup and make sure that your "WAN Connection Type" is set to "Automatic Configuration - DHCP" then scroll to the bottom and check that DHCP Server's radio-button is set to "enabled". Click on Apply Settings the last, hopefully, time and enjoy your new fully operational router!
braco
DD-WRT Novice


Joined: 16 Aug 2017
Posts: 6
Location: Bosnia and Hecegovina

PostPosted: Fri Aug 25, 2017 11:35    Post subject: Re: Here you go... Reply with quote
how to instal this
maddoctor
DD-WRT Novice


Joined: 20 Nov 2011
Posts: 12

PostPosted: Sun Aug 27, 2017 10:53    Post subject: Reply with quote
Glad I could help!
About flashing the 841,I told you to use the web flash file from the beginning... If you wanted to use the factory file you'd have to strip a bigger part of the image and not only the first 28 bytes... Wink
You should also mention that your setup keeps the network created by the repeater "isolated" from the main network, on a different subnet. If you want both networks to work "as one" you need a different setup - for that I needed to use lede with relayd... Maybe it is possible on dd-wrt, but I couldn't make it work.

Finally, it shows up as 941nd, because the 941ndV6 is a 940nV3 with detachable antennas... Wink
Lighting
DD-WRT Novice


Joined: 21 Aug 2017
Posts: 11

PostPosted: Sun Aug 27, 2017 14:34    Post subject: Reply with quote
Yeah, I kept that in mind but as I wasn't 100% sure about that, went the usual way (factory to ddwrt first). Anyway, I got a nice experience from that. Bricking router and learning how to fix it makes you more confident in further flashes, hah!

Yeah, there is no need for the communication between PCs in both networks, so this way totally works; I believe for them to see each other we need to use DHCP-forwarder instead of DHCP-server. But we will probably meet some routing/firewall issues. Gonna look into it closer.
Lighting
DD-WRT Novice


Joined: 21 Aug 2017
Posts: 11

PostPosted: Sun Aug 27, 2017 21:59    Post subject: Reply with quote
Here are the settings to make the repeater work within the main router's subnet:






It took me a very... while to pinpoint the issue with glitching internet. It was half working half not... Like skype did work but the browser wasn't able to resolve googles IP (google not loading) or when I tried to open google images and scroll down - none of the images were loading, only those that preloaded and were visible right after my search query. And it started to behave that way only after a few seconds to 10 minutes of router working. I thought that the problem was related to DNS so I was digging into that side with no luck. Then I spotted one article around setting up the repeater and it had something I missed to try - putting a checkbox on Filter Multicast. Unfortunately, it didn't do anything but gave me an idea to also try the Filter WAN NAT Redirection checkbox as it sounds quite related to the issue and voila it works for about two hours so far without problems. Tried to reboot the router a few times, doesn't look like anything changes into the bad side. Still can't be sure that it's the 100% fix but that's already something to work with.

The main con is that we have WAN disabled, therefore I can't use traff monitor, so this cup of tea isn't for me. But I hope that maybe it'll work for you if you'll ever decide to give DD another try on those routers Wink
maddoctor
DD-WRT Novice


Joined: 20 Nov 2011
Posts: 12

PostPosted: Sun Sep 03, 2017 17:15    Post subject: Reply with quote
Thank you for the feedback and for trying to find a solution, but for now I have LEDE working like a charm... Maybe I'll try that latter... Wink
peppelr
DD-WRT Novice


Joined: 26 Feb 2013
Posts: 9
Location: Italy

PostPosted: Sun Sep 24, 2017 22:42    Post subject: Re: Here you go... Reply with quote
Hi, I'm novice on this forum, but I follow it from some years.
I installed dd-wrt firmvare to several TP-Link WR-TL841N for my WiFi network.
So I buyed a TL-WR940N v4 and I would to install dd-wrt.
I found finally this thread.
I followed Step By Step guide using Lede official firmware some times without error, but after reboot the router brick asking DHCP lease and not responding to any IP packet.
I tried also ddwrt-to-factory, but router was bricked in infinite reboot status.
Fortunately I always recovered the router with TFTP procedure.
So I installed the maddoctor Lede+Luci build And it works fine, but I would know if 3x3 Mimo feature in Enabled.
Thank you.
Goto page Previous  1, 2, 3  Next Display posts from previous:    Page 2 of 3
Post new topic   Reply to topic    DD-WRT Forum Index -> Atheros WiSOC 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 cannot attach files in this forum
You cannot download files in this forum