[asterisk-commits] moy: branch moy/mfcr2 r115606 - /team/moy/mfcr2/channels/chan_zap.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Sun May 11 21:15:12 CDT 2008


Author: moy
Date: Sun May 11 21:15:12 2008
New Revision: 115606

URL: http://svn.digium.com/view/asterisk?view=rev&rev=115606
Log:
temporarily disable MF R2 main/dsp.c tone detection to use openr2 built-in detector

Modified:
    team/moy/mfcr2/channels/chan_zap.c

Modified: team/moy/mfcr2/channels/chan_zap.c
URL: http://svn.digium.com/view/asterisk/team/moy/mfcr2/channels/chan_zap.c?view=diff&rev=115606&r1=115605&r2=115606
==============================================================================
--- team/moy/mfcr2/channels/chan_zap.c (original)
+++ team/moy/mfcr2/channels/chan_zap.c Sun May 11 21:15:12 2008
@@ -1264,16 +1264,19 @@
 }
 
 static openr2_mflib_interface_t zt_r2_mf_iface = {
-	(openr2_mf_read_init_func)zt_r2_mf_rx_init,
+	/*(openr2_mf_read_init_func)zt_r2_mf_rx_init,*/
+	NULL,
 	(openr2_mf_write_init_func)zt_r2_mf_tx_init, 
 
-	(openr2_mf_detect_tone_func)zt_r2_mf_rx,
+	/*(openr2_mf_detect_tone_func)zt_r2_mf_rx,*/
+	NULL,
 	(openr2_mf_generate_tone_func)zt_r2_mf_tx,
 
 	(openr2_mf_select_tone_func)zt_r2_mf_tx_put,
 
 	(openr2_mf_want_generate_func)zt_r2_mf_want_generate,
-	(openr2_mf_read_dispose_func)zt_r2_mf_rx_dispose,
+	/*(openr2_mf_read_dispose_func)zt_r2_mf_rx_dispose,*/
+	NULL,
 	NULL
 };
 
@@ -1380,6 +1383,7 @@
 	} else {
 		ast_log(LOG_NOTICE, "Call accepted on forward channel %d\n", p->channel);
 		p->subs[SUB_REAL].needringing = 1;
+		p->dialing = 0;
 		/* chan_zap will take care of reading from now on, tell the library to forget about it */
 		openr2_chan_disable_read(r2chan);
 	}	
@@ -3007,6 +3011,7 @@
 			ast_log(LOG_WARNING, "Destiny number '%s' is shorter than stripmsd(%d)? hum, you should fix that. Assuming stripmsd = 0\n", c, strip);
 			strip = 0;
 		}
+		p->dialing = 1;
 		callres = openr2_chan_make_call(p->r2chan, l, (c + strip), zt_r2_get_channel_category(ast));
 		if (-1 == callres) {
 			ast_mutex_unlock(&p->lock);
@@ -8824,7 +8829,7 @@
 					/* TODO: should we check numchans overflow, or is it already done by zap? */
 					zap_r2->pvts[zap_r2->numchans++] = tmp;
 					tmp->r2chan = openr2_chan_new_from_fd(zap_r2->protocol_context, tmp->subs[SUB_REAL].zfd, 
-							&tmp->mf_tx_state, &tmp->mf_rx_state);
+							&tmp->mf_tx_state, NULL);
 					if (!tmp->r2chan) {
 						ast_log(LOG_ERROR, "Cannot create OpenR2 protocol context.\n");
 						destroy_zt_pvt(&tmp);




More information about the asterisk-commits mailing list