[Asterisk-cvs] zaptel tor2.c,1.17,1.18 wct1xxp.c,1.16,1.17 wct4xxp.c,1.39,1.40 zaptel.c,1.67,1.68 zaptel.h,1.30,1.31 ztcfg.c,1.13,1.14
markster at lists.digium.com
markster at lists.digium.com
Fri Apr 16 13:55:55 CDT 2004
Update of /usr/cvsroot/zaptel
In directory mongoose.digium.com:/tmp/cvs-serv7926
Modified Files:
tor2.c wct1xxp.c wct4xxp.c zaptel.c zaptel.h ztcfg.c
Log Message:
Add support for E&M / E1
Index: tor2.c
===================================================================
RCS file: /usr/cvsroot/zaptel/tor2.c,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -d -r1.17 -r1.18
--- tor2.c 11 Jan 2004 17:10:47 -0000 1.17
+++ tor2.c 16 Apr 2004 17:59:07 -0000 1.18
@@ -307,7 +307,7 @@
struct zt_chan *mychans = tor->chans[x] + y;
sprintf(mychans->name, "Tor2/%d/%d/%d", tor->num, x + 1, y + 1);
mychans->sigcap = ZT_SIG_EM | ZT_SIG_CLEAR | ZT_SIG_FXSLS | ZT_SIG_FXSGS | ZT_SIG_FXSKS |
- ZT_SIG_FXOLS | ZT_SIG_FXOGS | ZT_SIG_FXOKS | ZT_SIG_CAS | ZT_SIG_SF;
+ ZT_SIG_FXOLS | ZT_SIG_FXOGS | ZT_SIG_FXOKS | ZT_SIG_CAS | ZT_SIG_SF | ZT_SIG_EM_E1;
c = (x * tor->spans[x].channels) + y;
mychans->pvt = &tor->tchans[c];
mychans->chanpos = y + 1;
Index: wct1xxp.c
===================================================================
RCS file: /usr/cvsroot/zaptel/wct1xxp.c,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -d -r1.16 -r1.17
--- wct1xxp.c 6 Jan 2004 13:26:44 -0000 1.16
+++ wct1xxp.c 16 Apr 2004 17:59:07 -0000 1.17
@@ -786,7 +786,7 @@
init_waitqueue_head(&wc->span.maintq);
for (x=0;x<wc->span.channels;x++) {
sprintf(wc->chans[x].name, "WCT1/%d/%d", wc->num, x + 1);
- wc->chans[x].sigcap = ZT_SIG_EM | ZT_SIG_CLEAR |
+ wc->chans[x].sigcap = ZT_SIG_EM | ZT_SIG_CLEAR | ZT_SIG_EM_E1 |
ZT_SIG_FXSLS | ZT_SIG_FXSGS |
ZT_SIG_FXSKS | ZT_SIG_FXOLS |
ZT_SIG_FXOGS | ZT_SIG_FXOKS | ZT_SIG_CAS | ZT_SIG_SF;
Index: wct4xxp.c
===================================================================
RCS file: /usr/cvsroot/zaptel/wct4xxp.c,v
retrieving revision 1.39
retrieving revision 1.40
diff -u -d -r1.39 -r1.40
--- wct4xxp.c 15 Apr 2004 22:23:43 -0000 1.39
+++ wct4xxp.c 16 Apr 2004 17:59:07 -0000 1.40
@@ -583,7 +583,7 @@
struct zt_chan *mychans = wc->chans[x] + y;
sprintf(mychans->name, "TE4/%d/%d/%d", wc->num, x + 1, y + 1);
mychans->sigcap = ZT_SIG_EM | ZT_SIG_CLEAR | ZT_SIG_FXSLS | ZT_SIG_FXSGS | ZT_SIG_FXSKS |
- ZT_SIG_FXOLS | ZT_SIG_FXOGS | ZT_SIG_FXOKS | ZT_SIG_CAS;
+ ZT_SIG_FXOLS | ZT_SIG_FXOGS | ZT_SIG_FXOKS | ZT_SIG_CAS | ZT_SIG_EM_E1;
c = (x * wc->spans[x].channels) + y;
mychans->pvt = wc;
mychans->chanpos = y + 1;
Index: zaptel.c
===================================================================
RCS file: /usr/cvsroot/zaptel/zaptel.c,v
retrieving revision 1.67
retrieving revision 1.68
diff -u -d -r1.67 -r1.68
--- zaptel.c 9 Apr 2004 17:55:31 -0000 1.67
+++ zaptel.c 16 Apr 2004 17:59:07 -0000 1.68
@@ -339,7 +339,7 @@
static struct zt_zone *tone_zones[ZT_TONE_ZONE_MAX];
-#define NUM_SIGS 9
+#define NUM_SIGS 10
static inline void rotate_sums(void)
@@ -367,7 +367,8 @@
{ ZT_SIG_FXOLS,0 | (ZT_ABIT << 8)},
{ ZT_SIG_FXOGS,ZT_BBIT | ((ZT_ABIT | ZT_BBIT) << 8)},
{ ZT_SIG_FXOKS,0 | (ZT_ABIT << 8)},
- { ZT_SIG_SF, 0}
+ { ZT_SIG_SF, 0},
+ { ZT_SIG_EM_E1, ZT_DBIT | (ZT_ABIT << 8) },
} ;
/* must have span to begin with */
@@ -405,6 +406,8 @@
return "FXOGS";
case ZT_SIG_EM:
return "E&M";
+ case ZT_SIG_EM_E1:
+ return "E&M-E1";
case ZT_SIG_CLEAR:
return "ClearChannel";
case ZT_SIG_HDLCRAW:
@@ -1768,6 +1771,8 @@
ZT_ABIT | ZT_BBIT | ZT_CBIT | ZT_DBIT,
ZT_ABIT | ZT_BBIT | ZT_CBIT | ZT_DBIT,
ZT_BBIT | ZT_CBIT | ZT_DBIT }, /* no signalling */
+ { ZT_SIG_EM_E1, ZT_DBIT, ZT_ABIT | ZT_BBIT | ZT_DBIT,
+ ZT_ABIT | ZT_BBIT | ZT_DBIT, ZT_DBIT }, /* E and M E1 */
} ;
int x;
@@ -4800,6 +4805,7 @@
chan->rxhooksig = rxsig;
switch(chan->sig) {
case ZT_SIG_EM: /* E and M */
+ case ZT_SIG_EM_E1:
switch(rxsig) {
case ZT_RXSIG_OFFHOOK: /* went off hook */
/* The interface is going off hook */
@@ -4924,6 +4930,7 @@
}
/* Fall through */
case ZT_SIG_EM: /* E and M */
+ case ZT_SIG_EM_E1:
case ZT_SIG_FXOLS: /* FXO Loopstart */
case ZT_SIG_FXOKS: /* FXO Kewlstart */
if (cursig & ZT_ABIT) /* off hook */
Index: zaptel.h
===================================================================
RCS file: /usr/cvsroot/zaptel/zaptel.h,v
retrieving revision 1.30
retrieving revision 1.31
diff -u -d -r1.30 -r1.31
--- zaptel.h 26 Mar 2004 07:44:19 -0000 1.30
+++ zaptel.h 16 Apr 2004 17:59:07 -0000 1.31
@@ -101,6 +101,7 @@
#define ZT_SIG_SF (1 << 14) /* Single Freq. tone only, no sig bits */
#define ZT_SIG_CAS (1 << 15) /* Just get bits */
#define ZT_SIG_DACS ((1 << 16) | ZT_SIG_CLEAR) /* Cross connect */
+#define ZT_SIG_EM_E1 (1 << 17) /* E1 E&M Variation */
/* tone flag values */
#define ZT_REVERSE_RXTONE 1 /* reverse polarity rx tone logic */
Index: ztcfg.c
===================================================================
RCS file: /usr/cvsroot/zaptel/ztcfg.c,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -d -r1.13 -r1.14
--- ztcfg.c 13 Jan 2004 17:11:34 -0000 1.13
+++ ztcfg.c 16 Apr 2004 17:59:07 -0000 1.14
@@ -403,6 +403,9 @@
if (!strcasecmp(keyword, "e&m")) {
sig[x] = "E & M";
cc[x].sigtype = ZT_SIG_EM;
+ } else if (!strcasecmp(keyword, "e&me1")) {
+ sig[x] = "E & M E1";
+ cc[x].sigtype = ZT_SIG_EM_E1;
} else if (!strcasecmp(keyword, "fxsls")) {
sig[x] = "FXS Loopstart";
cc[x].sigtype = ZT_SIG_FXSLS;
@@ -600,6 +603,7 @@
{ "loadzone", registerzone },
{ "defaultzone", defaultzone },
{ "e&m", chanconfig },
+ { "e&me1", chanconfig },
{ "fxsls", chanconfig },
{ "fxsgs", chanconfig },
{ "fxsks", chanconfig },
More information about the svn-commits
mailing list