diff options
author | Tzafrir Cohen <tzafrir.cohen@xorcom.com> | 2009-08-13 15:15:49 +0000 |
---|---|---|
committer | Tzafrir Cohen <tzafrir.cohen@xorcom.com> | 2009-08-13 15:15:49 +0000 |
commit | a114167f3ee6db22217d70a48267871ee08e6c4b (patch) | |
tree | 681330f32689007ff556b2d3372a391b840f812d /xpp/waitfor_xpds | |
parent | abe5babe4742bf03b49971407b82ec3bc02fb14c (diff) |
xpp: Add astribank_is_starting:
astribank_is_running is used to tell when we may have an Astribank that
is initializing (and may be re-enumerating and thus not listed as a
device).
It uses a semaphore as we can always write to one and we can't always
write to a file.
git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@6987 a0bf4364-ded3-4de4-8d8a-66a801d63aff
Diffstat (limited to 'xpp/waitfor_xpds')
-rwxr-xr-x | xpp/waitfor_xpds | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/xpp/waitfor_xpds b/xpp/waitfor_xpds index 1e213eb..26a6ab5 100755 --- a/xpp/waitfor_xpds +++ b/xpp/waitfor_xpds @@ -40,7 +40,14 @@ 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 +if ! astribank_is_starting="`which astribank_is_starting 2>/dev/null`"; then + echo >&2 "$0: Missing astribank_is_starting" + exit 0 +fi +if [ "`$dahdi_hardware | grep xpp_usb`" != "" ]; then + astribank_is_starting -a +fi +if ! astribank_is_starting; then exit 0 fi @@ -70,3 +77,6 @@ do oldab="$ab" cat $ab done + +# Handled astribanks +astribank_is_starting -r |