OpenWrt Forum Archive

Topic: TP-Link TL-MR3020 Support

The content of this topic has been archived between 16 Jun 2013 and 7 May 2018. Unfortunately there are posts – most likely complete pages – missing.

Hi all!

I have used the official snapshot (squashfs, factory) for the MR3020 to test it on my device.
So far everything seems to work fine.

But the directory /etc/uci-defaults is empty. So the default setup of the LEDs is not set.
Does anybody know why this dir is empty?

Because all scripts in there are getting deleted after they ran.

jow wrote:

Because all scripts in there are getting deleted after they ran.

ok. I did not know that. But they have not done their job.

For example the "leds" script is supposed to setup two leds for the MR3020:
tl-mr3020)
        set_led_usbdev "usb" "USB" "tp-link:green:3g" "1-1"
        set_led_wlan "wlan" "WLAN" "tp-link:green:wlan" "phy0tpt"
        ;;

I do not see any "led" entries in /etc/config/system.

So something went wrong obviously.

Any idea?

No. Simply run the script manually and see if it works.

Look at /rom/etc/uci-defaults for the "deleted" scripts.

Nilfred wrote:

Look at /rom/etc/uci-defaults for the "deleted" scripts.

Thanks. Meanwhile I have found them. ;-)

I found a bug in my patch. The board type detected is "unknown" instead of "tl-mr3020". That's why the script did not work.

I am currently preparing a new patch. Before sending it the ML I have to test it.

Hi,
I think I bricked my TP-LINK TL-MR3020 v1.4...I tried to put openwrt (https://dev.openwrt.org/changeset/29651) by TP-LINK GUI...  When the router restart only the first led (power led) is on..
If I try to go on the web page of the router (192.168.1.1) return that "This web page is not available". By ssh command (i used putty), the client connects but I can not login to router (incorrect username and password, which I never set)..

What can i do?

Thanks!

(Last edited by Fado84 on 14 Jan 2012, 22:35)

Fado84 wrote:

Hi,
I think I bricked my TP-LINK TL-MR3020 v1.4...I tried to put openwrt (https://dev.openwrt.org/changeset/29651) by TP-LINK GUI...  When the router restart only the first led (power led) is on..
If I try to go on the web page of the router (192.168.1.1) return that "This web page is not available". By ssh command (i used putty), the client connects but I can not login to router (incorrect username and password, which I never set)..

What can i do?

Thanks!

I see two possibilities only:
1) Connect to the serial console to see if the bootloader is still ok. If it is still working, flash a new firmware using TFTP.
2) If the bootloader is broken, you will have to desolder the SPI flash chip and reprogram it with a backup copy from another user that owns a V1.4.
    There is a guide in the wiki somewhere which describes how to recover the bootloader in case it is broken.

Since you have flashed using the WebGUI, I think the chances are good that the bootloader is still ok.

The power LED is connected to power supply directly. So it will light up as soon as you apply power to the device.

What about the other LEDs? Do they flicker shortly after you have applied power or are they completely dark all the time?
From what I have seen from the bootloader source code, the LEDs should flicker shortly while the bootloader is initialising.

(Last edited by cille75 on 14 Jan 2012, 23:42)

Thanks a lot for your quick response cille75.

When I turn on the router all the LEDs light up and after about a second only the power LED is on.. like you've described.

Is there a simple, step-by-step guide to step 1? I'm a newbie...
Can I go directly to flash a new firmware using TFTP safely?

Thanks a lot.

Fado84 wrote:

Thanks a lot for your quick response cille75.

When I turn on the router all the LEDs light up and after about a second only the power LED is on.. like you've described.

Is there a simple, step-by-step guide to step 1? I'm a newbie...
Can I go directly to flash a new firmware using TFTP safely?

Thanks a lot.

Please have a look into the wiki:
http://wiki.openwrt.org/toh/tp-link/tl-mr3020

You should get the serial console working. After that you should try to print the environment of the bootloader to see if the flash laylout differs somehow.

Mine (V1.0) looks like this:

