[LEDE-DEV] TP-Link TL-WR841N v11.1 hardware led change vs v8/9/10

Laurent GUERBY laurent at guerby.net
Sat May 28 09:34:30 PDT 2016


Hi,

TP-Link TL-WR841N is now at version "11.1" in stores and the
number of leds of the device changed: the "system" led is gone and the
"wan" led seems to be able to be green or orange.

The antennas are also slightly different (a bit longer).

I flashed it with LEDE snapshot "v11".

Just after power on:
http://guerby.org/ftp/IMG_20160528_181137.jpg

A bit later:
http://guerby.org/ftp/IMG_20160528_181155.jpg

After LEDE (snapshot) boot is done :
http://guerby.org/ftp/IMG_20160528_180545.jpg

Notice that the power LED is off.

The two hardware buttons (wifi and reset/wps) seem to have their
normal function. network/wifi seem to be working fine.

Following
https://wiki.openwrt.org/doc/devel/add.new.device

I could get the power and wan "orange/green" control GPIO:

GPIO 1 : power led 0 => green, 1 => off
GPIO 2 : wan led 0 => change color to orange, 1 => back to green

GPIO/LED seems to be defined here:
source/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wr841n-v9.c

I can provide ssh remote access to the hardware + webcam on the LED,
ping me on IRC.

Sincerely,

Laurent ("guerby" on IRC)

root at lede:/sys/class/gpio# cat /tmp/sysinfo/*
tl-wr841n-v9
TP-Link TL-WR841N/ND v11

root at lede:/sys/class/gpio# cat /tmp/gpiod.sh 
#!/bin/sh
GPIOCHIP=0
BASE=$(cat /sys/class/gpio/gpiochip${GPIOCHIP}/base)
NGPIO=$(cat /sys/class/gpio/gpiochip${GPIOCHIP}/ngpio)
max=$(($BASE+$NGPIO))
gpio=$BASE
while [ $gpio -lt $max ] ; do
        echo $gpio > /sys/class/gpio/export
        [ -d /sys/class/gpio/gpio${gpio} ] && {
                echo in > /sys/class/gpio/gpio${gpio}/direction
                echo "[GPIO${gpio}] value $(cat /sys/class/gpio/gpio
${gpio}/value)"
                echo ${gpio} > /sys/class/gpio/unexport
        }
        gpio=$((gpio+1))
done
root at lede:/sys/class/gpio# /tmp/gpiod.sh 
[GPIO0] value 0
[GPIO1] value 0
[GPIO2] value 0
sh: write error: Resource busy
sh: write error: Resource busy
[GPIO5] value 1
[GPIO6] value 1
[GPIO7] value 0
[GPIO8] value 0
[GPIO9] value 0
[GPIO10] value 1
sh: write error: Resource busy
sh: write error: Resource busy
sh: write error: Resource busy
sh: write error: Resource busy
sh: write error: Resource busy
sh: write error: Resource busy
sh: write error: Resource busy
root at lede:/sys/class/gpio# GPIO=1;echo $GPIO > export;echo "out" > gpio
$GPIO/direction;echo 0 > gpio$GPIO/value;sleep 1s;echo 1 > gpio
$GPIO/value;sleep 1s;echo $GPIO > unexport
root at lede:/sys/class/gpio# GPIO=2;echo $GPIO > export;echo "out" > gpio
$GPIO/direction;echo 0 > gpio$GPIO/value;sleep 1s;echo 1 > gpio
$GPIO/value;sleep 1s;echo $GPIO > unexport





More information about the Lede-dev mailing list