[Pkg-voip-commits] r6846 - in /lcr/trunk/debian/patches: 00list 04_chan_lcr_dtmf.dpatch
dorchain-guest at alioth.debian.org
dorchain-guest at alioth.debian.org
Tue Mar 3 09:29:56 UTC 2009
Author: dorchain-guest
Date: Tue Mar 3 09:29:56 2009
New Revision: 6846
URL: http://svn.debian.org/wsvn/pkg-voip/?sc=1&rev=6846
Log:
Added patch for recognizing A-D dtmf tones in chan_lcr
Added:
lcr/trunk/debian/patches/04_chan_lcr_dtmf.dpatch
Modified:
lcr/trunk/debian/patches/00list
Modified: lcr/trunk/debian/patches/00list
URL: http://svn.debian.org/wsvn/pkg-voip/lcr/trunk/debian/patches/00list?rev=6846&op=diff
==============================================================================
--- lcr/trunk/debian/patches/00list (original)
+++ lcr/trunk/debian/patches/00list Tue Mar 3 09:29:56 2009
@@ -1,2 +1,3 @@
01_replace_local.dpatch
03_lcr_as_vbox.dpatch
+04_chan_lcr_dtmf.dpatch
Added: lcr/trunk/debian/patches/04_chan_lcr_dtmf.dpatch
URL: http://svn.debian.org/wsvn/pkg-voip/lcr/trunk/debian/patches/04_chan_lcr_dtmf.dpatch?rev=6846&op=file
==============================================================================
--- lcr/trunk/debian/patches/04_chan_lcr_dtmf.dpatch (added)
+++ lcr/trunk/debian/patches/04_chan_lcr_dtmf.dpatch Tue Mar 3 09:29:56 2009
@@ -1,0 +1,81 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## 04_chan_lcr_dtmf.dpatch by <joerg at Redstar.dorchain.net>
+##
+## All lines beginning with `## DP:' are a description of the patch.
+## DP: recognize DTMF A-D in chan lcr
+
+ at DPATCH@
+
+Date: Wed, 25 Feb 2009 17:40:04 +0100
+From: Ralf Schlatterbeck <ralf at zoo.priv.at>
+To: bensoup at free.fr, isdn4linux at listserv.isdn4linux.de
+Subject: Re: chan_lcr won't transmit some dtmf
+Message-ID: <20090225164004.GA15576 at priv.zoo>
+
+On Wed, Feb 25, 2009 at 05:02:45PM +0100, Ralf Schlatterbeck wrote:
+>
+> The attached patch fixes this problem which I was able to reproduce here
+> with chan_lcr version 1.3, the patch does two things
+> with the patch I'm able to receive DTMF A-D just fine with the asterisk
+> application "Read".
+Hmm, seems the convention in Asterisk is to send DTMF digits in
+uppercase. Instead of converting to lowercase and back to uppercase the
+following patch renames the "A" event (Answer) to "N" (think of it as
+"New call" or "aNswer".
+
+Signed-off-by: Ralf Schlatterbeck <rsc at runtux.com>
+
+--- a/chan_lcr.c.orig 2009-01-07 15:30:59.000000000 +0100
++++ b/chan_lcr.c 2009-02-25 17:38:07.000000000 +0100
+@@ -890,7 +890,7 @@
+ memcpy(&call->connectinfo, ¶m->connectinfo, sizeof(struct connect_info));
+ /* queue event to asterisk */
+ if (call->ast && call->pbx_started)
+- strncat(call->queue_string, "A", sizeof(call->queue_string)-1);
++ strncat(call->queue_string, "N", sizeof(call->queue_string)-1);
+ }
+
+ /*
+@@ -1507,7 +1507,7 @@
+ ast_queue_control(ast, AST_CONTROL_RINGING);
+ ast_setstate(ast, AST_STATE_RINGING);
+ break;
+- case 'A':
++ case 'N':
+ CDEBUG(call, ast, "Sending queued ANSWER to Asterisk.\n");
+ ast_queue_control(ast, AST_CONTROL_ANSWER);
+ break;
+@@ -1515,10 +1515,10 @@
+ CDEBUG(call, ast, "Sending queued HANGUP to Asterisk.\n");
+ ast_queue_hangup(ast);
+ break;
+- case '1': case '2': case '3': case 'a':
+- case '4': case '5': case '6': case 'b':
+- case '7': case '8': case '9': case 'c':
+- case '*': case '0': case '#': case 'd':
++ case '1': case '2': case '3': case 'A':
++ case '4': case '5': case '6': case 'B':
++ case '7': case '8': case '9': case 'C':
++ case '*': case '0': case '#': case 'D':
+ CDEBUG(call, ast, "Sending queued digit '%c' to Asterisk.\n", *p);
+ /* send digit to asterisk */
+ memset(&fr, 0, sizeof(fr));
+@@ -1530,7 +1530,7 @@
+ ast_queue_frame(ast, &fr);
+ break;
+ default:
+- CDEBUG(call, ast, "Ignoring queued digit 0x%02d.\n", *p);
++ CDEBUG(call, ast, "Ignoring queued digit 0x%02X.\n", *p);
+ }
+ p++;
+ }
+
+--
+Ralf Schlatterbeck
+email: ralf at zoo.priv.at FAX: +43/2243/26465/23
+
+_______________________________________________
+isdn4linux mailing list
+isdn4linux at listserv.isdn4linux.de
+https://www.isdn4linux.de/mailman/listinfo/isdn4linux
+
More information about the Pkg-voip-commits
mailing list