No subject
Thu Jan 15 22:29:28 CST 2009
Modified:
tools/trunk/xpp/waitfor_xpds
Modified: tools/trunk/xpp/waitfor_xpds
URL: http://svn.asterisk.org/svn-view/dahdi/tools/trunk/xpp/waitfor_xpds?view=diff&rev=6655&r1=6654&r2=6655
==============================================================================
--- tools/trunk/xpp/waitfor_xpds (original)
+++ tools/trunk/xpp/waitfor_xpds Mon May 25 09:30:20 2009
@@ -25,6 +25,10 @@
set -e
+# For lab testing
+mydir=`dirname $0`
+PATH="${mydir}:${PATH}"
+
ab_list() {
# Only check /sys info (don't use /proc anymore).
ab=`find /sys/bus/astribanks/devices/xbus-*/ -name waitfor_xpds 2> /dev/null || :`
@@ -32,7 +36,11 @@
}
# Any hardware?
-if [ "`dahdi_hardware | grep xpp_usb`" = "" ]; then
+if ! dahdi_hardware="`which dahdi_hardware 2>/dev/null`"; then
+ echo >&2 "$0: Missing $dahdi_hardware"
+ exit 0
+fi
+if [ "`$dahdi_hardware | grep xpp_usb`" = "" ]; then
exit 0
fi
@@ -42,6 +50,7 @@
while [ ! -e "/sys/bus/astribanks/devices/xbus-00" ]
do
if [ "$tries" -le 0 ]; then
+ echo 1>&2 "TIMEOUT"
exit 1
fi
echo -n 1>&2 "."
More information about the svn-commits
mailing list