[asterisk-dev] [dahdi-commits] sruffell: linux/trunk r9597 - /linux/trunk/drivers/dahdi/

Kevin P. Fleming kpfleming at digium.com
Tue Jan 4 13:07:03 CST 2011


On 01/03/2011 12:27 PM, SVN commits to the DAHDI project wrote:
> Author: sruffell
> Date: Mon Jan  3 12:27:23 2011
> New Revision: 9597
>
> URL: http://svnview.digium.com/svn/dahdi?view=rev&rev=9597
> Log:
> dahdi: Move the contents of digits.h directly into dahdi-base.c
>
> Clarify that these definitions are not / no longer used outside
> dahdi-base.c.

I'm not sure this is a good idea; before, there was a very logical place 
for a user to change these defaults if they so desired, and if they had 
a patch they would apply for that purpose, it would be fairly stable 
since the file being patched rarely ever sees changes. Now they'll have 
to create a patch against dahdi-base.c, and keep it updated.

These constants were not in a header file because they were shared among 
multiple code files, they were there for the convenience of users who 
may want to change them.

>
> Signed-off-by: Shaun Ruffell<sruffell at digium.com>
> Acked-by: Kinsey Moore<kmoore at digium.com>
>
> Removed:
>      linux/trunk/drivers/dahdi/digits.h
> Modified:
>      linux/trunk/drivers/dahdi/dahdi-base.c
>
> Modified: linux/trunk/drivers/dahdi/dahdi-base.c
> URL: http://svnview.digium.com/svn/dahdi/linux/trunk/drivers/dahdi/dahdi-base.c?view=diff&rev=9597&r1=9596&r2=9597
> ==============================================================================
> --- linux/trunk/drivers/dahdi/dahdi-base.c (original)
> +++ linux/trunk/drivers/dahdi/dahdi-base.c Mon Jan  3 12:27:23 2011
> @@ -287,7 +287,30 @@
>   	DIGIT_MODE_MFR2_REV,
>   };
>
> -#include "digits.h"
> +#define DEFAULT_DTMF_LENGTH	(100 * DAHDI_CHUNKSIZE)
> +#define DEFAULT_MFR1_LENGTH	(68 * DAHDI_CHUNKSIZE)
> +#define DEFAULT_MFR2_LENGTH	(100 * DAHDI_CHUNKSIZE)
> +#define PAUSE_LENGTH		(500 * DAHDI_CHUNKSIZE)
> +
> +/* At the end of silence, the tone stops */
> +static struct dahdi_tone dtmf_silence = {
> +	.tonesamples = DEFAULT_DTMF_LENGTH,
> +};
> +
> +/* At the end of silence, the tone stops */
> +static struct dahdi_tone mfr1_silence = {
> +	.tonesamples = DEFAULT_MFR1_LENGTH,
> +};
> +
> +/* At the end of silence, the tone stops */
> +static struct dahdi_tone mfr2_silence = {
> +	.tonesamples = DEFAULT_MFR2_LENGTH,
> +};
> +
> +/* A pause in the dialing */
> +static struct dahdi_tone tone_pause = {
> +	.tonesamples = PAUSE_LENGTH,
> +};
>
>   static struct dahdi_dialparams global_dialparams = {
>   	.dtmf_tonelen = DEFAULT_DTMF_LENGTH,
>
>
> --
> _____________________________________________________________________
> -- Bandwidth and Colocation Provided by http://www.api-digital.com --
>
> dahdi-commits mailing list
> To UNSUBSCRIBE or update options visit:
>     http://lists.digium.com/mailman/listinfo/dahdi-commits


-- 
Kevin P. Fleming
Digium, Inc. | Director of Software Technologies
445 Jan Davis Drive NW - Huntsville, AL 35806 - USA
skype: kpfleming | jabber: kfleming at digium.com
Check us out at www.digium.com & www.asterisk.org



More information about the asterisk-dev mailing list