hornet> printenv
bootargs=console=ttyS0,115200 root=31:02 rootfstype=squashfs init=/sbin/init mtdparts=ar7240-nor0:256k(u-boot),64k(u-boot-env),2752k(rootfs),896k(uImage),64k(NVRAM),64k(ART)
bootcmd=bootm 0x9f020000
bootdelay=1
baudrate=115200
ethaddr=0xba:0xbe:0xfa:0xce:0x07:0x41
ipaddr=192.168.1.111
serverip=192.168.1.100
stdin=serial
stdout=serial
stderr=serial
ethact=eth0

Environment size: 362/65532 bytes
hornet>

The interesting part is this:

mtdparts=ar7240-nor0:256k(u-boot),64k(u-boot-env),2752k(rootfs),896k(uImage),64k(NVRAM),64k(ART)

If these numbers are equal, you could probably try the TFTP manual method from the wiki.

But first try to get the serial console working. Please post here the text output if you got it working.

Hi,

I'm pretty new to OpenWrt and wanted to install it on my brand new TP-Link TL-MR3020 to use it as a music streaming client. Installing OpenWrt via the WebInterface worked fine. No problems connecting over ssh and so i changed the IP and installend luci. When I wanted to continue today i couldn't acces it neither over luci nor over ssh  anymore, I get "Operation timed out". I also tried to get all IPs of the network, as I thought i have maybe the wrong IP but the ping gave me only my computer (when connected directly over ethernet) or my laptop and the main router (when connected to the main router via ethernet). I also tried to acces the default 192.168.1.1 and put the binary via tftp, didn't work either. For manual flashing as described in the wiki I would also need the IP.
Would be awesome if someone knew what to do smile
Thanks for your help

patr-x

@cille75: maybe tomorrow will came the cable CA-42, do the test and after I will post the results.

@patr-x: What about the LEDs? Maybe you have the same problem but I can read the IP  by ifconfig (linux) o ipconfig(win). Try to see if the bootloader is still ok.. Like I will do..
I'm a newbie like you..

Thanks

patr-x wrote:

Hi,

I'm pretty new to OpenWrt and wanted to install it on my brand new TP-Link TL-MR3020 to use it as a music streaming client. Installing OpenWrt via the WebInterface worked fine. No problems connecting over ssh and so i changed the IP and installend luci. When I wanted to continue today i couldn't acces it neither over luci nor over ssh  anymore, I get "Operation timed out". I also tried to get all IPs of the network, as I thought i have maybe the wrong IP but the ping gave me only my computer (when connected directly over ethernet) or my laptop and the main router (when connected to the main router via ethernet). I also tried to acces the default 192.168.1.1 and put the binary via tftp, didn't work either. For manual flashing as described in the wiki I would also need the IP.
Would be awesome if someone knew what to do smile
Thanks for your help

patr-x

I think that you have a misunderstanding of how the manual method via TFTP works.
You definitely need a serial console like Fade84. So you have to open the case (voids your warranty) and attach a serial adapter cable as described in the wiki to the PCB.
After you have got the serial console working, you can access the bootloader and thus the TFTP client of the bootloader. You must setup a TFTP server yourself on your PC which provides the image you want to flash over the network.
You also setup the IP address manually then as described in the wiki.

This is basic stuff. Please read the wiki about TFTP/bootloaders and search the web.

Hi,

Has their been a fix for the MR3020 led behavior?

Apologies if that one got past me.

Cheers.

mrzaphodb wrote:

Hi,

Has their been a fix for the MR3020 led behavior?

Apologies if that one got past me.

Cheers.

Hi!

Not yet. I have already fixed it in my sources, but I did not have the time to prepare the patch and send it to the dev mailing list.

Hi,
this is the output of serial console:

Boot log

U-Boot 1.1.4 (Oct 21 2011 - 16:26:38)

AP121-2MB (ar9330) U-boot

DRAM:  32 MB
led turning on for 1s...
id read 0x100000ff
flash size 4194304, sector count = 64
Flash:  4 MB
Using default environment

