ar71xx: ubnt-(xm,xw): fix LED RSSI indication
[openwrt/staging/dedeckeh.git] / target / linux / ar71xx / base-files / etc / board.d / 01_leds
index 2b3e8b739c4569d1a4e7cce451abb85aea0cca60..170adaa7a22d1476cc269574f2b8b0c226a350f5 100755 (executable)
@@ -67,7 +67,7 @@ cpe870|\
 dr531|\
 e600g-v2|\
 e600gac-v2|\
-e750a-v2)
+e750a-v4)
        ucidef_set_led_netdev "lan" "LAN" "$board:green:lan" "eth0"
        ucidef_set_led_netdev "wan" "WAN" "$board:green:wan" "eth1"
 
@@ -129,6 +129,7 @@ archer-c7)
        ;;
 archer-c58-v1|\
 archer-c59-v1|\
+archer-c59-v2|\
 archer-c60-v1|\
 archer-c60-v2)
        ucidef_set_led_switch "lan" "LAN" "$board:green:lan" "switch0" "0x1E"
@@ -137,12 +138,14 @@ archer-c60-v2)
        ucidef_set_led_wlan "wlan5g" "WLAN5G" "$board:green:wlan5g" "phy0tpt"
 
        case "$board" in
-       archer-c59-v1)
+       archer-c59-v1|\
+       archer-c59-v2)
                ucidef_set_led_usbdev "usb" "USB" "$board:green:usb" "1-1"
                ;;
        esac
        ;;
-archer-c7-v4)
+archer-c7-v4|\
+archer-c7-v5)
        ucidef_set_led_wlan "wlan" "WLAN" "$board:green:wlan2g" "phy1tpt"
        ucidef_set_led_wlan "wlan5g" "WLAN5G" "$board:green:wlan5g" "phy0tpt"
        ucidef_set_led_switch "wan" "WAN" "$board:green:wan" "switch0" "0x02"
@@ -150,8 +153,19 @@ archer-c7-v4)
        ucidef_set_led_switch "lan2" "LAN2" "$board:green:lan3" "switch0" "0x08"
        ucidef_set_led_switch "lan3" "LAN3" "$board:green:lan2" "switch0" "0x10"
        ucidef_set_led_switch "lan4" "LAN4" "$board:green:lan1" "switch0" "0x20"
-       ucidef_set_led_usbdev "usb1" "USB1" "$board:green:usb1" "1-1"
-       ucidef_set_led_usbdev "usb2" "USB2" "$board:green:usb2" "2-1"
+
+       case "$board" in
+       archer-c7-v4)
+               ucidef_set_led_usbdev "usb1" "USB1" "$board:green:usb1" "1-1"
+               ucidef_set_led_usbdev "usb2" "USB2" "$board:green:usb2" "2-1"
+               ;;
+       esac
+
+       case "$board" in
+       archer-c7-v5)
+               ucidef_set_led_usbdev "usb" "USB" "$board:green:usb" "1-1"
+               ;;
+       esac
        ;;
 arduino-yun)
        ucidef_set_led_wlan "wlan" "WLAN" "arduino:blue:wlan" "phy0tpt"
@@ -170,10 +184,11 @@ nanostation-m|\
 nanostation-m-xw|\
 rocket-m|\
 rocket-m-xw)
-       ucidef_set_led_rssi "rssilow" "RSSILOW" "ubnt:red:link1" "wlan0" "1" "100" "0" "13"
-       ucidef_set_led_rssi "rssimediumlow" "RSSIMEDIUMLOW" "ubnt:orange:link2" "wlan0" "26" "100" "-25" "13"
-       ucidef_set_led_rssi "rssimediumhigh" "RSSIMEDIUMHIGH" "ubnt:green:link3" "wlan0" "51" "100" "-50" "13"
-       ucidef_set_led_rssi "rssihigh" "RSSIHIGH" "ubnt:green:link4" "wlan0" "76" "100" "-75" "13"
+       ucidef_set_rssimon "wlan0" "200000" "1"
+       ucidef_set_led_rssi "rssilow" "RSSILOW" "ubnt:red:link1" "wlan0" "1" "100"
+       ucidef_set_led_rssi "rssimediumlow" "RSSIMEDIUMLOW" "ubnt:orange:link2" "wlan0" "26" "100"
+       ucidef_set_led_rssi "rssimediumhigh" "RSSIMEDIUMHIGH" "ubnt:green:link3" "wlan0" "51" "100"
+       ucidef_set_led_rssi "rssihigh" "RSSIHIGH" "ubnt:green:link4" "wlan0" "76" "100"
        ;;
 bxu2000n-2-a1)
        ucidef_set_led_wlan "wlan" "WLAN" "bhu:green:wlan" "phy0tpt"
@@ -373,7 +388,8 @@ e1700ac-v2)
        ucidef_set_led_usbdev "usb" "USB" "$board:green:usb" "1-1"
        ucidef_set_led_wlan "wlan2g" "WLAN2G" "$board:green:wlan2g" "phy1tpt"
        ;;
-e558-v2)
+e558-v2|\
+e750g-v8)
        ucidef_set_led_wlan "wlan" "WLAN" "$board:green:wlan" "phy0tpt"
        ;;
 esr900)