ath79: move ubnt-xm 64M RAM boards back to generic
[openwrt/staging/wigyori.git] / target / linux / ath79 / tiny / base-files / etc / board.d / 01_leds
1
2 . /lib/functions/uci-defaults.sh
3
4 board_config_update
5
6 board=$(board_name)
7
8 case "$board" in
9 buffalo,whr-g301n|\
10 dlink,dir-615-e4|\
11 tplink,tl-wr740n-v1|\
12 tplink,tl-wr740n-v3|\
13 tplink,tl-wr741-v1|\
14 tplink,tl-wr743nd-v1|\
15 tplink,tl-wr841-v5|\
16 tplink,tl-wr941-v4)
17 ucidef_set_led_netdev "wan" "WAN" "green:wan" "eth0"
18 ucidef_set_led_switch "lan1" "LAN1" "green:lan1" "switch0" "0x02"
19 ucidef_set_led_switch "lan2" "LAN2" "green:lan2" "switch0" "0x04"
20 ucidef_set_led_switch "lan3" "LAN3" "green:lan3" "switch0" "0x08"
21 ucidef_set_led_switch "lan4" "LAN4" "green:lan4" "switch0" "0x10"
22 ;;
23 engenius,enh202-v1)
24 ucidef_set_led_switch "lan" "LAN" "amber:lan" "switch0" "0x10"
25 ucidef_set_led_netdev "wan" "WAN" "green:wan" "eth0"
26 ucidef_set_rssimon "wlan0" "200000" "1"
27 ucidef_set_led_rssi "rssilow" "RSSILOW" "red:rssilow" "wlan0" "1" "100"
28 ucidef_set_led_rssi "rssimedium" "RSSIMEDIUM" "amber:rssimedium" "wlan0" "33" "100"
29 ucidef_set_led_rssi "rssihigh" "RSSIHIGH" "green:rssihigh" "wlan0" "67" "100"
30 ;;
31 netgear,wnr1000-v2|\
32 netgear,wnr2000-v3)
33 ucidef_set_led_netdev "wan-amber" "WAN (amber)" "amber:wan" "eth0"
34 ucidef_set_led_switch "lan1green" "LAN1 (green)" "green:lan1" "switch0" "0x02" "0x04"
35 ucidef_set_led_switch "lan2green" "LAN2 (green)" "green:lan2" "switch0" "0x04" "0x04"
36 ucidef_set_led_switch "lan3green" "LAN3 (green)" "green:lan3" "switch0" "0x08" "0x04"
37 ucidef_set_led_switch "lan4green" "LAN4 (green)" "green:lan4" "switch0" "0x10" "0x04"
38 ucidef_set_led_switch "lan1amber" "LAN1 (amber)" "amber:lan1" "switch0" "0x02" "0x02"
39 ucidef_set_led_switch "lan2amber" "LAN2 (amber)" "amber:lan2" "switch0" "0x04" "0x02"
40 ucidef_set_led_switch "lan3amber" "LAN3 (amber)" "amber:lan3" "switch0" "0x08" "0x02"
41 ucidef_set_led_switch "lan4amber" "LAN4 (amber)" "amber:lan4" "switch0" "0x10" "0x02"
42 ;;
43 netgear,wnr612-v2|\
44 on,n150r)
45 ucidef_set_led_netdev "wan" "WAN" "green:wan" "eth0"
46 ucidef_set_led_switch "lan1" "LAN1" "green:lan1" "switch0" "0x02" "0x0f"
47 ucidef_set_led_switch "lan2" "LAN2" "green:lan2" "switch0" "0x04" "0x0f"
48 ;;
49 tplink,tl-mr3020-v1|\
50 tplink,tl-mr3040-v2|\
51 tplink,tl-wa701nd-v1|\
52 tplink,tl-wa730re-v1|\
53 tplink,tl-wa801nd-v1|\
54 tplink,tl-wa801nd-v3|\
55 tplink,tl-wa801nd-v4|\
56 tplink,tl-wa830re-v1|\
57 tplink,tl-wa860re-v1|\
58 tplink,tl-wa901nd-v1|\
59 tplink,tl-wa901nd-v3|\
60 tplink,tl-wa901nd-v4|\
61 tplink,tl-wa901nd-v5)
62 ucidef_set_led_netdev "lan" "LAN" "green:lan" "eth0"
63 ;;
64 tplink,tl-mr3420-v2|\
65 tplink,tl-wr740n-v4|\
66 tplink,tl-wr740n-v5|\
67 tplink,tl-wr741nd-v4|\
68 tplink,tl-wr841-v8|\
69 tplink,tl-wr941nd-v5)
70 ucidef_set_led_netdev "wan" "WAN" "green:wan" "eth1"
71 ucidef_set_led_switch "lan1" "LAN1" "green:lan1" "switch0" "0x04"
72 ucidef_set_led_switch "lan2" "LAN2" "green:lan2" "switch0" "0x08"
73 ucidef_set_led_switch "lan3" "LAN3" "green:lan3" "switch0" "0x10"
74 ucidef_set_led_switch "lan4" "LAN4" "green:lan4" "switch0" "0x02"
75 ;;
76 tplink,tl-mr3420-v3|\
77 tplink,tl-wr841-v9|\
78 tplink,tl-wr841-v10|\
79 tplink,tl-wr841-v11|\
80 tplink,tl-wr841-v12)
81 ucidef_set_led_netdev "wan" "WAN" "green:wan" "eth1"
82 ucidef_set_led_switch "lan1" "LAN1" "green:lan1" "switch0" "0x10"
83 ucidef_set_led_switch "lan2" "LAN2" "green:lan2" "switch0" "0x08"
84 ucidef_set_led_switch "lan3" "LAN3" "green:lan3" "switch0" "0x04"
85 ucidef_set_led_switch "lan4" "LAN4" "green:lan4" "switch0" "0x02"
86 ;;
87 tplink,tl-wa850re-v1|\
88 tplink,tl-wa850re-v2)
89 ucidef_set_led_netdev "lan" "LAN" "blue:lan" "eth0"
90 ucidef_set_rssimon "wlan0" "200000" "1"
91 ucidef_set_led_rssi "rssilow" "RSSILOW" "blue:signal1" "wlan0" "1" "100"
92 ucidef_set_led_rssi "rssimediumlow" "RSSIMEDIUMLOW" "blue:signal2" "wlan0" "20" "100"
93 ucidef_set_led_rssi "rssimedium" "RSSIMEDIUM" "blue:signal3" "wlan0" "40" "100"
94 ucidef_set_led_rssi "rssimediumhigh" "RSSIMEDIUMHIGH" "blue:signal4" "wlan0" "60" "100"
95 ucidef_set_led_rssi "rssihigh" "RSSIHIGH" "blue:signal5" "wlan0" "80" "100"
96 ;;
97 tplink,tl-wpa8630p-v2-int|\
98 tplink,tl-wpa8630p-v2.0-eu|\
99 tplink,tl-wpa8630p-v2.1-eu)
100 ucidef_set_led_switch "lan" "LAN" "green:lan" "switch0" "0x3c"
101 ;;
102 tplink,tl-wr940n-v3|\
103 tplink,tl-wr940n-v4|\
104 tplink,tl-wr941nd-v6)
105 ucidef_set_led_netdev "wan" "WAN" "blue:wan" "eth1"
106 ucidef_set_led_switch "lan1" "LAN1" "blue:lan1" "switch0" "0x10"
107 ucidef_set_led_switch "lan2" "LAN2" "blue:lan2" "switch0" "0x08"
108 ucidef_set_led_switch "lan3" "LAN3" "blue:lan3" "switch0" "0x04"
109 ucidef_set_led_switch "lan4" "LAN4" "blue:lan4" "switch0" "0x02"
110 ;;
111 tplink,tl-wr940n-v6)
112 ucidef_set_led_netdev "wan" "WAN" "blue:wan" "eth1"
113 ;;
114 ubnt,bullet-m-ar7240|\
115 ubnt,bullet-m-ar7241|\
116 ubnt,nanobridge-m|\
117 ubnt,nanostation-loco-m|\
118 ubnt,nanostation-m|\
119 ubnt,picostation-m)
120 ucidef_set_rssimon "wlan0" "200000" "1"
121 ucidef_set_led_rssi "rssilow" "RSSILOW" "red:link1" "wlan0" "1" "100"
122 ucidef_set_led_rssi "rssimediumlow" "RSSIMEDIUMLOW" "orange:link2" "wlan0" "26" "100"
123 ucidef_set_led_rssi "rssimediumhigh" "RSSIMEDIUMHIGH" "green:link3" "wlan0" "51" "100"
124 ucidef_set_led_rssi "rssihigh" "RSSIHIGH" "green:link4" "wlan0" "76" "100"
125 ;;
126 esac
127
128 board_config_flush
129
130 exit 0