GPIOs

→ port.GPIO
The AR933x platform provides 30 GPIOs. Some of them are used by the router for status LEDs, buttons and other stuff. The table below shows the results of some investigation:

Voltage level at GPIO in output-mode

gpioX/value in input-mode when GPIO is:

GPIO

Common Name

PCB Name

gpioX/value=1

gpioX/value=0

Floating

Pulled to GND

Pulled to Vcc

0

WLAN LED

LED4

1

unused Pulled to VCC

R2 and R5

2

3

4

5

6

R16

7

unused Pulled to ground

R15

8

USB power(?)

R18

9

10

11

WPS button

12

13

14

15

16

17

Ethernet LED

LED5

18

Sliding Sw.

19

20

Sliding Sw.

21

22

23

24

25

26

WPS LED

LED2

27

Internet LED

LED3

28

29

unused Pulled to ground

R17

To make the GPIOs available via sysfs, the required ones have to be exported to userspace, as it is explained on a page of the Squidge-Project. Kernel modules occupying that resource need to be removed before (e.g. "leds-gpio" and "gpio-buttons"). In output-mode, voltage levels of the GPIOs were measured against GND, after the value 1 or 0 had been written to /sys/class/gpio/gpioX/value. In input-mode, the value of the file /sys/class/gpio/gpioX/value was read when the GPIO was floating (initial state), pulled to GND or pulled to Vcc.

USB port and monitoring Serial Console via USB-Serial

The USB port on the TL-MR3020 is not compatible with USB1 devices (aka full speed) and only works properly with USB2 (aka high speed) devices. You can however plug a USB-Serial adapter as long as you plug that through a <$10 USB2. While you're at it, use another USB port to plug in a USB key and write data there (like serial console logs) so as not to wear out the built in flash.

Relevant Forum Links

Custom IPv6 image for mr3020 (v1.7)

A custom image with ipv6 support: radvd, wide-dhcpv6, 3g stick support, made for RCS-RDS Fiberlink dual stack PPPoE service,
but should be okay for static wan settings on other ISPs:
http://www.ip6.ro/firmware/mr3020/