In:    serial
Out:   serial
Err:   serial
Net:   ag7240_enet_initialize...
No valid address in Flash. Using fixed address
No valid address in Flash. Using fixed address
: cfg1 0x5 cfg2 0x7114
eth0: 00:03:7f:09:0b:ad
ag7240_phy_setup 
eth0 up
: cfg1 0xf cfg2 0x7214
eth1: 00:03:7f:09:0b:ad
athrs26_reg_init_lan
ATHRS26: resetting s26
ATHRS26: s26 reset done
ag7240_phy_setup 
eth1 up
eth0, eth1
Autobooting in 1 seconds
## Booting image at 9f020000 ...
   Uncompressing Kernel Image ... OK

Starting kernel ...

[    0.000000] Linux version 2.6.39.4 (openwrt@OpenWRTBuild) (gcc version 4.5.4 20110808 (prerelease) (Linaro GCC 4.5-2011.08) ) #1 Mon Jan 9 08:21:43 MST 2012
[    0.000000] bootconsole [early0] enabled
[    0.000000] CPU revision is: 00019374 (MIPS 24Kc)
[    0.000000] SoC: Atheros AR9330 rev 1
[    0.000000] Clocks: CPU:400.000MHz, DDR:400.000MHz, AHB:200.000MHz, Ref:25.000MHz
[    0.000000] Determined physical RAM map:
[    0.000000]  memory: 02000000 @ 00000000 (usable)
[    0.000000] Initrd not found or empty - disabling initrd
[    0.000000] Zone PFN ranges:
[    0.000000]   Normal   0x00000000 -> 0x00002000
[    0.000000] Movable zone start PFN for each node
[    0.000000] early_node_map[1] active PFN ranges
[    0.000000]     0: 0x00000000 -> 0x00002000
[    0.000000] Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 8128
[    0.000000] Kernel command line:  board=TL-MR3020 console=ttyATH0,115200 rootfstype=squashfs,jffs2 noinitrd
[    0.000000] PID hash table entries: 128 (order: -3, 512 bytes)
[    0.000000] Dentry cache hash table entries: 4096 (order: 2, 16384 bytes)
[    0.000000] Inode-cache hash table entries: 2048 (order: 1, 8192 bytes)
[    0.000000] Primary instruction cache 64kB, VIPT, 4-way, linesize 32 bytes.
[    0.000000] Primary data cache 32kB, 4-way, VIPT, cache aliases, linesize 32 bytes
[    0.000000] Writing ErrCtl register=00000000
[    0.000000] Readback ErrCtl register=00000000
[    0.000000] Memory: 29224k/32768k available (2119k kernel code, 3544k reserved, 413k data, 192k init, 0k highmem)
[    0.000000] SLUB: Genslabs=9, HWalign=32, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
[    0.000000] NR_IRQS:80
[    0.000000] Calibrating delay loop... 265.42 BogoMIPS (lpj=1327104)
[    0.080000] pid_max: default: 32768 minimum: 301
[    0.080000] Mount-cache hash table entries: 512
[    0.090000] NET: Registered protocol family 16
[    0.090000] MIPS: machine is TP-LINK TL-MR3020 v1
[    0.340000] bio: create slab <bio-0> at 0
[    0.350000] Switching to clocksource MIPS
[    0.350000] NET: Registered protocol family 2
[    0.360000] IP route cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.360000] TCP established hash table entries: 1024 (order: 1, 8192 bytes)
[    0.360000] TCP bind hash table entries: 1024 (order: 0, 4096 bytes)
[    0.370000] TCP: Hash tables configured (established 1024 bind 1024)
[    0.380000] TCP reno registered
[    0.380000] UDP hash table entries: 256 (order: 0, 4096 bytes)
[    0.380000] UDP-Lite hash table entries: 256 (order: 0, 4096 bytes)
[    0.390000] NET: Registered protocol family 1
[    0.410000] squashfs: version 4.0 (2009/01/31) Phillip Lougher
[    0.420000] JFFS2 version 2.2 (NAND) (SUMMARY) (LZMA) (RTIME) (CMODE_PRIORITY) (c) 2001-2006 Red Hat, Inc.
[    0.430000] msgmni has been set to 57
[    0.430000] io scheduler noop registered
[    0.430000] io scheduler deadline registered (default)
[    0.440000] Serial: 8250/16550 driver, 1 ports, IRQ sharing disabled
[    0.440000] ar933x-uart: ttyATH0 at MMIO 0x18020000 (irq = 11) is a AR933X UART
[    0.450000] console [ttyATH0] enabled, bootconsole disabled
[    0.450000] console [ttyATH0] enabled, bootconsole disabled
[    0.460000] Atheros AR71xx SPI Controller driver version 0.2.4
[    0.470000] m25p80 spi0.0: found s25sl032a, expected m25p80
[    0.470000] m25p80 spi0.0: s25sl032a (4096 Kbytes)
[    0.480000] 5 tp-link partitions found on MTD device spi0.0
[    0.480000] Creating 5 MTD partitions on "spi0.0":
[    0.490000] 0x000000000000-0x000000020000 : "u-boot"
[    0.490000] 0x000000020000-0x0000000fee70 : "kernel"
[    0.500000] mtd: partition "kernel" must either start or end on erase block boundary or be smaller than an erase block -- forcing read-only
[    0.510000] 0x0000000fee70-0x0000003f0000 : "rootfs"
[    0.520000] mtd: partition "rootfs" must either start or end on erase block boundary or be smaller than an erase block -- forcing read-only
[    0.530000] mtd: partition "rootfs" set to be root filesystem
[    0.530000] mtd: partition "rootfs_data" created automatically, ofs=270000, len=180000 
[    0.540000] 0x000000270000-0x0000003f0000 : "rootfs_data"
[    0.550000] 0x0000003f0000-0x000000400000 : "art"
[    0.550000] 0x000000020000-0x0000003f0000 : "firmware"
[    0.900000] ag71xx_mdio: probed
[    0.900000] eth0: Atheros AG71xx at 0xb9000000, irq 4
[    1.510000] Atheros AR71xx hardware watchdog driver version 0.1.0
[    1.510000] TCP westwood registered
[    1.510000] NET: Registered protocol family 17
[    1.520000] Bridge firewalling registered
[    1.520000] 802.1Q VLAN Support v1.8 Ben Greear <greearb@candelatech.com>
[    1.530000] All bugs added by David S. Miller <davem@redhat.com>
[    1.550000] VFS: Mounted root (squashfs filesystem) readonly on device 31:2.
[    1.550000] Freeing unused kernel memory: 192k freed
[    3.880000] input: gpio-keys-polled as /devices/platform/gpio-keys-polled/input/input0
[    4.060000] Button Hotplug driver version 0.4.1
- preinit -
Press the [f] key and hit [enter] to enter failsafe mode
- regular preinit -
[    7.450000] JFFS2 notice: (417) jffs2_build_xattr_subsystem: complete building xattr subsystem, 1 of xdatum (0 unchecked, 0 orphan) and 8 of xref (0 dead, 2 orphan) found.
switching to jffs2
- init -

