From: Gabor Juhos Date: Mon, 13 Aug 2012 14:01:37 +0000 (+0000) Subject: base-files: uci-defaults for rssileds X-Git-Tag: reboot~13108 X-Git-Url: http://git.openwrt.org/?a=commitdiff_plain;h=ca857b7a50506047aff1fef7b8ed3faa31f5075b;p=openwrt%2Fopenwrt.git base-files: uci-defaults for rssileds Adds capability to add uci-defaults defining RSSI LEDs Signed-off-by: Daniel Golle SVN-Revision: 33164 --- diff --git a/package/base-files/files/lib/functions/uci-defaults.sh b/package/base-files/files/lib/functions/uci-defaults.sh index 2cbf69a6ff..477c00cfd4 100644 --- a/package/base-files/files/lib/functions/uci-defaults.sh +++ b/package/base-files/files/lib/functions/uci-defaults.sh @@ -94,6 +94,50 @@ EOF UCIDEF_LEDS_CHANGED=1 } +ucidef_set_led_rssi() { + local cfg="led_$1" + local name=$2 + local sysfs=$3 + local iface=$4 + local minq=$5 + local maxq=$6 + local offset=$7 + local factor=$8 + + uci -q get system.$cfg && return 0 + + uci batch <