diff options
Diffstat (limited to 'xpp/utils')
-rwxr-xr-x | xpp/utils/xpp_sync | 29 | ||||
-rw-r--r-- | xpp/utils/zconf/Zaptel/Chans.pm | 2 | ||||
-rw-r--r-- | xpp/utils/zconf/Zaptel/Hardware/PCI.pm | 2 | ||||
-rw-r--r-- | xpp/utils/zconf/Zaptel/Hardware/USB.pm | 2 | ||||
-rw-r--r-- | xpp/utils/zconf/Zaptel/Span.pm | 2 | ||||
-rw-r--r-- | xpp/utils/zconf/Zaptel/Utils.pm (renamed from xpp/utils/zconf/XppUtils.pm) | 4 | ||||
-rw-r--r-- | xpp/utils/zconf/Zaptel/Xpp/Xbus.pm | 2 | ||||
-rw-r--r-- | xpp/utils/zconf/Zaptel/Xpp/Xpd.pm | 2 |
8 files changed, 35 insertions, 10 deletions
diff --git a/xpp/utils/xpp_sync b/xpp/utils/xpp_sync index 80b61c7..1438f50 100755 --- a/xpp/utils/xpp_sync +++ b/xpp/utils/xpp_sync @@ -17,7 +17,20 @@ use Zaptel::Xpp::Xbus; my $sync; my $autoselect; +sub usage() { + print + "$0: show / set Astribank sync source\n". + "\n". + "Usage: $0 Show sync source.\n". + " $0 <auto|NN|zaptel> Set sync source.\n". + ""; +} + if(@ARGV == 1) { + if ($ARGV[0] =~ /^(-h|--help|help)$/) { + usage; + exit(0); + } $sync = shift; $autoselect = 1 if $sync =~ /^auto$/i; } @@ -142,7 +155,7 @@ xpp_sync - Handle sync selection of Xorcom Astribanks. =head1 SYNOPSIS -xpp_sync [auto|host|nn] +xpp_sync [auto|zaptel|nn] =head1 DESCRIPTION @@ -164,12 +177,18 @@ output of xpp_sync, it may be unregistered. Try running zt_registration . Automatically selects the best Astribank for syncing. +=item zaptel + +Gets synchronization from the Zaptel sync master. + =item nn -Set XBUS number nn as sync source. +Sets XBUS-I<nn> as sync source. =back +(Parameter name is case-insensitive) + =head2 Example output: Setting SYNC @@ -188,6 +207,12 @@ In this example we see that the recommended xpp sync master is XBUS-02 - it is the first on the list. It is also the actual syncer, as we can see from the '+' beside it. +xpp_sync is normally called from both the zaptel init.d script and the +the Astribank udev script. The parameter it is called with defaults to +I<auto>, but it is possible to override that parameter (e.g: set it to +I<zaptel>) through the value of XPP_SYNC in either /etc/defualt/zaptel +or /etc/sysconfig/zaptel . + =head1 FILES =over diff --git a/xpp/utils/zconf/Zaptel/Chans.pm b/xpp/utils/zconf/Zaptel/Chans.pm index 236d6af..16ab1d5 100644 --- a/xpp/utils/zconf/Zaptel/Chans.pm +++ b/xpp/utils/zconf/Zaptel/Chans.pm @@ -8,7 +8,7 @@ package Zaptel::Chans; # $Id$ # use strict; -use XppUtils; +use Zaptel::Utils; sub new($$$$$$) { my $pack = shift or die "Wasn't called as a class method\n"; diff --git a/xpp/utils/zconf/Zaptel/Hardware/PCI.pm b/xpp/utils/zconf/Zaptel/Hardware/PCI.pm index 7d4e2b3..b1a6b67 100644 --- a/xpp/utils/zconf/Zaptel/Hardware/PCI.pm +++ b/xpp/utils/zconf/Zaptel/Hardware/PCI.pm @@ -8,7 +8,7 @@ package Zaptel::Hardware::PCI; # $Id$ # use strict; -use XppUtils; +use Zaptel::Utils; use Zaptel::Hardware; our @ISA = qw(Zaptel::Hardware); diff --git a/xpp/utils/zconf/Zaptel/Hardware/USB.pm b/xpp/utils/zconf/Zaptel/Hardware/USB.pm index a5501d1..a2dc08f 100644 --- a/xpp/utils/zconf/Zaptel/Hardware/USB.pm +++ b/xpp/utils/zconf/Zaptel/Hardware/USB.pm @@ -8,7 +8,7 @@ package Zaptel::Hardware::USB; # $Id$ # use strict; -use XppUtils; +use Zaptel::Utils; use Zaptel::Hardware; use Zaptel::Xpp; use Zaptel::Xpp::Xbus; diff --git a/xpp/utils/zconf/Zaptel/Span.pm b/xpp/utils/zconf/Zaptel/Span.pm index 951f603..f8e5f01 100644 --- a/xpp/utils/zconf/Zaptel/Span.pm +++ b/xpp/utils/zconf/Zaptel/Span.pm @@ -8,7 +8,7 @@ package Zaptel::Span; # $Id$ # use strict; -use XppUtils; +use Zaptel::Utils; use Zaptel::Chans; my $proc_base = "/proc/zaptel"; diff --git a/xpp/utils/zconf/XppUtils.pm b/xpp/utils/zconf/Zaptel/Utils.pm index 1526537..8d13ad7 100644 --- a/xpp/utils/zconf/XppUtils.pm +++ b/xpp/utils/zconf/Zaptel/Utils.pm @@ -1,4 +1,4 @@ -package XppUtils; +package Zaptel::Utils; # Accessors (miniperl does not have Class:Accessor) our $AUTOLOAD; @@ -43,7 +43,7 @@ sub import { # # Export symbols, but not by accident of inheritance. # - die "Sombody inherited XppUtils" if $pkg ne 'XppUtils'; + die "Sombody inherited Zaptel::Utils" if $pkg ne 'Zaptel::Utils'; no strict 'refs'; *{ $callpkg . '::AUTOLOAD' } = \&AUTOLOAD; *{ $callpkg . '::xpp_dump' } = \&xpp_dump; diff --git a/xpp/utils/zconf/Zaptel/Xpp/Xbus.pm b/xpp/utils/zconf/Zaptel/Xpp/Xbus.pm index 57c93f5..a5fcf1e 100644 --- a/xpp/utils/zconf/Zaptel/Xpp/Xbus.pm +++ b/xpp/utils/zconf/Zaptel/Xpp/Xbus.pm @@ -8,7 +8,7 @@ package Zaptel::Xpp::Xbus; # $Id$ # use strict; -use XppUtils; +use Zaptel::Utils; use Zaptel::Xpp::Xpd; my $proc_base = "/proc/xpp"; diff --git a/xpp/utils/zconf/Zaptel/Xpp/Xpd.pm b/xpp/utils/zconf/Zaptel/Xpp/Xpd.pm index ef479fb..c05cfdb 100644 --- a/xpp/utils/zconf/Zaptel/Xpp/Xpd.pm +++ b/xpp/utils/zconf/Zaptel/Xpp/Xpd.pm @@ -8,7 +8,7 @@ package Zaptel::Xpp::Xpd; # $Id$ # use strict; -use XppUtils; +use Zaptel::Utils; my $proc_base = "/proc/xpp"; |