Please press Enter to activate this console. [    8.510000] Compat-wireless backport release: compat-wireless-2011-11-29
[    8.510000] Backport based on wireless-testing.git master-2011-12-01
[    8.650000] cfg80211: Calling CRDA to update world regulatory domain
[    9.370000] usbcore: registered new interface driver usbfs
[    9.380000] usbcore: registered new interface driver hub
[    9.420000] cfg80211: World regulatory domain updated:
[    9.420000] cfg80211:     (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp)
[    9.430000] cfg80211:     (2402000 KHz - 2472000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
[    9.440000] cfg80211:     (2457000 KHz - 2482000 KHz @ 20000 KHz), (300 mBi, 2000 mBm)
[    9.440000] cfg80211:     (2474000 KHz - 2494000 KHz @ 20000 KHz), (300 mBi, 2000 mBm)
[    9.450000] cfg80211:     (5170000 KHz - 5250000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
[    9.460000] cfg80211:     (5735000 KHz - 5835000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
[    9.470000] usbcore: registered new device driver usb
[   10.550000] ieee80211 phy0: Atheros AR9330 Rev:1 mem=0xb8100000, irq=2
[   10.560000] cfg80211: Calling CRDA for country: US
[   10.670000] PPP generic driver version 2.4.2
[   10.680000] cfg80211: Regulatory domain changed to country: US
[   10.690000] cfg80211:     (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp)
[   10.690000] cfg80211:     (2402000 KHz - 2472000 KHz @ 40000 KHz), (300 mBi, 2700 mBm)
[   10.700000] cfg80211:     (5170000 KHz - 5250000 KHz @ 40000 KHz), (300 mBi, 1700 mBm)
[   10.710000] cfg80211:     (5250000 KHz - 5330000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
[   10.720000] cfg80211:     (5490000 KHz - 5600000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
[   10.720000] cfg80211:     (5650000 KHz - 5710000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
[   10.730000] cfg80211:     (5735000 KHz - 5835000 KHz @ 40000 KHz), (300 mBi, 3000 mBm)
[   11.060000] ip_tables: (C) 2000-2006 Netfilter Core Team
[   11.220000] NET: Registered protocol family 24
[   11.410000] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[   11.420000] ar71xx-ehci ar71xx-ehci: Atheros AR91xx built-in EHCI controller
[   11.420000] ar71xx-ehci ar71xx-ehci: new USB bus registered, assigned bus number 1
[   11.460000] ar71xx-ehci ar71xx-ehci: irq 3, io mem 0x1b000000
[   11.480000] ar71xx-ehci ar71xx-ehci: USB 2.0 started, EHCI 1.00
[   11.480000] hub 1-0:1.0: USB hub found
[   11.480000] hub 1-0:1.0: 1 port detected
[   11.590000] nf_conntrack version 0.5.0 (459 buckets, 1836 max)
[   11.970000] ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
[   13.180000] device eth0 entered promiscuous mode



BusyBox v1.19.3 (2012-01-08 21:07:48 MST) built-in shell (ash)
Enter 'help' for a list of built-in commands.

  _______                     ________        __
 |       |.-----.-----.-----.|  |  |  |.----.|  |_
 |   -   ||  _  |  -__|     ||  |  |  ||   _||   _|
 |_______||   __|_____|__|__||________||__|  |____|
          |__| W I R E L E S S   F R E E D O M
 ATTITUDE ADJUSTMENT (bleeding edge, r29697) ----------
  * 1/4 oz Vodka      Pour all ingredients into mixing
  * 1/4 oz Gin        tin with ice, strain into glass.
  * 1/4 oz Amaretto
  * 1/4 oz Triple sec
  * 1/4 oz Peach schnapps
  * 1/4 oz Sour mix
  * 1 splash Cranberry juice
 -----------------------------------------------------
root@OpenWrt:/#

printenv

hornet> printenv
bootargs=console=ttyS0,115200 root=31:02 rootfstype=squashfs init=/sbin/init mtdparts=ar7240-nor0:256k(u-boot),64k(u-boot-env),2752k(rootfs),896k(uImage),64k(NVRAM),64k(ART)
bootcmd=bootm 0x9f020000
bootdelay=1
baudrate=115200
ethaddr=0xba:0xbe:0xfa:0xce:0x07:0x41
ipaddr=192.168.1.111
serverip=192.168.1.100
stdin=serial
stdout=serial
stderr=serial
ethact=eth0

Environment size: 362/65532 bytes
hornet>

bootargs=console=ttyS0,115200 root=31:02 rootfstype=squashfs init=/sbin/init mtdparts=ar7240-nor0:256k(u-boot),64k(u-boot-nv),2752k(rootfs),896k(uImage),64k(NVRAM),64k(ART)

is equal!

Now can I try to flash a new firmware using TFTP??

Thanks a lot!

(Last edited by Fado84 on 17 Jan 2012, 15:08)

Fado84 wrote:

Now can I try to flash a new firmware using TFTP??

Thanks a lot!

Hi!

That looks good! You do not need to flash a new firmware at the moment.
Everything starts normal (kernel, rootfs).

I assume that the network configuration is probably not correct.

Try the usual linux commands to find out how the network interfaces are configured.

BTW: Please also keep in mind that the openwrt firmware image for the TL-MR3020 does not contain the WEBGUI (e.g. LuCi)!
The SPI flash with 4MB is to small to integrate that. So you cannot use your web browser to configure openwrt on this device.
If you want to have that you must use an additional external storage device (e.g. USB stick). For a guide, search the wiki for "extroot". Choose either "pivot-overlay" or "pivot-root".
"pivot-overlay" is recommended.

You must configure openwrt using the config files in /etc/config by using an editor (default editor is "vi").

One more thing. smile

As you now seem to have opened your device, could you please provide some detail pictures of the PCB (top, bottom)?
Could be interesting to see if there is a difference in version V1.4.

The bootloader on your devices has a later build time.  So far the only difference I have noticed.

Where did you buy your device?

I did not find a hint for revision V1.4 on the support page from TP-Link.

(Last edited by cille75 on 17 Jan 2012, 16:25)

Finally using the serial console I could change the password by passwd command!! big_smile big_smile

Thanks cille75!!!
I know that there isn't a luci ( but I never used it, always cli!!!).. thanks a lot, I use openwrt and I know the basic operation like expanded the memory.. I'm a newbie because I never hardware hacking a router.. up until now!

I bought the router in Italy 2 days ago..
On the router box there is written: Model TL-MR3020 Ver.1.4 but opened the device, on the pcd there is written Rev.1.1

Images
image1
image2
image3
image4
image5
image6

Last question: installed openwrt, how does it function the switch? is the function equal in any position ?

Thanks!!

Hi,

I'm a newbie like Fado84, and I think I've also bricked my MR3020. I flashed the firmware with the WebGUI and it seemed like it was successful. Unfortunately, it no longer broadcasts WiFi, and when I tried to plug it in via ethernet cable, I am unable to access the configuration page. As suggested, I opened it up and connected to its 4 pin serial interface. All I get in my terminal is weird characters, nothing readable, as though there is some kind of character set issue or something:

R???e???????E?75-95?5/??5#57?%-9!?%!75?

Any help would be appreciated.

~Ian

codeThatThinks wrote:

Hi,

I'm a newbie like Fado84, and I think I've also bricked my MR3020. I flashed the firmware with the WebGUI and it seemed like it was successful. Unfortunately, it no longer broadcasts WiFi, and when I tried to plug it in via ethernet cable, I am unable to access the configuration page. As suggested, I opened it up and connected to its 4 pin serial interface. All I get in my terminal is weird characters, nothing readable, as though there is some kind of character set issue or something:

R???e???????E?75-95?5/??5#57?%-9!?%!75?

Any help would be appreciated.

~Ian

Set the bit rate to 115200 and the rest default in device manager/ports (com&ltp), and same rate in putty.

Lennong wrote:

Set the bit rate to 115200 and the rest default in device manager/ports (com&ltp), and same rate in putty.

No luck. I'm using an actual serial cable connected to a Linux box running minicom. I've been using 115200 ever since I started because that was what I had read on the wiki page for this router. I tried both ansi and iso modes in minicom and I still have the same problem. I even tried this on a different machine, same result.

I already ordered another of these micorouters, so it isn't as big of a deal if this is bricked now.

Again, I appreciate any help.

~Ian

Ok, so I just tried it on a Windows machine running PuTTY. Same exact result. Tried everything, whether it be port speed, flow control, parity bit, character set. Same exact result.

I got some times a similar problem, but I think that this isn't your case.. merely reboot the system and router I solved..
try: cu -l /dev/ttyUSB0 -s 115200