[svn-commits] trunk r1215 - in /trunk/xpp: card_fxs.c
init_data_3_20.cmd utils/genzaptelconf
svn-commits at lists.digium.com
svn-commits at lists.digium.com
Mon Jul 10 14:57:55 MST 2006
Author: tzafrir
Date: Mon Jul 10 16:57:55 2006
New Revision: 1215
URL: http://svn.digium.com/view/zaptel?rev=1215&view=rev
Log:
* Fix currents handling in driver.
* genzaptelconf: A simpler wait_for_xpp using new proc wait_for_xpds
* genzaptelconf: fixed confusion between framing and coding for E1/{il/nl}
Modified:
trunk/xpp/card_fxs.c
trunk/xpp/init_data_3_20.cmd
trunk/xpp/utils/genzaptelconf
Modified: trunk/xpp/card_fxs.c
URL: http://svn.digium.com/view/zaptel/trunk/xpp/card_fxs.c?rev=1215&r1=1214&r2=1215&view=diff
==============================================================================
--- trunk/xpp/card_fxs.c (original)
+++ trunk/xpp/card_fxs.c Mon Jul 10 16:57:55 2006
@@ -769,13 +769,6 @@
NOTICE("%s: %s/%s is not registered. Skipping.\n", __FUNCTION__, xbus->busname, xpd->xpdname);
return -ENODEV;
}
-#if 0
- Is this needed?
- for_each_line(xpd, i) {
- if(IS_SET(sig_toggles, i))
- do_chan_power(xpd->xbus, xpd, BIT(i), 0); // Power down (prevent overheating!!!)
- }
-#endif
for_each_line(xpd, i) {
if(IS_SET(xpd->digital_outputs, i) || IS_SET(xpd->digital_inputs, i))
continue;
@@ -783,6 +776,7 @@
struct zt_chan *chan = &xpd->span.chans[i];
xpd->ringing[i] = 0; // No more ringing...
+ do_chan_power(xpd->xbus, xpd, BIT(i), 0); // When not ringing, VBAT is always Low
MARK_BLINK(priv,i,LED_GREEN,0);
if(IS_SET(sig_status, i)) {
DBG("OFFHOOK: channo=%d\n", chan->channo);
Modified: trunk/xpp/init_data_3_20.cmd
URL: http://svn.digium.com/view/zaptel/trunk/xpp/init_data_3_20.cmd?rev=1215&r1=1214&r2=1215&view=diff
==============================================================================
--- trunk/xpp/init_data_3_20.cmd (original)
+++ trunk/xpp/init_data_3_20.cmd Mon Jul 10 16:57:55 2006
@@ -104,8 +104,9 @@
FF 00 00 00 WD 13 FF
FF 00 00 00 WD 14 FF
-; Automatic/Manual Control: defaults - Cancel Power Alarm
-FF 00 00 00 WD 43 1E
+; Automatic/Manual Control:
+; Manual BATL/BATH select. NOTE: bit 08 switches VBAT to Low AND to High!
+FF 00 00 00 WD 43 16
FF 00 00 00 WD 4A 31
FF 00 00 00 WD 4B 10
@@ -124,7 +125,8 @@
FF 00 00 00 WD 46 0B
; Loop Current Limit
-FF 00 00 00 WD 47 07
+; 23 milliampere for line current
+FF 00 00 00 WD 47 01
; Setting of SLICs offsets
Modified: trunk/xpp/utils/genzaptelconf
URL: http://svn.digium.com/view/zaptel/trunk/xpp/utils/genzaptelconf?rev=1215&r1=1214&r2=1215&view=diff
==============================================================================
--- trunk/xpp/utils/genzaptelconf (original)
+++ trunk/xpp/utils/genzaptelconf Mon Jul 10 16:57:55 2006
@@ -37,6 +37,8 @@
# * Fixed timeout for Astribank load
# * Delete unsuccessfully-probe modules
# * Pass callerid from trunks
+# * A simpler wait_for_xpp using new proc wait_for_xpds
+# * fixed confusion between framing and coding for E1/{il/nl}
# 0.5.2:
# * Now it should detect most PRI cards and even wcusb
# 0.5.1:
@@ -485,21 +487,8 @@
[ "`cat /sys/module/xpp/parameters/zap_autoreg`" = 'Y' ]
then
# wait for the XPDs to register:
- # TODO: replace this loop with 'cat /proc/xpp/XBUS-*/waitfor_xpds
- success=0
- for i in `seq 30`; do
- if ! grep -q 0 /proc/xpp/*/*/zt_registration 2>/dev/null
- then
- # There are either no XPDs or all of them are
- # registered. Nothing to do
- success=1
- break
- fi
- sleep 1
- done
- if [ "$success" = 0 ]; then
- echo 1>&2 "$0: WARNING: some XPD's are not registered yet (timeout)"
- fi
+ # TODO: improve error reporting and produce a messagee here
+ cat /proc/xpp/XBUS-*/wait_for_xpds 2>/dev/null >/dev/null || true
fi
}
@@ -723,15 +712,15 @@
case "$lc_country" in
nl)
# (Just an example for per-country info)
- echo 'ami' >$tmp_dir/span_framing
- echo 'ccs' >$tmp_dir/span_coding
+ echo 'ccs' >$tmp_dir/span_framing
+ echo 'ami' >$tmp_dir/span_coding
#echo 'crc4' >$tmp_dir/span_yellow
#echo 'euroisdn' >$tmp_dir/span_switchtype
#echo 'pri_cpe' >$tmp_dir/span_signalling
;;
il)
- echo 'hdb3' >$tmp_dir/span_framing
- echo 'ccs' >$tmp_dir/span_coding
+ echo 'ccs' >$tmp_dir/span_framing
+ echo 'hdb3' >$tmp_dir/span_coding
echo 'crc4' >$tmp_dir/span_yellow
echo 'euroisdn' >$tmp_dir/span_switchtype
esac
More information about the svn-commits
mailing list