Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge branch 'master' of github.com:bismark-devel/bismark

  • Loading branch information...
commit 04ac1f0afc08f56ce5d096d13043ef7ad84b98da 2 parents 9f81aea + 26940be
Walter de Donato wdd authored
8 device/OpenWrt_common/scripts/bismark-measure-active
View
@@ -54,7 +54,9 @@ get_target ()
# --- Main ---
# Light "test in progess" LED (orange WPS led)
-echo 1 > /sys/devices/platform/leds-gpio/leds/wndr3700:orange:wps/brightness
+if [ -e /sys/devices/platform/leds-gpio/leds/wndr3700:orange:wps/brightness ]; then
+ echo 1 > /sys/devices/platform/leds-gpio/leds/wndr3700:orange:wps/brightness
+fi
# Create dirs and files
mkdir -p /tmp/bismark/active
@@ -233,6 +235,8 @@ mv $XML_FILE /tmp/bismark/data
}
# Extinguish "test in progess" LED
-echo 0 > /sys/devices/platform/leds-gpio/leds/wndr3700:orange:wps/brightness
+if [ -e /sys/devices/platform/leds-gpio/leds/wndr3700:orange:wps/brightness ]; then
+ echo 0 > /sys/devices/platform/leds-gpio/leds/wndr3700:orange:wps/brightness
+fi
scp -S "/tmp/bismark/ssh" -i $SSH_KEY /tmp/bismark/data/*.xml $USER@$SERVER:var/data && rm /tmp/bismark/data/*.xml
7 device/OpenWrt_common/scripts/bismark-tr
View
@@ -16,9 +16,12 @@ DATA_DIR=/tmp/bismark/active
# AWK filters
filter_common='
if (! gwip) {
- if (! ($2 == "*" || $2 ~ /^10\./ || $2 ~ /^192\.168/ || $2 ~ /^172\.16/) ) {
+ if (! ($2 ~ /^10\./ || $2 ~ /^192\.168/ || $2 ~ /^172\.16/) ) {
gwip=$2
- print gwip > "'$DATA_DIR'/gwip"
+ if (gwip != "*")
+ print gwip > "'$DATA_DIR'/gwip"
+ else
+ print "" > "'$DATA_DIR'/gwip"
}
}
'
Please sign in to comment.
Something went wrong with that request. Please try again.