[Asterisk-cvs] zaptel zaptel.c, 1.111, 1.112 zaptel.h, 1.45, 1.46 zconfig.h, 1.18, 1.19

jim jim
Fri Aug 26 12:38:50 CDT 2005


Update of /usr/cvsroot/zaptel
In directory mongoose.digium.com:/tmp/cvs-serv7272

Modified Files:
	zaptel.c zaptel.h zconfig.h 
Log Message:
Added RINGBEGIN event (optionally)


Index: zaptel.c
===================================================================
RCS file: /usr/cvsroot/zaptel/zaptel.c,v
retrieving revision 1.111
retrieving revision 1.112
diff -u -d -r1.111 -r1.112
--- zaptel.c	31 Jul 2005 21:18:45 -0000	1.111
+++ zaptel.c	26 Aug 2005 16:40:29 -0000	1.112
@@ -5139,6 +5139,11 @@
 	if ((chan->flags & ZT_FLAG_SIGFREEZE)) return;
 
 	chan->rxhooksig = rxsig;
+#ifdef	RINGBEGIN
+	if ((chan->sig & __ZT_SIG_FXS) && (rxsig == ZT_RXSIG_RING) &&
+	    (!chan->ringdebtimer))
+		__qevent(chan,ZT_EVENT_RINGBEGIN);  
+#endif
 	switch(chan->sig) {
 	    case ZT_SIG_EM:  /* E and M */
 	    case ZT_SIG_EM_E1:

Index: zaptel.h
===================================================================
RCS file: /usr/cvsroot/zaptel/zaptel.h,v
retrieving revision 1.45
retrieving revision 1.46
diff -u -d -r1.45 -r1.46
--- zaptel.h	24 Aug 2005 21:08:30 -0000	1.45
+++ zaptel.h	26 Aug 2005 16:40:29 -0000	1.46
@@ -804,6 +804,9 @@
 /* Timer event -- ping ready */
 #define ZT_EVENT_TIMER_PING		16
 
+/* Ring Begin event */
+#define ZT_EVENT_RINGBEGIN  18
+
 /* Polarity reversal event */
 #define ZT_EVENT_POLARITY  17
 

Index: zconfig.h
===================================================================
RCS file: /usr/cvsroot/zaptel/zconfig.h,v
retrieving revision 1.18
retrieving revision 1.19
diff -u -d -r1.18 -r1.19
--- zconfig.h	24 Aug 2005 21:08:30 -0000	1.18
+++ zconfig.h	26 Aug 2005 16:40:29 -0000	1.19
@@ -140,4 +140,11 @@
  */
 /* #define EMFLASH */
 
+/* 
+ * Comment out the following if you dont want events to indicate the
+ * beginning of an incomming ring. Most non-asterisk applications will
+ * want this commented out.
+ */
+/* #define RINGBEGIN */
+
 #endif




More information about the svn-commits mailing list