[asterisk-dev] [Code Review] chan_dahdi: Add dialtone_detect option
rmudgett
reviewboard at asterisk.org
Mon Mar 5 19:50:04 CST 2012
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviewboard.asterisk.org/r/1737/#review5739
-----------------------------------------------------------
Also added a note in CHANGES.
trunk/channels/chan_dahdi.c
<https://reviewboard.asterisk.org/r/1737/#comment10517>
I added an ast_channel_state(ast) == AST_STATE_UP test to this so the dialtone scanning timer will start running after the line answers. I also updated the chan_dahdi.conf.sample documentation to reflect this.
This makes it easier to figure out how long you should configure the line to look for dialtone.
- rmudgett
On March 5, 2012, 4:18 p.m., Jeremy Pepper wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviewboard.asterisk.org/r/1737/
> -----------------------------------------------------------
>
> (Updated March 5, 2012, 4:18 p.m.)
>
>
> Review request for Asterisk Developers.
>
>
> Summary
> -------
>
> chan_dahdi: Add dialtone_detect option
>
> This adds an option to chan_dahdi.conf called dialtone_detect. This can be set like this:
>
> dialtone_detect = yes ; Watch for dialtone for 10 seconds after answer
> dialtone_detect = always ; Watch for dialtone for the whole call
> dialtone_detect = 5000 ; Watch for dialtone for 5000ms
>
> If dialtone is detected on an inbound call, Asterisk will hang up the channel.
>
>
> This addresses bug ASTERISK-19316.
> https://issues.asterisk.org/jira/browse/ASTERISK-19316
>
>
> Diffs
> -----
>
> trunk/channels/chan_dahdi.c 358216
> trunk/configs/chan_dahdi.conf.sample 358216
>
> Diff: https://reviewboard.asterisk.org/r/1737/diff
>
>
> Testing
> -------
>
> This patch has been installed on an Asterisk box connected to another Asterisk box simulating an upstream carrier. Testing was done with dialtone_detect off, set to always, set to yes, and set to a custom value.
>
> Here's the relevant dialplan on the receiving side:
>
> [from-pstn]
> exten => s,1,Wait(5)
> exten => s,n,Answer
> exten => s,n,MusicOnHold
> exten => s,n,Hangup
>
> To trigger the issue this fixes, place a call to the test box, then hang up any time between when you see "Starting simple switch on 'DAHDI/1-1'" and when the call is answered.
>
>
> Thanks,
>
> Jeremy
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-dev/attachments/20120306/b8b3e553/attachment-0001.htm>
More information about the asterisk-dev
mailing list