2010-12-17 17:09:57 +00:00
|
|
|
#!/bin/sh
|
|
|
|
#
|
|
|
|
# Copyright (C) 2010 OpenWrt.org
|
|
|
|
#
|
|
|
|
|
|
|
|
. /lib/ar71xx.sh
|
|
|
|
|
|
|
|
board=$(ar71xx_board_name)
|
|
|
|
|
|
|
|
wzrhpg300nh_set_leds() {
|
|
|
|
uci batch <<EOF
|
|
|
|
add system led
|
|
|
|
set system.@led[-1]='led'
|
|
|
|
set system.@led[-1].name='Wireless'
|
2011-11-01 11:20:46 +00:00
|
|
|
set system.@led[-1].sysfs='buffalo:green:wireless'
|
2010-12-17 17:09:57 +00:00
|
|
|
set system.@led[-1].trigger='phy0tpt'
|
|
|
|
add system led
|
|
|
|
set system.@led[-1]='led'
|
|
|
|
set system.@led[-1].name='Router'
|
2011-11-01 11:20:46 +00:00
|
|
|
set system.@led[-1].sysfs='buffalo:green:router'
|
2010-12-17 17:09:57 +00:00
|
|
|
set system.@led[-1].trigger='netdev'
|
|
|
|
set system.@led[-1].dev='eth1'
|
|
|
|
set system.@led[-1].mode='link tx rx'
|
2010-12-17 17:10:16 +00:00
|
|
|
add system led
|
|
|
|
set system.@led[-1]='led'
|
|
|
|
set system.@led[-1].name='USB'
|
2011-11-01 11:20:46 +00:00
|
|
|
set system.@led[-1].sysfs='buffalo:blue:usb'
|
2010-12-17 17:10:16 +00:00
|
|
|
set system.@led[-1].trigger='usbdev'
|
|
|
|
set system.@led[-1].dev='1-1'
|
|
|
|
set system.@led[-1].interval='50'
|
2010-12-17 17:09:57 +00:00
|
|
|
commit system
|
|
|
|
EOF
|
|
|
|
}
|
|
|
|
|
2011-07-28 11:57:51 +00:00
|
|
|
if [ "${board}" == "wzr-hp-g300nh" ]; then
|
2010-12-17 17:09:57 +00:00
|
|
|
wzrhpg300nh_set_leds
|
2011-07-28 11:57:51 +00:00
|
|
|
fi
|